# Canadian CT Head Rule

Canadian CT Head Rule

Status: LIVE
Price: $0.005 USDC
`GET /api/calc/canadian_ct_head`
HTML: https://magentlab.com/docs/canadian-ct-head
Markdown: https://magentlab.com/docs/canadian-ct-head.md

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

## What it computes

Apply the Stiell 2001 Canadian CT Head Rule and return whether CT is indicated from caller-assigned high-risk and medium-risk findings after minor blunt head injury.

## When to use

When an agent has caller-assigned findings after blunt head trauma in a patient 16 or older with GCS 13-15 as published and needs the Canadian CT Head Rule, not PECARN, CATCH, or NEXUS.

## When not to use

- Not a diagnosis of brain injury. magent does not examine the patient.
- This tool is the Stiell 2001 Canadian CT Head Rule only. It is not NEXUS, not PECARN, not CATCH, and not a pediatric head-CT rule (published for age ≥16).
- Inclusion as published is blunt trauma with GCS 13-15. magent does not take a GCS integer; the caller assigns the high-risk and medium-risk findings.
- Dangerous mechanism is caller-assigned. Published list: pedestrian struck by a motor vehicle, occupant ejected from a motor vehicle, fall from elevation >3 feet or 5 stairs. magent does not classify mechanism.
- High-risk factors predict need for neurological intervention. Medium-risk factors detect clinically important brain injury. CT is indicated if either band is met.

## Formula

```
ct indicated if any high-risk (gcs_lt_15_at_2h or suspected_open_or_depressed_skull_fx or any_sign_basal_skull_fx or vomiting_two_or_more or age >= 65) or any medium-risk (amnesia_before_impact_gt_30min or dangerous_mechanism)
```

## Citation

