Schedule
curl --request GET \
--url https://api.sortx.co.uk/planned-maintenance/schedule \
--header 'x-api-key: <api-key>'const options = {method: 'GET', headers: {'x-api-key': '<api-key>'}};
fetch('https://api.sortx.co.uk/planned-maintenance/schedule', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));import requests
url = "https://api.sortx.co.uk/planned-maintenance/schedule"
headers = {"x-api-key": "<api-key>"}
response = requests.get(url, headers=headers)
print(response.text){
"today": "<string>",
"kpis": {
"overdue": {
"count": 123,
"oldestDays": 123
},
"dueThisMonth": {
"count": 123,
"booked": 123
},
"next90Days": {
"count": 123,
"properties": 123
},
"estimatedCost90Days": {
"totalMinor": 123,
"needsApprovalMinor": 123
}
},
"tabs": {
"all": 123,
"notBooked": 123,
"awaitingApproval": 123,
"booked": 123
},
"tab": "all",
"groups": [
{
"key": "<string>",
"label": "<string>",
"count": 123,
"jobs": [
{
"key": "<string>",
"source": "cycle",
"id": "<string>",
"title": "<string>",
"propertyId": "<string>",
"blockId": "<string>",
"addressLine": "<string>",
"area": "<string>",
"sourceLabel": "<string>",
"cycleId": "<string>",
"programmeId": "<string>",
"contractorContactId": "<string>",
"contractorName": "<string>",
"dueOn": "<string>",
"overdue": true,
"estCostMinor": 123,
"status": "assign",
"approvalState": "required",
"tenantNotifiedAt": "<string>",
"accessRefusedAt": "<string>",
"accessRefusedReason": "<string>",
"skippable": true,
"booking": {
"date": "<string>",
"startMinute": 123,
"endMinute": 123
},
"budgetLineId": "<string>",
"revision": 123
}
]
}
],
"calendar": {
"month": "<string>",
"days": [
{
"date": "<string>",
"due": 123,
"overdue": 123
}
],
"day": {
"date": "<string>",
"items": [
{
"key": "<string>",
"title": "<string>",
"addressLine": "<string>",
"startMinute": 123,
"endMinute": 123,
"overdue": true
}
]
}
}
}{
"_tag": "TenantCreateRejected",
"reason": "<string>",
"field": "<string>"
}{
"_tag": "Unauthenticated"
}{
"_tag": "TenantSuspended",
"tenantId": "<string>",
"reason": "<string>"
}{
"_tag": "EntitlementMissing",
"tenantId": "<string>",
"moduleId": "<string>"
}{
"_tag": "TenantNotFound",
"slug": "<string>"
}{
"_tag": "WebhookDuplicate",
"integration": "<string>",
"externalId": "<string>"
}{
"_tag": "RateLimited",
"key": "<string>",
"retryAfterSeconds": 123,
"message": "<string>"
}{
"_tag": "IntegrationUnavailable",
"integration": "<string>",
"detail": "<string>"
}planned-maintenance
Schedule
The Schedule: every open job from cycles and works programmes due in the next 90 days (and overdue), grouped, with KPIs, tab counts and a month calendar
GET
/
planned-maintenance
/
schedule
Schedule
curl --request GET \
--url https://api.sortx.co.uk/planned-maintenance/schedule \
--header 'x-api-key: <api-key>'const options = {method: 'GET', headers: {'x-api-key': '<api-key>'}};
fetch('https://api.sortx.co.uk/planned-maintenance/schedule', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));import requests
url = "https://api.sortx.co.uk/planned-maintenance/schedule"
headers = {"x-api-key": "<api-key>"}
response = requests.get(url, headers=headers)
print(response.text){
"today": "<string>",
"kpis": {
"overdue": {
"count": 123,
"oldestDays": 123
},
"dueThisMonth": {
"count": 123,
"booked": 123
},
"next90Days": {
"count": 123,
"properties": 123
},
"estimatedCost90Days": {
"totalMinor": 123,
"needsApprovalMinor": 123
}
},
"tabs": {
"all": 123,
"notBooked": 123,
"awaitingApproval": 123,
"booked": 123
},
"tab": "all",
"groups": [
{
"key": "<string>",
"label": "<string>",
"count": 123,
"jobs": [
{
"key": "<string>",
"source": "cycle",
"id": "<string>",
"title": "<string>",
"propertyId": "<string>",
"blockId": "<string>",
"addressLine": "<string>",
"area": "<string>",
"sourceLabel": "<string>",
"cycleId": "<string>",
"programmeId": "<string>",
"contractorContactId": "<string>",
"contractorName": "<string>",
"dueOn": "<string>",
"overdue": true,
"estCostMinor": 123,
"status": "assign",
"approvalState": "required",
"tenantNotifiedAt": "<string>",
"accessRefusedAt": "<string>",
"accessRefusedReason": "<string>",
"skippable": true,
"booking": {
"date": "<string>",
"startMinute": 123,
"endMinute": 123
},
"budgetLineId": "<string>",
"revision": 123
}
]
}
],
"calendar": {
"month": "<string>",
"days": [
{
"date": "<string>",
"due": 123,
"overdue": 123
}
],
"day": {
"date": "<string>",
"items": [
{
"key": "<string>",
"title": "<string>",
"addressLine": "<string>",
"startMinute": 123,
"endMinute": 123,
"overdue": true
}
]
}
}
}{
"_tag": "TenantCreateRejected",
"reason": "<string>",
"field": "<string>"
}{
"_tag": "Unauthenticated"
}{
"_tag": "TenantSuspended",
"tenantId": "<string>",
"reason": "<string>"
}{
"_tag": "EntitlementMissing",
"tenantId": "<string>",
"moduleId": "<string>"
}{
"_tag": "TenantNotFound",
"slug": "<string>"
}{
"_tag": "WebhookDuplicate",
"integration": "<string>",
"externalId": "<string>"
}{
"_tag": "RateLimited",
"key": "<string>",
"retryAfterSeconds": 123,
"message": "<string>"
}{
"_tag": "IntegrationUnavailable",
"integration": "<string>",
"detail": "<string>"
}