Emergency · LIVE
ASDAS-CRP (Ankylosing Spondylitis Disease Activity Score)
ASDAS-CRP
Compute the van der Heijde 2009 ASAS-preferred ASDAS-CRP from caller-assigned BASDAI 0–10 back pain, morning stiffness duration, peripheral pain/swelling, patient global, and CRP in mg/L.
Markdown: /docs/asdas-crp.md · Canonical: https://magentlab.com/docs/asdas-crp
Not a medical device. Not a diagnosis, dose, or listing recommendation.
What it computes
Compute the van der Heijde 2009 ASAS-preferred ASDAS-CRP from caller-assigned BASDAI 0–10 back pain, morning stiffness duration, peripheral pain/swelling, patient global, and CRP in mg/L.
When to use
When an agent already has caller-assigned 0–10 BASDAI items (questions 2, 3, and 6), a 0–10 patient global, and CRP in mg/L and needs the published 2009 ASDAS-CRP, not ASDAS-ESR and not a BASDAI total.
When not to use
- Not a medical device and not a biologic order.
- magent does not examine the patient or assay CRP. back_pain, morning_stiffness_duration, patient_global, and peripheral_pain_swelling are caller-assigned 0–10 VAS/NRS items. morning_stiffness_duration is BASDAI question 6 on 0–10, not hours. CRP is mg/L as published. The 0–500 CRP range is a magent clamp.
- Computes ASDAS-CRP only. Does not compute ASDAS-ESR. Not a BASDAI total (does not use BASDAI questions 1, 4, or 5).
- van der Heijde 2009 selected the CRP version as preferred and did not publish inactive/low/high/very-high cuts. magent does not apply Machado 2011 1.3/2.1/3.5 bands or a later CRP 2 mg/L floor.
Formula
ASDAS-CRP = 0.12*back_pain + 0.06*morning_stiffness_duration + 0.11*patient_global + 0.07*peripheral_pain_swelling + 0.58*ln(crp_mg_l+1); van der Heijde 2009 preferred CRP formula; BASDAI 0-10 items (Q2 back pain, Q6 stiffness duration, Q3 peripheral pain/swelling) and patient global 0-10; CRP mg/L; not ASDAS-ESR; not BASDAI total; no Machado 2011 1.3/2.1/3.5 cuts; magent does not examine the patient or assay CRP
Citation
- Authors
- van der Heijde D, Lie E, Kvien TK, Sieper J, Van den Bosch F, Listing J, Braun J, Landewé R; ASAS
- Source
- Ann Rheum Dis. 2009;68(12):1811-1818
Worked example
All zeros isolate ln(CRP+1) at CRP 0 mg/L
Given:
back_pain=0crp_mg_l=0morning_stiffness_duration=0patient_global=0peripheral_pain_swelling=0
- BASDAI 0-10 terms are 0; CRP 0 mg/L (no 2009 floor)
- 0.58*ln(0+1) = 0.58*ln(1) = 0
- score 0.00
Clinical zeros isolate 0.58*ln(CRP+1) at CRP 9 mg/L
Given:
back_pain=0crp_mg_l=9morning_stiffness_duration=0patient_global=0peripheral_pain_swelling=0
- 0.58*ln(9+1) = 0.58*ln(10)
- score 1.34
Also searched as
- ASDAS CRP
- ASDAS-CRP
- ankylosing spondylitis disease activity score CRP
- ASAS ASDAS CRP
- van der Heijde ASDAS
- axial spondyloarthritis ASDAS CRP
- BASDAI CRP ASDAS
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/asdas_crp?back_pain=0&morning_stiffness_duration=0&patient_global=0&peripheral_pain_swelling=0&crp_mg_l=0
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/asdas_crp?back_pain=0&morning_stiffness_duration=0&patient_global=0&peripheral_pain_swelling=0&crp_mg_l=0"
Parameters
| Name | Type | Required | Description |
|---|---|---|---|
back_pain |
number | required | Caller-assigned total back pain on a 0-10 VAS or NRS (van der Heijde 2009; BASDAI question 2, neck/back/hip pain). Number 0-10. magent does not examine the patient. |
morning_stiffness_duration |
number | required | Caller-assigned duration of morning stiffness on a 0-10 VAS or NRS (van der Heijde 2009; BASDAI question 6). Number 0-10, not hours. magent does not examine the patient. |
patient_global |
number | required | Caller-assigned patient global assessment of disease activity on a 0-10 VAS or NRS (van der Heijde 2009). Number 0-10. magent does not examine the patient. |
peripheral_pain_swelling |
number | required | Caller-assigned peripheral pain/swelling on a 0-10 VAS or NRS (van der Heijde 2009; BASDAI question 3, joints other than neck/back/hips). Number 0-10. magent does not examine the patient. |
crp_mg_l |
number | required | Caller-assigned C-reactive protein in mg/L (van der Heijde 2009; not mg/dL). Number 0-500 is a magent clamp. The 2009 papers do not floor CRP at 2 mg/L. magent does not assay CRP. |
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": [
{
"back_pain": "0",
"crp_mg_l": "0",
"morning_stiffness_duration": "0",
"patient_global": "0",
"peripheral_pain_swelling": "0"
},
{
"back_pain": "0",
"crp_mg_l": "0",
"morning_stiffness_duration": "0",
"patient_global": "0",
"peripheral_pain_swelling": "0"
}
]
}
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/asdas_crp",
"items": [
{
"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": "van der Heijde D, Lie E, Kvien TK, Sieper J, Van den Bosch F, Listing J, Braun J, Landewé R; ASAS",
"doi": "10.1136/ard.2008.100826",
"id": "van-der-heijde-2009",
"pmid": "19060001",
"source": "Ann Rheum Dis. 2009;68(12):1811-1818",
"title": "ASDAS, a highly discriminatory ASAS-endorsed disease activity score in patients with ankylosing spondylitis"
},
"formula": "asdas_crp",
"formula_expression": "ASDAS-CRP = 0.12*back_pain + 0.06*morning_stiffness_duration + 0.11*patient_global + 0.07*peripheral_pain_swelling + 0.58*ln(crp_mg_l+1); van der Heijde 2009 preferred CRP formula; BASDAI 0-10 items (Q2 back pain, Q6 stiffness duration, Q3 peripheral pain/swelling) and patient global 0-10; CRP mg/L; not ASDAS-ESR; not BASDAI total; no Machado 2011 1.3/2.1/3.5 cuts; magent does not examine the patient or assay CRP",
"score": 0.0,
"crp_mg_l": 0.0,
"back_pain": 0.0,
"morning_stiffness_duration": 0.0,
"patient_global": 0.0,
"peripheral_pain_swelling": 0.0
},
{
"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": "van der Heijde D, Lie E, Kvien TK, Sieper J, Van den Bosch F, Listing J, Braun J, Landewé R; ASAS",
"doi": "10.1136/ard.2008.100826",
"id": "van-der-heijde-2009",
"pmid": "19060001",
"source": "Ann Rheum Dis. 2009;68(12):1811-1818",
"title": "ASDAS, a highly discriminatory ASAS-endorsed disease activity score in patients with ankylosing spondylitis"
},
"formula": "asdas_crp",
"formula_expression": "ASDAS-CRP = 0.12*back_pain + 0.06*morning_stiffness_duration + 0.11*patient_global + 0.07*peripheral_pain_swelling + 0.58*ln(crp_mg_l+1); van der Heijde 2009 preferred CRP formula; BASDAI 0-10 items (Q2 back pain, Q6 stiffness duration, Q3 peripheral pain/swelling) and patient global 0-10; CRP mg/L; not ASDAS-ESR; not BASDAI total; no Machado 2011 1.3/2.1/3.5 cuts; magent does not examine the patient or assay CRP",
"score": 0.0,
"crp_mg_l": 0.0,
"back_pain": 0.0,
"morning_stiffness_duration": 0.0,
"patient_global": 0.0,
"peripheral_pain_swelling": 0.0
}
]
}
Response
| Field | Type | Description |
|---|---|---|
formula |
string | asdas_crp |
formula_expression |
string | Exact expression used |
score |
number | van der Heijde 2009 ASDAS-CRP, 2 decimals. 0.12*back_pain+0.06*morning_stiffness_duration+0.11*patient_global+0.07*peripheral_pain_swelling+0.58*ln(crp_mg_l+1) |
back_pain |
number | Back pain 0-10 used |
morning_stiffness_duration |
number | Morning stiffness duration 0-10 used |
patient_global |
number | Patient global 0-10 used |
peripheral_pain_swelling |
number | Peripheral pain/swelling 0-10 used |
crp_mg_l |
number | CRP in mg/L used |
citation |
object | van der Heijde et al. Ann Rheum Dis 2009 citation |
disclaimer |
string | Not-a-device notice |
Example JSON
Machine form of the same example. Frozen fixture. Not a live lookup.
{
"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": "van der Heijde D, Lie E, Kvien TK, Sieper J, Van den Bosch F, Listing J, Braun J, Landewé R; ASAS",
"doi": "10.1136/ard.2008.100826",
"id": "van-der-heijde-2009",
"pmid": "19060001",
"source": "Ann Rheum Dis. 2009;68(12):1811-1818",
"title": "ASDAS, a highly discriminatory ASAS-endorsed disease activity score in patients with ankylosing spondylitis"
},
"formula": "asdas_crp",
"formula_expression": "ASDAS-CRP = 0.12*back_pain + 0.06*morning_stiffness_duration + 0.11*patient_global + 0.07*peripheral_pain_swelling + 0.58*ln(crp_mg_l+1); van der Heijde 2009 preferred CRP formula; BASDAI 0-10 items (Q2 back pain, Q6 stiffness duration, Q3 peripheral pain/swelling) and patient global 0-10; CRP mg/L; not ASDAS-ESR; not BASDAI total; no Machado 2011 1.3/2.1/3.5 cuts; magent does not examine the patient or assay CRP",
"score": 0.0,
"crp_mg_l": 0.0,
"back_pain": 0.0,
"morning_stiffness_duration": 0.0,
"patient_global": 0.0,
"peripheral_pain_swelling": 0.0
}
Client errors (HTTP 400)
Invalid params return 400 without charge. Shared HTTP 402 and 503 meanings: Payments.
| HTTP | Code | When |
|---|---|---|
| 400 | invalid_asdas_crp |
ASDAS-CRP inputs must match van der Heijde 2009 back pain, stiffness, patient global, peripheral complaints, and CRP from that paper. 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
- ASAS axial SpA — Apply the 2009 ASAS classification criteria for axial spondyloarthritis (Rudwaleit set 3a / figure 2): require chronic back pain ≥3 months with age at onset <45, then return whether the imaging arm (sacroiliitis plus ≥1 SpA feature) or the clinical arm (HLA-B27 plus ≥2 other SpA features) classifies axial SpA. Not a diagnosis.
- DAS28-CRP — Compute the Wells 2009 28-joint Disease Activity Score based on C-reactive protein from caller-assigned TJC28, SJC28, CRP in mg/L, and 0–100 mm general health, including the +0.96 constant, and return DAS28-defined remission when the score is <2.6.
- SDAI — Sum caller-assigned 28-joint swollen and tender counts, 0–10 cm patient and evaluator globals, and CRP in mg/dL, and return the Aletaha 2005 SDAI with the newly proposed activity state.
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.