MAGENT

GI · LIVE

Pediatric Crohn's Disease Activity Index (PCDAI)

PCDAI

Sum eleven caller-assigned Hyams 1991 PCDAI item points and return the published total (max 100). Does not return activity bands.

LIVE $0.005 USDC GET /api/calc/pcdai

Markdown: /docs/pcdai.md · Canonical: https://magentlab.com/docs/pcdai

Not a medical device. Not a diagnosis, dose, or listing recommendation.

What it computes

Sum eleven caller-assigned Hyams 1991 PCDAI item points and return the published total (max 100). Does not return activity bands.

When to use

When an agent has already assigned Hyams 1991 published point values for the eleven PCDAI items and needs the total, not a diagnosis, CDAI, SES-CD, PUCAI, hematocrit table, or later activity cutoffs.

When not to use

  • Not a medical device and not a diagnosis of Crohn's disease or a treatment order.
  • Each of the eleven items is a caller-assigned published point value from Hyams 1991. magent does not examine the child or assign hematocrit age/sex tables.
  • Pediatric Crohn's Disease Activity Index (PCDAI). Not the Best 1976 CDAI, not SES-CD, and not PUCAI.
  • Hyams 1991 did not publish inactive, mild, or moderate cut scores. magent returns score and max_score only and does not apply later Hyams 2005 or other unofficial bands.

Formula

PCDAI = abdominal_pain + stools + well_being + hematocrit + esr + albumin + weight + height + abdomen + perirectal + extra_intestinal; Hyams 1991 caller-assigned item points; hematocrit and esr 0, 2.5, or 5; remaining items 0, 5, or 10; max 100; no published activity bands

Citation

Title
Development and validation of a pediatric Crohn's disease activity index
Authors
Hyams JS, Ferry GD, Mandel FS, et al.
Source
J Pediatr Gastroenterol Nutr. 1991;12(4):439-447
DOI
10.1097/00005176-199105000-00001

Worked example

All eleven items 0

Given: abdomen=0abdominal_pain=0albumin=0esr=0extra_intestinal=0height=0hematocrit=0perirectal=0stools=0weight=0well_being=0

  1. abdominal_pain 0 + stools 0 + well_being 0 + hematocrit 0 + esr 0 + albumin 0 + weight 0 + height 0 + abdomen 0 + perirectal 0 + extra_intestinal 0
  2. Score = 0 (max 100). No activity band.

Published theoretical maximum

Given: abdomen=10abdominal_pain=10albumin=10esr=5extra_intestinal=10height=10hematocrit=5perirectal=10stools=10weight=10well_being=10

  1. abdominal_pain 10 + stools 10 + well_being 10 + hematocrit 5 + esr 5 + albumin 10 + weight 10 + height 10 + abdomen 10 + perirectal 10 + extra_intestinal 10
  2. Score = 100 (max 100). No activity band.

Also searched as

  • PCDAI
  • pediatric Crohn's disease activity index
  • Hyams PCDAI
  • pediatric Crohn activity
  • PCDAI score
  • Crohn's disease children
  • Hyams 1991 PCDAI
  • pediatric Crohn index

Try

Opens the live endpoint. Unpaid browser requests show the paywall; agents should send Accept: application/json.

/api/calc/pcdai?abdominal_pain=0&stools=0&well_being=0&hematocrit=0&esr=0&albumin=0&weight=0&height=0&abdomen=0&perirectal=0&extra_intestinal=0

Full URL: https://api.magentlab.com/api/calc/pcdai?abdominal_pain=0&stools=0&well_being=0&hematocrit=0&esr=0&albumin=0&weight=0&height=0&abdomen=0&perirectal=0&extra_intestinal=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/pcdai?abdominal_pain=0&stools=0&well_being=0&hematocrit=0&esr=0&albumin=0&weight=0&height=0&abdomen=0&perirectal=0&extra_intestinal=0"

Parameters

