/v1/molarmass
Molar mass of a formula
Essayez-le en direct
10 appels gratuits par jour — sans inscription, sans clé API. Passe par la passerelle oanor.
Ça marche. Récupérez une clé API et utilisez-la dans votre projet.
Obtenez une clé APIExtraits de code
curl "https://api.oanor.com/molarmass-api/v1/molarmass" \ -H "x-oanor-key: oanor_test_..."
await fetch("https://api.oanor.com/molarmass-api/v1/molarmass", {
headers: { "x-oanor-key": "oanor_test_..." }
});
$ch = curl_init("https://api.oanor.com/molarmass-api/v1/molarmass");
curl_setopt($ch, CURLOPT_HTTPHEADER, ["x-oanor-key: oanor_test_..."]);
curl_setopt($ch, CURLOPT_RETURNTRANSFER, true);
$out = curl_exec($ch);
import requests
requests.get(
"https://api.oanor.com/molarmass-api/v1/molarmass",
headers={"x-oanor-key": "oanor_test_..."}
)
Exemple de réponse
Une réponse réelle de ce endpoint, capturée lors du dernier contrôle de santé.
{
"data": {
"note": "Molar mass = Σ(atomic weight × count), using IUPAC conventional atomic weights. Percent is the mass fraction of each element.",
"inputs": {
"formula": "CuSO4.5H2O"
},
"elements": [
{
"count": 1,
"element": "Cu",
"percent": 25.451283,
"atomic_weight": 63.546,
"mass_contribution": 63.546
},
{
"count": 1,
"element": "S",
"percent": 12.84059,
"atomic_weight": 32.06,
"mass_contribution": 32.06
},
{
"count": 9,
"element": "O",
"percent": 57.670911,
"atomic_weight": 15.999,
"mass_contribution": 143.991
},
{
"count": 10,
"element": "H",
"percent": 4.037216,
"atomic_weight": 1.008,
"mass_contribution": 10.08
}
],
"atom_count": 21,
"molar_mass_g_mol": 249.677
},
"meta": {
"timestamp": "2026-06-04T18:38:04.898Z",
"request_id": "19ee7c8a-4f3e-40b7-96eb-ba5776846a07"
},
"status": "ok",
"message": "Molar mass",
"success": true
}