StructureCalcs API

The same solver that powers the site — solve beams and trusses, query 2,686 steel sections, and render diagrams, over HTTP. Built for AI assistants, engineers, students, and institutions.

Quickstart

Loads: negative = downward. A gravity UDL is start: -10 — the one convention to know before your first call. Below: a complete, working call — a 6 m simply supported beam under a 10 kN/m UDL. No key required; the free anonymous tier answers immediately. The same engine powers the site — how the numbers are verified.

curl -X POST https://api.structurecalcs.com/v1/beam/solve \
  -H 'Content-Type: application/json' \
  -d '{
    "units": "SI",
    "spans":    [{ "length": 6, "E": 200, "I": 1e8 }],
    "supports": [{ "type": "pin", "position": 0 },
                 { "type": "roller", "position": 6 }],
    "loads":    [{ "type": "udl", "start": -10, "from": 0, "to": 6 }]
  }'

Response

{
  "reactions": [
    { "type": "pin",    "position": 0, "vertical": 30, "moment": 0 },
    { "type": "roller", "position": 6, "vertical": 30, "moment": 0 }
  ],
  "extremes": {
    "moment":     { "maxSagging": { "value": 45, "position": 3 }, ... },
    "deflection": { "max": { "value": -8.44, "position": 3 } }
  },
  "meta": { "engineVersion": "0.1.0+…", "units": "SI", "computeMs": 1 }
}

Pricing

Published, flat prices — no per-call metering. The free tier works in ten seconds with no signup and no identity checks. Every result is verified against classical hand calculations, and there is an MCP endpoint for AI assistants.

How limits work. Three windows, all UTC: a per-minute burst, a per-day cap (anonymous only), and a per-month cap. Each resets on its own boundary — the next minute, midnight UTC, the 1st of the month. Exceeding any one answers 429, naming the window it hit in both the detail and X-RateLimit-Window, with a Retry-After for that window; solve responses carry X-RateLimit-Remaining. Your API key is your account — there is no login or password.

TierPriceIncludes
AnonymousFree30/day · 300/month · 10/min. Try it instantly, no signup. Shared per IP address.Nothing to do — start calling.
StudentFree2,000/month · 60/min. For students, learning, and evaluation.Your own budget — the anonymous tier is shared per IP, so on a campus or office network it is consumed by whoever else is on it.Request a key
Pro$19/mo50,000/month · 300/min. For commercial projects — includes diagram rendering.
Consultancy$79/mo250,000/month · 600/min. Team use for a practice or consultancy.
Institution$499/yr100,000/month · 600/min. A yearly site licence for a school or department.
AI / Enterprise$499/mo1,000,000/month · 1,200/min. For AI assistants and platforms calling at scale, plus custom volumes.

Student keys are issued by hand, usually within a day.

How paying works

Choose a paid tier and click Subscribe. You pay on a Stripe page in your browser — never in your terminal or code — and your key appears immediately afterwards, shown once. No card details ever touch this API. You can manage or cancel any time through Stripe’s customer portal — there is no separate login. Lost the tab, or lost your key? Go to your account page and we’ll email you a secure link to manage billing or re-issue your key.

Student keys stay by request (they are free), and the anonymous tier needs nothing at all.

Frequently asked questions

Does StructureCalcs have an API and is it REST?
Yes. StructureCalcs has a public REST API at api.structurecalcs.com that runs the same solver as the website over HTTP. You POST JSON to endpoints like /v1/beam/solve and /v1/truss/solve, and GET endpoints serve the steel-section library and standards; there is also /v1/health and the OpenAPI 3.1 spec at /v1/openapi.json. Interactive reference docs and copy-paste curl, Python, and JavaScript quickstarts live on the /api page.
Is there an MCP server for StructureCalcs so AI assistants can solve beams, trusses and frames?
Yes. There is a stateless MCP server at https://api.structurecalcs.com/mcp that speaks JSON-RPC over HTTP. It exposes nine tools: solve_beam, solve_truss, solve_frame, section_properties, get_section, search_sections, render_beam_diagram, render_truss_diagram, and render_frame_diagram. You can add it to Claude Code with "claude mcp add --transport http structurecalcs https://api.structurecalcs.com/mcp", or paste the URL as a custom connector in Claude.ai.
What can I solve and render through the StructureCalcs API?
You can solve multi-span beams (point loads, uniform and linearly-varying distributed loads — which cover triangular and trapezoidal shapes — pressure/area loads, and applied moments, returning reactions plus shear, moment, rotation, and deflection with their extremes), solve 2-D pin-jointed trusses (member forces, reactions, support settlement, thermal and fabrication effects), query all 2,686 steel sections across the six standards, and render beam or truss diagrams. Diagrams are returned as SVG. There is no PDF, PNG, or report-builder endpoint in the current version.
Is the StructureCalcs API free, and what does it cost?
There is a free anonymous tier that works with no signup, capped at 30 requests per day and 300 per month per IP address with a 10-per-minute burst. A free Student key raises that to 2,000 requests per month. Paid tiers are Pro at $19/month, Consultancy at $79/month, Institution at $499/year, and AI/Enterprise at $499/month; pricing is flat, not metered. Paid tiers are self-serve: click Subscribe on the pricing table, pay by card on Stripe, and your key is shown once — manage or cancel any time in the Stripe billing portal.
How do I authenticate with the StructureCalcs API?
No authentication is needed for the free anonymous tier — you can start calling immediately. For higher limits you send your key as an HTTP header, Authorization: Bearer sc_live_..., and that key is your whole account (there is no login or password). A paid key is issued the moment you subscribe and pay on Stripe; a free Student key is issued by hand after you request one.
What units and sign conventions does the StructureCalcs API use?
Each request can set units to either SI (m, kN, kN/m, GPa, mm4) or imperial (ft, kip, k/ft, ksi, in4), matching the website’s conventions; SI is the default if you omit the field. The one sign rule to know is that loads are negative for downward, so a gravity UDL uses start: -10; support settlements are also negative for downward, and truss member forces come back tension-positive and compression-negative.

