Untether LabsDevelopers

Upload Demand Forecast

posthttps://app.untetherlabs.com/api/v1/forecasting/demand

Upload demand forecasts for one or more roles.

Demand is the number of staff needed during a 15-minute window, the same staffing level consumed by the autoscheduler and coverage metrics. A row spanning more than 15 minutes applies its demand to every 15-minute window in its range: a day-long row with a demand of 4 means 4 staff are needed throughout that day.

startDate and endDate must be ISO-8601 strings with an explicit timezone offset and fall on 15-minute boundaries (:00, :15, :30 or :45). Rows may be supplied in any order, but rows for the same role and axis values must not overlap; overlapping rows that differ in an axis value (e.g. one per language) express concurrent demand and sum in unfiltered views. There is no limit on the range a request may cover: contiguous rows with the same demand are stored as one range.

Any existing forecast data between each role's first startDate and last endDate is replaced.

The body may be sent as application/json, or as text/csv with a header row containing the columns: role, startDate, endDate, demand. A role whose demand config defines skill axes accepts each axis as an extra optional column (the skill name lowercased, spaces as underscores). Other extra columns are ignored and echoed back in ignoredColumns; a value that is not one of a configured axis skill's values is rejected.

Request body#

UploadDemandForecastRow[]
roleuuid
Required
startDatestring
Required
endDatestring
Required
demandnumber· min 0
Required

Response 201#

ignoredColumnsstring[]
Required

Errors#

Input validation failed.

Show extension members
pathstring
messagestring
Required

A specified role does not exist in the system.