{"openapi":"3.1.0","info":{"title":"Geometry API","version":"1.0.0","description":"Calculate the geometry of common shapes. Get the area of 2D shapes (circle, square, rectangle, triangle — by base/height or three sides via Heron, trapezoid, parallelogram, rhombus, ellipse, regular polygon), the perimeter or circumference, and for 3D shapes the volume and surface area (sphere, cube, box, cylinder, cone, square pyramid). Pass a shape and its dimensions and get back the exact result plus the formula used. Pure local math — no key, no third-party service, instant and deterministic. Live. 6 endpoints. Built for CAD and engineering tools, education and e-learning, construction and material estimation, and any app that needs reliable shape math. Distinct from a generic expression evaluator or unit converter.","contact":{"name":"PremiumApi","url":"https://www.oanor.com/by/premiumapi"}},"servers":[{"url":"https://api.oanor.com/geometry-api","description":"oanor gateway"}],"tags":[{"name":"Geometry"},{"name":"Reference"},{"name":"Meta"}],"components":{"securitySchemes":{"oanorKey":{"type":"apiKey","in":"header","name":"x-oanor-key","description":"Get your key at https://www.oanor.com/developer/keys"}}},"security":[{"oanorKey":[]}],"paths":{"/v1/area":{"get":{"operationId":"get_v1_area","tags":["Geometry"],"summary":"Area of a 2D shape","description":"","parameters":[{"name":"shape","in":"query","required":true,"description":"circle|square|rectangle|triangle|trapezoid|parallelogram|rhombus|ellipse|regular_polygon","schema":{"type":"string"},"example":"circle"},{"name":"radius","in":"query","required":false,"description":"e.g. for circle","schema":{"type":"string"},"example":"5"}],"security":[{"oanorKey":[]}],"responses":{"200":{"description":"OK","content":{"application/json":{"example":{"data":{"area":78.5398,"shape":"circle","formula":"π·r²"},"meta":{"timestamp":"2026-06-02T16:51:55.844Z","request_id":"1000a333-93ba-44ee-a8ea-ecdb328de105"},"status":"ok","message":"Area of a 2D shape","success":true}}}},"401":{"description":"Missing or invalid x-oanor-key header"},"402":{"description":"Active subscription required"},"429":{"description":"Rate-limit or monthly quota reached"},"502":{"description":"Upstream did not respond"}}}},"/v1/perimeter":{"get":{"operationId":"get_v1_perimeter","tags":["Geometry"],"summary":"Perimeter / circumference","description":"","parameters":[{"name":"shape","in":"query","required":true,"description":"circle|square|rectangle|triangle|regular_polygon|ellipse","schema":{"type":"string"},"example":"rectangle"},{"name":"width","in":"query","required":false,"description":"e.g. for rectangle","schema":{"type":"string"},"example":"4"},{"name":"height","in":"query","required":false,"description":"e.g. for rectangle","schema":{"type":"string"},"example":"3"}],"security":[{"oanorKey":[]}],"responses":{"200":{"description":"OK","content":{"application/json":{"example":{"data":{"shape":"rectangle","formula":"2·(w+h)","perimeter":14},"meta":{"timestamp":"2026-06-02T16:51:55.984Z","request_id":"e244f67f-3d6f-4a5e-a2e4-f6725bf360aa"},"status":"ok","message":"Perimeter / circumference","success":true}}}},"401":{"description":"Missing or invalid x-oanor-key header"},"402":{"description":"Active subscription required"},"429":{"description":"Rate-limit or monthly quota reached"},"502":{"description":"Upstream did not respond"}}}},"/v1/surface-area":{"get":{"operationId":"get_v1_surface_area","tags":["Geometry"],"summary":"Surface area of a 3D shape","description":"","parameters":[{"name":"shape","in":"query","required":true,"description":"sphere|cube|box|cylinder|cone","schema":{"type":"string"},"example":"cylinder"},{"name":"radius","in":"query","required":false,"description":"e.g. for cylinder","schema":{"type":"string"},"example":"2"},{"name":"height","in":"query","required":false,"description":"e.g. for cylinder","schema":{"type":"string"},"example":"10"}],"security":[{"oanorKey":[]}],"responses":{"200":{"description":"OK","content":{"application/json":{"example":{"data":{"shape":"cylinder","formula":"2·π·r·(r+h)","surface_area":150.7964},"meta":{"timestamp":"2026-06-02T16:51:56.079Z","request_id":"78e88502-e275-457f-bf44-3a0ace6b245c"},"status":"ok","message":"Surface area of a 3D shape","success":true}}}},"401":{"description":"Missing or invalid x-oanor-key header"},"402":{"description":"Active subscription required"},"429":{"description":"Rate-limit or monthly quota reached"},"502":{"description":"Upstream did not respond"}}}},"/v1/volume":{"get":{"operationId":"get_v1_volume","tags":["Geometry"],"summary":"Volume of a 3D shape","description":"","parameters":[{"name":"shape","in":"query","required":true,"description":"sphere|cube|box|cylinder|cone|pyramid","schema":{"type":"string"},"example":"sphere"},{"name":"radius","in":"query","required":false,"description":"e.g. for sphere","schema":{"type":"string"},"example":"3"}],"security":[{"oanorKey":[]}],"responses":{"200":{"description":"OK","content":{"application/json":{"example":{"data":{"shape":"sphere","volume":113.0973,"formula":"4⁄3·π·r³"},"meta":{"timestamp":"2026-06-02T16:51:56.182Z","request_id":"dcde6f38-a07a-499a-b8f8-e2707fd92f86"},"status":"ok","message":"Volume of a 3D shape","success":true}}}},"401":{"description":"Missing or invalid x-oanor-key header"},"402":{"description":"Active subscription required"},"429":{"description":"Rate-limit or monthly quota reached"},"502":{"description":"Upstream did not respond"}}}},"/v1/shapes":{"get":{"operationId":"get_v1_shapes","tags":["Reference"],"summary":"Supported shapes per operation","description":"","parameters":[],"security":[{"oanorKey":[]}],"responses":{"200":{"description":"OK","content":{"application/json":{"example":{"data":{"area":["circle","square","rectangle","triangle","trapezoid","parallelogram","rhombus","ellipse","regular_polygon"],"volume":["sphere","cube","box","cylinder","cone","pyramid"],"perimeter":["circle","square","rectangle","triangle","regular_polygon","ellipse"],"surface_area":["sphere","cube","box","cylinder","cone"]},"meta":{"timestamp":"2026-06-02T16:51:56.282Z","request_id":"d64ea49e-2956-4474-b2a0-0f92f9371528"},"status":"ok","message":"Supported shapes","success":true}}}},"401":{"description":"Missing or invalid x-oanor-key header"},"402":{"description":"Active subscription required"},"429":{"description":"Rate-limit or monthly quota reached"},"502":{"description":"Upstream did not respond"}}}},"/v1/meta":{"get":{"operationId":"get_v1_meta","tags":["Meta"],"summary":"Spec","description":"","parameters":[],"security":[{"oanorKey":[]}],"responses":{"200":{"description":"OK","content":{"application/json":{"example":{"data":{"auth":"none upstream; this gateway requires x-api-key","name":"Geometry API","note":"Compute area (/v1/area), perimeter/circumference (/v1/perimeter), volume (/v1/volume) and surface area (/v1/surface-area) of common shapes. Pass ?shape= and its dimensions (e.g. shape=circle&radius=5, shape=rectangle&width=4&height=3, shape=triangle&a=3&b=4&c=5, shape=cylinder&radius=2&height=10). /v1/shapes lists supported shapes per operation. Returns the value and the formula used. Instant, exact.","source":"Local geometric formulas — no key, no upstream","endpoints":6},"meta":{"timestamp":"2026-06-02T16:51:56.392Z","request_id":"94ae1dd7-ac30-49f6-8b97-043d06dbaef6"},"status":"ok","message":"Meta","success":true}}}},"401":{"description":"Missing or invalid x-oanor-key header"},"402":{"description":"Active subscription required"},"429":{"description":"Rate-limit or monthly quota reached"},"502":{"description":"Upstream did not respond"}}}}},"x-oanor-pricing":[{"slug":"free","name":"Free","price_cents_month":0,"monthly_call_quota":1340,"rps_limit":2,"hard_limit":true},{"slug":"starter","name":"Starter","price_cents_month":520,"monthly_call_quota":20000,"rps_limit":8,"hard_limit":true},{"slug":"pro","name":"Pro","price_cents_month":2480,"monthly_call_quota":166000,"rps_limit":20,"hard_limit":true},{"slug":"mega","name":"Mega","price_cents_month":6080,"monthly_call_quota":850000,"rps_limit":50,"hard_limit":true}],"x-oanor-marketplace-url":"https://www.oanor.com/api/geometry-api"}