# Construction calculator data as a free JSON API

> Free static JSON for 1,181 construction calculators: inputs, units and 3,536 test vectors, plus takeoffs and codes. No key, CC BY 4.0.

Page: https://craftquantities.com/api/ (page). This is the page's Markdown copy; the HTML page is the canonical version.

Every input, bound, unit and test vector behind the 1,181 construction calculators on this site, with the 79 job takeoffs, the codes they cite, a cross-market glossary and the corrections ledger — as plain JSON files on a CDN. No key, no quota and no rate limit, because there is nothing to meter.

- 1,181 Calculators, one file each
- 3,536 Published test vectors
- 8,214 Links between pages

- [Open index.json](https://craftquantities.com/api/v1/index.json)
- Every endpoint

Quick start

## Three requests to a working integration

Discover, list, then fetch the one file you need. Every request is a plain GET for a static file.

1. ### Read the index

   index.json names every endpoint and carries the current counts, so nothing has to be hard-coded.

   [/api/v1/index.json](https://craftquantities.com/api/v1/index.json)
2. ### List the calculators

   calculators.json has one row per calculator: its slug, category, title, page and its own file's address.

   [/api/v1/calculators.json](https://craftquantities.com/api/v1/calculators.json)
3. ### Fetch one calculator

   Each calculator's file holds every input with its dimension, bounds and default, its sources and its test vectors.

   [/api/v1/calculators/concrete-calculator.json](https://craftquantities.com/api/v1/calculators/concrete-calculator.json)

```
# 1. What exists, and how much of it
curl -s https://craftquantities.com/api/v1/index.json

# 2. The catalogue: one row per calculator
curl -s https://craftquantities.com/api/v1/calculators.json

# 3. One calculator in full: inputs, bounds, sources, test vectors
curl -s https://craftquantities.com/api/v1/calculators/concrete-calculator.json
```

13 endpoints

## Every endpoint

All GET, all JSON, all under /api/v1/. A path in braces is a pattern; its link opens one real file.

**Every file the API publishes, what it returns and what to use it for**

| Endpoint | Returns | Use it for |
|---|---|---|
| Index GET [/api/v1/index.json](https://craftquantities.com/api/v1/index.json) | Every endpoint's address and the current counts. Fetch it first. | Discovering what exists, and reading counts instead of hard-coding them. |
| Calculator catalogue GET [/api/v1/calculators.json](https://craftquantities.com/api/v1/calculators.json) | One row per calculator: slug, category, title, description, page URL, its own file's URL, and how many inputs, test vectors and sources it has. | Building a search or an index, or checking a slug exists before linking to it. |
| One calculator GET [/api/v1/calculators/{slug}.json](https://craftquantities.com/api/v1/calculators/concrete-calculator.json) | The catalogue row plus every input (type, dimension, default, bounds, options, which inputs hold money), its sources, its test vectors with worked steps, a citation block, and the takeoffs that run it. | Driving or re-implementing one calculation, and checking it against the published vectors. |
| Job takeoffs GET [/api/v1/assemblies.json](https://craftquantities.com/api/v1/assemblies.json) | Each job takeoff and the calculators it runs, in order, with the reason each one is part of the job. | Seeing which calculations a whole job needs, and in what order. |
| Codes and standards registry GET [/api/v1/standards.json](https://craftquantities.com/api/v1/standards.json) | The code families (title, abbreviations, publisher, what each governs, the jurisdiction it is written for, published editions) and the bodies that publish them. | Resolving an abbreviation in a specification to the document and its publisher. |
| One standard GET [/api/v1/standards/{body}/{id}.json](https://craftquantities.com/api/v1/standards/icc/irc.json) | What one cited code governs, its editions, and every calculator that cites it — grouped by section where the citation names one. | Finding every calculation that relies on a given code, section by section. |
| Reference table GET [/api/v1/reference/{table}.json](https://craftquantities.com/api/v1/reference/bulk-densities.json) | One reference data table with each row's source kept beside it, and the calculators that compute with each row. | Using a cited construction dataset — densities, conductor ampacities, labour rates — without losing its sources. |
| Corrections ledger GET [/api/v1/corrections.json](https://craftquantities.com/api/v1/corrections.json) | The confirmed errors the ledger records: what was wrong, what is right, what now prevents it, and the date it was found. Append-only. | Auditing the error record, or citing one correction by its id. |
| Units and conversion factors GET [/api/v1/units.json](https://craftquantities.com/api/v1/units.json) | Every dimension and unit with its exact factor to the dimension's base unit, and the offset the temperature scales need. | Converting a value into the base unit the inputs and vectors use, exactly as the site does. |
| Cross-market glossary GET [/api/v1/glossary.json](https://craftquantities.com/api/v1/glossary.json) | Each construction concept with its name in US, Canadian, UK and Australian usage, and how close each name really is. | Translating a construction term between markets without assuming two words mean the same thing. |
| Validation corpus GET [/api/v1/validation.json](https://craftquantities.com/api/v1/validation.json) | Every test vector the test suite runs, with worked steps and a measured account of the corpus's own gaps. | Checking the maths in bulk. For one calculator, its own file is a few kilobytes instead. |
| Link graph GET [/api/v1/link-graph.json](https://craftquantities.com/api/v1/link-graph.json) | Every link between a calculator and a page of another kind — guide, standard, takeoff, glossary term, worked example — grouped by page. | Finding every page that names a calculator, or every calculator a page names. |
| Worked examples GET [/api/v1/examples.json](https://craftquantities.com/api/v1/examples.json) | Each worked job: its measurements, and every step with the calculator it runs, the inputs in base units, the answer and the figure the page prints. | Testing a re-implementation against whole jobs rather than single calculations, in the order a trade does them. |

Anatomy of a file

## What every file carries, and what one calculator holds

Trimmed from the real files. Open any link above for the whole thing.

_Every file opens with these seven fields_

```
{
  "version": "v1",
  "source": "https://craftquantities.com",
  "licence": "CC BY 4.0",
  "licenceUrl": "https://creativecommons.org/licenses/by/4.0/",
  "attribution": "Craft Quantities — craftquantities.com",
  "documentation": "https://craftquantities.com/api/",
  "versioning": "Fields are added, never removed or repurposed, within a version. A breaking change becomes /api/v2/ and v1 keeps being built."
}
```

_index.json (trimmed)_

```
{
  "endpoints": {
    "calculators": "https://craftquantities.com/api/v1/calculators.json",
    "calculator": "https://craftquantities.com/api/v1/calculators/{slug}.json",
    "units": "https://craftquantities.com/api/v1/units.json",
    "validation": "https://craftquantities.com/api/v1/validation.json"
  },
  "counts": {
    "calculators": 1181,
    "assemblies": 79,
    "validationVectors": 3536,
    "linkGraphLinks": 8214
  }
}
```

_calculators/concrete-calculator.json (trimmed)_

```
{
  "slug": "concrete-calculator",
  "category": "materials-quantities",
  "title": "Concrete Calculator",
  "inputs": [
    {
      "id": "slabLength",
      "label": "Slab Length",
      "type": "number",
      "dimension": "length",
      "defaultValue": 3,
      "min": 0.01,
      "max": 50,
      "step": 0.1
    }
  ],
  "testCases": [
    {
      "name": "3x3m slab, 0.1m thick, 10% waste",
      "inputs": { "slabLength": 3, "slabWidth": 3, "slabThickness": 0.1, "wasteFactorPercent": 10 },
      "expected": 1.29,
      "toleranceDecimalPlaces": 1,
      "unit": "cubic yards"
    }
  ]
}
```

Values are in base units. A dimensioned input’s default, bounds and step, and every test vector’s inputs, are in its dimension’s base unit — slabLength’s 3 is metres. A money input whose default is an empty string is a rate the caller must supply, not zero. `toleranceDecimalPlaces` counts decimal places, and is two where absent.

Units

## Every dimensioned value is in its base unit

Convert anything else with units.json: base value = (value + offsetToBase) × toBase. Only the temperature scales carry an offset.

- length

  Meters m

  1 ft = 0.3048 m
- area

  Square Meters m²

  1 sq ft = 0.09290304 m²
- volume

  Liters L

  1 gal = 3.785411784 L
- weight

  Kilograms kg

  1 lb = 0.45359237 kg
- temperature

  Celsius °C

  °C = (°F − 32) × 0.5555555556
- pressure

  Pascals Pa

  1 psf = 47.88025898 Pa
- flow

  Liters per minute L/min

  1 gal/min = 3.785411784 L/min
- density

  Kilograms per cubic meter kg/m³

  1 pcf = 16.01846337 kg/m³

## Licence and credit

**CC BY 4.0.** Use it commercially, build on it and redistribute it; credit Craft Quantities and link back. The licence and the credit line are repeated inside every file, for whoever has the JSON open and not this page. It covers these data files, not the site’s software or pages, which are not licensed for reuse.

_Credit line_

```
Data: <a href="https://craftquantities.com/">Craft Quantities</a>, CC BY 4.0
```

## Caching and change

Files are cached for an hour and carry an ETag: a request with If-None-Match returns 304 when nothing has changed. The build that produced them is named at [/build-info.json](https://craftquantities.com/build-info.json).

Inside v1, fields are only ever added. An incompatible change would become /api/v2/, and v1 would keep being built.

## Calling it from a browser

Every file is sent with Access-Control-Allow-Origin: \*, so a plain fetch works from any origin. Keep to simple GET or HEAD requests: custom headers trigger a CORS preflight, which a static host does not answer.

A missing file returns the site’s HTML 404 page, not JSON — check `response.ok` before parsing, as the quick start does.

Executable API and MCP

## Run a calculator, not just read it

The same calculators, computed on request for a program or an AI assistant, at https://api.craftquantities.com/v1/ and as an MCP server at https://api.craftquantities.com/mcp.

**Each engine tool, its HTTP route and what it does**

| Tool and route | What it does |
|---|---|
| `search`GET/v1/search?q={words} | Finds calculators by what the job is, in American, British or Australian words; returns ids and slugs, best first. |
| `fetch`MCP | One search result as a plain-text document: what the calculator works out, each input with its units and opening value, its sources and how to cite it. |
| `get_calculator`GET/v1/describe/{slug} | Each input's id, accepted units, range, options and the value the page opens on in both systems, with sources, version and a citation. |
| `calculate`GET, POST/v1/calculate/{slug} | Runs the calculator as its page does. The answer in metric and US customary, each input used and where it came from, the breakdown, the version, the sources, a citation and a link. |
| `convert_units`GET/v1/convert?value=&from=&to= | Converts between the units the calculators use, by the exact statutory factors in units.json. |
| `get_sources`GET/v1/sources/{slug} | The sources as the calculator cites them, the codes and standards they name, the matching standards pages here, and the citation in four formats. |
| `open_in_site_link`GET, POST/v1/link/{slug} | A link that opens the calculator's page with the same inputs and unit system, for handing the working to a person. |
| `get_takeoff`GET/v1/takeoff/{id} | A whole-job takeoff's measurements with their units and opening figures, its build-up choices, the calculators it runs and what it leaves out. |
| `run_takeoff`GET, POST/v1/takeoff/{id}/run | Works the whole job as its takeoff page does: every row's quantity, what to order, the allowance and its source, every input and where it came from, both systems, the sources and a link to the page on this job. |
| `get_example`GET/v1/example/{slug} | A worked example as published: the measurements, the calculators in order and why, and the figure each step pins. |
| `run_example`GET/v1/example/{slug}/run | Runs every pinned step of a worked example now, in both systems, and says whether each still meets the published figure. |
| `create_project_file_from_calculations`POST/v1/my-project-file | A My Project backup file from calculator lines, each computed as the page adds it, for Restore from a backup. Nothing is stored; no prices. |
| `create_project_file_from_takeoffs`POST/v1/my-project-file | A My Project backup file from whole-job takeoffs, each worked as its page commits it. Nothing is stored; no prices. |
| `create_project_file_from_house`POST/v1/my-project-file | A My Project backup file from a House Estimator form: its lines and its drawing, which the canvas reopens. Nothing is stored; no prices. |
| `create_project_file_from_plan`POST/v1/my-project-file | A My Project backup file from a room plan (one space, or spaces and a roof), saved as the planner saves it. Nothing is stored; no prices. |
| `create_project_file_from_drawing`POST/v1/my-project-file | A My Project backup file from a Construction Canvas drawing: its lines and the drawing itself. Nothing is stored; no prices. |
| `check_quote`POST/v1/check/{slug} | Reads a contractor's quote against the reader's own job as the site's quote check does: each quantity against the range the job's calculators give, what it leaves out and adds, and the questions to ask. Money is taken out and never judged; nothing is kept. |
| `estimate_house`GET, POST/v1/house | The House Estimator: a one- or two-storey house drawn from the form, and every quantity of its footing, slab, walls, openings and roof with what to order, both systems, what the drawing could not hold, its assumptions, each storey's plan and labour hours. It counts; it never designs. |
| `get_planner`GET/v1/planner/{kind} | The room planner's own ids for one kind of space: its figures, surfaces and finishes, scope questions, trades, rows and how a decision is written, stable within the model schema version it names. |
| `plan_room`POST/v1/plan | Plans one space as the site's planner does — a room, bathroom, slab, deck, driveway, fence, loft, retaining wall, exterior wall or stair — and returns every row it works, what it waits for, what is not built and why, the finishes compared, labour hours and the plan. |
| `plan_project`POST/v1/plan-project | Plans several spaces in one planner model — rooms, bathrooms, slabs, decks and the rest — and a roof over the rooms and bathrooms with its pitch, as the site's planner holds a whole project; each space's rows, every line together, labour hours and the plan. |
| `create_drawing`POST/v1/drawing | Makes a Construction Canvas drawing from simple shapes (a room with doors and windows, a deck, patio, bed or path, a fence of legs and turns), from the House Estimator's form, from drawing commands or from a canvas document, lists every material the canvas lists for it, and returns a one-click link that opens it on the canvas and a My Project file that carries it. |
| `import_quote`POST/v1/quote-import | The reader's own quote, prices and all, read as Quote to Estimate reads it, its arithmetic checked, and returned as a My Project file. The prices are the reader's figures, never the site's. |
| `diagnose_symptom`GET, POST/v1/diagnose?symptom={words} | Matches a defect described in plain words to the site's diagnosis pages: each candidate cause with what tells it apart and the one check, the checks in order and when to call a professional. Never says which cause you have; ambiguous words return the candidates. |
| `solve_backwards`GET, POST/v1/solve/{page}?have={amount} | Works backwards from what the reader has — sheets, tins, bags, bricks, a volume — to the area and the room, wall, deck or slab it covers, as the Solve Backwards page does: its calculator at its own settings, the waste taken off. Never sizes structure. |
| `market_documents`GET/v1/documents?market={market}&subject={words} | Names the family of codes or standards that governs a kind of work, or a calculator's subject, in the US, Canada, the UK or Australia, who publishes it and the site's page for it — never an edition or a date. Adoption is local; the answer says who decides. |
| `translate_term`GET/v1/term?term={word}&from={market}&to={market} | A trade word in each market's usage — plasterboard and drywall, skirting and baseboard — matched however it is written (a brand said for the product such as gyprock or sheetrock, spaced, plural or misspelt), how close each equivalent is, the warning where the same word is a false friend, each market's unit system, the unit traps it raises (US and imperial gallons, short, long and metric tons, the survey foot, board feet, a yard of concrete, bag sizes) with their conversions, and the market's document family — never an edition. |
| `create_supplier_quote_request`POST/v1/supplier-quote-request | Turns a bill of materials into a request for quote to merchants, as the site's request does: Markdown to paste, a CSV, the site's link each merchant opens to price it, and a My Project file. It carries no price and sends nothing. |
| `get_benchmark`GET/v1/benchmark?page={n} | The Construction Quantities Benchmark a page at a time, or one calculator's items: each question's inputs and prompt in metric and US units, the answer the page gives in each with its tolerance, and the worked steps, with the dataset's edition, download and citation. CC BY 4.0; no model results. |
| `measure_sketch`POST/v1/sketch | Measures areas, perimeters and lengths from points an assistant reads off a plan, sketch or photo, scaled by one known dimension or an ID-1 card, A4 or Letter sheet in the same image: both systems, an uncertainty band from the pixel error and the reference, closure and crossing checks, optionally a calculator run on the figure, and a link that opens the scaled shapes on the canvas. No image is sent. |
| `export_drawing`POST/v1/drawing-export | A Construction Canvas drawing (a template, shapes, a room layout, commands, house figures or a canvas document) as DXF with the site's CQ-\* layers and as SVG, one plan per level in millimetres, painted by the canvas's own exporters; a file too large to return is rebuilt from the drawing's link. |
| `layout_reinforcement`POST/v1/rebar-layout | A bar layout for a rectangular slab or footing from the bar size, spacing and cover the engineer gives: bars each way inside the cover by the Rebar Calculator's count, bar lengths, total with lap, stock sticks, weight where the Rebar Weight Calculator carries the size, a bar schedule (each mark's size, count, length with its laps at the lap length given, and weight from the nominal diameter) with the stock to buy from the site's cut optimiser (engine 1.7.0), and the layout as SVG and DXF. A quantity layout, never a design. |
| `calculate_batch`POST/v1/calculate-batch | Up to 25 calculator runs in one request, each a slug or permanent id with its own inputs, each answered exactly as calculate answers it, in order; a refused run leaves the others answered. |
| `update_project`POST/v1/project-update | Changes a project carried in a state token — a space added or removed, a dimension changed, a takeoff or calculator line added or removed, a roof's pitch — rebuilds every line and returns the new token, the diff, the totals and a link that opens it in My Project. The token is compact, not encrypted; nothing is stored. |
| `classify_items`POST/v1/classify | Groups lines, calculators or a project's token by MasterFormat 2018 division with My Project's own rule: a suggestion to read a list by, not a specification. No Uniclass or NRM grouping, which no calculator here cites. |
| `resolve_id`GET/v1/id/{id} | A permanent id, an old slug or a site address to the page as it is today, with its slug history. Every calculator, takeoff, guide, worked example, glossary term and diagnosis has one; /id/<id>/ on the site redirects to it. |
| `plan_programme`POST/v1/programme | A build programme from a project's labour hours (a state token, a My Project file, takeoffs or a drawing): tasks by trade, stage and level in the usual order of work, each the site's labour hours or the reader's own over the crew and working day given, in working days rounded up to the half day, with level-by-level overlaps, totals, a CSV and, with a start date, a calendar file. A planning aid in hours and days, no prices; a contractor's programme decides. |
| `optimise_cuts`POST/v1/optimise-cuts | A cut list optimised with the site's own optimiser, as its cut-list tool and the Construction Canvas run it: pieces cut from the stock lengths a merchant sells, or rectangles nested on sheets in edge-to-edge cuts; the stock or sheets to buy, a cutting plan per bar or sheet, the real waste and the bound no plan beats. A piece no stock takes is listed, never split. |
| `estimate_hours`POST/v1/hours | The estimated person-hours on every line of a project, as My Project shows them (hours typed on a line, else the band an operation's production rate gives its quantity, else why there are none), and the project's person-hours and crew-days at the crew and working day given. From a state token, a My Project file, calculators, takeoffs or a drawing. Hours only, never money. |
| `compare_on_job`POST/v1/compare-on-job | A comparison page's two options worked on one job: each side's quantity in both unit systems, allowance, weight and person-hours, the difference in the measure both share, and where the two cross as one job figure is swept, each point run through the calculators' own pipeline. No prices. |
| `run_guide_chain`POST/v1/guide-chain | A guide's "Try the calculation" on the caller's figures: each step's calculator in the guide's order, the materials to buy with waste and order quantities, the checks between them, both unit systems, the person-hours and the guide's own link that opens the block on these figures. |
| `run_example_live`POST/v1/example-live | A worked example with the job's figures changed: each change carried down every step that reads it, each step beside its published figure with the difference, both unit systems, the project lines it makes with their offered hours, and the example's #live= link. A modelled job, not a record. |
| `stair_flight`POST/v1/stair | A stair laid out as built, by the stair pages' own code: risers, goings, pitch, 2R+G, the floor opening for a headroom, the stringer as cut and the timber and fixings (straight, or an L or U on a landing or winders), concrete, formwork and bars (cast), or steel mass (stringers), every length in both systems, the limits read against a named code (never compliance) and a canvas link. The stringer, waist, bars and section are the reader's; nothing is sized. |
| `level_quotes`POST/v1/level-quotes | Two to six quotes for one job levelled line by line against the job's own lines, by the quote check's own reader: included (and where its quantity sits against the job's range, both systems), left out, excluded in words or covered by an alternative; what each adds; the scopes each names; the questions to ask; CSV files. Money is taken out first: no total, no score, no ranking. |
| `write_variation`POST/v1/variation | The variation (change order) between an agreed and a proposed version of a project, by My Project's own code: every line added, removed or changed with its quantity in metric and imperial, the labour hours, and the document as the site prints it. Money only from the reader's own rates (in the files or passed); with none, unpriced. |
| `write_proposal`POST/v1/proposal | The client proposal My Project prints, from a project: the scope by line or trade division, a quantities summary in both systems, assumptions, exclusions, terms, stages of payment and the signature block, every word and figure formatted. Every line "Not priced" unless the reader's own rates are on it or passed. |
| `make_job_sheet`POST/v1/job-sheet | A takeoff's one-page job sheet, as its PDF button builds it: the job's picture as SVG, the key dimensions in metric and imperial, the build-up, the materials going in with what to buy where the takeoff knows a pack, the labour hours by trade, and the link that reopens the takeoff on these figures. No prices. |
| `make_canvas_link`POST/v1/canvas-link | A takeoff the Construction Canvas wraps, or a worked example it draws, at the caller's figures, as a canvas drawing built through the canvas's own commands, in a #d= link that opens it (the fragment never reaches a server), with what the drawing cannot carry. A drawing for quantities, not a construction drawing. |
| `get_illustration`POST/v1/illustration | The topic illustration a page carries, as the SVG's address on the site with its subject in words: one per guide, comparison, diagnosis, worked or calculator example, category, material hub, solve-backwards question and site page, and a shared plate for the glossary, methods, policies, standards, reference tables and tools. Drawings with no figures in them. |
| `trim_corner`POST/v1/trim-corner | One corner of skirting/baseboard, casing/architrave or crown/cornice cut on a named saw from the site's library (or the reader's own limits), by the miter-angle page's own solver: per piece the mitre and bevel as the saw's dials read them, the stop each sits on or how far it is from one, how the piece lies on the saw, which side of the blade to keep, and whether the saw can make the cut (with what to do if not); cope or mitre, and the gap a 45° cut would leave, in both unit systems. Cutting geometry only. |
| `plan_room_trim`POST/v1/room-trim | Skirting, crown or picture rail planned round a whole room, by the room trim plan's own code: walls and corners as measured, door openings and built-ins, every piece numbered in fitting order with its long- and short-point lengths in both systems, each end's cope, mitre, butt or 45° scarf (placed on studs when the stud layout is given) with its saw settings, the cut list per stock length and the stock to buy. |
| `scribe_template`POST/v1/scribe-template | The scribe line for a board against an uneven wall, by the scribe template calculator's own code: from gaps measured off a straight line (or a preset wall shape), the widest and narrowest gap, the board width to start from, the strip to cut away, the line itself as full-size SVG and DXF, and how the full-size template tiles on A4, A3, Letter, Tabloid or a roll. A pattern for the cut, not a fit. |
| `fit_panel`POST/v1/fit-panel | A worktop, shelf or panel fitted between walls that are not square, by the panel fit's own code: the true shape with its front and back lengths, setbacks and diagonals, the blank with the scribe allowance and the back wall's bow, then the blank and any other parts nested on the market's stock sizes with part ids, grain held, the saw cuts in order, offcuts worth keeping and edge banding. Geometry and quantities only. |
| `fit_worktop_run`POST/v1/worktop-run | A worktop run along several wall faces, as the Construction Canvas's worktop cuts it: each piece's true shape at the room's real angles, butt or mitre joints at the corners, a straight longer than the stock joined, the front run and the free ends, and every blank nested on worktop lengths with the cut order and the edge banding, in both unit systems. Support, overhangs and loads are the maker's. |
| `miter_chart`POST/v1/miter-chart | The mitre saw angle chart, from the same library as the page: for each corner angle the mitre each piece takes, the outside corner read through the room, the gap a 45° cut leaves on 18 mm and 3/4 in trim and where it opens, crown laid flat at 38/52 and 45/45 (mitre and bevel), and the handing table at a square corner; the site's corners from 80° to 150°, or any asked for. |
| `print_template`POST/v1/print-template | The full-size template a calculator page prints, by the page's own template code: a stair stringer or its step gauge, a rafter's cuts or the whole rafter, a cone or frustum pattern, an arch's centring or voussoirs, an anchor bolt setting board or plate, a curved wall's plate, a spiral stair's tread or landing, a turn's winder blanks, a housed string or ship's ladder stringer, a split stair's stringers, a handrail's gooseneck or easing; the calculator's inputs and the template's own figures in, the lines out as full-size SVG and DXF with the checks to measure, what the template does not show, the structural notice where it applies, and the tiling on A4, Letter or a roll. A pattern for marking out, never a design. |
| `edit_drawing`POST/v1/drawing-edit | A Construction Canvas drawing changed and handed back, by the canvas's own commands: the drawing arrives as its link, its document or any form create_drawing takes, and each edit is one the canvas's editor makes — a wall moved by a vector or a compass direction with the walls joined to it following so the room stays closed, a wall's length set, a door or window added (centred unless an offset is given), properties or the build-up type set, an object removed with its openings, or any drawing command added. A wall can be named by the side it faces, of a room or of the building; where more than one wall answers, the edit is refused with the candidates, never guessed. The answer is the edited drawing (it passes the canvas's own checks), the link that opens it, what changed object by object, and the canvas dock's quantities that moved, before and after, in both unit systems. Quantities only; nothing is sized. |
| `plan_set_takeoff`POST/v1/plan-set-takeoff | A set of plan sheets taken off as the plan takeoff takes them: each sheet with its own scale, set from a line whose real length is known or given as pixels per millimetre, and the counts, lengths and areas read off the sheets as points in each sheet's own pixels. Marks with one layer name add up across the sheets, each measured with its own sheet's scale, and the answer is each layer's total and each sheet's share in metric and US units, with an area's perimeter. A length or area on a sheet with no scale is left out of the totals and counted as unscaled, never added as zero. The engine receives no drawing; quantities only. |
| `roof_framing`POST/v1/roof-framing | A gable or hip roof laid out from the caller's own sizes as the roof framing tool lays it out, with an optional equal-pitch gable wing and its valleys: each common, king common, hip, valley, jack and cripple rafter with its count and hands, its length along the measuring line after the deductions, its tail, the board it needs, the birdsmouth with its height above the plate, the plumb and cheek cuts as saw settings (mitre and bevel, and the angle on the top edge), and the hip's backing or drop; the ridge and fascia runs; a cut list against the caller's stock lengths, where no rafter is ever joined; and, on request, one member's full-size template as SVG and DXF in millimetres. Both unit systems. The geometry of the members given, never their size. |

```
curl "https://api.craftquantities.com/v1/calculate/concrete-calculator?slabLength=3%20m&slabWidth=3%20m&slabThickness=10%20cm"
```

MCP protocol versions 2026-07-28, 2025-11-25, 2025-06-18, 2025-03-26; the server card is at [/mcp/server-card](https://api.craftquantities.com/mcp/server-card), the OpenAPI description at [/openapi.json](https://api.craftquantities.com/openapi.json) and the API catalogue at [/.well-known/api-catalog](https://api.craftquantities.com/.well-known/api-catalog).

### Every tool, worked

One call for each tool, as an MCP client sends it and as the same request over HTTP. The test suite runs every one of them.

**`search` — Which calculator works out a concrete slab?**

```
{
  "query": "concrete slab",
  "limit": 3
}
```

**`fetch` — Everything about the concrete calculator, as one document.**

```
{
  "id": "calculator:concrete-calculator"
}
```

**`get_calculator` — What does the paint calculator ask for?**

```
{
  "slug": "paint-calculator"
}
```

**`calculate` — How much concrete for a 10 × 10 ft slab, 4 inches thick?**

```
{
  "slug": "concrete-calculator",
  "inputs": {
    "slabLength": "10 ft",
    "slabWidth": "10 ft",
    "slabThickness": "4 in"
  },
  "system": "imperial"
}
```

**`convert_units` — 10 feet in metres.**

```
{
  "value": 10,
  "from": "ft",
  "to": "m"
}
```

**`get_sources` — Where do the concrete calculator's figures come from?**

```
{
  "slug": "concrete-calculator"
}
```

**`open_in_site_link` — A link that opens the concrete calculator on a 3 × 3 m slab.**

```
{
  "slug": "concrete-calculator",
  "inputs": {
    "slabLength": "3 m",
    "slabWidth": "3 m",
    "slabThickness": "10 cm"
  }
}
```

**`get_takeoff` — What does the concrete slab takeoff measure?**

```
{
  "takeoff": "concrete-slab"
}
```

**`run_takeoff` — Everything to order for a 6 × 4 m slab, 100 mm thick.**

```
{
  "takeoff": "concrete-slab",
  "measurements": {
    "length": "6 m",
    "width": "4 m",
    "thickness": "100 mm"
  },
  "system": "metric"
}
```

**`get_example` — The published bathroom re-tile example.**

```
{
  "slug": "bathroom-gutted-and-retiled"
}
```

**`run_example` — Does the bathroom example still meet its published figures?**

```
{
  "slug": "bathroom-gutted-and-retiled"
}
```

**`create_project_file_from_calculations` — A My Project file with the garage slab's concrete.**

```
{
  "name": "Garage slab",
  "system": "metric",
  "calculators": [
    {
      "slug": "concrete-calculator",
      "inputs": {
        "slabLength": "6 m",
        "slabWidth": "4 m",
        "slabThickness": "100 mm"
      }
    }
  ]
}
```

**`create_project_file_from_takeoffs` — A My Project file with the garage slab's takeoff.**

```
{
  "name": "Garage slab",
  "system": "metric",
  "takeoffs": [
    {
      "takeoff": "concrete-slab",
      "measurements": {
        "length": "6 m",
        "width": "4 m",
        "thickness": "100 mm"
      }
    }
  ]
}
```

**`create_project_file_from_house` — A My Project file for the House Estimator's opening house, with its drawing.**

```
{
  "name": "House",
  "system": "metric",
  "houses": [
    {}
  ]
}
```

**`create_project_file_from_plan` — A My Project file for a 4 × 3 m bedroom.**

```
{
  "name": "Bedroom",
  "system": "metric",
  "plan": {
    "kind": "room",
    "name": "Bedroom",
    "figures": {
      "length": "4 m",
      "width": "3 m",
      "height": "2.4 m"
    },
    "doors": {
      "count": 1
    },
    "windows": {
      "count": 1
    }
  }
}
```

**`create_project_file_from_drawing` — A My Project file for a 6 × 4 m deck drawn on the canvas.**

```
{
  "name": "Deck",
  "system": "metric",
  "drawing": {
    "shapes": [
      {
        "shape": "deck",
        "width": "6 m",
        "depth": "4 m"
      }
    ]
  }
}
```

**`check_quote` — Is anything missing from this bathroom quote?**

```
{
  "job": "bathroom-quote",
  "quote": "Wall and floor tiles 12 m2\nTile adhesive 6 bags\nGrout 3 bags"
}
```

**`estimate_house` — Everything a 12 × 8 m one-storey house is built from.**

```
{
  "values": {
    "length": "12 m",
    "width": "8 m",
    "windows": 6,
    "outsideDoors": 2
  },
  "storeys": 1,
  "system": "metric"
}
```

**`get_planner` — What does the planner ask for a deck?**

```
{
  "kind": "deck"
}
```

**`plan_room` — Plan a 4 × 3 m bedroom with a door and two windows.**

```
{
  "kind": "room",
  "figures": {
    "length": "4 m",
    "width": "3 m",
    "height": "2.4 m"
  },
  "doors": {
    "count": 1
  },
  "windows": {
    "count": 2
  },
  "name": "Bedroom"
}
```

**`plan_project` — Plan a bedroom and a bathroom with a 6-in-12 roof over both.**

```
{
  "spaces": [
    {
      "kind": "room",
      "name": "Bedroom",
      "figures": {
        "length": "4 m",
        "width": "3 m",
        "height": "2.4 m"
      },
      "doors": {
        "count": 1
      },
      "windows": {
        "count": 2
      }
    },
    {
      "kind": "bathroom",
      "figures": {
        "length": "2.5 m",
        "width": "2 m",
        "height": "2.4 m"
      },
      "doors": {
        "count": 1
      }
    }
  ],
  "roof": {
    "pitch": 6
  }
}
```

**`create_drawing` — Draw a 6 × 4 m studio with a door and a window, list it, and give me the file.**

```
{
  "commands": [
    {
      "op": "wall",
      "ref": "south",
      "from": {
        "x": "0 m",
        "y": "0 m"
      },
      "to": {
        "x": "6 m",
        "y": "0 m"
      }
    },
    {
      "op": "wall",
      "from": {
        "x": "6 m",
        "y": "0 m"
      },
      "to": {
        "x": "6 m",
        "y": "4 m"
      }
    },
    {
      "op": "wall",
      "from": {
        "x": "6 m",
        "y": "4 m"
      },
      "to": {
        "x": "0 m",
        "y": "4 m"
      }
    },
    {
      "op": "wall",
      "from": {
        "x": "0 m",
        "y": "4 m"
      },
      "to": {
        "x": "0 m",
        "y": "0 m"
      }
    },
    {
      "op": "opening",
      "kind": "door",
      "wall": "south",
      "offset": "1.5 m",
      "p": {
        "exterior": true
      }
    },
    {
      "op": "opening",
      "kind": "window",
      "wall": "south",
      "offset": "4 m"
    },
    {
      "op": "room",
      "name": "Studio",
      "at": {
        "x": "3 m",
        "y": "2 m"
      }
    }
  ],
  "name": "Studio",
  "system": "metric"
}
```

**`import_quote` — Turn my supplier's quote into a My Project file, prices and all.**

```
{
  "quote": "Plasterboard 12.5 mm 30 sheets @ 9.50\nJointing compound 4 bags @ 12.00",
  "currency": "£",
  "supplier": "Builders' merchant"
}
```

**`diagnose_symptom` — My breaker keeps tripping. What could it be, and how do I tell?**

```
{
  "symptom": "breaker keeps tripping"
}
```

**`solve_backwards` — I have 24 gallons of wall paint. How much wall will it cover?**

```
{
  "page": "wall-paint",
  "have": "24 gal"
}
```

**`market_documents` — Which document governs wiring a kitchen in England, and who decides what is in force?**

```
{
  "market": "England",
  "subject": "kitchen wiring"
}
```

**`translate_term` — My American contractor says "casing". What is that in the UK, and is it the same thing?**

```
{
  "term": "casing",
  "from": "US",
  "to": "UK"
}
```

**`create_supplier_quote_request` — Turn my slab's bill into a request for quote I can send to two merchants.**

```
{
  "project": "Garage slab",
  "market": "UK",
  "items": [
    {
      "description": "Ready-mix concrete, C25/30",
      "quantity": 2.64,
      "unit": "m³",
      "notes": "Pump access from the drive"
    },
    {
      "description": "Rebar, 12 mm, 12 m lengths",
      "quantity": 11,
      "unit": "sticks"
    },
    {
      "description": "Formwork boards, 2.4 m",
      "quantity": 10,
      "unit": "boards"
    }
  ]
}
```

**`get_benchmark` — Show me the benchmark items for the concrete calculator, with the answer in both unit systems.**

```
{
  "calculator": "concrete-calculator"
}
```

**`measure_sketch` — From the plan in my photo: the living room's floor area and the fence along the garden, scaled from the 6 m dimension.**

```
{
  "reference": {
    "dimension": {
      "from": {
        "x": 100,
        "y": 80
      },
      "to": {
        "x": 700,
        "y": 80
      },
      "length": "6 m"
    }
  },
  "shapes": [
    {
      "name": "Living room",
      "kind": "area",
      "points": [
        {
          "x": 100,
          "y": 100
        },
        {
          "x": 700,
          "y": 100
        },
        {
          "x": 700,
          "y": 500
        },
        {
          "x": 400,
          "y": 500
        },
        {
          "x": 400,
          "y": 350
        },
        {
          "x": 100,
          "y": 350
        }
      ],
      "calculator": {
        "slug": "self-leveling-underlayment-calculator",
        "input": "floorArea"
      }
    },
    {
      "name": "Garden fence",
      "kind": "length",
      "as": "fence",
      "points": [
        {
          "x": 100,
          "y": 600
        },
        {
          "x": 700,
          "y": 600
        },
        {
          "x": 700,
          "y": 800
        }
      ]
    }
  ],
  "system": "metric"
}
```

**`export_drawing` — The single-room template as a DXF and an SVG I can open in CAD.**

```
{
  "template": "single-room",
  "system": "metric"
}
```

**`layout_reinforcement` — Lay out #4 bars at 12 in each way with 2 in cover in a 20 × 12 ft slab, and count them.**

```
{
  "element": "slab",
  "length": "20 ft",
  "width": "12 ft",
  "cover": "2 in",
  "barSize": "#4",
  "spacing": "12 in",
  "system": "imperial"
}
```

**`calculate_batch` — In one request: the concrete for a 6 × 4 m slab, the drywall and the paint for the room (by its permanent id).**

```
{
  "system": "metric",
  "items": [
    {
      "ref": "Slab",
      "slug": "concrete-calculator",
      "inputs": {
        "slabLength": "6 m",
        "slabWidth": "4 m",
        "slabThickness": "100 mm"
      }
    },
    {
      "ref": "Walls",
      "slug": "drywall-calculator"
    },
    {
      "ref": "Paint",
      "slug": "cq-c0656"
    }
  ]
}
```

**`update_project` — Make the bedroom 4.5 m long, add a bathroom and put a 6-in-12 roof over both.**

```
{
  "token": "cqp1.zZYtBDsIgEEWvYv6amFRdzdKb1M4IxMIYoDZNw90NRBfG5fv_vR0v0GDw8JFBeM5jhEEcg4BwFU6qAQZ5y0UCCEFK8hMMbsobaP-GH-8vvHu7JMnNnCXa4kC4HNqzeu507uTEW1dAOB3bXQ1YNfVu0iUW0FBbE1nX37XWNw.a6887bd2",
  "operations": [
    {
      "op": "set_dimension",
      "target": "space",
      "index": 0,
      "field": "length",
      "value": "4.5 m"
    },
    {
      "op": "add_space",
      "space": {
        "kind": "bathroom",
        "name": "Bathroom",
        "figures": {
          "length": "2.5 m",
          "width": "2 m",
          "height": "2.4 m"
        },
        "doors": {
          "count": 1
        }
      }
    },
    {
      "op": "set_roof_pitch",
      "pitch": 6
    }
  ]
}
```

**`classify_items` — Group my slab's bill by MasterFormat division.**

```
{
  "lines": [
    {
      "label": "Ready-mix concrete",
      "quantity": 2.64,
      "unit": "m³",
      "slug": "concrete-calculator"
    },
    {
      "label": "Rebar, 12 mm",
      "quantity": 11,
      "unit": "sticks",
      "slug": "rebar-calculator"
    },
    {
      "label": "Damp-proof membrane",
      "quantity": 30,
      "unit": "m²"
    },
    {
      "label": "Hardcore sub-base",
      "quantity": 2.4,
      "unit": "t"
    }
  ]
}
```

**`resolve_id` — Where is page cq-c0187 today?**

```
{
  "ref": "cq-c0187"
}
```

**`plan_programme` — How long would a crew of two take to build the two-storey house template, eight-hour days, starting 2 November?**

```
{
  "drawing": {
    "template": "two-storey-house"
  },
  "crew": 2,
  "hoursPerDay": 8,
  "startDate": "2026-11-02"
}
```

**`optimise_cuts` — A wall's 24 studs, 3 sills and 3 plates: which lengths of timber to buy from 2.4, 3, 3.6 and 4.8 m, with a 3 mm saw?**

```
{
  "kind": "linear",
  "material": "timber",
  "pieces": [
    {
      "length": "2.326 m",
      "count": 24,
      "label": "stud"
    },
    {
      "length": "1.225 m",
      "count": 3,
      "label": "sill"
    },
    {
      "length": "8.9 m",
      "count": 3,
      "label": "plate",
      "join": true
    }
  ],
  "stock": [
    "2.4 m",
    "3 m",
    "3.6 m",
    "4.8 m"
  ],
  "kerf": "3 mm",
  "system": "metric"
}
```

**`estimate_hours` — How many hours would a crew of two take for the garage slab and a 6 m stud wall?**

```
{
  "name": "Garage",
  "system": "metric",
  "crew": 2,
  "takeoffs": [
    {
      "takeoff": "concrete-slab",
      "measurements": {
        "length": "6 m",
        "width": "4 m",
        "thickness": "100 mm"
      }
    },
    {
      "takeoff": "stud-wall",
      "measurements": {
        "length": "6 m",
        "height": "2.4 m"
      }
    }
  ]
}
```

**`compare_on_job` — Paint or wallpaper for a 4 × 3.5 m room with 2.4 m walls: how much of each, and how long?**

```
{
  "comparison": "paint-vs-wallpaper",
  "job": {
    "roomLength": "4 m",
    "roomWidth": "3.5 m",
    "wallHeight": "2.4 m"
  },
  "system": "metric"
}
```

**`run_guide_chain` — Boarding a 5 × 2.4 m loft deck over insulation on 600 mm trusses: what do I buy?**

```
{
  "guide": "how-to-board-a-loft-over-insulation",
  "measurements": {
    "length": "5 m",
    "width": "2.4 m",
    "centres": "600 mm"
  },
  "system": "metric"
}
```

**`run_example_live` — The retiled bathroom example, but my room is 4.5 × 3 m: what changes?**

```
{
  "example": "bathroom-gutted-and-retiled",
  "figures": {
    "length": "4.5 m",
    "width": "3 m"
  }
}
```

**`stair_flight` — A straight timber stair for a 2.8 m floor-to-floor rise under the UK rules: risers, goings, the opening and the stringer.**

```
{
  "kind": "straight",
  "inputs": {
    "totalRise": "2.8 m",
    "buildingCode": "uk"
  },
  "system": "metric"
}
```

**`level_quotes` — Two bathroom quotes: what does each include, leave out or exclude?**

```
{
  "job": "bathroom-quote",
  "quotes": [
    {
      "name": "Quote A",
      "text": "Wall and floor tiles 12 m2\nTile adhesive 6 bags\nGrout 3 bags\nTanking membrane 8 m2"
    },
    {
      "name": "Quote B",
      "text": "Tiles 11 m2\nAdhesive 5 bags\nExclusions: grout, skip hire"
    }
  ]
}
```

**`write_variation` — The client wants the slab 7 m long instead of 6 m: write the variation at my own rate of 120 a cubic metre.**

```
{
  "name": "Garage slab",
  "system": "metric",
  "market": "UK",
  "before": {
    "calculators": [
      {
        "slug": "concrete-calculator",
        "inputs": {
          "slabLength": "6 m",
          "slabWidth": "4 m",
          "slabThickness": "100 mm"
        }
      }
    ]
  },
  "after": {
    "calculators": [
      {
        "slug": "concrete-calculator",
        "inputs": {
          "slabLength": "7 m",
          "slabWidth": "4 m",
          "slabThickness": "100 mm"
        }
      }
    ]
  },
  "rates": {
    "concrete-calculator": 120
  },
  "reason": "Slab extended by 1 m for a workbench bay."
}
```

**`write_proposal` — Turn the garage slab and its stud wall into a client proposal (I will add my prices).**

```
{
  "name": "Garage",
  "system": "metric",
  "takeoffs": [
    {
      "takeoff": "concrete-slab",
      "measurements": {
        "length": "6 m",
        "width": "4 m",
        "thickness": "100 mm"
      }
    },
    {
      "takeoff": "stud-wall",
      "measurements": {
        "length": "6 m",
        "height": "2.4 m"
      }
    }
  ],
  "companyName": "Example Builders",
  "reference": "Q-0001"
}
```

**`make_job_sheet` — A one-page job sheet for the 6 × 4 m garage slab.**

```
{
  "takeoff": "concrete-slab",
  "measurements": {
    "length": "6 m",
    "width": "4 m",
    "thickness": "100 mm"
  },
  "system": "metric"
}
```

**`make_canvas_link` — Open the 6 × 4 m slab as a drawing on the Construction Canvas.**

```
{
  "takeoff": "concrete-slab",
  "measurements": {
    "length": "6 m",
    "width": "4 m",
    "thickness": "100 mm"
  },
  "system": "metric"
}
```

**`get_illustration` — The illustration of the guide to anchoring into concrete.**

```
{
  "family": "guides",
  "slug": "how-to-anchor-into-concrete"
}
```

**`trim_corner` — Skirting into a 92° inside corner on a double-bevel slider: what do I set the saw to, and do I cope it?**

```
{
  "trim": "skirting",
  "corner": {
    "kind": "inside",
    "angle": 92
  },
  "saw": "double-bevel",
  "system": "metric"
}
```

**`plan_room_trim` — Skirting round a 4 × 3 m room with a door: every piece, its ends and the lengths to buy.**

```
{
  "walls": [
    {
      "label": "North",
      "length": "4 m"
    },
    {
      "label": "East",
      "length": "3 m",
      "openings": [
        {
          "kind": "door",
          "start": "0.4 m",
          "width": "0.8 m"
        }
      ]
    },
    {
      "label": "South",
      "length": "4 m"
    },
    {
      "label": "West",
      "length": "3 m"
    }
  ],
  "corners": [
    {
      "kind": "inside",
      "angle": 90
    },
    {
      "kind": "inside",
      "angle": 91
    },
    {
      "kind": "inside",
      "angle": 89
    },
    {
      "kind": "inside",
      "angle": 90
    }
  ],
  "trim": "skirting",
  "system": "metric"
}
```

**`scribe_template` — These five gaps along a 1.2 m wall: the scribe line, and how it prints on A4.**

```
{
  "readings": [
    {
      "at": "0 mm",
      "gap": "4 mm"
    },
    {
      "at": "300 mm",
      "gap": "11 mm"
    },
    {
      "at": "600 mm",
      "gap": "15 mm"
    },
    {
      "at": "900 mm",
      "gap": "9 mm"
    },
    {
      "at": "1200 mm",
      "gap": "3 mm"
    }
  ],
  "allowance": "10 mm",
  "formats": [
    "svg"
  ],
  "system": "metric"
}
```

**`fit_panel` — A worktop between walls at 91° and 88.5°, 2.4 m apart, with a 6 mm bow: the true shape and the length to buy.**

```
{
  "kind": "worktop",
  "span": "2.4 m",
  "leftAngle": 91,
  "rightAngle": 88.5,
  "bow": "6 mm",
  "system": "metric"
}
```

**`fit_worktop_run` — An L-shaped worktop, 3 m and 2.2 m round a square corner: each piece and the lengths to buy.**

```
{
  "faces": [
    {
      "length": "3 m",
      "label": "Back"
    },
    {
      "length": "2.2 m",
      "label": "Side"
    }
  ],
  "corners": [
    {
      "kind": "inside",
      "angle": 90
    }
  ],
  "start": {
    "end": "wall",
    "angle": 90
  },
  "finish": {
    "end": "open"
  },
  "system": "metric"
}
```

**`miter_chart` — The mitre and the 45° gap for 88°, 90°, 92° and 135° corners.**

```
{
  "angles": [
    88,
    90,
    92,
    135
  ],
  "handing": false,
  "system": "metric"
}
```

**`print_template` — A full-size step gauge for the stringer the stair stringer calculator opens on.**

```
{
  "calculator": "stair-stringer-calculator",
  "kind": "gauge",
  "formats": [
    "svg"
  ],
  "system": "metric"
}
```

**`edit_drawing` — Take the single-room template, move its east wall 300 mm east and put a window in the north wall.**

```
{
  "drawing": {
    "template": "single-room"
  },
  "operations": [
    {
      "op": "move",
      "target": {
        "side": "east"
      },
      "direction": "east",
      "distance": "300 mm"
    },
    {
      "op": "add_opening",
      "target": {
        "side": "north"
      },
      "kind": "window"
    }
  ],
  "system": "metric"
}
```

**`plan_set_takeoff` — Two plan sheets at their own scales: 4 outlets and a 7 m wall run on the ground floor, 3 outlets and a 4 m run upstairs. The totals per layer and per sheet.**

```
{
  "name": "House A",
  "sheets": [
    {
      "name": "Ground floor",
      "scale": {
        "line": [
          [
            100,
            100
          ],
          [
            1100,
            100
          ]
        ],
        "length": "5 m"
      },
      "marks": [
        {
          "layer": "Outlets",
          "kind": "count",
          "countType": "outlet",
          "points": [
            [
              200,
              300
            ],
            [
              400,
              300
            ],
            [
              600,
              300
            ],
            [
              800,
              500
            ]
          ]
        },
        {
          "layer": "Partition walls",
          "kind": "length",
          "points": [
            [
              100,
              600
            ],
            [
              1100,
              600
            ],
            [
              1100,
              1000
            ]
          ]
        }
      ]
    },
    {
      "name": "First floor",
      "scale": {
        "pixelsPerMm": 0.1
      },
      "marks": [
        {
          "layer": "Outlets",
          "kind": "count",
          "countType": "outlet",
          "points": [
            [
              150,
              150
            ],
            [
              450,
              150
            ],
            [
              750,
              150
            ]
          ]
        },
        {
          "layer": "Partition walls",
          "kind": "length",
          "points": [
            [
              0,
              0
            ],
            [
              400,
              0
            ]
          ]
        }
      ]
    }
  ],
  "system": "metric"
}
```

**`roof_framing` — A 24 by 40 ft hip roof at 6 in 12 with a 12 in overhang, 2×8 commons and 2×10 hips at 16 in centres: every rafter's length and cuts, and the boards to buy in 8 to 20 ft lengths.**

```
{
  "kind": "hip",
  "span": "24 ft",
  "length": "40 ft",
  "pitch": 6,
  "overhang": "12 in",
  "rafterDepth": "7.25 in",
  "rafterThickness": "1.5 in",
  "hipDepth": "9.25 in",
  "hipThickness": "1.5 in",
  "ridgeThickness": "1.5 in",
  "plateWidth": "3.5 in",
  "spacing": "16 in",
  "stock": [
    "8 ft",
    "10 ft",
    "12 ft",
    "14 ft",
    "16 ft",
    "18 ft",
    "20 ft"
  ],
  "system": "imperial"
}
```

## Units travel with numbers

A length, area or volume is written with its unit — "12 ft", "3.5 m" or {"value": 12, "unit": "ft"}, and a length in feet and inches with its foot and inch marks. A bare number on one is refused with the units it accepts, unless the request says inputUnits "base", the form the published test vectors use. An input left out takes the value its page opens on, and the answer lists it as a default.

## What every answer carries

The figure in both unit systems as the page prints it, every input with where it came from, the breakdown, the confidence and any allowance, the calculator's version and the date its sources were checked, the sources as the calculator cites them, a citation in plain, APA, Harvard and BibTeX form with today's date, the page and a link that reopens it with the same inputs, the licence and a notice.

## A report an assistant can quote

Over MCP, each tool's text is a short Markdown report: the figure in both unit systems, the inputs as read, the assumptions, what a professional must decide, the page link and one citation line built only from the calculation's own version, sources date and page. The full answer is the structured content. Over HTTP, add ?format=md or send Accept: text/markdown. search and fetch answer JSON, as OpenAI's search contract reads it. Every other tool also takes detail summary: the result lines, what a professional must decide, the citation and the page only.

## The same answer as the page

The engine has no formula of its own. It calls the calculator's own code with the four steps the page takes, and the test suite holds it to every published test vector and to every calculator's opening answer in both systems.

## Why an assistant might cite this, and why we cannot make it

No site can make an assistant cite it. What this offers is what makes citing easy: an exact figure with its unit, the version and sources of the calculation that produced it, a stable page, a ready citation and an open licence. Whether a given assistant uses it is that assistant's decision.

## Nothing is kept

The engine stores nothing and logs no request: no account, no key, no record of the inputs sent. A request is computed on Cloudflare's network and forgotten. The calculators on the site's own pages still run in the visitor's browser.

## A project in a token

Every My Project file the engine makes also comes with a state token: the project's inputs, deflated and base64url-encoded, with a format version (cqp1) and a CRC-32 check. Passed back with operations, it changes the project without the engine keeping anything; opened as craftquantities.com/project/#p=<token>, the site rebuilds the project in the browser and adds it beside yours when you say so. A token holds at most 16,384 characters. It is compact, not encrypted: anyone who has it can read the project.

## Permanent ids

Every calculator, takeoff, guide, worked example, glossary term and diagnosis has a permanent id (cq-c0187 is the concrete calculator), assigned once and kept when a page is renamed or moved. craftquantities.com/id/<id>/ redirects to the page, every engine route that takes a slug takes an id or an earlier slug, and the whole list is published at craftquantities.com/api/v1/ids.json.

## An open drawing format

A Construction Canvas drawing is published as a versioned JSON Schema at craftquantities.com/schemas/canvas-drawing-5.json: levels, build-up types and placed objects in whole millimetres, nothing derived. create_drawing and edit_drawing return drawings in it, and edit_drawing gives each drawing a revision: an edit sent with a revision the drawing has moved on from is refused, so two assistants, or an assistant and a person, never overwrite each other's change. The schema holds the shape; the canvas's own checks are the final word. A drawing for quantities: nothing in it is sized.

## An open request-for-quote format

The request for quote and the supplier's reply are published as a versioned JSON Schema at craftquantities.com/schemas/rfq-1.json, with how a request link carries them, so a merchant can read a request into their own system and write a reply the site opens. Nothing is sent by the site or the engine: the request and the reply travel as links or files people hand over.

## Typed calculators, one trade at a time

Each trade has an MCP endpoint of its own, api.craftquantities.com/mcp/<trade>, serving that trade's calculators as typed tools: every input named, with its units, opening values and range, each tool answering exactly as calculate does. The same calculators are typed OpenAPI operations at craftquantities.com/openapi/<trade>.json (operationId = the tool's name, fixed by the calculator's permanent id), and each calculator's request is a JSON Schema at craftquantities.com/schemas/calculators/<slug>.json, or <id>.json. The lists are at api.craftquantities.com/v1/trades and craftquantities.com/openapi/index.json. The main /mcp stays as it is: search, describe and calculate for every calculator, and the workflow tools.

## Show the working

calculate and every typed tool take explain: true. The answer then also carries the working: the inputs as the calculator received them, every intermediate figure its own code reports with its unit, which inputs moved each figure (measured by running it again), the allowance, the range check and the restatement in each unit system, ending on the same figures. No formula is written for a calculator that does not state one; the answer says what the working leaves out.

## The page's drawing, as SVG

calculate takes drawing: true on the nine calculators whose pages draw the job (engine 1.7.0): the tile set-out with every tile and cut (tile-layout-calculator), the deck plan with joists, butt joints and a fixing at every crossing (deck-board-calculator), the wall elevation course by course with the bond, cut units, openings where they were placed and the lintels (brick-calculator, cmu-block-grout-calculator), the drywall hanging layout with whole and cut boards (drywall-calculator), the stud and plate layout at the spacing (framing-stud-calculator), the siding face with its starter and J-channel runs (siding-calculator), the gutter runs with their joints and downspouts (gutter-calculator) and the fence elevation with its posts, rails, pickets, gates and post concrete (fence-calculator). The answer then also carries the drawing as a standalone SVG, a sentence describing it in the system asked for, what it lays and its units per metre for printing to a scale. A setting-out aid from the figures given: nothing is sized.

## Tools in the browser (WebMCP)

In a browser that offers a model context (document.modelContext, Chrome's WebMCP preview), the site's pages register their own tools for the browser's assistant and withdraw them when the page is left: every calculator page run_calculator and read_current_result; the stair pages, spiral, helical and winder included, also compute_stair_flight, read_stair_cut_list and open_stair_in_canvas; every takeoff page run_takeoff, describe_takeoff and read_current_takeoff; the Construction Canvas add_canvas_wall, add_canvas_room, add_canvas_opening, add_canvas_symbol, list_canvas_objects, read_canvas_takeoff and export_canvas_drawing; the House Estimator set_house_parameters and read_house_estimate; every planner describe_planner, add_plan_space and read_plan; My Project list_project_lines, add_calculator_result, read_project_totals and describe_job; the roof framing tool set_roof_framing and read_roof_framing. A tool that only reads is marked read-only. A tool that changes something changes only the person's own drawing, house, plan or project on that page, as one step its Undo takes back, and answers once the page shows it; none deletes anything, sizes a structure or quotes a price. A browser without a model context loads none of it.

## Fair use

There is no key and no charge. Requests may be limited per address to keep the service up for everyone; each address may run 60 calculations, takeoffs, plans, drawings or project updates (a batch of up to 25 calculations counts as one) and 300 look-ups a minute, and a request past that gets HTTP 429 and should wait a minute. Descriptions may be cached for a day and GET answers for an hour; each carries an ETag, so asking again with If-None-Match costs nothing.

Limits

## What it does not do

- ### Its files do not compute

  The static files publish every input, bound and test vector; the engine below runs the calculations. Neither supplies a price, sizes a structure or certifies anything.
- ### It holds no prices

  The site publishes none: every price on it is one a visitor typed, and it stays on their device. The API says which inputs hold money, and whether each is a rate the caller supplies or an amount of their own.
- ### It holds no adoption data

  standards.json says what each document is and the jurisdiction it is written for, not who has adopted which edition. Adoption is local and lags publication, and this site does not track it.

Versioning

## Changes inside v1

Additive only, newest first. Nothing listed here removed or renamed a field.

1. 2026-09-25

   examples.json: every worked example, step by step, with each computed step's inputs, answer and printed figure. units.json gains offsetToBase on the temperature scales, so a Fahrenheit value converts correctly; select inputs whose options differ by unit system gain optionsBySystem; each takeoff step in assemblies.json gains the note saying why the calculator is part of the job.
2. 2026-09-22

   link-graph.json: every link between a calculator and a page of another kind, grouped by page.
3. 2026-09-15

   glossary.json: the cross-market construction glossary, one record per concept.
4. 2026-09-14

   One file per cited standard (standards/{body}/{id}.json), one per reference table (reference/{table}.json), the corrections ledger, and a citation block in every calculator, standard and table file.
5. 2026-09-12

   v1 published: index, calculators, one file per calculator, takeoffs, standards, units and the validation corpus.

The same data, on pages

## Check the maths before you build on it

The validation page runs the published vectors in the open and says how to report a failure.

- [How the maths is checked](https://craftquantities.com/validation/)
- [The vectors as a benchmark](https://craftquantities.com/benchmark/)
- [Embed a calculator instead](https://craftquantities.com/embeds/)

- Generated from the site's own build

  The files come from the same bundle the pages run, so they cannot drift from them.
- A corrections ledger, in the open

  Confirmed errors are published with the fix and what now prevents each one.
- Standards named, never paraphrased

  Each calculator cites its code or standard; the standards files list who cites what.

## Frequently asked questions

**Is there a free API for construction calculations?**

Yes. Every input, bound, unit and published test vector behind 1,181 construction calculators is a static JSON file under https://craftquantities.com/api/v1/, licensed CC BY 4.0. There is no key, no quota and no rate limit, because there is nothing to meter — the files are served from a CDN like any other page.

**Do I need an API key or an account?**

No. Fetch the files directly. Nothing is logged against a key because there is no key, and nothing can be switched off for one caller, which is the point of publishing files rather than running a service.

**Can I call it from JavaScript in a browser?**

Yes, with a plain fetch. Every file is served with Access-Control-Allow-Origin: \*. Only simple GET and HEAD requests work: a request with custom headers triggers a CORS preflight, which a static host does not answer. A missing file returns the site's HTML 404 page, so check response.ok before parsing.

**Does the API compute results?**

No. It publishes what a calculation needs — every input with its dimension, bounds and default, the sources, and the test vectors with expected results and tolerances — which is enough to check a re-implementation. The formulas themselves live in the site's code and are not an endpoint.

**How do I know when the data changes?**

Each file carries an ETag, and a request with If-None-Match returns 304 when nothing has changed. Files are cached for an hour. The build that produced them is named at /build-info.json. Inside v1, fields are only ever added; an incompatible change would become /api/v2/ while v1 keeps being built.

Base address: [https://craftquantities.com/api/v1/index.json](https://craftquantities.com/api/v1/index.json)

---
Source: https://craftquantities.com/api/
Craft Quantities: free to read, cite and link to; the pages are not licensed for republication. Quantities only: no prices, no design and no certification.
