Knitting Gauge API
Knitting and crochet gauge maths as an API, computed locally and deterministically. The stitches endpoint turns a gauge — the standard stitches and rows per 10 cm measured from a tension swatch — into the number of stitches to cast on for a target width and the number of rows for a target length; at 22 stitches and 30 rows per 10 cm, a 50 cm wide by 60 cm long piece needs 110 stitches and 180 rows. The gauge endpoint works backwards from a measured swatch, converting a count over a measured distance into stitches (or rows) per 10 cm, per centimetre and per inch — 33 stitches over 15 cm is a gauge of 22 per 10 cm. The convert-pattern endpoint re-scales a pattern written for one gauge to your own gauge so the finished garment keeps its intended size: your count = pattern count · (your gauge / pattern gauge), so a 100-stitch cast-on at a 20-per-10 cm pattern becomes 110 at your 22-per-10 cm tension. Dimensions are in centimetres. Everything is computed locally and deterministically, so it is instant and private. Ideal for knitting, crochet, pattern-design, craft-marketplace and maker app developers, gauge and tension calculators, and yarn-shop tools. Pure local computation — no key, no third-party service, instant. Live, nothing stored. 3 endpoints. This is gauge and stitch maths; works for crochet too by using your stitch gauge.
api.oanor.com/knitting-api