API & MCP
Everything a person can do on SMILES to 3D Coordinates (XYZ) with Force-Field Minimisation, a program or AI agent can do with the same inputs and get the identical result.
HTTP API
POST https://prooflinemoleculegeometry.usefulweb.app/api/v1/calculate– run SMILES to 3D Coordinates (XYZ) with Force-Field MinimisationGET https://prooflinemoleculegeometry.usefulweb.app/api/v1/tool– inputs, output schema, examples- OpenAPI 3.1: /openapi.json · /openapi.yaml
- Errors:
application/problem+json;422includes per-fielderrors.
SMILES to 3D Coordinates (XYZ) with Force-Field Minimisation
Turn a SMILES string or a 2-D MOL file into approximate 3-D coordinates: hydrogens are added, a start geometry is built from the 2-D layout and relaxed with a small UFF-style force field by conjugate gradients or steepest descent. You get XYZ and MOL files, the force-field energy by term, bond-length statistics, a ball-and-stick picture and any distances, angles or dihedrals you ask for. Approximate geometry, not quantum chemistry. Part of the Proofline math notebook and its Molecule Lab.
| Field | Type | Default | Description |
|---|---|---|---|
structure (required) | textarea | "CCO" | Structure. A SMILES string (CCO, c1ccccc1, [NH4+]), a MOL/SDF V2000 block or XYZ coordinates. SMILES subset: organic atoms B C N O P S F Cl Br I and aromatic b c n o p s, bracket atoms with isotope, hydrogens and charge, bonds - = # :, branches, ring numbers and %nn, dots between parts. Stereo marks are read but not used. At most 300 atoms including hydrogens. |
format | select (auto, smiles, mol, xyz) | "auto" | Format |
method | select (cg, sd) | "cg" | Minimiser |
maxIterations | integer | 2000 | Maximum iterations. Per start; minimisation stops earlier when the largest gradient is below 0.001 kcal/mol/Å. |
starts | integer | 3 | Starting structures. Different seeded start geometries; the one with the lowest energy is kept. |
measure | text | — | Measure (optional). Atom numbers of the result (hydrogens come after the heavy atoms): two for a distance, three for an angle, four for a dihedral, separated by commas. |
Example request
Ethanol with the C–O bond and the C–C–O angle
curl -X POST https://prooflinemoleculegeometry.usefulweb.app/api/v1/calculate -H 'content-type: application/json' -d '{"structure":"CCO","measure":"2-3, 1-2-3"}'
Every result contains
inputs (normalised, defaults applied), summary, result (validated against the published schema), units, assumptions, sources, warnings, computedAt and links.
MCP (Model Context Protocol)
- Streamable HTTP endpoint:
https://prooflinemoleculegeometry.usefulweb.app/mcp– protocol revisions 2026-07-28 (stateless) and 2025-11-25 / 2025-06-18 / 2025-03-26 (initialize handshake). - Tools:
proofline_molecule_geometry - Local stdio connector:
node src/mcp-stdio.ts --tool=proofline-molecule-geometry
{
"mcpServers": {
"proofline-molecule-geometry": { "type": "http", "url": "https://prooflinemoleculegeometry.usefulweb.app/mcp" }
}
}