API Reference

The full contract — every endpoint, schema, and error — generated from the OpenAPI 3.1 spec.

v1.0.0
OpenAPI 3.1.0

The StructureCalcs public API: the same WASM solver that powers structurecalcs.com, at the edge.

Units — every request takes "units": "SI" (default) or "imperial"; each field documents its unit. SI = m · kN · kN/m · kPa · kN·m · GPa · mm⁴ · mm² · mm. Imperial = ft · kip · k/ft · ksf · k·ft · ksi · in⁴ · in² · in. Conversions are identical to the website’s. Sign conventions — loads negative = downward; applied moments clockwise-positive; support settlements DOWN IS NEGATIVE; truss and frame member axial forces tension-positive; frame REACTION moments clockwise-positive. Auth & limits — anonymous (no key) is a real, free, rate-limited tier. Authorization: Bearer sc_live_… lifts the limits. See the tiers below.

Accuracy — every result is held to the same hand-calculation standard as the website’s Learn examples (a permanent golden test reproduces the classical solutions through this API).

NOT in v1 (roadmap, named so nobody infers omission): server-side PDF or PNG export, the report-builder document endpoints, batch/bulk solving, async jobs, webhooks, and file storage/share links.

Server:https://api.structurecalcs.com

Production

No authentication selected
Client Libraries

Structural analysis.

SVG diagrams (the website’s figures).

The steel section library (2,600+ sections; 6 standards).

