# Magent RSBI Calculator

> Magent RSBI Calculator is a paid API for AI agents from api.magentlab.com, paid per call via x402, $0.005/call, status unknown (last checked 2026-09-15).

Computes the Rapid Shallow Breathing Index (f/VT) from respiratory rate and tidal volume, and flags if the ratio exceeds the 105 breaths/min/L weaning threshold

## Facts

- Endpoint: GET https://api.magentlab.com/api/calc/rsbi
- Price: $0.005/call
- Payment: x402
- Status: unknown
- Last checked: 2026-09-15
- Activations on Zero: 0
- Tags: x402
- Canonical page: https://www.zero.xyz/c/magent-rsbi-calculator-0ddf1575
- Structured record (JSON): https://api.zero.xyz/v1/capabilities/cap_f2djeOUTdHuV5Af1c7VD-

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 magent-rsbi-calculator-0ddf1575
```

Example prompt: Calculate the RSBI for a patient breathing at 28 breaths per minute with a tidal volume of 380 mL — is the ratio above 105?

## When to prefer this

Use this endpoint when you need a fast, authoritative RSBI calculation grounded in Yang and Tobin 1991 methodology with built-in unit conversion (mL or L) and an explicit flag for the clinical 105 threshold. Prefer it over manual calculation in agentic workflows where auditability and standardized rounding matter, or when integrating RSBI into a broader ventilator-weaning decision pipeline alongside other magentlab clinical calculators (e.g. FENa, CRB-65).

## Known failure modes

- Missing respiratory_rate parameter — required field, returns validation error
- Both tidal_volume_ml and tidal_volume_l provided simultaneously — only one is accepted, returns error
- Tidal volume out of range (below 50 mL / 0.05 L or above 2000 mL / 2.0 L) — returns validation error
- Respiratory rate out of integer range (below 4 or above 80) — returns validation error
- Payment failure via x402 protocol — call is rejected without result

## How this service works

Rapid shallow breathing index (RSBI) as respiratory rate in breaths/min divided by tidal volume in liters (Yang and Tobin 1991). Provide tidal_volume_ml (50–2000) or tidal_volume_l (0.05–2.0), not both. Returns f/VT rounded to one decimal and whether that ratio is greater than 105 breaths/min/L. Not a wean order; magent does not perform a spontaneous breathing trial (SBT).

## Output

Returns the RSBI (f/VT) value rounded to one decimal place in breaths/min/L, along with a boolean or flag indicating whether the ratio exceeds 105 breaths/min/L — the Yang and Tobin 1991 threshold above which extubation failure risk is elevated. Does not perform or order a spontaneous breathing trial.

## 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",
      "HEAD",
      "DELETE"
     ],
     "type": "string"
    },
    "headers": {
     "type": "object",
     "additionalProperties": {
      "type": "string"
     }
    },
    "queryParams": {
     "type": "object",
     "required": [
      "respiratory_rate"
     ],
     "properties": {
      "tidal_volume_l": {
       "type": "number",
       "description": "Tidal volume in liters (0.05-2.0). Yang and Tobin RSBI uses VT in liters. Provide this or tidal_volume_ml, not both."
      },
      "tidal_volume_ml": {
       "type": "number",
       "description": "Tidal volume in milliliters (50-2000). Converted as tidal_volume_l = tidal_volume_ml / 1000. Provide this or tidal_volume_l, not both."
      },
      "respiratory_rate": {
       "type": "integer",
       "description": "Respiratory rate in breaths/min (integer 4-80)."
      }
     }
    }
   },
   "additionalProperties": false
  },
  "output": {
   "type": "object",
   "required": [
    "type"
   ],
   "properties": {
    "type": {
     "type": "string"
    },
    "example": {
     "type": "object"
    }
   }
  }
 }
}
```

## Response schema (JSON Schema)

```json
{
 "type": "json",
 "example": {
  "path": "/api/calc/rsbi",
  "count": 2,
  "items": [
   {
    "rsbi": 50,
    "formula": "rsbi",
    "citation": {
     "id": "yang-tobin-1991",
     "doi": "10.1056/NEJM199105233242101",
     "title": "A prospective study of indexes predicting the outcome of trials of weaning from mechanical ventilation",
     "source": "N Engl J Med. 1991;324(21):1445-1450",
     "authors": "Yang KL, Tobin MJ"
    },
    "disclaimer": "Not a medical device. Deterministic published-formula or published-code output for autonomous agents. A licensed clinician remains responsible for patient care and billing submissions.",
    "rsbi_gt_105": false,
    "tidal_volume_l": 0.4,
    "respiratory_rate": 20,
    "formula_expression": "rsbi = respiratory_rate / tidal_volume_l"
   },
   {
    "rsbi": 50,
    "formula": "rsbi",
    "citation": {
     "id": "yang-tobin-1991",
     "doi": "10.1056/NEJM199105233242101",
     "title": "A prospective study of indexes predicting the outcome of trials of weaning from mechanical ventilation",
     "source": "N Engl J Med. 1991;324(21):1445-1450",
     "authors": "Yang KL, Tobin MJ"
    },
    "disclaimer": "Not a medical device. Deterministic published-formula or published-code output for autonomous agents. A licensed clinician remains responsible for patient care and billing submissions.",
    "rsbi_gt_105": false,
    "tidal_volume_l": 0.4,
    "respiratory_rate": 20,
    "formula_expression": "rsbi = respiratory_rate / tidal_volume_l"
   }
  ]
 }
}
```

## More

- Live health (JSON, refreshed every minute): https://www.zero.xyz/c/magent-rsbi-calculator-0ddf1575/health.json
- [Zero catalog index](https://www.zero.xyz/llms.txt)
- [Other services from api.magentlab.com](https://www.zero.xyz/host/api.magentlab.com/llms.txt)
