Respiratory · LIVE
RESP score (Schmidt)
RESP
Sum Schmidt 2014 Table 3 RESP points from caller-assigned pre-ECMO predictors and return class I–V with published hospital survival percents.
Markdown: /docs/resp.md · Canonical: https://magentlab.com/docs/resp
Not a medical device. Not a diagnosis, dose, or listing recommendation.
What it computes
Sum Schmidt 2014 Table 3 RESP points from caller-assigned pre-ECMO predictors and return class I–V with published hospital survival percents.
When to use
When an agent needs the published RESP point total and class survival percent and must not invent an ECMO cannulation order or a continuous logit.
When not to use
- Not a medical device and not an ECMO initiation, cannulation, or continuation order. magent does not assign ECMO and does not examine the patient.
- One Table 3 acute respiratory diagnosis group only. Do not add a second diagnosis. Flags are caller-assigned (immunocompromised includes malignancy, solid organ transplant, HIV, or cirrhosis as assigned).
- PaCO2 uses the published ≥75 mm Hg cutoff (the paper also states ≥10 kPa). magent accepts mm Hg only and does not convert kPa.
- Hospital survival percents are the five published risk-class figures (I 92%, II 76%, III 57%, IV 33%, V 18%). This tool does not compute a continuous logit.
Formula
RESP = age_years (18-49 → 0, 50-59 → -2, ≥60 → -3) + immunocompromised (-2) + mechanical_ventilation_before_ecmo (lt_48h → 3, h48_to_7d → 1, gt_7d → 0) + diagnosis (viral_pneumonia → 3, bacterial_pneumonia → 3, asthma → 11, trauma_burn → 3, aspiration_pneumonitis → 5, other_acute_respiratory → 1, nonrespiratory_or_chronic_respiratory → 0) + cns_dysfunction (-7) + acute_nonpulmonary_infection (-3) + neuromuscular_blockade_before_ecmo (1) + nitric_oxide_before_ecmo (-1) + bicarbonate_infusion_before_ecmo (-2) + cardiac_arrest_before_ecmo (-2) + (paco2_mm_hg ≥75 → -1) + (peak_inspiratory_pressure_cm_h2o ≥42 → -1); Schmidt 2014 Table 3; range -22 to 15; class I ≥6 (92%), II 3 to 5 (76%), III -1 to 2 (57%), IV -5 to -2 (33%), V ≤-6 (18%) hospital survival
Citation
- Authors
- Schmidt M, Bailey M, Sheldrake J, et al.
- Source
- Am J Respir Crit Care Med. 2014;189(11):1374-1382
Worked example
Age 40, viral pneumonia, MV <48 h
Given:
acute_nonpulmonary_infection=falseage_years=40bicarbonate_infusion_before_ecmo=falsecardiac_arrest_before_ecmo=falsecns_dysfunction=falsediagnosis=viral_pneumoniaimmunocompromised=falsemechanical_ventilation_before_ecmo=lt_48hneuromuscular_blockade_before_ecmo=falsenitric_oxide_before_ecmo=falsepaco2_mm_hg=40peak_inspiratory_pressure_cm_h2o=30
- age 40 → 0; immunocompromised false → 0; lt_48h → +3; viral_pneumonia → +3; remaining flags false; PaCO2 40 → 0; PIP 30 → 0
- Score = 6 (range -22 to 15); resp_class I; hospital_survival_percent 92
Age 60, immunocompromised, CNS dysfunction is class V
Given:
acute_nonpulmonary_infection=falseage_years=60bicarbonate_infusion_before_ecmo=falsecardiac_arrest_before_ecmo=falsecns_dysfunction=truediagnosis=viral_pneumoniaimmunocompromised=truemechanical_ventilation_before_ecmo=lt_48hneuromuscular_blockade_before_ecmo=falsenitric_oxide_before_ecmo=falsepaco2_mm_hg=40peak_inspiratory_pressure_cm_h2o=30
- age 60 → -3; immunocompromised → -2; lt_48h → +3; viral_pneumonia → +3; cns_dysfunction → -7
- Score = -6; resp_class V; hospital_survival_percent 18. Not an ECMO order.
Also searched as
- RESP score
- Respiratory ECMO Survival Prediction
- Schmidt RESP
- pre-ECMO survival score
- VV-ECMO survival
- RESP class
- extracorporeal membrane oxygenation survival prediction
- Schmidt 2014 RESP
Try
Opens the live endpoint. Unpaid browser requests show the paywall; agents should send Accept: application/json.
Full URL: https://api.magentlab.com/api/calc/resp?age_years=40&immunocompromised=false&mechanical_ventilation_before_ecmo=lt_48h&diagnosis=viral_pneumonia&cns_dysfunction=false´_nonpulmonary_infection=false&neuromuscular_blockade_before_ecmo=false&nitric_oxide_before_ecmo=false&bicarbonate_infusion_before_ecmo=false&cardiac_arrest_before_ecmo=false&paco2_mm_hg=40&peak_inspiratory_pressure_cm_h2o=30
Call
Expect HTTP 402 until you retry with PAYMENT-SIGNATURE. Incomplete query params
return HTTP 400 before any quote or charge.
curl -i -H "Accept: application/json" "https://api.magentlab.com/api/calc/resp?age_years=40&immunocompromised=false&mechanical_ventilation_before_ecmo=lt_48h&diagnosis=viral_pneumonia&cns_dysfunction=false´_nonpulmonary_infection=false&neuromuscular_blockade_before_ecmo=false&nitric_oxide_before_ecmo=false&bicarbonate_infusion_before_ecmo=false&cardiac_arrest_before_ecmo=false&paco2_mm_hg=40&peak_inspiratory_pressure_cm_h2o=30"
Parameters
| Name | Type | Required | Description |
|---|---|---|---|
age_years |
integer | required | Age in years, integer 18-120, as assigned before ECMO (Schmidt 2014 Table 3). 18-49 → 0; 50-59 → -2; ≥60 → -3. |
immunocompromised |
boolean | required | Immunocompromised status as assigned by the caller (Schmidt 2014: malignancy, solid organ transplant, HIV, or cirrhosis). true or false. true scores -2. |
mechanical_ventilation_before_ecmo |
string | required · lt_48h, h48_to_7d, gt_7d | Duration of mechanical ventilation before ECMO as one token (Schmidt 2014 Table 3). lt_48h → +3; h48_to_7d → +1; gt_7d → 0. magent does not subtract timestamps. |
diagnosis |
string | required · viral_pneumonia, bacterial_pneumonia, asthma, trauma_burn, aspiration_pneumonitis, other_acute_respiratory, nonrespiratory_or_chronic_respiratory | One acute respiratory diagnosis group (Schmidt 2014 Table 3). viral_pneumonia → +3; bacterial_pneumonia → +3; asthma → +11; trauma_burn → +3; aspiration_pneumonitis → +5; other_acute_respiratory → +1; nonrespiratory_or_chronic_respiratory → 0. Select one token. magent does not diagnose. |
cns_dysfunction |
boolean | required | Central nervous system dysfunction as assigned by the caller (Schmidt 2014: neurotrauma, stroke, encephalopathy, cerebral embolism, or seizure). true or false. true scores -7. magent does not examine the patient. |
acute_nonpulmonary_infection |
boolean | required | Acute associated (nonpulmonary) infection as assigned by the caller (Schmidt 2014: bacteremia, pneumonia diagnosed >48 h before ECMO, or infected burns). true or false. true scores -3. |
neuromuscular_blockade_before_ecmo |
boolean | required | Neuromuscular blockade agents before ECMO as assigned by the caller (Schmidt 2014 Table 3). true or false. true scores +1. |
nitric_oxide_before_ecmo |
boolean | required | Nitric oxide use before ECMO as assigned by the caller (Schmidt 2014 Table 3). true or false. true scores -1. |
bicarbonate_infusion_before_ecmo |
boolean | required | Bicarbonate infusion before ECMO as assigned by the caller (Schmidt 2014 Table 3). true or false. true scores -2. |
cardiac_arrest_before_ecmo |
boolean | required | Cardiac arrest before ECMO as assigned by the caller (Schmidt 2014 Table 3). true or false. true scores -2. |
paco2_mm_hg |
number | required | Arterial PaCO2 in mm Hg (8-200) as assigned before ECMO. ≥75 scores -1 (Schmidt 2014 Table 3; the paper also states ≥10 kPa). magent does not convert kPa and does not read an ABG. |
peak_inspiratory_pressure_cm_h2o |
number | required | Peak inspiratory pressure in cm H2O (5-80) as assigned before ECMO. ≥42 scores -1 (Schmidt 2014 Table 3). magent does not read a ventilator. |
Bulk (POST)
POST the same path with a JSON items array. The first item is the GET unit; each additional item is $0.002. Invalid items return HTTP 400 before settlement.
- 1 to 25 items. Each item uses the same keys as the GET query parameters.
- POST of 1 item costs the same as GET. Lists longer than 25: chunk into multiple POSTs. Extra items still execute; do not pad dummy rows.
- The first invalid item fails the whole request (index in the 400 JSON). You are not charged.
- HTTP 200 is {count, path, items}. Each items[i] is the GET 200 body for that row.
- Catalog misses (empty matches, found=false) stay paid 200s inside that slot.
- x402 resource URL is this path plus n and body_sha256. Browsers that prefer text/html get the same paywall as GET; Pay retries POST with the same items.
Example request (fixture)
{
"items": [
{
"acute_nonpulmonary_infection": "false",
"age_years": "40",
"bicarbonate_infusion_before_ecmo": "false",
"cardiac_arrest_before_ecmo": "false",
"cns_dysfunction": "false",
"diagnosis": "viral_pneumonia",
"immunocompromised": "false",
"mechanical_ventilation_before_ecmo": "lt_48h",
"neuromuscular_blockade_before_ecmo": "false",
"nitric_oxide_before_ecmo": "false",
"paco2_mm_hg": "40",
"peak_inspiratory_pressure_cm_h2o": "30"
},
{
"acute_nonpulmonary_infection": "false",
"age_years": "40",
"bicarbonate_infusion_before_ecmo": "false",
"cardiac_arrest_before_ecmo": "false",
"cns_dysfunction": "false",
"diagnosis": "viral_pneumonia",
"immunocompromised": "false",
"mechanical_ventilation_before_ecmo": "lt_48h",
"neuromuscular_blockade_before_ecmo": "false",
"nitric_oxide_before_ecmo": "false",
"paco2_mm_hg": "40",
"peak_inspiratory_pressure_cm_h2o": "30"
}
]
}
Opens a two-item fixture on the API host. Unpaid browsers get the same MetaMask paywall as GET; Pay retries POST with those items.
Example 200 (fixture)
{
"count": 2,
"path": "/api/calc/resp",
"items": [
{
"components": [
{
"value": 40,
"factor": "age_years",
"points": 0,
"present": false
},
{
"factor": "immunocompromised",
"points": 0,
"present": false
},
{
"value": "lt_48h",
"factor": "mechanical_ventilation_before_ecmo",
"points": 3,
"present": true
},
{
"value": "viral_pneumonia",
"factor": "diagnosis",
"points": 3,
"present": true
},
{
"factor": "cns_dysfunction",
"points": 0,
"present": false
},
{
"factor": "acute_nonpulmonary_infection",
"points": 0,
"present": false
},
{
"factor": "neuromuscular_blockade_before_ecmo",
"points": 0,
"present": false
},
{
"factor": "nitric_oxide_before_ecmo",
"points": 0,
"present": false
},
{
"factor": "bicarbonate_infusion_before_ecmo",
"points": 0,
"present": false
},
{
"factor": "cardiac_arrest_before_ecmo",
"points": 0,
"present": false
},
{
"value": 40.0,
"factor": "paco2_mm_hg",
"points": 0,
"present": false
},
{
"value": 30.0,
"factor": "peak_inspiratory_pressure_cm_h2o",
"points": 0,
"present": false
}
],
"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.",
"citation": {
"authors": "Schmidt M, Bailey M, Sheldrake J, et al.",
"doi": "10.1164/rccm.201311-2023OC",
"id": "schmidt-2014",
"pmid": "24693864",
"source": "Am J Respir Crit Care Med. 2014;189(11):1374-1382",
"title": "Predicting Survival after Extracorporeal Membrane Oxygenation for Severe Acute Respiratory Failure. The Respiratory Extracorporeal Membrane Oxygenation Survival Prediction (RESP) Score"
},
"formula": "resp",
"formula_expression": "RESP = age_years (18-49 → 0, 50-59 → -2, ≥60 → -3) + immunocompromised (-2) + mechanical_ventilation_before_ecmo (lt_48h → 3, h48_to_7d → 1, gt_7d → 0) + diagnosis (viral_pneumonia → 3, bacterial_pneumonia → 3, asthma → 11, trauma_burn → 3, aspiration_pneumonitis → 5, other_acute_respiratory → 1, nonrespiratory_or_chronic_respiratory → 0) + cns_dysfunction (-7) + acute_nonpulmonary_infection (-3) + neuromuscular_blockade_before_ecmo (1) + nitric_oxide_before_ecmo (-1) + bicarbonate_infusion_before_ecmo (-2) + cardiac_arrest_before_ecmo (-2) + (paco2_mm_hg ≥75 → -1) + (peak_inspiratory_pressure_cm_h2o ≥42 → -1); Schmidt 2014 Table 3; range -22 to 15; class I ≥6 (92%), II 3 to 5 (76%), III -1 to 2 (57%), IV -5 to -2 (33%), V ≤-6 (18%) hospital survival",
"paco2_mm_hg": 40.0,
"age_years": 40,
"max_score": 15,
"score": 6,
"diagnosis": "viral_pneumonia",
"min_score": -22,
"hospital_survival_percent": 92,
"mechanical_ventilation_before_ecmo": "lt_48h",
"peak_inspiratory_pressure_cm_h2o": 30.0,
"resp_class": "I"
},
{
"components": [
{
"value": 40,
"factor": "age_years",
"points": 0,
"present": false
},
{
"factor": "immunocompromised",
"points": 0,
"present": false
},
{
"value": "lt_48h",
"factor": "mechanical_ventilation_before_ecmo",
"points": 3,
"present": true
},
{
"value": "viral_pneumonia",
"factor": "diagnosis",
"points": 3,
"present": true
},
{
"factor": "cns_dysfunction",
"points": 0,
"present": false
},
{
"factor": "acute_nonpulmonary_infection",
"points": 0,
"present": false
},
{
"factor": "neuromuscular_blockade_before_ecmo",
"points": 0,
"present": false
},
{
"factor": "nitric_oxide_before_ecmo",
"points": 0,
"present": false
},
{
"factor": "bicarbonate_infusion_before_ecmo",
"points": 0,
"present": false
},
{
"factor": "cardiac_arrest_before_ecmo",
"points": 0,
"present": false
},
{
"value": 40.0,
"factor": "paco2_mm_hg",
"points": 0,
"present": false
},
{
"value": 30.0,
"factor": "peak_inspiratory_pressure_cm_h2o",
"points": 0,
"present": false
}
],
"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.",
"citation": {
"authors": "Schmidt M, Bailey M, Sheldrake J, et al.",
"doi": "10.1164/rccm.201311-2023OC",
"id": "schmidt-2014",
"pmid": "24693864",
"source": "Am J Respir Crit Care Med. 2014;189(11):1374-1382",
"title": "Predicting Survival after Extracorporeal Membrane Oxygenation for Severe Acute Respiratory Failure. The Respiratory Extracorporeal Membrane Oxygenation Survival Prediction (RESP) Score"
},
"formula": "resp",
"formula_expression": "RESP = age_years (18-49 → 0, 50-59 → -2, ≥60 → -3) + immunocompromised (-2) + mechanical_ventilation_before_ecmo (lt_48h → 3, h48_to_7d → 1, gt_7d → 0) + diagnosis (viral_pneumonia → 3, bacterial_pneumonia → 3, asthma → 11, trauma_burn → 3, aspiration_pneumonitis → 5, other_acute_respiratory → 1, nonrespiratory_or_chronic_respiratory → 0) + cns_dysfunction (-7) + acute_nonpulmonary_infection (-3) + neuromuscular_blockade_before_ecmo (1) + nitric_oxide_before_ecmo (-1) + bicarbonate_infusion_before_ecmo (-2) + cardiac_arrest_before_ecmo (-2) + (paco2_mm_hg ≥75 → -1) + (peak_inspiratory_pressure_cm_h2o ≥42 → -1); Schmidt 2014 Table 3; range -22 to 15; class I ≥6 (92%), II 3 to 5 (76%), III -1 to 2 (57%), IV -5 to -2 (33%), V ≤-6 (18%) hospital survival",
"paco2_mm_hg": 40.0,
"age_years": 40,
"max_score": 15,
"score": 6,
"diagnosis": "viral_pneumonia",
"min_score": -22,
"hospital_survival_percent": 92,
"mechanical_ventilation_before_ecmo": "lt_48h",
"peak_inspiratory_pressure_cm_h2o": 30.0,
"resp_class": "I"
}
]
}
Response
| Field | Type | Description |
|---|---|---|
formula |
string | resp |
formula_expression |
string | Exact expression used |
score |
integer | Schmidt 2014 Table 3 RESP points, theoretical range -22 to 15 |
min_score |
integer | -22 |
max_score |
integer | 15 |
resp_class |
string | Schmidt 2014 risk class I (≥6), II (3 to 5), III (-1 to 2), IV (-5 to -2), or V (≤-6). A class, not an ECMO order. |
hospital_survival_percent |
integer | Published hospital survival percent for the class: I 92, II 76, III 57, IV 33, V 18. Not a continuous logit. |
age_years |
integer | Age in years used for Table 3 age points |
diagnosis |
string | Diagnosis token used (one Table 3 group) |
mechanical_ventilation_before_ecmo |
string | Mechanical-ventilation duration token used |
paco2_mm_hg |
number | Arterial PaCO2 in mm Hg used for the ≥75 cutoff |
peak_inspiratory_pressure_cm_h2o |
number | Peak inspiratory pressure in cm H2O used for the ≥42 cutoff |
components |
array | Per-factor points |
citation |
object | Schmidt et al. Am J Respir Crit Care Med 2014 citation |
disclaimer |
string | Not-a-device notice |
Example JSON
Machine form of the same example. Frozen fixture. Not a live lookup.
{
"components": [
{
"value": 40,
"factor": "age_years",
"points": 0,
"present": false
},
{
"factor": "immunocompromised",
"points": 0,
"present": false
},
{
"value": "lt_48h",
"factor": "mechanical_ventilation_before_ecmo",
"points": 3,
"present": true
},
{
"value": "viral_pneumonia",
"factor": "diagnosis",
"points": 3,
"present": true
},
{
"factor": "cns_dysfunction",
"points": 0,
"present": false
},
{
"factor": "acute_nonpulmonary_infection",
"points": 0,
"present": false
},
{
"factor": "neuromuscular_blockade_before_ecmo",
"points": 0,
"present": false
},
{
"factor": "nitric_oxide_before_ecmo",
"points": 0,
"present": false
},
{
"factor": "bicarbonate_infusion_before_ecmo",
"points": 0,
"present": false
},
{
"factor": "cardiac_arrest_before_ecmo",
"points": 0,
"present": false
},
{
"value": 40.0,
"factor": "paco2_mm_hg",
"points": 0,
"present": false
},
{
"value": 30.0,
"factor": "peak_inspiratory_pressure_cm_h2o",
"points": 0,
"present": false
}
],
"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.",
"citation": {
"authors": "Schmidt M, Bailey M, Sheldrake J, et al.",
"doi": "10.1164/rccm.201311-2023OC",
"id": "schmidt-2014",
"pmid": "24693864",
"source": "Am J Respir Crit Care Med. 2014;189(11):1374-1382",
"title": "Predicting Survival after Extracorporeal Membrane Oxygenation for Severe Acute Respiratory Failure. The Respiratory Extracorporeal Membrane Oxygenation Survival Prediction (RESP) Score"
},
"formula": "resp",
"formula_expression": "RESP = age_years (18-49 → 0, 50-59 → -2, ≥60 → -3) + immunocompromised (-2) + mechanical_ventilation_before_ecmo (lt_48h → 3, h48_to_7d → 1, gt_7d → 0) + diagnosis (viral_pneumonia → 3, bacterial_pneumonia → 3, asthma → 11, trauma_burn → 3, aspiration_pneumonitis → 5, other_acute_respiratory → 1, nonrespiratory_or_chronic_respiratory → 0) + cns_dysfunction (-7) + acute_nonpulmonary_infection (-3) + neuromuscular_blockade_before_ecmo (1) + nitric_oxide_before_ecmo (-1) + bicarbonate_infusion_before_ecmo (-2) + cardiac_arrest_before_ecmo (-2) + (paco2_mm_hg ≥75 → -1) + (peak_inspiratory_pressure_cm_h2o ≥42 → -1); Schmidt 2014 Table 3; range -22 to 15; class I ≥6 (92%), II 3 to 5 (76%), III -1 to 2 (57%), IV -5 to -2 (33%), V ≤-6 (18%) hospital survival",
"paco2_mm_hg": 40.0,
"age_years": 40,
"max_score": 15,
"score": 6,
"diagnosis": "viral_pneumonia",
"min_score": -22,
"hospital_survival_percent": 92,
"mechanical_ventilation_before_ecmo": "lt_48h",
"peak_inspiratory_pressure_cm_h2o": 30.0,
"resp_class": "I"
}
Client errors (HTTP 400)
Invalid params return 400 without charge. Shared HTTP 402 and 503 meanings: Payments.
| HTTP | Code | When |
|---|---|---|
| 400 | invalid_resp |
RESP needs Schmidt 2014 pre-ECMO respiratory-failure predictors in published ranges. Returned before settlement; you are not charged. |
| 400 | invalid_items |
POST body must be a JSON object with only an items array Returned before settlement; you are not charged. |
| 400 | invalid_item_count |
items must be an array of 1 to 25 objects Returned before settlement; you are not charged. |
| 400 | invalid_item |
each items entry must be a JSON object Returned before settlement; you are not charged. |
Related tools
- APACHE II — Compute the Knaus 1985 APACHE II integer from 12 Acute Physiology Score items, age points, and chronic-health points.
- SAPS 3 — Compute the Moreno 2005 SAPS 3 admission integer from Box I, Box II, and Box III at ICU admission, then the Part 2 global logit hospital-mortality percent.
Payment
Unpaid requests return HTTP 402 even if query parameters or POST items are missing or invalid, so CDP and agents can index the path. After a PAYMENT-SIGNATURE, invalid params return HTTP 400 JSON before settlement. magent does not charge. Fix the params, then request a new 402 quote for that complete URL. Catalog misses (empty matches, found=false) are valid paid 200s. Unpaid valid requests return HTTP 402 with a base64
PAYMENT-REQUIRED
header. HTTP 503 is not a new quote: retry the same PAYMENT-SIGNATURE. Full handshake
and shared payment errors: Payments.
Stdio MCP: /docs/mcp.
Guarantees
- HTTP 402 is unpaid, including a missing query. After PAYMENT-SIGNATURE, invalid parameters return HTTP 400 before settlement. You are not charged. HTTP 402 never includes the tool JSON.
- exact: settlement finishes before the tool (paymentFlow upfront). batch-settlement: verify/deposit before the tool; chargedCumulativeAmount commits after HTTP 2xx. Uncertain or failed settlement fails closed (HTTP 503). Retry the same PAYMENT-SIGNATURE.
- HTTP 402 is unpaid only. Do not sign a second authorization because of a 503.
- Execution is timeout-bounded and concurrency-capped.
- Calculator inputs are stored encrypted for allowlisted operators (Magent Console). They are not in public logs, SSH lookups, catalog, or rollups. Request logs store path without query.