curl --request POST \
--url https://api.ionworks.com/ecm/validate \
--header 'Content-Type: application/json' \
--data '
{
"measurement_id": "<string>",
"example_id": "<string>",
"start_step": 123,
"end_step": 123,
"initial_soc": 0.5,
"capacity": 1,
"fit_results": {
"soc": [
123
],
"ocv": [
123
],
"r0": [
123
],
"rc_pairs": [
{
"r": [
123
],
"c": [
123
],
"tau": [
123
]
}
],
"capacity_Ah": [
123
]
},
"parameterized_model_id": "<string>"
}
'import requests
url = "https://api.ionworks.com/ecm/validate"
payload = {
"measurement_id": "<string>",
"example_id": "<string>",
"start_step": 123,
"end_step": 123,
"initial_soc": 0.5,
"capacity": 1,
"fit_results": {
"soc": [123],
"ocv": [123],
"r0": [123],
"rc_pairs": [
{
"r": [123],
"c": [123],
"tau": [123]
}
],
"capacity_Ah": [123]
},
"parameterized_model_id": "<string>"
}
headers = {"Content-Type": "application/json"}
response = requests.post(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'POST',
headers: {'Content-Type': 'application/json'},
body: JSON.stringify({
measurement_id: '<string>',
example_id: '<string>',
start_step: 123,
end_step: 123,
initial_soc: 0.5,
capacity: 1,
fit_results: {
soc: [123],
ocv: [123],
r0: [123],
rc_pairs: [{r: [123], c: [123], tau: [123]}],
capacity_Ah: [123]
},
parameterized_model_id: '<string>'
})
};
fetch('https://api.ionworks.com/ecm/validate', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://api.ionworks.com/ecm/validate",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "POST",
CURLOPT_POSTFIELDS => json_encode([
'measurement_id' => '<string>',
'example_id' => '<string>',
'start_step' => 123,
'end_step' => 123,
'initial_soc' => 0.5,
'capacity' => 1,
'fit_results' => [
'soc' => [
123
],
'ocv' => [
123
],
'r0' => [
123
],
'rc_pairs' => [
[
'r' => [
123
],
'c' => [
123
],
'tau' => [
123
]
]
],
'capacity_Ah' => [
123
]
],
'parameterized_model_id' => '<string>'
]),
CURLOPT_HTTPHEADER => [
"Content-Type: application/json"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"strings"
"net/http"
"io"
)
func main() {
url := "https://api.ionworks.com/ecm/validate"
payload := strings.NewReader("{\n \"measurement_id\": \"<string>\",\n \"example_id\": \"<string>\",\n \"start_step\": 123,\n \"end_step\": 123,\n \"initial_soc\": 0.5,\n \"capacity\": 1,\n \"fit_results\": {\n \"soc\": [\n 123\n ],\n \"ocv\": [\n 123\n ],\n \"r0\": [\n 123\n ],\n \"rc_pairs\": [\n {\n \"r\": [\n 123\n ],\n \"c\": [\n 123\n ],\n \"tau\": [\n 123\n ]\n }\n ],\n \"capacity_Ah\": [\n 123\n ]\n },\n \"parameterized_model_id\": \"<string>\"\n}")
req, _ := http.NewRequest("POST", url, payload)
req.Header.Add("Content-Type", "application/json")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.post("https://api.ionworks.com/ecm/validate")
.header("Content-Type", "application/json")
.body("{\n \"measurement_id\": \"<string>\",\n \"example_id\": \"<string>\",\n \"start_step\": 123,\n \"end_step\": 123,\n \"initial_soc\": 0.5,\n \"capacity\": 1,\n \"fit_results\": {\n \"soc\": [\n 123\n ],\n \"ocv\": [\n 123\n ],\n \"r0\": [\n 123\n ],\n \"rc_pairs\": [\n {\n \"r\": [\n 123\n ],\n \"c\": [\n 123\n ],\n \"tau\": [\n 123\n ]\n }\n ],\n \"capacity_Ah\": [\n 123\n ]\n },\n \"parameterized_model_id\": \"<string>\"\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.ionworks.com/ecm/validate")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Post.new(url)
request["Content-Type"] = 'application/json'
request.body = "{\n \"measurement_id\": \"<string>\",\n \"example_id\": \"<string>\",\n \"start_step\": 123,\n \"end_step\": 123,\n \"initial_soc\": 0.5,\n \"capacity\": 1,\n \"fit_results\": {\n \"soc\": [\n 123\n ],\n \"ocv\": [\n 123\n ],\n \"r0\": [\n 123\n ],\n \"rc_pairs\": [\n {\n \"r\": [\n 123\n ],\n \"c\": [\n 123\n ],\n \"tau\": [\n 123\n ]\n }\n ],\n \"capacity_Ah\": [\n 123\n ]\n },\n \"parameterized_model_id\": \"<string>\"\n}"
response = http.request(request)
puts response.read_body{
"rmse_mV": 123,
"mae_mV": 123,
"max_mV": 123,
"num_rcs": 123,
"capacity_Ah": [
123
],
"initial_soc": 123,
"model_source": "<string>",
"time": [
123
],
"data_voltage": [
123
],
"model_voltage": [
123
],
"residual_mV": [
123
]
}{
"detail": [
{
"loc": [
"<string>"
],
"msg": "<string>",
"type": "<string>",
"input": "<unknown>",
"ctx": {}
}
]
}Validate Ecm Endpoint
Validate a fitted ECM on held-out data (synchronous, no fit, no pipeline).
Re-simulates the fitted model forward on the held-out current using the same
engine POST /ecm/fit runs internally, then returns model-vs-data traces
and RMSE/MAE/Max voltage error.
curl --request POST \
--url https://api.ionworks.com/ecm/validate \
--header 'Content-Type: application/json' \
--data '
{
"measurement_id": "<string>",
"example_id": "<string>",
"start_step": 123,
"end_step": 123,
"initial_soc": 0.5,
"capacity": 1,
"fit_results": {
"soc": [
123
],
"ocv": [
123
],
"r0": [
123
],
"rc_pairs": [
{
"r": [
123
],
"c": [
123
],
"tau": [
123
]
}
],
"capacity_Ah": [
123
]
},
"parameterized_model_id": "<string>"
}
'import requests
url = "https://api.ionworks.com/ecm/validate"
payload = {
"measurement_id": "<string>",
"example_id": "<string>",
"start_step": 123,
"end_step": 123,
"initial_soc": 0.5,
"capacity": 1,
"fit_results": {
"soc": [123],
"ocv": [123],
"r0": [123],
"rc_pairs": [
{
"r": [123],
"c": [123],
"tau": [123]
}
],
"capacity_Ah": [123]
},
"parameterized_model_id": "<string>"
}
headers = {"Content-Type": "application/json"}
response = requests.post(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'POST',
headers: {'Content-Type': 'application/json'},
body: JSON.stringify({
measurement_id: '<string>',
example_id: '<string>',
start_step: 123,
end_step: 123,
initial_soc: 0.5,
capacity: 1,
fit_results: {
soc: [123],
ocv: [123],
r0: [123],
rc_pairs: [{r: [123], c: [123], tau: [123]}],
capacity_Ah: [123]
},
parameterized_model_id: '<string>'
})
};
fetch('https://api.ionworks.com/ecm/validate', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://api.ionworks.com/ecm/validate",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "POST",
CURLOPT_POSTFIELDS => json_encode([
'measurement_id' => '<string>',
'example_id' => '<string>',
'start_step' => 123,
'end_step' => 123,
'initial_soc' => 0.5,
'capacity' => 1,
'fit_results' => [
'soc' => [
123
],
'ocv' => [
123
],
'r0' => [
123
],
'rc_pairs' => [
[
'r' => [
123
],
'c' => [
123
],
'tau' => [
123
]
]
],
'capacity_Ah' => [
123
]
],
'parameterized_model_id' => '<string>'
]),
CURLOPT_HTTPHEADER => [
"Content-Type: application/json"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"strings"
"net/http"
"io"
)
func main() {
url := "https://api.ionworks.com/ecm/validate"
payload := strings.NewReader("{\n \"measurement_id\": \"<string>\",\n \"example_id\": \"<string>\",\n \"start_step\": 123,\n \"end_step\": 123,\n \"initial_soc\": 0.5,\n \"capacity\": 1,\n \"fit_results\": {\n \"soc\": [\n 123\n ],\n \"ocv\": [\n 123\n ],\n \"r0\": [\n 123\n ],\n \"rc_pairs\": [\n {\n \"r\": [\n 123\n ],\n \"c\": [\n 123\n ],\n \"tau\": [\n 123\n ]\n }\n ],\n \"capacity_Ah\": [\n 123\n ]\n },\n \"parameterized_model_id\": \"<string>\"\n}")
req, _ := http.NewRequest("POST", url, payload)
req.Header.Add("Content-Type", "application/json")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.post("https://api.ionworks.com/ecm/validate")
.header("Content-Type", "application/json")
.body("{\n \"measurement_id\": \"<string>\",\n \"example_id\": \"<string>\",\n \"start_step\": 123,\n \"end_step\": 123,\n \"initial_soc\": 0.5,\n \"capacity\": 1,\n \"fit_results\": {\n \"soc\": [\n 123\n ],\n \"ocv\": [\n 123\n ],\n \"r0\": [\n 123\n ],\n \"rc_pairs\": [\n {\n \"r\": [\n 123\n ],\n \"c\": [\n 123\n ],\n \"tau\": [\n 123\n ]\n }\n ],\n \"capacity_Ah\": [\n 123\n ]\n },\n \"parameterized_model_id\": \"<string>\"\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.ionworks.com/ecm/validate")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Post.new(url)
request["Content-Type"] = 'application/json'
request.body = "{\n \"measurement_id\": \"<string>\",\n \"example_id\": \"<string>\",\n \"start_step\": 123,\n \"end_step\": 123,\n \"initial_soc\": 0.5,\n \"capacity\": 1,\n \"fit_results\": {\n \"soc\": [\n 123\n ],\n \"ocv\": [\n 123\n ],\n \"r0\": [\n 123\n ],\n \"rc_pairs\": [\n {\n \"r\": [\n 123\n ],\n \"c\": [\n 123\n ],\n \"tau\": [\n 123\n ]\n }\n ],\n \"capacity_Ah\": [\n 123\n ]\n },\n \"parameterized_model_id\": \"<string>\"\n}"
response = http.request(request)
puts response.read_body{
"rmse_mV": 123,
"mae_mV": 123,
"max_mV": 123,
"num_rcs": 123,
"capacity_Ah": [
123
],
"initial_soc": 123,
"model_source": "<string>",
"time": [
123
],
"data_voltage": [
123
],
"model_voltage": [
123
],
"residual_mV": [
123
]
}{
"detail": [
{
"loc": [
"<string>"
],
"msg": "<string>",
"type": "<string>",
"input": "<unknown>",
"ctx": {}
}
]
}Body
Request body for validating a fitted ECM against a held-out trace.
Provide exactly one held-out data source (measurement_id or
example_id) and exactly one model source (fit_results or
parameterized_model_id). The model is re-simulated forward on the
held-out current — no fit and no pipeline — and compared to the held-out
voltage.
Held-out cell measurement to validate against.
Built-in example dataset id to validate against.
Optional inclusive start step (measurement only).
Optional inclusive end step (measurement only).
Known SOC (0–1) at the start of the held-out trace. When omitted it is recovered from the trace's first voltage via the fitted OCV(SOC) curve (assumes the trace starts near rest).
0 <= x <= 1Cell capacity [Ah] for the SOC integration. Defaults to the fit/model capacity (the SOC reference the curves were fitted against); it is never re-estimated from the held-out trace.
x > 0In-memory fit results to re-simulate.
Show child attributes
Show child attributes
Saved ECM parameterized model to re-simulate.
Response
Successful Response
Held-out validation result: error metrics + downsampled overlay traces.
Root-mean-square voltage error [mV].
Mean absolute voltage error [mV].
Maximum absolute voltage error [mV].
RC-pair count of the validated model.
Capacity used for SOC integration [Ah] (single-element list).
Initial SOC used for the held-out trace.
Where the validated model came from.
Downsampled time grid [s].
Held-out measured voltage [V].
Re-simulated model voltage [V].
Model − data voltage residual [mV].
Was this page helpful?