Respiratory · LIVE
GOLD spirometric COPD grade
GOLD spirometric grade
Apply the 2017 GOLD executive summary spirometric classification: obstruction when post-bronchodilator FEV1/FVC is < 0.70, then GOLD grades 1-4 from FEV1 percent predicted.
Markdown: /docs/gold-copd.md · Canonical: https://magentlab.com/docs/gold-copd
Not a medical device. Not a diagnosis, dose, or listing recommendation.
What it computes
Apply the 2017 GOLD executive summary spirometric classification: obstruction when post-bronchodilator FEV1/FVC is < 0.70, then GOLD grades 1-4 from FEV1 percent predicted.
When to use
When an agent already has post-bronchodilator FEV1 percent predicted and FEV1/FVC and needs the published GOLD 1-4 grade or a not_obstructed result. magent does not perform spirometry. Not GOLD ABE.
When not to use
- Not a medical device and not a diagnosis of COPD.
- Not GOLD ABE: this tool does not implement ABE groups (mMRC, CAT, or exacerbations).
- magent does not perform spirometry. fev1_percent_predicted and fev1_fvc_ratio are caller-supplied post-bronchodilator values.
- GOLD 1-4 apply only when FEV1/FVC is < 0.70. A ratio of 0.70 or higher returns not_obstructed even if FEV1 percent predicted is low.
- This is the 2017 GOLD executive summary spirometric classification only (Vogelmeier et al.). It is not a treatment recommendation.
Formula
If post-bronchodilator FEV1/FVC >= 0.70 then gold_grade is not_obstructed (no GOLD 1-4). If FEV1/FVC < 0.70: GOLD 1 (mild) FEV1 >= 80% predicted; GOLD 2 (moderate) 50% <= FEV1 < 80%; GOLD 3 (severe) 30% <= FEV1 < 50%; GOLD 4 (very severe) FEV1 < 30% (Vogelmeier 2017 GOLD executive summary)
Citation
- Authors
- Vogelmeier CF, Criner GJ, Martinez FJ, Anzueto A, Barnes PJ, Bourbeau J, Celli BR, Chen R, Decramer M, Fabbri LM, Frith P, Halpin DMG, López Varela MV, Nishimura M, Roche N, Rodriguez-Roisin R, Sin DD, Singh D, Stockley R, Vestbo J, Wedzicha JA, Agustí A
- Source
- Eur Respir J. 2017;49(3):1700214
Worked example
Obstructed GOLD 1 (mild)
Given:
fev1_fvc_ratio=0.65fev1_percent_predicted=85
- fev1_fvc_ratio 0.65 < 0.70 → obstructed true
- fev1_percent_predicted 85 >= 80 → gold_grade 1 (mild)
Also searched as
- GOLD spirometric grade
- GOLD 1-4 COPD
- FEV1 FVC obstruction
- GOLD airflow limitation
- Vogelmeier 2017 GOLD
- post-bronchodilator FEV1 grade
- GOLD mild moderate severe
- COPD spirometric classification
Try
Opens the live endpoint. Unpaid browser requests show the paywall; agents should send Accept: application/json.
/api/calc/gold_copd?fev1_percent_predicted=85&fev1_fvc_ratio=0.65
Full URL: https://api.magentlab.com/api/calc/gold_copd?fev1_percent_predicted=85&fev1_fvc_ratio=0.65
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/gold_copd?fev1_percent_predicted=85&fev1_fvc_ratio=0.65"
Parameters
| Name | Type | Required | Description |
|---|---|---|---|
fev1_percent_predicted |
number | required | Post-bronchodilator FEV1 as percent of predicted (10-150). Used for GOLD 1-4 only when FEV1/FVC is < 0.70. magent does not perform spirometry. |
fev1_fvc_ratio |
number | required | Post-bronchodilator FEV1/FVC as a fraction (0.20-1.00). Values < 0.70 are obstructed; 0.70 and above are not_obstructed with no GOLD 1-4. magent does not perform spirometry. |
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": [
{
"fev1_fvc_ratio": "0.65",
"fev1_percent_predicted": "85"
},
{
"fev1_fvc_ratio": "0.65",
"fev1_percent_predicted": "85"
}
]
}
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/gold_copd",
"items": [
{
"components": [
{
"value": 0.65,
"factor": "obstructed",
"met": true
},
{
"value": 85.0,
"factor": "gold_1",
"met": true
},
{
"value": 85.0,
"factor": "gold_2",
"met": false
},
{
"value": 85.0,
"factor": "gold_3",
"met": false
},
{
"value": 85.0,
"factor": "gold_4",
"met": 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": "Vogelmeier CF, Criner GJ, Martinez FJ, Anzueto A, Barnes PJ, Bourbeau J, Celli BR, Chen R, Decramer M, Fabbri LM, Frith P, Halpin DMG, López Varela MV, Nishimura M, Roche N, Rodriguez-Roisin R, Sin DD, Singh D, Stockley R, Vestbo J, Wedzicha JA, Agustí A",
"doi": "10.1183/13993003.00214-2017",
"id": "vogelmeier-2017",
"source": "Eur Respir J. 2017;49(3):1700214",
"title": "Global Strategy for the Diagnosis, Management, and Prevention of Chronic Obstructive Lung Disease 2017 Report. GOLD Executive Summary"
},
"formula": "gold_copd",
"formula_expression": "If post-bronchodilator FEV1/FVC >= 0.70 then gold_grade is not_obstructed (no GOLD 1-4). If FEV1/FVC < 0.70: GOLD 1 (mild) FEV1 >= 80% predicted; GOLD 2 (moderate) 50% <= FEV1 < 80%; GOLD 3 (severe) 30% <= FEV1 < 50%; GOLD 4 (very severe) FEV1 < 30% (Vogelmeier 2017 GOLD executive summary)",
"fev1_percent_predicted": 85.0,
"fev1_fvc_ratio": 0.65,
"gold_grade": "1",
"obstructed": true
},
{
"components": [
{
"value": 0.65,
"factor": "obstructed",
"met": true
},
{
"value": 85.0,
"factor": "gold_1",
"met": true
},
{
"value": 85.0,
"factor": "gold_2",
"met": false
},
{
"value": 85.0,
"factor": "gold_3",
"met": false
},
{
"value": 85.0,
"factor": "gold_4",
"met": 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": "Vogelmeier CF, Criner GJ, Martinez FJ, Anzueto A, Barnes PJ, Bourbeau J, Celli BR, Chen R, Decramer M, Fabbri LM, Frith P, Halpin DMG, López Varela MV, Nishimura M, Roche N, Rodriguez-Roisin R, Sin DD, Singh D, Stockley R, Vestbo J, Wedzicha JA, Agustí A",
"doi": "10.1183/13993003.00214-2017",
"id": "vogelmeier-2017",
"source": "Eur Respir J. 2017;49(3):1700214",
"title": "Global Strategy for the Diagnosis, Management, and Prevention of Chronic Obstructive Lung Disease 2017 Report. GOLD Executive Summary"
},
"formula": "gold_copd",
"formula_expression": "If post-bronchodilator FEV1/FVC >= 0.70 then gold_grade is not_obstructed (no GOLD 1-4). If FEV1/FVC < 0.70: GOLD 1 (mild) FEV1 >= 80% predicted; GOLD 2 (moderate) 50% <= FEV1 < 80%; GOLD 3 (severe) 30% <= FEV1 < 50%; GOLD 4 (very severe) FEV1 < 30% (Vogelmeier 2017 GOLD executive summary)",
"fev1_percent_predicted": 85.0,
"fev1_fvc_ratio": 0.65,
"gold_grade": "1",
"obstructed": true
}
]
}
Response
| Field | Type | Description |
|---|---|---|
formula |
string | gold_copd |
formula_expression |
string | Published Vogelmeier 2017 GOLD spirometric grade rule |
fev1_percent_predicted |
number | Echo of post-bronchodilator FEV1 percent predicted |
fev1_fvc_ratio |
number | Echo of post-bronchodilator FEV1/FVC |
obstructed |
boolean | true when FEV1/FVC is < 0.70 |
gold_grade |
string | GOLD 1, 2, 3, or 4 when obstructed; not_obstructed when FEV1/FVC is >= 0.70. Not a diagnosis. |
components |
array | Rows for obstructed and gold_1 through gold_4 with factor, met, and value |
citation |
object | Vogelmeier 2017 Eur Respir J citation |
disclaimer |
string | Not-a-device notice |
Example JSON
Machine form of the same example. Frozen fixture. Not a live lookup.
{
"components": [
{
"value": 0.65,
"factor": "obstructed",
"met": true
},
{
"value": 85.0,
"factor": "gold_1",
"met": true
},
{
"value": 85.0,
"factor": "gold_2",
"met": false
},
{
"value": 85.0,
"factor": "gold_3",
"met": false
},
{
"value": 85.0,
"factor": "gold_4",
"met": 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": "Vogelmeier CF, Criner GJ, Martinez FJ, Anzueto A, Barnes PJ, Bourbeau J, Celli BR, Chen R, Decramer M, Fabbri LM, Frith P, Halpin DMG, López Varela MV, Nishimura M, Roche N, Rodriguez-Roisin R, Sin DD, Singh D, Stockley R, Vestbo J, Wedzicha JA, Agustí A",
"doi": "10.1183/13993003.00214-2017",
"id": "vogelmeier-2017",
"source": "Eur Respir J. 2017;49(3):1700214",
"title": "Global Strategy for the Diagnosis, Management, and Prevention of Chronic Obstructive Lung Disease 2017 Report. GOLD Executive Summary"
},
"formula": "gold_copd",
"formula_expression": "If post-bronchodilator FEV1/FVC >= 0.70 then gold_grade is not_obstructed (no GOLD 1-4). If FEV1/FVC < 0.70: GOLD 1 (mild) FEV1 >= 80% predicted; GOLD 2 (moderate) 50% <= FEV1 < 80%; GOLD 3 (severe) 30% <= FEV1 < 50%; GOLD 4 (very severe) FEV1 < 30% (Vogelmeier 2017 GOLD executive summary)",
"fev1_percent_predicted": 85.0,
"fev1_fvc_ratio": 0.65,
"gold_grade": "1",
"obstructed": true
}
Client errors (HTTP 400)
Invalid params return 400 without charge. Shared HTTP 402 and 503 meanings: Payments.
| HTTP | Code | When |
|---|---|---|
| 400 | invalid_fev1_percent |
fev1_percent_predicted must be a number from 10 to 150. Returned before settlement; you are not charged. |
| 400 | invalid_fev1_fvc_ratio |
fev1_fvc_ratio must be a number from 0.20 to 1.00 (post-bronchodilator). 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
- mMRC — Return the Mahler 1988 modified Medical Research Council (mMRC) dyspnea grade 0-4 from a caller-assigned integer, with the published grade wording.
- BODE — Sum Celli 2004 BODE points from BMI, FEV1 percent predicted, MMRC dyspnea, and 6-minute walk distance.
- DECAF — Sum Steer 2012 DECAF points from extended MRC dyspnoea, eosinophils, chest radiograph consolidation, arterial pH, and atrial fibrillation.
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.