curl --request POST \
--url https://api.ionworks.com/cell_specifications \
--header 'Content-Type: application/json' \
--data '
{
"name": "<string>",
"ratings": {
"capacity": {
"value": 123,
"unit": "<string>"
},
"voltage_min": {
"value": 123,
"unit": "<string>"
},
"voltage_max": {
"value": 123,
"unit": "<string>"
},
"nominal_voltage": {
"value": 123,
"unit": "<string>"
},
"energy": {
"value": 123,
"unit": "<string>"
},
"energy_density_gravimetric": {
"value": 123,
"unit": "<string>"
},
"energy_density_volumetric": {
"value": 123,
"unit": "<string>"
},
"max_discharge_rate": {
"value": 123,
"unit": "<string>"
},
"max_charge_rate": {
"value": 123,
"unit": "<string>"
}
},
"project_id": "<string>",
"form_factor": "<string>",
"manufacturer": "<string>",
"properties": {},
"source": {},
"anode": {
"material": {
"name": "<string>",
"definition": {},
"manufacturer": "<string>",
"product_id": "<string>"
},
"properties": {}
},
"cathode": {
"material": {
"name": "<string>",
"definition": {},
"manufacturer": "<string>",
"product_id": "<string>"
},
"properties": {}
},
"electrolyte": {
"material": {
"name": "<string>",
"definition": {},
"manufacturer": "<string>",
"product_id": "<string>"
},
"properties": {}
},
"separator": {
"material": {
"name": "<string>",
"definition": {},
"manufacturer": "<string>",
"product_id": "<string>"
},
"properties": {}
},
"case": {
"material": {
"name": "<string>",
"definition": {},
"manufacturer": "<string>",
"product_id": "<string>"
},
"properties": {}
},
"notes": "<string>"
}
'import requests
url = "https://api.ionworks.com/cell_specifications"
payload = {
"name": "<string>",
"ratings": {
"capacity": {
"value": 123,
"unit": "<string>"
},
"voltage_min": {
"value": 123,
"unit": "<string>"
},
"voltage_max": {
"value": 123,
"unit": "<string>"
},
"nominal_voltage": {
"value": 123,
"unit": "<string>"
},
"energy": {
"value": 123,
"unit": "<string>"
},
"energy_density_gravimetric": {
"value": 123,
"unit": "<string>"
},
"energy_density_volumetric": {
"value": 123,
"unit": "<string>"
},
"max_discharge_rate": {
"value": 123,
"unit": "<string>"
},
"max_charge_rate": {
"value": 123,
"unit": "<string>"
}
},
"project_id": "<string>",
"form_factor": "<string>",
"manufacturer": "<string>",
"properties": {},
"source": {},
"anode": {
"material": {
"name": "<string>",
"definition": {},
"manufacturer": "<string>",
"product_id": "<string>"
},
"properties": {}
},
"cathode": {
"material": {
"name": "<string>",
"definition": {},
"manufacturer": "<string>",
"product_id": "<string>"
},
"properties": {}
},
"electrolyte": {
"material": {
"name": "<string>",
"definition": {},
"manufacturer": "<string>",
"product_id": "<string>"
},
"properties": {}
},
"separator": {
"material": {
"name": "<string>",
"definition": {},
"manufacturer": "<string>",
"product_id": "<string>"
},
"properties": {}
},
"case": {
"material": {
"name": "<string>",
"definition": {},
"manufacturer": "<string>",
"product_id": "<string>"
},
"properties": {}
},
"notes": "<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({
name: '<string>',
ratings: {
capacity: {value: 123, unit: '<string>'},
voltage_min: {value: 123, unit: '<string>'},
voltage_max: {value: 123, unit: '<string>'},
nominal_voltage: {value: 123, unit: '<string>'},
energy: {value: 123, unit: '<string>'},
energy_density_gravimetric: {value: 123, unit: '<string>'},
energy_density_volumetric: {value: 123, unit: '<string>'},
max_discharge_rate: {value: 123, unit: '<string>'},
max_charge_rate: {value: 123, unit: '<string>'}
},
project_id: '<string>',
form_factor: '<string>',
manufacturer: '<string>',
properties: {},
source: {},
anode: {
material: {
name: '<string>',
definition: {},
manufacturer: '<string>',
product_id: '<string>'
},
properties: {}
},
cathode: {
material: {
name: '<string>',
definition: {},
manufacturer: '<string>',
product_id: '<string>'
},
properties: {}
},
electrolyte: {
material: {
name: '<string>',
definition: {},
manufacturer: '<string>',
product_id: '<string>'
},
properties: {}
},
separator: {
material: {
name: '<string>',
definition: {},
manufacturer: '<string>',
product_id: '<string>'
},
properties: {}
},
case: {
material: {
name: '<string>',
definition: {},
manufacturer: '<string>',
product_id: '<string>'
},
properties: {}
},
notes: '<string>'
})
};
fetch('https://api.ionworks.com/cell_specifications', 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/cell_specifications",
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([
'name' => '<string>',
'ratings' => [
'capacity' => [
'value' => 123,
'unit' => '<string>'
],
'voltage_min' => [
'value' => 123,
'unit' => '<string>'
],
'voltage_max' => [
'value' => 123,
'unit' => '<string>'
],
'nominal_voltage' => [
'value' => 123,
'unit' => '<string>'
],
'energy' => [
'value' => 123,
'unit' => '<string>'
],
'energy_density_gravimetric' => [
'value' => 123,
'unit' => '<string>'
],
'energy_density_volumetric' => [
'value' => 123,
'unit' => '<string>'
],
'max_discharge_rate' => [
'value' => 123,
'unit' => '<string>'
],
'max_charge_rate' => [
'value' => 123,
'unit' => '<string>'
]
],
'project_id' => '<string>',
'form_factor' => '<string>',
'manufacturer' => '<string>',
'properties' => [
],
'source' => [
],
'anode' => [
'material' => [
'name' => '<string>',
'definition' => [
],
'manufacturer' => '<string>',
'product_id' => '<string>'
],
'properties' => [
]
],
'cathode' => [
'material' => [
'name' => '<string>',
'definition' => [
],
'manufacturer' => '<string>',
'product_id' => '<string>'
],
'properties' => [
]
],
'electrolyte' => [
'material' => [
'name' => '<string>',
'definition' => [
],
'manufacturer' => '<string>',
'product_id' => '<string>'
],
'properties' => [
]
],
'separator' => [
'material' => [
'name' => '<string>',
'definition' => [
],
'manufacturer' => '<string>',
'product_id' => '<string>'
],
'properties' => [
]
],
'case' => [
'material' => [
'name' => '<string>',
'definition' => [
],
'manufacturer' => '<string>',
'product_id' => '<string>'
],
'properties' => [
]
],
'notes' => '<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/cell_specifications"
payload := strings.NewReader("{\n \"name\": \"<string>\",\n \"ratings\": {\n \"capacity\": {\n \"value\": 123,\n \"unit\": \"<string>\"\n },\n \"voltage_min\": {\n \"value\": 123,\n \"unit\": \"<string>\"\n },\n \"voltage_max\": {\n \"value\": 123,\n \"unit\": \"<string>\"\n },\n \"nominal_voltage\": {\n \"value\": 123,\n \"unit\": \"<string>\"\n },\n \"energy\": {\n \"value\": 123,\n \"unit\": \"<string>\"\n },\n \"energy_density_gravimetric\": {\n \"value\": 123,\n \"unit\": \"<string>\"\n },\n \"energy_density_volumetric\": {\n \"value\": 123,\n \"unit\": \"<string>\"\n },\n \"max_discharge_rate\": {\n \"value\": 123,\n \"unit\": \"<string>\"\n },\n \"max_charge_rate\": {\n \"value\": 123,\n \"unit\": \"<string>\"\n }\n },\n \"project_id\": \"<string>\",\n \"form_factor\": \"<string>\",\n \"manufacturer\": \"<string>\",\n \"properties\": {},\n \"source\": {},\n \"anode\": {\n \"material\": {\n \"name\": \"<string>\",\n \"definition\": {},\n \"manufacturer\": \"<string>\",\n \"product_id\": \"<string>\"\n },\n \"properties\": {}\n },\n \"cathode\": {\n \"material\": {\n \"name\": \"<string>\",\n \"definition\": {},\n \"manufacturer\": \"<string>\",\n \"product_id\": \"<string>\"\n },\n \"properties\": {}\n },\n \"electrolyte\": {\n \"material\": {\n \"name\": \"<string>\",\n \"definition\": {},\n \"manufacturer\": \"<string>\",\n \"product_id\": \"<string>\"\n },\n \"properties\": {}\n },\n \"separator\": {\n \"material\": {\n \"name\": \"<string>\",\n \"definition\": {},\n \"manufacturer\": \"<string>\",\n \"product_id\": \"<string>\"\n },\n \"properties\": {}\n },\n \"case\": {\n \"material\": {\n \"name\": \"<string>\",\n \"definition\": {},\n \"manufacturer\": \"<string>\",\n \"product_id\": \"<string>\"\n },\n \"properties\": {}\n },\n \"notes\": \"<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/cell_specifications")
.header("Content-Type", "application/json")
.body("{\n \"name\": \"<string>\",\n \"ratings\": {\n \"capacity\": {\n \"value\": 123,\n \"unit\": \"<string>\"\n },\n \"voltage_min\": {\n \"value\": 123,\n \"unit\": \"<string>\"\n },\n \"voltage_max\": {\n \"value\": 123,\n \"unit\": \"<string>\"\n },\n \"nominal_voltage\": {\n \"value\": 123,\n \"unit\": \"<string>\"\n },\n \"energy\": {\n \"value\": 123,\n \"unit\": \"<string>\"\n },\n \"energy_density_gravimetric\": {\n \"value\": 123,\n \"unit\": \"<string>\"\n },\n \"energy_density_volumetric\": {\n \"value\": 123,\n \"unit\": \"<string>\"\n },\n \"max_discharge_rate\": {\n \"value\": 123,\n \"unit\": \"<string>\"\n },\n \"max_charge_rate\": {\n \"value\": 123,\n \"unit\": \"<string>\"\n }\n },\n \"project_id\": \"<string>\",\n \"form_factor\": \"<string>\",\n \"manufacturer\": \"<string>\",\n \"properties\": {},\n \"source\": {},\n \"anode\": {\n \"material\": {\n \"name\": \"<string>\",\n \"definition\": {},\n \"manufacturer\": \"<string>\",\n \"product_id\": \"<string>\"\n },\n \"properties\": {}\n },\n \"cathode\": {\n \"material\": {\n \"name\": \"<string>\",\n \"definition\": {},\n \"manufacturer\": \"<string>\",\n \"product_id\": \"<string>\"\n },\n \"properties\": {}\n },\n \"electrolyte\": {\n \"material\": {\n \"name\": \"<string>\",\n \"definition\": {},\n \"manufacturer\": \"<string>\",\n \"product_id\": \"<string>\"\n },\n \"properties\": {}\n },\n \"separator\": {\n \"material\": {\n \"name\": \"<string>\",\n \"definition\": {},\n \"manufacturer\": \"<string>\",\n \"product_id\": \"<string>\"\n },\n \"properties\": {}\n },\n \"case\": {\n \"material\": {\n \"name\": \"<string>\",\n \"definition\": {},\n \"manufacturer\": \"<string>\",\n \"product_id\": \"<string>\"\n },\n \"properties\": {}\n },\n \"notes\": \"<string>\"\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.ionworks.com/cell_specifications")
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 \"name\": \"<string>\",\n \"ratings\": {\n \"capacity\": {\n \"value\": 123,\n \"unit\": \"<string>\"\n },\n \"voltage_min\": {\n \"value\": 123,\n \"unit\": \"<string>\"\n },\n \"voltage_max\": {\n \"value\": 123,\n \"unit\": \"<string>\"\n },\n \"nominal_voltage\": {\n \"value\": 123,\n \"unit\": \"<string>\"\n },\n \"energy\": {\n \"value\": 123,\n \"unit\": \"<string>\"\n },\n \"energy_density_gravimetric\": {\n \"value\": 123,\n \"unit\": \"<string>\"\n },\n \"energy_density_volumetric\": {\n \"value\": 123,\n \"unit\": \"<string>\"\n },\n \"max_discharge_rate\": {\n \"value\": 123,\n \"unit\": \"<string>\"\n },\n \"max_charge_rate\": {\n \"value\": 123,\n \"unit\": \"<string>\"\n }\n },\n \"project_id\": \"<string>\",\n \"form_factor\": \"<string>\",\n \"manufacturer\": \"<string>\",\n \"properties\": {},\n \"source\": {},\n \"anode\": {\n \"material\": {\n \"name\": \"<string>\",\n \"definition\": {},\n \"manufacturer\": \"<string>\",\n \"product_id\": \"<string>\"\n },\n \"properties\": {}\n },\n \"cathode\": {\n \"material\": {\n \"name\": \"<string>\",\n \"definition\": {},\n \"manufacturer\": \"<string>\",\n \"product_id\": \"<string>\"\n },\n \"properties\": {}\n },\n \"electrolyte\": {\n \"material\": {\n \"name\": \"<string>\",\n \"definition\": {},\n \"manufacturer\": \"<string>\",\n \"product_id\": \"<string>\"\n },\n \"properties\": {}\n },\n \"separator\": {\n \"material\": {\n \"name\": \"<string>\",\n \"definition\": {},\n \"manufacturer\": \"<string>\",\n \"product_id\": \"<string>\"\n },\n \"properties\": {}\n },\n \"case\": {\n \"material\": {\n \"name\": \"<string>\",\n \"definition\": {},\n \"manufacturer\": \"<string>\",\n \"product_id\": \"<string>\"\n },\n \"properties\": {}\n },\n \"notes\": \"<string>\"\n}"
response = http.request(request)
puts response.read_body{
"name": "<string>",
"ratings": {
"capacity": {
"value": 123,
"unit": "<string>"
},
"voltage_min": {
"value": 123,
"unit": "<string>"
},
"voltage_max": {
"value": 123,
"unit": "<string>"
},
"nominal_voltage": {
"value": 123,
"unit": "<string>"
},
"energy": {
"value": 123,
"unit": "<string>"
},
"energy_density_gravimetric": {
"value": 123,
"unit": "<string>"
},
"energy_density_volumetric": {
"value": 123,
"unit": "<string>"
},
"max_discharge_rate": {
"value": 123,
"unit": "<string>"
},
"max_charge_rate": {
"value": 123,
"unit": "<string>"
}
},
"id": "<string>",
"organization_id": "<string>",
"form_factor": "<string>",
"manufacturer": "<string>",
"anode_id": "<string>",
"cathode_id": "<string>",
"electrolyte_id": "<string>",
"separator_id": "<string>",
"case_id": "<string>",
"properties": {},
"source": {},
"notes": "<string>",
"project_id": "<string>",
"created_by": "<string>",
"created_by_email": "<string>",
"instance_ids": [
{}
],
"anode": {
"material_id": "<string>",
"id": "<string>",
"organization_id": "<string>",
"created_at": "2023-11-07T05:31:56Z",
"updated_at": "2023-11-07T05:31:56Z",
"properties": {},
"project_id": "<string>",
"material": {
"name": "<string>",
"id": "<string>",
"organization_id": "<string>",
"created_at": "2023-11-07T05:31:56Z",
"updated_at": "2023-11-07T05:31:56Z",
"definition": {},
"manufacturer": "<string>",
"product_id": "<string>",
"project_id": "<string>",
"property_count": 0
}
},
"cathode": {
"material_id": "<string>",
"id": "<string>",
"organization_id": "<string>",
"created_at": "2023-11-07T05:31:56Z",
"updated_at": "2023-11-07T05:31:56Z",
"properties": {},
"project_id": "<string>",
"material": {
"name": "<string>",
"id": "<string>",
"organization_id": "<string>",
"created_at": "2023-11-07T05:31:56Z",
"updated_at": "2023-11-07T05:31:56Z",
"definition": {},
"manufacturer": "<string>",
"product_id": "<string>",
"project_id": "<string>",
"property_count": 0
}
},
"electrolyte": {
"material_id": "<string>",
"id": "<string>",
"organization_id": "<string>",
"created_at": "2023-11-07T05:31:56Z",
"updated_at": "2023-11-07T05:31:56Z",
"properties": {},
"project_id": "<string>",
"material": {
"name": "<string>",
"id": "<string>",
"organization_id": "<string>",
"created_at": "2023-11-07T05:31:56Z",
"updated_at": "2023-11-07T05:31:56Z",
"definition": {},
"manufacturer": "<string>",
"product_id": "<string>",
"project_id": "<string>",
"property_count": 0
}
},
"separator": {
"material_id": "<string>",
"id": "<string>",
"organization_id": "<string>",
"created_at": "2023-11-07T05:31:56Z",
"updated_at": "2023-11-07T05:31:56Z",
"properties": {},
"project_id": "<string>",
"material": {
"name": "<string>",
"id": "<string>",
"organization_id": "<string>",
"created_at": "2023-11-07T05:31:56Z",
"updated_at": "2023-11-07T05:31:56Z",
"definition": {},
"manufacturer": "<string>",
"product_id": "<string>",
"project_id": "<string>",
"property_count": 0
}
},
"case": {
"material_id": "<string>",
"id": "<string>",
"organization_id": "<string>",
"created_at": "2023-11-07T05:31:56Z",
"updated_at": "2023-11-07T05:31:56Z",
"properties": {},
"project_id": "<string>",
"material": {
"name": "<string>",
"id": "<string>",
"organization_id": "<string>",
"created_at": "2023-11-07T05:31:56Z",
"updated_at": "2023-11-07T05:31:56Z",
"definition": {},
"manufacturer": "<string>",
"product_id": "<string>",
"project_id": "<string>",
"property_count": 0
}
}
}{
"detail": [
{
"loc": [
"<string>"
],
"msg": "<string>",
"type": "<string>",
"input": "<unknown>",
"ctx": {}
}
]
}Create a new cell specification with nested component/material data
Create a new cell specification with nested component and material data.
Materials and components are automatically upserted based on uniqueness:
- Materials: unique on (organization_id, name, manufacturer)
- Components: unique on (organization_id, component_type, material_id, properties)
Example request body:
{
"name": "NCM622/Graphite Coin Cell",
"capacity": 0.002,
"lower_voltage_cutoff": 2.5,
"upper_voltage_cutoff": 4.2,
"form_factor": "R2032",
"anode": {
"properties": {"diameter_mm": 15, "thickness_um": 23},
"material": {"name": "Graphite", "manufacturer": "Customcells"}
},
"cathode": {
"properties": {"diameter_mm": 14, "thickness_um": 22},
"material": {
"name": "NCM622",
"definition": {"formula": "LiNi0.6Co0.2Mn0.2O2"}
}
}
}
curl --request POST \
--url https://api.ionworks.com/cell_specifications \
--header 'Content-Type: application/json' \
--data '
{
"name": "<string>",
"ratings": {
"capacity": {
"value": 123,
"unit": "<string>"
},
"voltage_min": {
"value": 123,
"unit": "<string>"
},
"voltage_max": {
"value": 123,
"unit": "<string>"
},
"nominal_voltage": {
"value": 123,
"unit": "<string>"
},
"energy": {
"value": 123,
"unit": "<string>"
},
"energy_density_gravimetric": {
"value": 123,
"unit": "<string>"
},
"energy_density_volumetric": {
"value": 123,
"unit": "<string>"
},
"max_discharge_rate": {
"value": 123,
"unit": "<string>"
},
"max_charge_rate": {
"value": 123,
"unit": "<string>"
}
},
"project_id": "<string>",
"form_factor": "<string>",
"manufacturer": "<string>",
"properties": {},
"source": {},
"anode": {
"material": {
"name": "<string>",
"definition": {},
"manufacturer": "<string>",
"product_id": "<string>"
},
"properties": {}
},
"cathode": {
"material": {
"name": "<string>",
"definition": {},
"manufacturer": "<string>",
"product_id": "<string>"
},
"properties": {}
},
"electrolyte": {
"material": {
"name": "<string>",
"definition": {},
"manufacturer": "<string>",
"product_id": "<string>"
},
"properties": {}
},
"separator": {
"material": {
"name": "<string>",
"definition": {},
"manufacturer": "<string>",
"product_id": "<string>"
},
"properties": {}
},
"case": {
"material": {
"name": "<string>",
"definition": {},
"manufacturer": "<string>",
"product_id": "<string>"
},
"properties": {}
},
"notes": "<string>"
}
'import requests
url = "https://api.ionworks.com/cell_specifications"
payload = {
"name": "<string>",
"ratings": {
"capacity": {
"value": 123,
"unit": "<string>"
},
"voltage_min": {
"value": 123,
"unit": "<string>"
},
"voltage_max": {
"value": 123,
"unit": "<string>"
},
"nominal_voltage": {
"value": 123,
"unit": "<string>"
},
"energy": {
"value": 123,
"unit": "<string>"
},
"energy_density_gravimetric": {
"value": 123,
"unit": "<string>"
},
"energy_density_volumetric": {
"value": 123,
"unit": "<string>"
},
"max_discharge_rate": {
"value": 123,
"unit": "<string>"
},
"max_charge_rate": {
"value": 123,
"unit": "<string>"
}
},
"project_id": "<string>",
"form_factor": "<string>",
"manufacturer": "<string>",
"properties": {},
"source": {},
"anode": {
"material": {
"name": "<string>",
"definition": {},
"manufacturer": "<string>",
"product_id": "<string>"
},
"properties": {}
},
"cathode": {
"material": {
"name": "<string>",
"definition": {},
"manufacturer": "<string>",
"product_id": "<string>"
},
"properties": {}
},
"electrolyte": {
"material": {
"name": "<string>",
"definition": {},
"manufacturer": "<string>",
"product_id": "<string>"
},
"properties": {}
},
"separator": {
"material": {
"name": "<string>",
"definition": {},
"manufacturer": "<string>",
"product_id": "<string>"
},
"properties": {}
},
"case": {
"material": {
"name": "<string>",
"definition": {},
"manufacturer": "<string>",
"product_id": "<string>"
},
"properties": {}
},
"notes": "<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({
name: '<string>',
ratings: {
capacity: {value: 123, unit: '<string>'},
voltage_min: {value: 123, unit: '<string>'},
voltage_max: {value: 123, unit: '<string>'},
nominal_voltage: {value: 123, unit: '<string>'},
energy: {value: 123, unit: '<string>'},
energy_density_gravimetric: {value: 123, unit: '<string>'},
energy_density_volumetric: {value: 123, unit: '<string>'},
max_discharge_rate: {value: 123, unit: '<string>'},
max_charge_rate: {value: 123, unit: '<string>'}
},
project_id: '<string>',
form_factor: '<string>',
manufacturer: '<string>',
properties: {},
source: {},
anode: {
material: {
name: '<string>',
definition: {},
manufacturer: '<string>',
product_id: '<string>'
},
properties: {}
},
cathode: {
material: {
name: '<string>',
definition: {},
manufacturer: '<string>',
product_id: '<string>'
},
properties: {}
},
electrolyte: {
material: {
name: '<string>',
definition: {},
manufacturer: '<string>',
product_id: '<string>'
},
properties: {}
},
separator: {
material: {
name: '<string>',
definition: {},
manufacturer: '<string>',
product_id: '<string>'
},
properties: {}
},
case: {
material: {
name: '<string>',
definition: {},
manufacturer: '<string>',
product_id: '<string>'
},
properties: {}
},
notes: '<string>'
})
};
fetch('https://api.ionworks.com/cell_specifications', 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/cell_specifications",
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([
'name' => '<string>',
'ratings' => [
'capacity' => [
'value' => 123,
'unit' => '<string>'
],
'voltage_min' => [
'value' => 123,
'unit' => '<string>'
],
'voltage_max' => [
'value' => 123,
'unit' => '<string>'
],
'nominal_voltage' => [
'value' => 123,
'unit' => '<string>'
],
'energy' => [
'value' => 123,
'unit' => '<string>'
],
'energy_density_gravimetric' => [
'value' => 123,
'unit' => '<string>'
],
'energy_density_volumetric' => [
'value' => 123,
'unit' => '<string>'
],
'max_discharge_rate' => [
'value' => 123,
'unit' => '<string>'
],
'max_charge_rate' => [
'value' => 123,
'unit' => '<string>'
]
],
'project_id' => '<string>',
'form_factor' => '<string>',
'manufacturer' => '<string>',
'properties' => [
],
'source' => [
],
'anode' => [
'material' => [
'name' => '<string>',
'definition' => [
],
'manufacturer' => '<string>',
'product_id' => '<string>'
],
'properties' => [
]
],
'cathode' => [
'material' => [
'name' => '<string>',
'definition' => [
],
'manufacturer' => '<string>',
'product_id' => '<string>'
],
'properties' => [
]
],
'electrolyte' => [
'material' => [
'name' => '<string>',
'definition' => [
],
'manufacturer' => '<string>',
'product_id' => '<string>'
],
'properties' => [
]
],
'separator' => [
'material' => [
'name' => '<string>',
'definition' => [
],
'manufacturer' => '<string>',
'product_id' => '<string>'
],
'properties' => [
]
],
'case' => [
'material' => [
'name' => '<string>',
'definition' => [
],
'manufacturer' => '<string>',
'product_id' => '<string>'
],
'properties' => [
]
],
'notes' => '<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/cell_specifications"
payload := strings.NewReader("{\n \"name\": \"<string>\",\n \"ratings\": {\n \"capacity\": {\n \"value\": 123,\n \"unit\": \"<string>\"\n },\n \"voltage_min\": {\n \"value\": 123,\n \"unit\": \"<string>\"\n },\n \"voltage_max\": {\n \"value\": 123,\n \"unit\": \"<string>\"\n },\n \"nominal_voltage\": {\n \"value\": 123,\n \"unit\": \"<string>\"\n },\n \"energy\": {\n \"value\": 123,\n \"unit\": \"<string>\"\n },\n \"energy_density_gravimetric\": {\n \"value\": 123,\n \"unit\": \"<string>\"\n },\n \"energy_density_volumetric\": {\n \"value\": 123,\n \"unit\": \"<string>\"\n },\n \"max_discharge_rate\": {\n \"value\": 123,\n \"unit\": \"<string>\"\n },\n \"max_charge_rate\": {\n \"value\": 123,\n \"unit\": \"<string>\"\n }\n },\n \"project_id\": \"<string>\",\n \"form_factor\": \"<string>\",\n \"manufacturer\": \"<string>\",\n \"properties\": {},\n \"source\": {},\n \"anode\": {\n \"material\": {\n \"name\": \"<string>\",\n \"definition\": {},\n \"manufacturer\": \"<string>\",\n \"product_id\": \"<string>\"\n },\n \"properties\": {}\n },\n \"cathode\": {\n \"material\": {\n \"name\": \"<string>\",\n \"definition\": {},\n \"manufacturer\": \"<string>\",\n \"product_id\": \"<string>\"\n },\n \"properties\": {}\n },\n \"electrolyte\": {\n \"material\": {\n \"name\": \"<string>\",\n \"definition\": {},\n \"manufacturer\": \"<string>\",\n \"product_id\": \"<string>\"\n },\n \"properties\": {}\n },\n \"separator\": {\n \"material\": {\n \"name\": \"<string>\",\n \"definition\": {},\n \"manufacturer\": \"<string>\",\n \"product_id\": \"<string>\"\n },\n \"properties\": {}\n },\n \"case\": {\n \"material\": {\n \"name\": \"<string>\",\n \"definition\": {},\n \"manufacturer\": \"<string>\",\n \"product_id\": \"<string>\"\n },\n \"properties\": {}\n },\n \"notes\": \"<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/cell_specifications")
.header("Content-Type", "application/json")
.body("{\n \"name\": \"<string>\",\n \"ratings\": {\n \"capacity\": {\n \"value\": 123,\n \"unit\": \"<string>\"\n },\n \"voltage_min\": {\n \"value\": 123,\n \"unit\": \"<string>\"\n },\n \"voltage_max\": {\n \"value\": 123,\n \"unit\": \"<string>\"\n },\n \"nominal_voltage\": {\n \"value\": 123,\n \"unit\": \"<string>\"\n },\n \"energy\": {\n \"value\": 123,\n \"unit\": \"<string>\"\n },\n \"energy_density_gravimetric\": {\n \"value\": 123,\n \"unit\": \"<string>\"\n },\n \"energy_density_volumetric\": {\n \"value\": 123,\n \"unit\": \"<string>\"\n },\n \"max_discharge_rate\": {\n \"value\": 123,\n \"unit\": \"<string>\"\n },\n \"max_charge_rate\": {\n \"value\": 123,\n \"unit\": \"<string>\"\n }\n },\n \"project_id\": \"<string>\",\n \"form_factor\": \"<string>\",\n \"manufacturer\": \"<string>\",\n \"properties\": {},\n \"source\": {},\n \"anode\": {\n \"material\": {\n \"name\": \"<string>\",\n \"definition\": {},\n \"manufacturer\": \"<string>\",\n \"product_id\": \"<string>\"\n },\n \"properties\": {}\n },\n \"cathode\": {\n \"material\": {\n \"name\": \"<string>\",\n \"definition\": {},\n \"manufacturer\": \"<string>\",\n \"product_id\": \"<string>\"\n },\n \"properties\": {}\n },\n \"electrolyte\": {\n \"material\": {\n \"name\": \"<string>\",\n \"definition\": {},\n \"manufacturer\": \"<string>\",\n \"product_id\": \"<string>\"\n },\n \"properties\": {}\n },\n \"separator\": {\n \"material\": {\n \"name\": \"<string>\",\n \"definition\": {},\n \"manufacturer\": \"<string>\",\n \"product_id\": \"<string>\"\n },\n \"properties\": {}\n },\n \"case\": {\n \"material\": {\n \"name\": \"<string>\",\n \"definition\": {},\n \"manufacturer\": \"<string>\",\n \"product_id\": \"<string>\"\n },\n \"properties\": {}\n },\n \"notes\": \"<string>\"\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.ionworks.com/cell_specifications")
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 \"name\": \"<string>\",\n \"ratings\": {\n \"capacity\": {\n \"value\": 123,\n \"unit\": \"<string>\"\n },\n \"voltage_min\": {\n \"value\": 123,\n \"unit\": \"<string>\"\n },\n \"voltage_max\": {\n \"value\": 123,\n \"unit\": \"<string>\"\n },\n \"nominal_voltage\": {\n \"value\": 123,\n \"unit\": \"<string>\"\n },\n \"energy\": {\n \"value\": 123,\n \"unit\": \"<string>\"\n },\n \"energy_density_gravimetric\": {\n \"value\": 123,\n \"unit\": \"<string>\"\n },\n \"energy_density_volumetric\": {\n \"value\": 123,\n \"unit\": \"<string>\"\n },\n \"max_discharge_rate\": {\n \"value\": 123,\n \"unit\": \"<string>\"\n },\n \"max_charge_rate\": {\n \"value\": 123,\n \"unit\": \"<string>\"\n }\n },\n \"project_id\": \"<string>\",\n \"form_factor\": \"<string>\",\n \"manufacturer\": \"<string>\",\n \"properties\": {},\n \"source\": {},\n \"anode\": {\n \"material\": {\n \"name\": \"<string>\",\n \"definition\": {},\n \"manufacturer\": \"<string>\",\n \"product_id\": \"<string>\"\n },\n \"properties\": {}\n },\n \"cathode\": {\n \"material\": {\n \"name\": \"<string>\",\n \"definition\": {},\n \"manufacturer\": \"<string>\",\n \"product_id\": \"<string>\"\n },\n \"properties\": {}\n },\n \"electrolyte\": {\n \"material\": {\n \"name\": \"<string>\",\n \"definition\": {},\n \"manufacturer\": \"<string>\",\n \"product_id\": \"<string>\"\n },\n \"properties\": {}\n },\n \"separator\": {\n \"material\": {\n \"name\": \"<string>\",\n \"definition\": {},\n \"manufacturer\": \"<string>\",\n \"product_id\": \"<string>\"\n },\n \"properties\": {}\n },\n \"case\": {\n \"material\": {\n \"name\": \"<string>\",\n \"definition\": {},\n \"manufacturer\": \"<string>\",\n \"product_id\": \"<string>\"\n },\n \"properties\": {}\n },\n \"notes\": \"<string>\"\n}"
response = http.request(request)
puts response.read_body{
"name": "<string>",
"ratings": {
"capacity": {
"value": 123,
"unit": "<string>"
},
"voltage_min": {
"value": 123,
"unit": "<string>"
},
"voltage_max": {
"value": 123,
"unit": "<string>"
},
"nominal_voltage": {
"value": 123,
"unit": "<string>"
},
"energy": {
"value": 123,
"unit": "<string>"
},
"energy_density_gravimetric": {
"value": 123,
"unit": "<string>"
},
"energy_density_volumetric": {
"value": 123,
"unit": "<string>"
},
"max_discharge_rate": {
"value": 123,
"unit": "<string>"
},
"max_charge_rate": {
"value": 123,
"unit": "<string>"
}
},
"id": "<string>",
"organization_id": "<string>",
"form_factor": "<string>",
"manufacturer": "<string>",
"anode_id": "<string>",
"cathode_id": "<string>",
"electrolyte_id": "<string>",
"separator_id": "<string>",
"case_id": "<string>",
"properties": {},
"source": {},
"notes": "<string>",
"project_id": "<string>",
"created_by": "<string>",
"created_by_email": "<string>",
"instance_ids": [
{}
],
"anode": {
"material_id": "<string>",
"id": "<string>",
"organization_id": "<string>",
"created_at": "2023-11-07T05:31:56Z",
"updated_at": "2023-11-07T05:31:56Z",
"properties": {},
"project_id": "<string>",
"material": {
"name": "<string>",
"id": "<string>",
"organization_id": "<string>",
"created_at": "2023-11-07T05:31:56Z",
"updated_at": "2023-11-07T05:31:56Z",
"definition": {},
"manufacturer": "<string>",
"product_id": "<string>",
"project_id": "<string>",
"property_count": 0
}
},
"cathode": {
"material_id": "<string>",
"id": "<string>",
"organization_id": "<string>",
"created_at": "2023-11-07T05:31:56Z",
"updated_at": "2023-11-07T05:31:56Z",
"properties": {},
"project_id": "<string>",
"material": {
"name": "<string>",
"id": "<string>",
"organization_id": "<string>",
"created_at": "2023-11-07T05:31:56Z",
"updated_at": "2023-11-07T05:31:56Z",
"definition": {},
"manufacturer": "<string>",
"product_id": "<string>",
"project_id": "<string>",
"property_count": 0
}
},
"electrolyte": {
"material_id": "<string>",
"id": "<string>",
"organization_id": "<string>",
"created_at": "2023-11-07T05:31:56Z",
"updated_at": "2023-11-07T05:31:56Z",
"properties": {},
"project_id": "<string>",
"material": {
"name": "<string>",
"id": "<string>",
"organization_id": "<string>",
"created_at": "2023-11-07T05:31:56Z",
"updated_at": "2023-11-07T05:31:56Z",
"definition": {},
"manufacturer": "<string>",
"product_id": "<string>",
"project_id": "<string>",
"property_count": 0
}
},
"separator": {
"material_id": "<string>",
"id": "<string>",
"organization_id": "<string>",
"created_at": "2023-11-07T05:31:56Z",
"updated_at": "2023-11-07T05:31:56Z",
"properties": {},
"project_id": "<string>",
"material": {
"name": "<string>",
"id": "<string>",
"organization_id": "<string>",
"created_at": "2023-11-07T05:31:56Z",
"updated_at": "2023-11-07T05:31:56Z",
"definition": {},
"manufacturer": "<string>",
"product_id": "<string>",
"project_id": "<string>",
"property_count": 0
}
},
"case": {
"material_id": "<string>",
"id": "<string>",
"organization_id": "<string>",
"created_at": "2023-11-07T05:31:56Z",
"updated_at": "2023-11-07T05:31:56Z",
"properties": {},
"project_id": "<string>",
"material": {
"name": "<string>",
"id": "<string>",
"organization_id": "<string>",
"created_at": "2023-11-07T05:31:56Z",
"updated_at": "2023-11-07T05:31:56Z",
"definition": {},
"manufacturer": "<string>",
"product_id": "<string>",
"project_id": "<string>",
"property_count": 0
}
}
}{
"detail": [
{
"loc": [
"<string>"
],
"msg": "<string>",
"type": "<string>",
"input": "<unknown>",
"ctx": {}
}
]
}Body
Model for creating a cell specification with nested component/material data.
Components and materials are upserted based on uniqueness constraints:
- Materials: unique on (organization_id, name, manufacturer, product_id)
- Components: unique on (organization_id, component_type, material_id, properties)
Name of the cell specification
Electrical ratings from spec sheet
Show child attributes
Show child attributes
Project to associate with
Form factor (e.g., R2032, 18650, pouch)
Who assembled/manufactured the cell
Non-electrical design properties (assembly_method, etc.)
Source/provenance info: doi, license, publication_date, citation, creator_name, creator_orcid
Anode component with material
Show child attributes
Show child attributes
Cathode component with material
Show child attributes
Show child attributes
Electrolyte component with material
Show child attributes
Show child attributes
Separator component with material
Show child attributes
Show child attributes
Case component with material
Show child attributes
Show child attributes
Optional notes about the cell specification
Response
Successful Response
Cell specification with nested component information.
Name of the cell specification
Electrical ratings from the spec sheet / design targets (rated capacity, voltage min/max, optional nominal voltage, energy, energy densities, max charge/discharge C-rates). See :class:Ratings.
Show child attributes
Show child attributes
Unique identifier for the cell specification
Organization ID of the cell specification
Physical form factor. Common values: '18650', '21700', 'R2032' (coin cell), 'pouch', 'prismatic', 'cylindrical'.
Who assembled/manufactured the cell
ID of the anode component
ID of the cathode component
ID of the electrolyte component
ID of the separator component
ID of the case component
Other design-level properties that are not electrical ratings and not tied to a specific component — e.g. assembly method, overall cell dimensions, mass, target thickness. Numeric values must use the Quantity format ({'value': ..., 'unit': ...}).
Provenance of the design. Typical keys: 'doi', 'citation', 'publication_date' (ISO 8601), 'license', 'creator_name', 'creator_orcid'. Lives on the specification (not the instance) because it describes the published design.
Free-text notes about the cell specification
Project this cell specification belongs to
User ID of the user who created this specification
Email of the user who created this specification
List of instance IDs associated with the cell specification
Anode component with material
Show child attributes
Show child attributes
Cathode component with material
Show child attributes
Show child attributes
Electrolyte component with material
Show child attributes
Show child attributes
Separator component with material
Show child attributes
Show child attributes
Case component with material
Show child attributes
Show child attributes
Was this page helpful?