{"openapi":"3.1.0","info":{"title":"Interpolation API","version":"1.0.0","description":"Interpolation maths as an API, computed locally and deterministically. The linear endpoint interpolates between two points, y = y0 + (y1 − y0)·(x − x0)/(x1 − x0), returning the value at a target x (or, given a target y, solving the x that produces it), the parameter t and whether the point lies outside the segment. The table endpoint does piecewise-linear interpolation within a table of (x, y) points supplied as comma-separated lists — it sorts the points, finds the two that bracket your query and interpolates between them, extending the nearest segment and flagging the result when you query outside the data range, ideal for calibration curves and lookup tables. The bilinear endpoint interpolates on a rectangular grid from four corner values, interpolating along x at each y-edge and then along y. Everything is computed locally and deterministically, so it is instant and private, and unlike regression it passes exactly through the supplied points. Ideal for engineering, data-visualisation, gaming, mapping and scientific-computing app developers, lookup-table and calibration tools, and numerical-methods education. Pure local computation — no key, no third-party service, instant. Live, nothing stored. 3 endpoints. This is interpolation; for least-squares regression and correlation use a statistics API.","contact":{"name":"PremiumApi","url":"https://www.oanor.com/by/premiumapi"}},"servers":[{"url":"https://api.oanor.com/interpolation-api","description":"oanor gateway"}],"tags":[{"name":"Interpolation"},{"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/bilinear":{"get":{"operationId":"get_v1_bilinear","tags":["Interpolation"],"summary":"Bilinear interpolation","description":"","parameters":[{"name":"x1","in":"query","required":true,"description":"Grid x1","schema":{"type":"string"},"example":"0"},{"name":"x2","in":"query","required":true,"description":"Grid x2","schema":{"type":"string"},"example":"1"},{"name":"y1","in":"query","required":true,"description":"Grid y1","schema":{"type":"string"},"example":"0"},{"name":"y2","in":"query","required":true,"description":"Grid y2","schema":{"type":"string"},"example":"1"},{"name":"q11","in":"query","required":true,"description":"Value at (x1,y1)","schema":{"type":"string"},"example":"0"},{"name":"q21","in":"query","required":true,"description":"Value at (x2,y1)","schema":{"type":"string"},"example":"10"},{"name":"q12","in":"query","required":true,"description":"Value at (x1,y2)","schema":{"type":"string"},"example":"20"},{"name":"q22","in":"query","required":true,"description":"Value at (x2,y2)","schema":{"type":"string"},"example":"30"},{"name":"x","in":"query","required":true,"description":"Query x","schema":{"type":"string"},"example":"0.5"},{"name":"y","in":"query","required":true,"description":"Query y","schema":{"type":"string"},"example":"0.5"}],"security":[{"oanorKey":[]}],"responses":{"200":{"description":"OK","content":{"application/json":{"example":{"data":{"tx":0.5,"ty":0.5,"note":"Bilinear interpolation: interpolate along x at each y-edge (q11→q21 and q12→q22), then along y. q11=(x1,y1), q21=(x2,y1), q12=(x1,y2), q22=(x2,y2).","value":15,"inputs":{"x":0.5,"y":0.5,"x1":0,"x2":1,"y1":0,"y2":1},"extrapolated":false},"meta":{"timestamp":"2026-06-04T18:38:06.621Z","request_id":"a2750d06-8868-4449-a86f-0f71c66a2d70"},"status":"ok","message":"Bilinear interp","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/linear":{"get":{"operationId":"get_v1_linear","tags":["Interpolation"],"summary":"Linear interpolation","description":"","parameters":[{"name":"x0","in":"query","required":true,"description":"First point x","schema":{"type":"string"},"example":"0"},{"name":"y0","in":"query","required":true,"description":"First point y","schema":{"type":"string"},"example":"0"},{"name":"x1","in":"query","required":true,"description":"Second point x","schema":{"type":"string"},"example":"10"},{"name":"y1","in":"query","required":true,"description":"Second point y","schema":{"type":"string"},"example":"100"},{"name":"x","in":"query","required":false,"description":"Query x (returns y)","schema":{"type":"string"},"example":"3"},{"name":"y","in":"query","required":false,"description":"Or query y (returns x)","schema":{"type":"string"}}],"security":[{"oanorKey":[]}],"responses":{"200":{"description":"OK","content":{"application/json":{"example":{"data":{"t":0.3,"x":3,"y":30,"note":"Linear interpolation y = y0 + (y1−y0)·(x−x0)/(x1−x0). 'extrapolated' is true when the point lies outside the segment.","inputs":{"point0":[0,0],"point1":[10,100]},"extrapolated":false},"meta":{"timestamp":"2026-06-04T18:38:06.713Z","request_id":"5bef30b7-24d8-48c4-8a26-3bed2a17107e"},"status":"ok","message":"Linear interp","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/table":{"get":{"operationId":"get_v1_table","tags":["Interpolation"],"summary":"Table interpolation","description":"","parameters":[{"name":"x_values","in":"query","required":true,"description":"Comma-separated x values","schema":{"type":"string"},"example":"0,10,20"},{"name":"y_values","in":"query","required":true,"description":"Comma-separated y values","schema":{"type":"string"},"example":"0,100,150"},{"name":"x","in":"query","required":true,"description":"Query x","schema":{"type":"string"},"example":"15"}],"security":[{"oanorKey":[]}],"responses":{"200":{"description":"OK","content":{"application/json":{"example":{"data":{"y":125,"note":"Piecewise-linear interpolation between the two bracketing points. Outside the data range the nearest segment is extended and 'extrapolated' is true.","inputs":{"x":15,"points":3},"segment":{"to":[20,150],"from":[10,100]},"extrapolated":false},"meta":{"timestamp":"2026-06-04T18:38:06.833Z","request_id":"f97f270f-c297-49d3-8c04-d5349bef80b0"},"status":"ok","message":"Table interp","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":{"notes":"Tables are passed as comma-separated 'x_values' and 'y_values'. 'extrapolated' flags points outside the known range. Distinct from regression — interpolation passes exactly through the given points.","service":"interpolation-api","formulae":{"linear":"y = y0 + (y1−y0)·(x−x0)/(x1−x0)","bilinear":"interpolate along x at each y-edge, then along y"},"endpoints":{"GET /v1/meta":"This document.","GET /v1/table":"Piecewise-linear interpolation within a table of points.","GET /v1/linear":"Linear interpolation between two points; solve y from x or x from y.","GET /v1/bilinear":"Bilinear interpolation on a rectangular grid from four corner values."},"description":"Interpolation calculator: linear interpolation/extrapolation between two points (and the inverse), piecewise-linear lookup within an (x,y) table, and bilinear interpolation on a 2D grid."},"meta":{"timestamp":"2026-06-04T18:38:06.918Z","request_id":"e2635980-90a5-49d3-b453-b9ec6065a244"},"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":3000,"rps_limit":2,"hard_limit":true},{"slug":"starter","name":"Starter","price_cents_month":500,"monthly_call_quota":40000,"rps_limit":5,"hard_limit":true},{"slug":"pro","name":"Pro","price_cents_month":1500,"monthly_call_quota":300000,"rps_limit":20,"hard_limit":true},{"slug":"mega","name":"Mega","price_cents_month":4500,"monthly_call_quota":2000000,"rps_limit":60,"hard_limit":true}],"x-oanor-marketplace-url":"https://www.oanor.com/api/interpolation-api"}