Health & the spec.

  • type
    Type: string Format: uri
    required
  • title
    Type: string
    required
  • status
    Type: integer
    required

    Integer numbers.

  • code
    Type: string enum
    required

    A stable machine code. invalid_input (400, schema/validation — see issues[]) · unauthorized (401, bad API key; ABSENCE of a key is the anonymous tier, not an error) · rate_limited (429, with Retry-After) · unstable_structure (422, a mechanism/singular system, never a 500) · engine_error (422) · payload_too_large (413) · not_found (404) · method_not_allowed (405) · stripe_error (502, an upstream Stripe rejection surfaced with Stripe’s own message + code — returned only by the self-serve account/billing endpoints, e.g. checkout/portal, never by the analysis API) · internal_error (500).

    values
    • invalid_input
    • unauthorized
    • rate_limited
    • payload_too_large
    • not_found
  • detail
    Type: string
  • issues
    Type: array object[]

    Per-field validation problems (invalid_input only) — path is the dotted JSON path.

  • units
    Type: string enum

    Unit system. SI: m, kN, kN/m, kPa, kN.m, GPa, mm4, mm2, mm. imperial: ft, kip, k/ft, ksf, k.ft, ksi, in4, in2, in.

    values
    • SI
    • imperial
  • spans
    Type: array object[] 1…20
    required

    Consecutive spans left to right; each carries its own E·I (stepped sections supported).

  • supports
    Type: array object[] 1…21
    required
  • loads
    Type: array …200
  • combinations
    Type: object
  • units
    Type: string enum

    Unit system. SI: m, kN, kN/m, kPa, kN.m, GPa, mm4, mm2, mm. imperial: ft, kip, k/ft, ksf, k.ft, ksi, in4, in2, in.

    values
    • SI
    • imperial
  • nodes
    Type: array object[] 2…300
    required
  • members
    Type: array object[] 1…1000
    required
  • materials
    Type: array object[] 1…100
    required
  • supports
    Type: array object[] 1…100
    required
  • loads
    Type: array …500
  • fabricationErrors
    Type: array …200
  • combinations
    Type: object
  • units
    Type: string enum

    Unit system. SI: m, kN, kN/m, kPa, kN.m, GPa, mm4, mm2, mm. imperial: ft, kip, k/ft, ksf, k.ft, ksi, in4, in2, in.

    values
    • SI
    • imperial
  • nodes
    Type: array object[] 2…300
    required
  • members
    Type: array object[] 1…1000
    required
  • materials
    Type: array object[] 1…100
    required
  • supports
    Type: array object[] 1…100
    required
  • nodalLoads
    Type: array object[] …500
  • memberLoads
    Type: array object[] …500
  • units
    Type: string enum

    Unit system. SI: m, kN, kN/m, kPa, kN.m, GPa, mm4, mm2, mm. imperial: ft, kip, k/ft, ksf, k.ft, ksi, in4, in2, in.

    values
    • SI
    • imperial
  • shapes
    Type: array 1…200
    required

    The pieces the section is made of. Overlapping solids are UNIONED — shared material is counted once, so you can build a section from pieces that lap over each other without inflating the area. A void removes material wherever it lies inside a solid.

  • units
    Type: string enum

    Unit system. SI: m, kN, kN/m, kPa, kN.m, GPa, mm4, mm2, mm. imperial: ft, kip, k/ft, ksf, k.ft, ksi, in4, in2, in.

    values
    • SI
    • imperial
  • spans
    Type: array object[] 1…20
    required

    Consecutive spans left to right; each carries its own E·I (stepped sections supported).

  • supports
    Type: array object[] 1…21
    required
  • loads
    Type: array …200
  • combinations
    Type: object
  • view
    Type: string enum

    Which figure: 'problem' (clean setup) · 'setup' (with reactions) · 'results' (reactions + deflected shape) · 'shear' | 'moment' | 'axial' | 'deflection' (the charts; the BMD uses the site's sagging-positive convention, and 'axial' is tension-positive and reads zero throughout unless a load is tilted).

    values
    • problem
    • setup
    • results
    • shear
    • moment
    • axial
    • deflection
  • deformed
    Type: boolean

    Overlay the deflected shape on the 'setup' view.

  • width
    Type: integer
    min:  
    400
    max:  
    2000

    SVG width in px (default 860 — the site figure width).

  • height
    Type: integer
    min:  
    150
    max:  
    1500

    SVG height in px (defaults per view: 250 beam · 240 charts · 460 truss).

  • theme
    Type: string enum

    Colour theme: 'light' (default — the paper look, byte-identical to the site's figures) or 'dark' (dark-mode figures on a slate ground).

    values
    • light
    • dark
  • style
    Type: string enum

    Drawing style: 'modern' (default — the site's textbook look: open-triangle supports with a solid hinge dot) or 'classic' (the original engineering-schematic glyphs).

    values
    • classic
    • modern
  • units
    Type: string enum

    Unit system. SI: m, kN, kN/m, kPa, kN.m, GPa, mm4, mm2, mm. imperial: ft, kip, k/ft, ksf, k.ft, ksi, in4, in2, in.

    values
    • SI
    • imperial
  • nodes
    Type: array object[] 2…300
    required
  • members
    Type: array object[] 1…1000
    required
  • materials
    Type: array object[] 1…100
    required
  • supports
    Type: array object[] 1…100
    required
  • loads
    Type: array …500
  • fabricationErrors
    Type: array …200
  • combinations
    Type: object
  • view
    Type: string enum

    Which figure: 'problem' (geometry + loads + supports) · 'results' (reactions + member forces coloured tension-red/compression-blue + deflected shape).

    values
    • problem
    • results
  • width
    Type: integer
    min:  
    400
    max:  
    2000

    SVG width in px (default 860).

  • height
    Type: integer
    min:  
    150
    max:  
    1500

    SVG height in px (default 460).

  • theme
    Type: string enum

    Colour theme: 'light' (default — the paper look, byte-identical to the site's figures) or 'dark' (dark-mode figures on a slate ground).

    values
    • light
    • dark
  • style
    Type: string enum

    Drawing style: 'modern' (default — the site's textbook look: open-triangle supports with a solid hinge dot) or 'classic' (the original engineering-schematic glyphs).

    values
    • classic
    • modern
  • units
    Type: string enum

    Unit system. SI: m, kN, kN/m, kPa, kN.m, GPa, mm4, mm2, mm. imperial: ft, kip, k/ft, ksf, k.ft, ksi, in4, in2, in.

    values
    • SI
    • imperial
  • nodes
    Type: array object[] 2…300
    required
  • members
    Type: array object[] 1…1000
    required
  • materials
    Type: array object[] 1…100
    required
  • supports
    Type: array object[] 1…100
    required
  • nodalLoads
    Type: array object[] …500
  • memberLoads
    Type: array object[] …500
  • view
    Type: string enum

    Which figure: 'problem' (geometry + supports + loads, no results) · 'results' (the solved frame with support reactions annotated) · 'deflected' (the exaggerated deflected shape, dashed, over the undeformed frame).

    values
    • problem
    • results
    • deflected
  • width
    Type: integer
    min:  
    400
    max:  
    2000

    SVG width in px (default 860).

  • height
    Type: integer
    min:  
    150
    max:  
    1500

    SVG height in px (default 420).

  • theme
    Type: string enum

    Colour theme: 'light' (default — the paper look, byte-identical to the site's figures) or 'dark' (dark-mode figures on a slate ground).

    values
    • light
    • dark
  • style
    Type: string enum

    Drawing style: 'modern' (default — the site's textbook look: open-triangle supports with a solid hinge dot) or 'classic' (the original engineering-schematic glyphs).

    values
    • classic
    • modern
  • reactions
    Type: array object[]
  • diagrams
    Type: object

    Each series is [position, value] pairs, in the display convention (sagging-positive BMD).

  • extremes
    Type: object

    Max/min with the position each occurs at.

  • meta
    Type: object ·
  • links
    Type: object ·

    links.view opens THIS EXACT model, solved, on structurecalcs.com — the SI-normalized, material-resolved model is deflate-raw + base64url encoded into the URL’s ?model= parameter. The whole links block is OMITTED when the encoded URL would exceed 2,000 characters: a model is never truncated, so the link can never show something different from this response.

  • reactions
    Type: array object[]
  • members
    Type: array object[]
  • displacements
    Type: array object[]
  • meta
    Type: object ·
  • area
    Type: number

    mm2 | in2.

  • centroid
    Type: object

    In the coordinates you supplied.

  • Ix
    Type: number

    Second moment about the centroidal x axis (mm4 | in4).

  • Iy
    Type: number
  • Ixy
    Type: number

    Product of inertia about the centroidal axes — zero for a section symmetric about either.

  • principal
    Type: object
  • rx
    Type: number
  • ry
    Type: number
  • Zx
    Type: number

    Governing ELASTIC section modulus, Ix/c (mm3 | in3). AS 4100 naming — AISC tables call this S.

  • Zy
    Type: number

    Governing ELASTIC section modulus about y, Iy/c (mm3 | in3). AS 4100 naming — AISC tables call this S.

  • elasticModuli
    Type: object

    Per-fibre elastic moduli.

  • Sx
    Type: number

    PLASTIC section modulus about x (mm3 | in3). AS 4100 naming — AISC tables call this Z.

  • Sy
    Type: number

    PLASTIC section modulus about y (mm3 | in3). AS 4100 naming — AISC tables call this Z.

  • plasticNeutralAxis
    Type: object
  • extents
    Type: object
  • notes
    Type: array string[]

    What is NOT included — currently that J and Cw are not computed.

  • meta
    Type: object ·
  • reactions
    Type: array object[]
  • memberForces
    Type: array object[]
  • displacements
    Type: array object[]
  • meta
    Type: object ·
  • links
    Type: object ·

    links.view opens THIS EXACT model, solved, on structurecalcs.com — the SI-normalized, material-resolved model is deflate-raw + base64url encoded into the URL’s ?model= parameter. The whole links block is OMITTED when the encoded URL would exceed 2,000 characters: a model is never truncated, so the link can never show something different from this response.

  • Type: array array number[][]

    [position, value] pairs.

  • engineVersion
    Type: string
  • units
    Type: string enum
    values
    • SI
    • imperial
  • unitLabels
    Type: object
  • computeMs
    Type: number
  • attribution
    Type: string

    One-line attribution: "Solved by StructureCalcs — structurecalcs.com".

  • warnings
    Type: array string[]

    Non-fatal advisories — e.g. every load points UPWARD (+), which usually means the caller assumed down-positive; the convention is NEGATIVE = downward.

  • view
    Type: string Format: uri

    Open this model, solved, in the interactive calculator.

    1. Terms of use

      By using the StructureCalcs API you agree to these terms, together with the site’s Terms of Use and Privacy Policy.

      • Acceptable use. Use the API for its intended purpose — solving structural models, querying the steel-section library, and rendering diagrams. Do not attempt to overload it, work around the rate limits, resell raw access, or use it to operate a competing hosted solver.
      • No warranty; not a substitute for engineering judgement. Results are provided “as is”, without warranty of any kind. The API is a calculation tool — a qualified engineer remains responsible for reviewing and signing off any design.
      • Limits and tiers may change. Rate limits, quotas, tier definitions, and pricing may change with reasonable notice as the service evolves.
      • Keys may be revoked. API keys that abuse the service — circumventing limits, disrupting availability, or breaching these terms — may be throttled or revoked.

      Questions? Contact us.

      Verifying your link…