Name Type Required Description
abdominal_pain integer required Caller-assigned Hyams 1991 PCDAI abdominal pain points (integer 0, 5, or 10): 0 none; 5 mild (brief, does not interfere with activities); 10 moderate/severe (daily, longer lasting, affects activities, nocturnal). magent does not examine the child.
stools integer required Caller-assigned Hyams 1991 PCDAI stools per day points (integer 0, 5, or 10): 0 for 0-1 liquid stools, no blood; 5 for up to 2 semi-formed with small blood, or 2-5 liquid; 10 for gross bleeding, or ≥6 liquid, or nocturnal diarrhea. magent does not examine the child.
well_being integer required Caller-assigned Hyams 1991 PCDAI patient functioning / general well-being points (integer 0, 5, or 10): 0 no limitation of activities, well; 5 occasional difficulty in maintaining age-appropriate activities; 10 frequent limitation of activities, very poor. magent does not examine the child.
hematocrit number required Caller-assigned Hyams 1991 PCDAI hematocrit points (number 0, 2.5, or 5). The paper's age- and sex-specific hematocrit table is applied by the caller. magent does not assign that table. magent does not examine the child.
esr number required Caller-assigned Hyams 1991 PCDAI erythrocyte sedimentation rate points (number 0, 2.5, or 5): 0 for ESR <20 mm/h; 2.5 for 20-50; 5 for >50. magent does not assay ESR. magent does not examine the child.
albumin integer required Caller-assigned Hyams 1991 PCDAI albumin points (integer 0, 5, or 10): 0 for albumin ≥3.5 g/dL; 5 for 3.1-3.4; 10 for ≤3.0. magent does not assay albumin. magent does not examine the child.
weight integer required Caller-assigned Hyams 1991 PCDAI weight points (integer 0, 5, or 10): 0 weight gain or voluntary stable/loss; 5 involuntary stable or weight loss 1-9%; 10 weight loss ≥10%. magent does not examine the child.
height integer required Caller-assigned Hyams 1991 PCDAI height points (integer 0, 5, or 10): at diagnosis 0 <1 channel decrease, 5 ≥1 and <2 channel decrease, 10 ≥2 channel decrease; at follow-up 0 height velocity ≥-1 SD, 5 <-1 SD and >-2 SD, 10 ≤-2 SD. magent does not measure height. magent does not examine the child.
abdomen integer required Caller-assigned Hyams 1991 PCDAI abdomen points (integer 0, 5, or 10): 0 no tenderness, no mass; 5 tenderness, or mass without tenderness; 10 tenderness, involuntary guarding, definite mass. magent does not examine the child.
perirectal integer required Caller-assigned Hyams 1991 PCDAI perirectal disease points (integer 0, 5, or 10): 0 none, asymptomatic tags; 5 1-2 indolent fistula, scant drainage, no tenderness; 10 active fistula, drainage, tenderness, or abscess. magent does not examine the child.
extra_intestinal integer required Caller-assigned Hyams 1991 PCDAI extra-intestinal manifestation points (integer 0, 5, or 10): 0 none; 5 one; 10 two or more (fever ≥38.5°C for 3 days over the past week, arthritis, uveitis, erythema nodosum, pyoderma gangrenosum). magent does not examine the child.

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.

POST /api/calc/pcdai Max 25 unit_amount + extra_item_amount * (n - 1) extra $0.002 PREVIEW

  • 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": [
    {
      "abdomen": "0",
      "abdominal_pain": "0",
      "albumin": "0",
      "esr": "0",
      "extra_intestinal": "0",
      "height": "0",
      "hematocrit": "0",
      "perirectal": "0",
      "stools": "0",
      "weight": "0",
      "well_being": "0"
    },
    {
      "abdomen": "0",
      "abdominal_pain": "0",
      "albumin": "0",
      "esr": "0",
      "extra_intestinal": "0",
      "height": "0",
      "hematocrit": "0",
      "perirectal": "0",
      "stools": "0",
      "weight": "0",
      "well_being": "0"
    }
  ]
}

