Model Runs
List runs for a model
Returns a paginated list of runs for the model, ordered by creation time descending. By default only completed runs are returned.
Parameters
idstringrequired
axisstring[]key:value, split at the first :. Repeat the parameter with one axis to accept any listed choice, or across axes to require all; an unknown key or a value you may not read is a 400.sensitivitystringbase for base runs only, or pass a sensitivity id to filter to that variant. Omit to include every sensitivity.statusstringpending,running,failed). Defaults to completed.beforestringrunDatetime is before this ISO 8601 instant.afterstringrunDatetime is after this ISO 8601 instant.cursorstringnextCursor from a previous page.limitnumberReturns
dataModelRun[]nextCursorstring | nullcursor query parameter on the next request.hasMorebooleanError codes
data.issues names each offending param and the accepted values.curl "https://api.v2.pd4castr.com.au/v1/model/d2f4e0c0-1c1a-4f7c-9b6c-3a4f2c1c1f8d/run?axis=ref_year:2015&sensitivity={sensitivity}&status=completed&before={before}&after={after}&cursor={cursor}&limit={limit}" \
-H "Authorization: Bearer $PD4CASTR_TOKEN"{
"data": [
{
"id": "6ee9f6b4-7d31-4d51-8f8c-bd5f9b1f0d5e",
"status": "completed",
"modelId": "d2f4e0c0-1c1a-4f7c-9b6c-3a4f2c1c1f8d",
"createdAt": "2026-04-12T03:14:15.000Z",
"runDatetime": "2026-04-12T00:00:00.000Z",
"startedAt": "2026-04-12T03:14:25.000Z",
"completedAt": "2026-04-12T03:15:08.000Z",
"erroredAt": null,
"sensitivity": null,
"axisValues": null,
"error": null,
"containerId": "365abb96b5f9400eb1f4b346480a9b25",
"hasAggregationErrors": false,
"outputMetadata": {
"rowCount": 8760,
"columns": [
{
"name": "forecast_datetime",
"type": "date"
},
{
"name": "vic1",
"type": "float"
},
{
"name": "nsw1",
"type": "float"
}
],
"datetimeRange": {
"column": "forecast_datetime",
"min": "2026-04-12T00:00:00.000Z",
"max": "2027-04-11T23:00:00.000Z"
},
"sizeBytes": 184754,
"computedAt": "2026-04-12T03:15:20.000Z"
}
},
{
"id": "5dd8e5a3-6c20-3d40-7e7b-ac4e8a0e9c4d",
"status": "completed",
"modelId": "d2f4e0c0-1c1a-4f7c-9b6c-3a4f2c1c1f8d",
"createdAt": "2026-04-11T03:14:15.000Z",
"runDatetime": "2026-04-11T00:00:00.000Z",
"startedAt": "2026-04-11T03:14:23.000Z",
"completedAt": "2026-04-11T03:15:02.000Z",
"erroredAt": null,
"sensitivity": null,
"axisValues": null,
"error": null,
"containerId": "365abb96b5f9400eb1f4b346480a9b25",
"hasAggregationErrors": false,
"outputMetadata": {
"rowCount": 8760,
"columns": [
{
"name": "forecast_datetime",
"type": "date"
},
{
"name": "vic1",
"type": "float"
},
{
"name": "nsw1",
"type": "float"
}
],
"datetimeRange": {
"column": "forecast_datetime",
"min": "2026-04-12T00:00:00.000Z",
"max": "2027-04-11T23:00:00.000Z"
},
"sizeBytes": 184754,
"computedAt": "2026-04-12T03:15:20.000Z"
}
}
],
"nextCursor": "eyJjcmVhdGVkQXQiOiIyMDI2LTA0LTExVDAzOjE0OjE1WiIsImlkIjoiNWRkIn0",
"hasMore": true
}Get the latest output
Convenience endpoint that returns the completed run's output for the newest run datetime, optionally with comparison runs. By default, restricts to base runs (no sensitivity). axis params select a run variant; without them, the run is the default variant's base run.
Parameters
idstringrequired
axisstring[]key:value, split at the first :. Repeat the parameter to name several axes; an axis you omit resolves to its default, or to the first value your organisation may read. Values parse per the axis type declared on the model. Naming one key twice, an unknown key, or a value you may not read is a 400.comparisonModelstring[]sensitivitystringbase for base runs only, or a sensitivity id to fetch that variant. Defaults to base.Returns
runModelRunWithOutputcomparisonRunsRecord<string, ModelRunWithOutput>comparisonModel query parameters were supplied.Error codes
data.issues names each offending param and the accepted values.curl "https://api.v2.pd4castr.com.au/v1/model/d2f4e0c0-1c1a-4f7c-9b6c-3a4f2c1c1f8d/run/latest/output?axis=ref_year:2015&comparisonModel={comparisonModel}&sensitivity={sensitivity}" \
-H "Authorization: Bearer $PD4CASTR_TOKEN"{
"run": {
"id": "6ee9f6b4-7d31-4d51-8f8c-bd5f9b1f0d5e",
"runDatetime": "2026-04-12T00:00:00.000Z",
"sensitivity": null,
"axisValues": null,
"model": {
"id": "d2f4e0c0-1c1a-4f7c-9b6c-3a4f2c1c1f8d",
"displayName": "Demand Forecast (30min)",
"displayTimezone": "Australia/Sydney",
"revision": 0
},
"colours": {
"price": "#1f77b4"
},
"data": [
{
"forecast_datetime": "2026-04-12T00:30:00.000Z",
"price": 84.12
},
{
"forecast_datetime": "2026-04-12T01:00:00.000Z",
"price": 81.07
},
{
"forecast_datetime": "2026-04-12T01:30:00.000Z",
"price": 79.55
}
]
},
"comparisonRuns": {}
}Get the latest run
Convenience endpoint that returns the completed run for the newest run datetime. By default, restricts to base runs (no sensitivity). axis params select a run variant; without them, the run is the default variant's base run.
Parameters
idstringrequired
axisstring[]key:value, split at the first :. Repeat the parameter to name several axes; an axis you omit resolves to its default, or to the first value your organisation may read. Values parse per the axis type declared on the model. Naming one key twice, an unknown key, or a value you may not read is a 400.sensitivitystringbase for base runs only, or a sensitivity id to fetch that variant. Defaults to base.Returns
idstringstatus"pending" | "input_files_prepared" | "running" | "completed" | "failed"modelIdstringcreatedAtstringrunDatetimestringstartedAtstring | nullcompletedAtstring | nullerroredAtstring | nullsensitivitySensitivity | nullaxisValuesRecord<string, unknown> | nullerrorstring | nullcontainerIdstring | nullhasAggregationErrorsbooleanoutputMetadataRunDataMetadata | nullError codes
data.issues names each offending param and the accepted values.curl "https://api.v2.pd4castr.com.au/v1/model/d2f4e0c0-1c1a-4f7c-9b6c-3a4f2c1c1f8d/run/latest?axis=ref_year:2015&sensitivity={sensitivity}" \
-H "Authorization: Bearer $PD4CASTR_TOKEN"{
"id": "6ee9f6b4-7d31-4d51-8f8c-bd5f9b1f0d5e",
"status": "completed",
"modelId": "d2f4e0c0-1c1a-4f7c-9b6c-3a4f2c1c1f8d",
"createdAt": "2026-04-12T03:14:15.000Z",
"runDatetime": "2026-04-12T00:00:00.000Z",
"startedAt": "2026-04-12T03:14:25.000Z",
"completedAt": "2026-04-12T03:15:08.000Z",
"erroredAt": null,
"sensitivity": null,
"axisValues": null,
"error": null,
"containerId": "365abb96b5f9400eb1f4b346480a9b25",
"hasAggregationErrors": false,
"outputMetadata": {
"rowCount": 8760,
"columns": [
{
"name": "forecast_datetime",
"type": "date"
},
{
"name": "vic1",
"type": "float"
},
{
"name": "nsw1",
"type": "float"
}
],
"datetimeRange": {
"column": "forecast_datetime",
"min": "2026-04-12T00:00:00.000Z",
"max": "2027-04-11T23:00:00.000Z"
},
"sizeBytes": 184754,
"computedAt": "2026-04-12T03:15:20.000Z"
}
}Get a run's output
Fetches the forecast output for a completed run, optionally with comparison runs.
Parameters
idstringrequired
runIdstringrequired
comparisonModelstring[]Returns
runModelRunWithOutputcomparisonRunsRecord<string, ModelRunWithOutput>comparisonModel query parameters were supplied.Error codes
curl "https://api.v2.pd4castr.com.au/v1/model/d2f4e0c0-1c1a-4f7c-9b6c-3a4f2c1c1f8d/run/6ee9f6b4-7d31-4d51-8f8c-bd5f9b1f0d5e/output?comparisonModel={comparisonModel}" \
-H "Authorization: Bearer $PD4CASTR_TOKEN"{
"run": {
"id": "6ee9f6b4-7d31-4d51-8f8c-bd5f9b1f0d5e",
"runDatetime": "2026-04-12T00:00:00.000Z",
"sensitivity": null,
"axisValues": null,
"model": {
"id": "d2f4e0c0-1c1a-4f7c-9b6c-3a4f2c1c1f8d",
"displayName": "Demand Forecast (30min)",
"displayTimezone": "Australia/Sydney",
"revision": 0
},
"colours": {
"price": "#1f77b4"
},
"data": [
{
"forecast_datetime": "2026-04-12T00:30:00.000Z",
"price": 84.12
},
{
"forecast_datetime": "2026-04-12T01:00:00.000Z",
"price": 81.07
},
{
"forecast_datetime": "2026-04-12T01:30:00.000Z",
"price": 79.55
}
]
},
"comparisonRuns": {}
}Run a view
Runs one of the model's published views against a completed run with the given parameter values and returns the result rows with their columns. A parameter left out resolves from the view's default or the run's axis values.
Parameters
idstringrequired
runIdstringrequired
viewIdstringrequired
Request body
Content type: application/json
paramsRecord<string, unknown | null>key. A parameter you leave out resolves from the view's default or the run's axis values.Returns
columnsModelViewResultColumn[]rowsobject[]key.resolvedParamsRecord<string, unknown | null>null where nothing resolved.fromCachebooleanError codes
curl -X POST "https://api.v2.pd4castr.com.au/v1/model/d2f4e0c0-1c1a-4f7c-9b6c-3a4f2c1c1f8d/run/6ee9f6b4-7d31-4d51-8f8c-bd5f9b1f0d5e/views/9c1d6c9f-0a8e-4f7c-9b6c-3a4f2c1c1f8d/run" \
-H "Authorization: Bearer $PD4CASTR_TOKEN" \
-H "Content-Type: application/json" \
-d '{"params":{"region":"NSW1"}}'{
"columns": [
{
"key": "region",
"type": "string",
"role": "dimension",
"label": "Region",
"unit": null,
"format": null
},
{
"key": "price",
"type": "number",
"role": "measure",
"label": "Price",
"unit": "AUD/MWh",
"format": "currency"
}
],
"rows": [
{
"region": "NSW1",
"price": 84.12
},
{
"region": "VIC1",
"price": 81.07
}
],
"resolvedParams": {
"region": "NSW1"
},
"fromCache": false
}Get a run's input file
Returns the input file the run consumed under inputKey, exactly as the model read it and in the format format on the model input. Set link=true to receive a signed, time-limited download link instead of the file. Available only for input keys your organisation has been granted.
Parameters
idstringrequired
runIdstringrequired
inputKeystringrequired
linkbooleanexpiresAt. Defaults to false.Returns
The input file, or the download link when link=true. The Content-Type follows the input format: application/json, text/csv or application/vnd.apache.parquet for the file, application/json for the link.
idstringkeystringformat"json" | "csv" | "parquet"urlstringexpiresAt.expiresAtstringmetadataRunDataMetadata | nullError codes
link is not a boolean. data.issues names the offending param.inputKey that your organisation may read.curl "https://api.v2.pd4castr.com.au/v1/model/d2f4e0c0-1c1a-4f7c-9b6c-3a4f2c1c1f8d/run/6ee9f6b4-7d31-4d51-8f8c-bd5f9b1f0d5e/input/demand_forecast?link=false" \
-H "Authorization: Bearer $PD4CASTR_TOKEN"{
"id": "b2f4e0c0-1c1a-4f7c-9b6c-3a4f2c1c1f8d",
"key": "demand_forecast",
"format": "json",
"url": "https://pd4castr-model-run-inputs.s3.ap-southeast-2.amazonaws.com/runs/6ee9f6b4-7d31-4d51-8f8c-bd5f9b1f0d5e/b2f4e0c0-1c1a-4f7c-9b6c-3a4f2c1c1f8d.json?X-Amz-Expires=1800&X-Amz-Signature=…",
"expiresAt": "2026-04-12T00:30:00.000Z",
"metadata": {
"rowCount": 17520,
"columns": [
{
"name": "settlement_date",
"type": "TIMESTAMP"
},
{
"name": "demand_mw",
"type": "DOUBLE"
}
],
"datetimeRange": {
"column": "settlement_date",
"min": "2026-04-12T00:00:00.000Z",
"max": "2026-04-12T23:30:00.000Z"
},
"sizeBytes": 4096,
"computedAt": "2026-04-12T00:05:00.000Z"
}
}Get a run
Returns a single run by its unique id.
Parameters
idstringrequired
runIdstringrequired
Returns
idstringstatus"pending" | "input_files_prepared" | "running" | "completed" | "failed"modelIdstringcreatedAtstringrunDatetimestringstartedAtstring | nullcompletedAtstring | nullerroredAtstring | nullsensitivitySensitivity | nullaxisValuesRecord<string, unknown> | nullerrorstring | nullcontainerIdstring | nullhasAggregationErrorsbooleanoutputMetadataRunDataMetadata | nullError codes
curl "https://api.v2.pd4castr.com.au/v1/model/d2f4e0c0-1c1a-4f7c-9b6c-3a4f2c1c1f8d/run/6ee9f6b4-7d31-4d51-8f8c-bd5f9b1f0d5e" \
-H "Authorization: Bearer $PD4CASTR_TOKEN"{
"id": "6ee9f6b4-7d31-4d51-8f8c-bd5f9b1f0d5e",
"status": "completed",
"modelId": "d2f4e0c0-1c1a-4f7c-9b6c-3a4f2c1c1f8d",
"createdAt": "2026-04-12T03:14:15.000Z",
"runDatetime": "2026-04-12T00:00:00.000Z",
"startedAt": "2026-04-12T03:14:25.000Z",
"completedAt": "2026-04-12T03:15:08.000Z",
"erroredAt": null,
"sensitivity": null,
"axisValues": null,
"error": null,
"containerId": "365abb96b5f9400eb1f4b346480a9b25",
"hasAggregationErrors": false,
"outputMetadata": {
"rowCount": 8760,
"columns": [
{
"name": "forecast_datetime",
"type": "date"
},
{
"name": "vic1",
"type": "float"
},
{
"name": "nsw1",
"type": "float"
}
],
"datetimeRange": {
"column": "forecast_datetime",
"min": "2026-04-12T00:00:00.000Z",
"max": "2027-04-11T23:00:00.000Z"
},
"sizeBytes": 184754,
"computedAt": "2026-04-12T03:15:20.000Z"
}
}