Catalog/geometry-sphere-sphere-intersect

Geometry

Sphere-sphere intersection API

Intersection of two spheres: relation classification plus the intersection circle (radius, center) and lens overlap volume. Answers 'do these two spheres overlap, and by how much volume?'.

Price$0.03per request
MethodPOST
Route/v1/geometry/sphere-sphere-intersect
StatusLive
MIME typeapplication/json
Rate limit120/minute
Cache0s public
intersectionsphereoverlaplensvolume3dgeometry
API URLhttps://x402.hexl.dev/v1/geometry/sphere-sphere-intersect
Integration docs
Example request
{
  "c1": [
    0,
    0,
    0
  ],
  "r1": 2,
  "c2": [
    3,
    0,
    0
  ],
  "r2": 2
}
Example response
{
  "relation": "intersecting",
  "intersectionCircleRadius": 1.322875656,
  "intersectionCircleCenter": [
    1.5,
    0,
    0
  ],
  "overlapVolume": 2.879793266
}
Input schema
{
  "type": "object",
  "required": [
    "c1",
    "r1",
    "c2",
    "r2"
  ],
  "properties": {
    "c1": {
      "type": "array",
      "items": {
        "type": "number"
      },
      "examples": [
        [
          0,
          0,
          0
        ]
      ]
    },
    "r1": {
      "type": "number",
      "examples": [
        2
      ]
    },
    "c2": {
      "type": "array",
      "items": {
        "type": "number"
      },
      "examples": [
        [
          3,
          0,
          0
        ]
      ]
    },
    "r2": {
      "type": "number",
      "examples": [
        2
      ]
    }
  }
}
Output schema
{
  "type": "object",
  "additionalProperties": true
}