[The Canadian CT Head Rule for patients with minor head injury](https://doi.org/10.1016/S0140-6736(00)04561-X)
Stiell IG, Wells GA, Vandemheen K, et al.
Lancet. 2001;357(9266):1391-1396
DOI: [10.1016/S0140-6736(00)04561-X](https://doi.org/10.1016/S0140-6736(00)04561-X)

## Worked example

### All findings absent

Given: `age=40, amnesia_before_impact_gt_30min=false, any_sign_basal_skull_fx=false, dangerous_mechanism=false, gcs_lt_15_at_2h=false, suspected_open_or_depressed_skull_fx=false, vomiting_two_or_more=false`

1. Age 40 is not a high-risk factor; no high-risk or medium-risk flags
2. CT is not indicated


### Age 65 is high-risk

Given: `age=65, amnesia_before_impact_gt_30min=false, any_sign_basal_skull_fx=false, dangerous_mechanism=false, gcs_lt_15_at_2h=false, suspected_open_or_depressed_skull_fx=false, vomiting_two_or_more=false`

1. Age ≥65 is a high-risk factor
2. CT is indicated


### Dangerous mechanism is medium-risk

Given: `age=40, amnesia_before_impact_gt_30min=false, any_sign_basal_skull_fx=false, dangerous_mechanism=true, gcs_lt_15_at_2h=false, suspected_open_or_depressed_skull_fx=false, vomiting_two_or_more=false`

1. No high-risk factor
2. Dangerous mechanism is a medium-risk factor (caller-assigned from the paper list)
3. CT is indicated for clinically important brain injury


## Also searched as

- Canadian CT Head Rule
- Canadian CT Head Injury Rule
- CCHR
- Stiell CT head
- Stiell 2001 head CT
- Canadian Head CT Rule
- minor head injury CT rule
- CIBI CT rule

## Parameters

- `age` (integer, required): Age in years (16-120). Age ≥65 is a high-risk factor that indicates CT; 64 does not. The published rule is for patients ≥16 years.
- `gcs_lt_15_at_2h` (boolean, required): GCS <15 at 2 hours after injury. true or false as assigned by the caller. High-risk. magent does not take a GCS integer.
- `suspected_open_or_depressed_skull_fx` (boolean, required): Suspected open or depressed skull fracture. true or false as assigned by the caller. High-risk.
- `any_sign_basal_skull_fx` (boolean, required): Any sign of basal skull fracture (hemotympanum, raccoon eyes, CSF otorrhea/rhinorrhea, or Battle's sign). true or false as assigned by the caller. High-risk.
- `vomiting_two_or_more` (boolean, required): Two or more episodes of vomiting. true or false as assigned by the caller. High-risk.
- `amnesia_before_impact_gt_30min` (boolean, required): Amnesia before impact of more than 30 minutes. true or false as assigned by the caller. Medium-risk.
- `dangerous_mechanism` (boolean, required): Dangerous mechanism as assigned by the caller. true or false. Medium-risk. Published list: pedestrian struck by a motor vehicle, occupant ejected from a motor vehicle, fall from elevation >3 feet or 5 stairs. magent does not classify mechanism.

## Bulk (POST)

POST the same path with a JSON items array. Price is n times the GET unit. Invalid items return HTTP 400 before settlement.

Method: `POST /api/calc/canadian_ct_head`
Max items: 25
Price: unit_amount * n (unit 5000 atomic)
Status: PREVIEW

- 1 to 25 items. Each item uses the same keys as the GET query parameters.
- 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:

```json
{
  "items": [
    {
      "age": "40",
      "amnesia_before_impact_gt_30min": "false",
      "any_sign_basal_skull_fx": "false",
      "dangerous_mechanism": "false",
      "gcs_lt_15_at_2h": "false",
      "suspected_open_or_depressed_skull_fx": "false",
      "vomiting_two_or_more": "false"
    },
    {
      "age": "40",
      "amnesia_before_impact_gt_30min": "false",
      "any_sign_basal_skull_fx": "false",
      "dangerous_mechanism": "false",
      "gcs_lt_15_at_2h": "false",
      "suspected_open_or_depressed_skull_fx": "false",
      "vomiting_two_or_more": "false"
    }
  ]
}
```

Human paywall (two-item fixture): https://api.magentlab.com/paywall/bulk/canadian-ct-head

Example 200:

```json
{
  "count": 2,
  "path": "/api/calc/canadian_ct_head",
  "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": "Stiell IG, Wells GA, Vandemheen K, et al.",
        "doi": "10.1016/S0140-6736(00)04561-X",
        "id": "stiell-2001-ct-head",
        "source": "Lancet. 2001;357(9266):1391-1396",
        "title": "The Canadian CT Head Rule for patients with minor head injury"
      },
      "formula": "canadian_ct_head",
      "formula_expression": "ct indicated if any high-risk (gcs_lt_15_at_2h or suspected_open_or_depressed_skull_fx or any_sign_basal_skull_fx or vomiting_two_or_more or age >= 65) or any medium-risk (amnesia_before_impact_gt_30min or dangerous_mechanism)",
      "age_years": 40,
      "criteria": [
        {
          "factor": "gcs_lt_15_at_2h",
          "met": false
        },
        {
          "factor": "suspected_open_or_depressed_skull_fx",
          "met": false
        },
        {
          "factor": "any_sign_basal_skull_fx",
          "met": false
        },
        {
          "factor": "vomiting_two_or_more",
          "met": false
        },
        {
          "value": 40,
          "factor": "age_ge_65",
          "met": false
        },
        {
          "factor": "amnesia_before_impact_gt_30min",
          "met": false
        },
        {
          "factor": "dangerous_mechanism",
          "met": false
        }
      ],
      "ct_indicated": false,
      "high_risk": false,
      "medium_risk": 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": "Stiell IG, Wells GA, Vandemheen K, et al.",
        "doi": "10.1016/S0140-6736(00)04561-X",
        "id": "stiell-2001-ct-head",
        "source": "Lancet. 2001;357(9266):1391-1396",
        "title": "The Canadian CT Head Rule for patients with minor head injury"
      },
      "formula": "canadian_ct_head",
      "formula_expression": "ct indicated if any high-risk (gcs_lt_15_at_2h or suspected_open_or_depressed_skull_fx or any_sign_basal_skull_fx or vomiting_two_or_more or age >= 65) or any medium-risk (amnesia_before_impact_gt_30min or dangerous_mechanism)",
      "age_years": 40,
      "criteria": [
        {
          "factor": "gcs_lt_15_at_2h",
          "met": false
        },
        {
          "factor": "suspected_open_or_depressed_skull_fx",
          "met": false
        },
        {
          "factor": "any_sign_basal_skull_fx",
          "met": false
        },
        {
          "factor": "vomiting_two_or_more",
          "met": false
        },
        {
          "value": 40,
          "factor": "age_ge_65",
          "met": false
        },
        {
          "factor": "amnesia_before_impact_gt_30min",
          "met": false
        },
        {
          "factor": "dangerous_mechanism",
          "met": false
        }
      ],
      "ct_indicated": false,
      "high_risk": false,
      "medium_risk": false
    }
  ]
}
```

## Response fields

- `formula` (string): canadian_ct_head
- `formula_expression` (string): Stiell 2001 high-risk or medium-risk CT indication rule
- `ct_indicated` (boolean): true when any high-risk or medium-risk factor is met (published imaging rule for clinically important brain injury). Not a diagnosis.
- `high_risk` (boolean): true when any high-risk factor is met (GCS <15 at 2 h, suspected open or depressed skull fracture, any basal skull fracture sign, vomiting ≥2, or age ≥65). Predicts need for neurological intervention.
- `medium_risk` (boolean): true when any medium-risk factor is met (amnesia before impact >30 min or dangerous mechanism), independent of high_risk
- `age_years` (integer): Age used for the ≥65 high-risk factor
- `criteria` (array): Per-factor rows with factor and met; age_ge_65 is computed from age (value is age_years)
- `citation` (object): Stiell 2001 Lancet citation
- `disclaimer` (string): Not-a-device notice

## Example JSON

Frozen fixture. Not a live lookup.

```json
{
  "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": "Stiell IG, Wells GA, Vandemheen K, et al.",
    "doi": "10.1016/S0140-6736(00)04561-X",
    "id": "stiell-2001-ct-head",
    "source": "Lancet. 2001;357(9266):1391-1396",
    "title": "The Canadian CT Head Rule for patients with minor head injury"
  },
  "formula": "canadian_ct_head",
  "formula_expression": "ct indicated if any high-risk (gcs_lt_15_at_2h or suspected_open_or_depressed_skull_fx or any_sign_basal_skull_fx or vomiting_two_or_more or age >= 65) or any medium-risk (amnesia_before_impact_gt_30min or dangerous_mechanism)",
  "age_years": 40,
  "criteria": [
    {
      "factor": "gcs_lt_15_at_2h",
      "met": false
    },
    {
      "factor": "suspected_open_or_depressed_skull_fx",
      "met": false
    },
    {
      "factor": "any_sign_basal_skull_fx",
      "met": false
    },
    {
      "factor": "vomiting_two_or_more",
      "met": false
    },
    {
      "value": 40,
      "factor": "age_ge_65",
      "met": false
    },
    {
      "factor": "amnesia_before_impact_gt_30min",
      "met": false
    },
    {
      "factor": "dangerous_mechanism",
      "met": false
    }
  ],
  "ct_indicated": false,
  "high_risk": false,
  "medium_risk": false
}
```

## Errors

- HTTP 400 `invalid_canadian_ct_age`: age must be an integer from 16 to 120. Returned before settlement; you are not charged.
- HTTP 400 `invalid_flag`: boolean clinical flags must be true or false Returned before settlement; you are not charged.
- HTTP 400 `invalid_items`: POST body must be a JSON object with only an items array Returned before settlement; you are not charged.
- HTTP 400 `invalid_item_count`: items must be an array of 1 to 25 objects Returned before settlement; you are not charged.
- HTTP 400 `invalid_item`: each items entry must be a JSON object Returned before settlement; you are not charged.

Shared HTTP 402 and 503: https://magentlab.com/docs/payments

## Related tools

- [NEXUS C-spine](https://magentlab.com/docs/nexus) — Apply the Hoffman 2000 NEXUS C-spine rule and return whether the five low-risk criteria all hold (imaging not indicated by this rule).
- [Glasgow Coma Scale](https://magentlab.com/docs/gcs) — Compute the Glasgow Coma Scale as the sum of caller-assigned eye, verbal, and motor integers. The 1974 or 1976 edition is required.

## Payment

Required query parameters must be present and valid. 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.

- GET the tool with Accept: application/json (do not send Accept: text/html unless you want the human paywall).
- HTTP 402 means you have not paid. Decode the base64 PAYMENT-REQUIRED header. HTTP 503 is not a new quote.
- Sign EIP-3009 (scheme exact, assetTransferMethod eip3009) with validBefore = now + accepts[0].maxTimeoutSeconds (600 seconds). That window starts when you sign and must cover wallet confirmation plus CDP verify and settle. Magent retries transient facilitator 429/5xx before answering. Do not send upto or batch-settlement payloads; magent does not offer those schemes.
- Retry the same URL with PAYMENT-SIGNATURE (base64 JSON echoing accepted, payload, and extensions when present).
- Success is HTTP 200 JSON plus PAYMENT-RESPONSE. Settlement happens before the tool runs. HTTP 503 settlement_uncertain or settle_failed: retry the same PAYMENT-SIGNATURE. Mint a new nonce only after a new HTTP 402.

- offered `exact` on eip155:8453: Fixed-price USDC on Base. The buyer authorizes the advertised amount (EIP-3009). magent settles before the tool runs (paymentFlow upfront). extra.assetTransferMethod=eip3009 extra.paymentFlow=upfront.

- not offered `upto`: Not offered. Usage-based: buyer authorizes a ceiling, seller settles the actual amount after work. Reserved for a future metered tool. Not for current calculators or code search.
- not offered `batch-settlement`: Not offered. Payment-channel vouchers claimed later in batches. Not the same as POST {items} bulk (that is still exact).

Same-path POST {items} is still scheme exact: one EIP-3009 authorization for n times the GET unit. That is not x402 batch-settlement (payment channels / vouchers).

Shared HTTP 402 and 503 table: https://magentlab.com/docs/payments

Stdio MCP (one process per host): https://magentlab.com/docs/mcp

## Guarantees

- Invalid query parameters return HTTP 400 before settlement. You are not charged.
- Settlement finishes before the tool executes (paymentFlow upfront). 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.
