Skip to main content
POST
/
platform
/
v2
/
sites
/
models
/
train
Train Site Models
import requests

url = "https://api.rebase.energy/platform/v2/sites/models/train"

payload = { "site_ids": ["48302759-0371-4d54-9ba1-506708b576fe", "f02918ab-736b-409f-8f86-cbbeec1d6700"] }
headers = {
    "Authorization": "<api-key>",
    "Content-Type": "application/json"
}

response = requests.post(url, json=payload, headers=headers)

print(response.text)
{}

Authorizations

Authorization
string
header
required

Your API key. This is required to access our API programatically. You can view your API key in the Rebase dashboard.

Body

application/json
site_ids
string[]
required
Example:
[
"48302759-0371-4d54-9ba1-506708b576fe",
"f02918ab-736b-409f-8f86-cbbeec1d6700"
]
output_backtest_data
boolean
default:false

If true, backtest forecasts will be generated for the period of the training data

Example:

false

splits
TrainRange · object[]
Example:
[
{
"end_date": "2023-08-01T00:00Z",
"start_date": "2023-01-01T00:00Z"
},
{
"end_date": "2024-01-01T00:00Z",
"start_date": "2023-10-01T00:00Z"
}
]
wait
boolean
default:false

If true, the request will wait until the training is completed before returning

Response

Successful Response

The response is of type Response Train Site Models Platform V2 Sites Models Train Post · object.