# Space Objects – Asteroid Diameter from Absolute Magnitude

> Space Objects – Asteroid Diameter from Absolute Magnitude is a paid API for AI agents from space-objects.x402tookit.com, paid per call via x402, $0.02/call, status unknown (last checked 2026-10-21).

Calculates asteroid diameter in meters and kilometers from absolute magnitude H and albedo, with optional impact energy in megatons

## Facts

- Endpoint: GET https://space-objects.x402tookit.com/asteroid-size?utm_source=zero.xyz
- Price: $0.02/call
- Payment: x402
- Status: unknown
- Last checked: 2026-10-21
- Activations on Zero: 0
- Tags: x402
- Canonical page: https://www.zero.xyz/c/space-objects-asteroid-diameter-from-absolute-magnitude-324112d3
- Structured record (JSON): https://api.zero.xyz/v1/capabilities/cap_qqghAnjuCnuAqDRbTJfuq

Status and success rate cover calls made through Zero and Zero's own probes. Third-party monitors may report differently.

## How to call it through Zero

Zero handles the 402 payment challenge and records the run. With the Zero CLI installed (`npm i -g @zeroxyz/cli`):

```sh
zero fetch --capability space-objects-asteroid-diameter-from-absolute-magnitude-324112d3
```

Example prompt: What's the estimated diameter of an asteroid with absolute magnitude H=22 and albedo 0.14, and how much impact energy would it release hitting Earth at 20 km/s?

## When to prefer this

Use this endpoint when you need to translate an asteroid's absolute magnitude (H) into a physical size estimate — especially when albedo is known or a bracketed range is acceptable. Ideal for planetary defense analysis, impact hazard estimation, and educational or research workflows where you want both size and impact energy from a single call. Prefer over general astronomy APIs when you specifically need the diameter-from-H formula with optional impact energy output in standardized units (megatons, Hiroshima equivalents).

## Known failure modes

- H magnitude outside -5 to 40 range returns validation error
- albedo outside 0.01 to 1 returns validation error
- velocity outside 5 to 72 km/s returns validation error
- density outside 500 to 8000 kg/m3 returns validation error
- missing required H parameter returns 400 error
- payment not provided or insufficient returns 402 error

## How this service works

Asteroid diameter from absolute magnitude H and albedo (or a dark-to-bright range), plus optional impact energy in megatons.

## Output

Returns asteroid diameter in both meters and kilometers (point estimate or dark-to-bright range if albedo is omitted), along with the formula used, source notes, and optionally: impact mass, speed, density, energy in joules, megatons of TNT, and Hiroshima equivalents — plus a human-readable summary and any relevant caveats or disclaimers.

## Request schema (JSON Schema)

```json
{
 "type": "object",
 "$schema": "https://json-schema.org/draft/2020-12/schema",
 "required": [
  "input"
 ],
 "properties": {
  "input": {
   "type": "object",
   "required": [
    "type",
    "method"
   ],
   "properties": {
    "type": {
     "type": "string",
     "const": "http"
    },
    "method": {
     "enum": [
      "GET"
     ],
     "type": "string"
    },
    "queryParams": {
     "type": "object",
     "required": [
      "H"
     ],
     "properties": {
      "H": {
       "type": "number",
       "description": "Absolute magnitude H, -5 to 40"
      },
      "albedo": {
       "type": "number",
       "description": "Geometric albedo 0.01 to 1; omit for the 0.05 to 0.25 range"
      },
      "densityKgM3": {
       "type": "number",
       "description": "Bulk density 500 to 8000 kg/m3 (default 2600)"
      },
      "velocityKmS": {
       "type": "number",
       "description": "Impact speed 5 to 72 km/s, to also get impact energy"
      }
     }
    }
   },
   "additionalProperties": false
  },
  "output": {
   "type": "object",
   "required": [
    "type"
   ],
   "properties": {
    "type": {
     "type": "string"
    },
    "example": {
     "type": "object",
     "properties": {
      "asOf": {
       "type": [
        "null",
        "string"
       ]
      },
      "albedo": {
       "type": [
        "null",
        "number"
       ]
      },
      "impact": {
       "type": [
        "null",
        "object"
       ],
       "properties": {
        "massKg": {
         "type": [
          "null",
          "number"
         ]
        },
        "speedKmS": {
         "type": [
          "null",
          "number"
         ]
        },
        "densityKgM3": {
         "type": [
          "null",
          "number"
         ]
        },
        "energyJoules": {
         "type": [
          "null",
          "number"
         ]
        },
        "diameterKmUsed": {
         "type": [
          "null",
          "number"
         ]
        },
        "energyMegatonsTnt": {
         "type": [
          "null",
          "number"
         ]
        },
        "energyHiroshimaEquivalents": {
         "type": [
          "null",
          "number"
         ]
        }
       }
      },
      "source": {
       "type": [
        "null",
        "string"
       ]
      },
      "formula": {
       "type": [
        "null",
        "string"
       ]
      },
      "reasons": {
       "type": [
        "array",
        "null"
       ],
 
… (truncated)
```

## More

- Live health (JSON, refreshed every minute): https://www.zero.xyz/c/space-objects-asteroid-diameter-from-absolute-magnitude-324112d3/health.json
- [Zero catalog index](https://www.zero.xyz/llms.txt)
- [Other services from space-objects.x402tookit.com](https://www.zero.xyz/host/space-objects.x402tookit.com/llms.txt)
