{"openapi":"3.1.0","info":{"title":"Bézier Curve API","version":"1.0.0","description":"Bézier-curve geometry maths as an API, computed locally and deterministically. The point endpoint evaluates a quadratic (three control points) or cubic (four) Bézier curve at a parameter t between 0 and 1 using de Casteljau's algorithm, returning the point on the curve and the tangent there — its direction vector, angle and speed (the derivative B'(t)). The length endpoint computes the arc length of the curve by fine polyline sampling, together with the straight-line chord length and the axis-aligned bounding box (min and max x and y, width and height). The split endpoint splits the curve at a parameter into two sub-curves and returns the control points of each — the standard de Casteljau subdivision used for trimming and adaptive rendering. Control points are passed as plain x/y coordinates. Everything is computed locally and deterministically, so it is instant and private. Ideal for graphics, CAD, font, animation, game-engine and vector-design app developers, path and curve tools, and computational-geometry education. Pure local computation — no key, no third-party service, instant. Live, nothing stored. 3 endpoints. This is Bézier-curve geometry; for animation easing and timing functions use an easing API.","contact":{"name":"PremiumApi","url":"https://www.oanor.com/by/premiumapi"}},"servers":[{"url":"https://api.oanor.com/bezier-api","description":"oanor gateway"}],"tags":[{"name":"Bezier"},{"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/length":{"get":{"operationId":"get_v1_length","tags":["Bezier"],"summary":"Arc length & bbox","description":"","parameters":[{"name":"x0","in":"query","required":true,"description":"Start point x","schema":{"type":"string"},"example":"0"},{"name":"y0","in":"query","required":true,"description":"Start point y","schema":{"type":"string"},"example":"0"},{"name":"x1","in":"query","required":true,"description":"Control 1 x","schema":{"type":"string"},"example":"0"},{"name":"y1","in":"query","required":true,"description":"Control 1 y","schema":{"type":"string"},"example":"1"},{"name":"x2","in":"query","required":true,"description":"Control 2 / end x","schema":{"type":"string"},"example":"1"},{"name":"y2","in":"query","required":true,"description":"Control 2 / end y","schema":{"type":"string"},"example":"1"},{"name":"x3","in":"query","required":false,"description":"End x (cubic)","schema":{"type":"string"},"example":"1"},{"name":"y3","in":"query","required":false,"description":"End y (cubic)","schema":{"type":"string"},"example":"0"},{"name":"steps","in":"query","required":false,"description":"Sampling steps","schema":{"type":"string"},"example":"2000"}],"security":[{"oanorKey":[]}],"responses":{"200":{"description":"OK","content":{"application/json":{"example":{"data":{"note":"Arc length from fine polyline sampling (default 2000 steps). Bounding box from the sampled points.","inputs":{"steps":2000,"degree":3},"arc_length":2,"bounding_box":{"max_x":1,"max_y":0.75,"min_x":0,"min_y":0,"width":1,"height":0.75},"chord_length":1},"meta":{"timestamp":"2026-06-04T18:38:03.377Z","request_id":"76d04365-4fdb-4691-b395-105987d0669b"},"status":"ok","message":"Arc length","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/point":{"get":{"operationId":"get_v1_point","tags":["Bezier"],"summary":"Point & tangent at t","description":"","parameters":[{"name":"x0","in":"query","required":true,"description":"Start point x","schema":{"type":"string"},"example":"0"},{"name":"y0","in":"query","required":true,"description":"Start point y","schema":{"type":"string"},"example":"0"},{"name":"x1","in":"query","required":true,"description":"Control 1 x","schema":{"type":"string"},"example":"0"},{"name":"y1","in":"query","required":true,"description":"Control 1 y","schema":{"type":"string"},"example":"1"},{"name":"x2","in":"query","required":true,"description":"Control 2 / end x","schema":{"type":"string"},"example":"1"},{"name":"y2","in":"query","required":true,"description":"Control 2 / end y","schema":{"type":"string"},"example":"1"},{"name":"x3","in":"query","required":false,"description":"End x (cubic)","schema":{"type":"string"},"example":"1"},{"name":"y3","in":"query","required":false,"description":"End y (cubic)","schema":{"type":"string"},"example":"0"},{"name":"t","in":"query","required":true,"description":"Parameter 0–1","schema":{"type":"string"},"example":"0.5"}],"security":[{"oanorKey":[]}],"responses":{"200":{"description":"OK","content":{"application/json":{"example":{"data":{"x":0.5,"y":0.75,"note":"Point via de Casteljau; tangent is the first derivative B'(t). Degree 2 = quadratic, 3 = cubic.","inputs":{"t":0.5,"degree":3,"control_points":4},"tangent":{"dx":1.5,"dy":0,"speed":1.5,"angle_deg":0}},"meta":{"timestamp":"2026-06-04T18:38:03.488Z","request_id":"5463a626-82e1-4c46-8a25-f1a597a725dc"},"status":"ok","message":"Curve point","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/split":{"get":{"operationId":"get_v1_split","tags":["Bezier"],"summary":"Split at t","description":"","parameters":[{"name":"x0","in":"query","required":true,"description":"Start point x","schema":{"type":"string"},"example":"0"},{"name":"y0","in":"query","required":true,"description":"Start point y","schema":{"type":"string"},"example":"0"},{"name":"x1","in":"query","required":true,"description":"Control 1 x","schema":{"type":"string"},"example":"0"},{"name":"y1","in":"query","required":true,"description":"Control 1 y","schema":{"type":"string"},"example":"1"},{"name":"x2","in":"query","required":true,"description":"Control 2 / end x","schema":{"type":"string"},"example":"1"},{"name":"y2","in":"query","required":true,"description":"Control 2 / end y","schema":{"type":"string"},"example":"1"},{"name":"x3","in":"query","required":false,"description":"End x (cubic)","schema":{"type":"string"},"example":"1"},{"name":"y3","in":"query","required":false,"description":"End y (cubic)","schema":{"type":"string"},"example":"0"},{"name":"t","in":"query","required":true,"description":"Parameter 0–1","schema":{"type":"string"},"example":"0.5"}],"security":[{"oanorKey":[]}],"responses":{"200":{"description":"OK","content":{"application/json":{"example":{"data":{"note":"de Casteljau split at t: left_curve and right_curve share the split point and together reproduce the original.","inputs":{"t":0.5,"degree":3},"left_curve":[{"x":0,"y":0},{"x":0,"y":0.5},{"x":0.25,"y":0.75},{"x":0.5,"y":0.75}],"right_curve":[{"x":0.5,"y":0.75},{"x":0.75,"y":0.75},{"x":1,"y":0.5},{"x":1,"y":0}],"split_point":{"x":0.5,"y":0.75}},"meta":{"timestamp":"2026-06-04T18:38:03.574Z","request_id":"649f0ab6-b241-4d68-b87b-4fb33e4ac544"},"status":"ok","message":"Split curve","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":"Control points as x0,y0,x1,y1,x2,y2 (quadratic) plus x3,y3 (cubic). Parameter t in [0,1]. 2D curves.","service":"bezier-api","formulae":{"cubic":"B(t) = (1−t)³P₀ + 3(1−t)²t·P₁ + 3(1−t)t²·P₂ + t³P₃","quadratic":"B(t) = (1−t)²P₀ + 2(1−t)t·P₁ + t²P₂","derivative_cubic":"B'(t) = 3(1−t)²(P₁−P₀) + 6(1−t)t(P₂−P₁) + 3t²(P₃−P₂)"},"endpoints":{"GET /v1/meta":"This document.","GET /v1/point":"Point (x,y) and tangent on the curve at parameter t (de Casteljau).","GET /v1/split":"Split the curve at t into two sub-curves' control points.","GET /v1/length":"Arc length and axis-aligned bounding box of the curve."},"description":"Bézier-curve geometry calculator: evaluate a point and tangent at a parameter, the arc length and bounding box, and split a quadratic or cubic curve at a parameter."},"meta":{"timestamp":"2026-06-04T18:38:03.686Z","request_id":"cc5170b7-0dee-4311-8d99-cc8f2f95a5da"},"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":250000,"rps_limit":15,"hard_limit":true},{"slug":"mega","name":"Mega","price_cents_month":4900,"monthly_call_quota":1542000,"rps_limit":40,"hard_limit":true}],"x-oanor-marketplace-url":"https://www.oanor.com/api/bezier-api"}