Open bulk paywall →

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/pcdai",
  "items": [
    {
      "components": [
        {
          "value": 0,
          "factor": "abdominal_pain",
          "points": 0,
          "present": true
        },
        {
          "value": 0,
          "factor": "stools",
          "points": 0,
          "present": true
        },
        {
          "value": 0,
          "factor": "well_being",
          "points": 0,
          "present": true
        },
        {
          "value": 0,
          "factor": "hematocrit",
          "points": 0,
          "present": true
        },
        {
          "value": 0,
          "factor": "esr",
          "points": 0,
          "present": true
        },
        {
          "value": 0,
          "factor": "albumin",
          "points": 0,
          "present": true
        },
        {
          "value": 0,
          "factor": "weight",
          "points": 0,
          "present": true
        },
        {
          "value": 0,
          "factor": "height",
          "points": 0,
          "present": true
        },
        {
          "value": 0,
          "factor": "abdomen",
          "points": 0,
          "present": true
        },
        {
          "value": 0,
          "factor": "perirectal",
          "points": 0,
          "present": true
        },
        {
          "value": 0,
          "factor": "extra_intestinal",
          "points": 0,
          "present": true
        }
      ],
      "weight": 0,
      "height": 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": "Hyams JS, Ferry GD, Mandel FS, et al.",
        "doi": "10.1097/00005176-199105000-00001",
        "id": "hyams-1991",
        "pmid": "1678008",
        "source": "J Pediatr Gastroenterol Nutr. 1991;12(4):439-447",
        "title": "Development and validation of a pediatric Crohn's disease activity index"
      },
      "formula": "pcdai",
      "formula_expression": "PCDAI = abdominal_pain + stools + well_being + hematocrit + esr + albumin + weight + height + abdomen + perirectal + extra_intestinal; Hyams 1991 caller-assigned item points; hematocrit and esr 0, 2.5, or 5; remaining items 0, 5, or 10; max 100; no published activity bands",
      "max_score": 100,
      "score": 0,
      "abdominal_pain": 0,
      "well_being": 0,
      "abdomen": 0,
      "albumin": 0,
      "esr": 0,
      "extra_intestinal": 0,
      "hematocrit": 0,
      "perirectal": 0,
      "stools": 0
    },
    {
      "components": [
        {
          "value": 0,
          "factor": "abdominal_pain",
          "points": 0,
          "present": true
        },
        {
          "value": 0,
          "factor": "stools",
          "points": 0,
          "present": true
        },
        {
          "value": 0,
          "factor": "well_being",
          "points": 0,
          "present": true
        },
        {
          "value": 0,
          "factor": "hematocrit",
          "points": 0,
          "present": true
        },
        {
          "value": 0,
          "factor": "esr",
          "points": 0,
          "present": true
        },
        {
          "value": 0,
          "factor": "albumin",
          "points": 0,
          "present": true
        },
        {
          "value": 0,
          "factor": "weight",
          "points": 0,
          "present": true
        },
        {
          "value": 0,
          "factor": "height",
          "points": 0,
          "present": true
        },
        {
          "value": 0,
          "factor": "abdomen",
          "points": 0,
          "present": true
        },
        {
          "value": 0,
          "factor": "perirectal",
          "points": 0,
          "present": true
        },
        {
          "value": 0,
          "factor": "extra_intestinal",
          "points": 0,
          "present": true
        }
      ],
      "weight": 0,
      "height": 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": "Hyams JS, Ferry GD, Mandel FS, et al.",
        "doi": "10.1097/00005176-199105000-00001",
        "id": "hyams-1991",
        "pmid": "1678008",
        "source": "J Pediatr Gastroenterol Nutr. 1991;12(4):439-447",
        "title": "Development and validation of a pediatric Crohn's disease activity index"
      },
      "formula": "pcdai",
      "formula_expression": "PCDAI = abdominal_pain + stools + well_being + hematocrit + esr + albumin + weight + height + abdomen + perirectal + extra_intestinal; Hyams 1991 caller-assigned item points; hematocrit and esr 0, 2.5, or 5; remaining items 0, 5, or 10; max 100; no published activity bands",
      "max_score": 100,
      "score": 0,
      "abdominal_pain": 0,
      "well_being": 0,
      "abdomen": 0,
      "albumin": 0,
      "esr": 0,
      "extra_intestinal": 0,
      "hematocrit": 0,
      "perirectal": 0,
      "stools": 0
    }
  ]
}

Response

Field Type Description
formula string pcdai
formula_expression string Exact expression used
score number Hyams 1991 PCDAI points 0-100. Half-points (2.5) occur when hematocrit or esr is 2.5.
max_score integer Always 100
abdominal_pain integer Caller-assigned abdominal pain points 0, 5, or 10
stools integer Caller-assigned stools points 0, 5, or 10
well_being integer Caller-assigned well-being points 0, 5, or 10
hematocrit number Caller-assigned hematocrit points 0, 2.5, or 5
esr number Caller-assigned ESR points 0, 2.5, or 5
albumin integer Caller-assigned albumin points 0, 5, or 10
weight integer Caller-assigned weight points 0, 5, or 10
height integer Caller-assigned height points 0, 5, or 10
abdomen integer Caller-assigned abdomen points 0, 5, or 10
perirectal integer Caller-assigned perirectal points 0, 5, or 10
extra_intestinal integer Caller-assigned extra-intestinal points 0, 5, or 10
components array Per-item caller-assigned points
citation object Hyams et al. J Pediatr Gastroenterol Nutr 1991 citation
disclaimer string Not a medical device

Example JSON

Machine form of the same example. Frozen fixture. Not a live lookup.

{
  "components": [
    {
      "value": 0,
      "factor": "abdominal_pain",
      "points": 0,
      "present": true
    },
    {
      "value": 0,
      "factor": "stools",
      "points": 0,
      "present": true
    },
    {
      "value": 0,
      "factor": "well_being",
      "points": 0,
      "present": true
    },
    {
      "value": 0,
      "factor": "hematocrit",
      "points": 0,
      "present": true
    },
    {
      "value": 0,
      "factor": "esr",
      "points": 0,
      "present": true
    },
    {
      "value": 0,
      "factor": "albumin",
      "points": 0,
      "present": true
    },
    {
      "value": 0,
      "factor": "weight",
      "points": 0,
      "present": true
    },
    {
      "value": 0,
      "factor": "height",
      "points": 0,
      "present": true
    },
    {
      "value": 0,
      "factor": "abdomen",
      "points": 0,
      "present": true
    },
    {
      "value": 0,
      "factor": "perirectal",
      "points": 0,
      "present": true
    },
    {
      "value": 0,
      "factor": "extra_intestinal",
      "points": 0,
      "present": true
    }
  ],
  "weight": 0,
  "height": 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": "Hyams JS, Ferry GD, Mandel FS, et al.",
    "doi": "10.1097/00005176-199105000-00001",
    "id": "hyams-1991",
    "pmid": "1678008",
    "source": "J Pediatr Gastroenterol Nutr. 1991;12(4):439-447",
    "title": "Development and validation of a pediatric Crohn's disease activity index"
  },
  "formula": "pcdai",
  "formula_expression": "PCDAI = abdominal_pain + stools + well_being + hematocrit + esr + albumin + weight + height + abdomen + perirectal + extra_intestinal; Hyams 1991 caller-assigned item points; hematocrit and esr 0, 2.5, or 5; remaining items 0, 5, or 10; max 100; no published activity bands",
  "max_score": 100,
  "score": 0,
  "abdominal_pain": 0,
  "well_being": 0,
  "abdomen": 0,
  "albumin": 0,
  "esr": 0,
  "extra_intestinal": 0,
  "hematocrit": 0,
  "perirectal": 0,
  "stools": 0
}

Client errors (HTTP 400)

Invalid params return 400 without charge. Shared HTTP 402 and 503 meanings: Payments.

HTTP Code When
400 invalid_pcdai PCDAI items must be Hyams 1991 caller-assigned points: abdominal_pain, stools, well_being, albumin, weight, height, abdomen, perirectal, and extra_intestinal each 0, 5, or 10; hematocrit and esr each 0, 2.5, or 5. 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

  • CDAI — Compute the Best 1976 Crohn's disease activity index from eight caller-assigned variables and return the rounded integer score. Does not return later trial activity bands.
  • SES-CD — Sum four caller-assigned Daperno 2004 SES-CD integers (ulcers, ulcerated_surface, affected_surface, narrowings; each 0-3) in each of five ileocolonic segments (ileum, right_colon, transverse_colon, left_colon, rectum) and return the total (max 60). Does not return activity bands.
  • PUCAI — Sum six caller-assigned Turner 2007 PUCAI item points and return the published total (max 85) with activity band.
  • HBI — Sum Harvey 1980 simple-index items (previous-day well-being, abdominal pain, liquid stools, abdominal mass, and one point per listed complication) and return the total. Does not return later remission or activity bands.

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.