# magent ASCO 2018 Immune-Related Hepatitis (irAE) Grader

> magent ASCO 2018 Immune-Related Hepatitis (irAE) Grader is a paid API for AI agents from api.magentlab.com, paid per call via x402, $0.005/call, status unknown (last checked 2026-09-14).

Grades immune-related hepatitis severity per ASCO 2018 Brahmer guidelines from AST, ALT, and total bilirubin values, and returns the ICI management action (continue, hold, or permanently discontinue).

## Facts

- Endpoint: GET https://api.magentlab.com/api/calc/irae_hepatitis
- Price: $0.005/call
- Payment: x402
- Status: unknown
- Last checked: 2026-09-14
- Activations on Zero: 0
- Tags: x402
- Canonical page: https://www.zero.xyz/c/magent-asco-2018-immune-related-hepatitis-irae-grader-f1af75c5
- Structured record (JSON): https://api.zero.xyz/v1/capabilities/cap_LMnQDmlSq-kHqjH6cF__j

Status and success rate cover calls made through Zero and Zero's own probes. Third-party monitors may report differently.

## How to call it through Zero

Zero handles the 402 payment challenge and records the run. With the Zero CLI installed (`npm i -g @zeroxyz/cli`):

```sh
zero fetch --capability magent-asco-2018-immune-related-hepatitis-irae-grader-f1af75c5
```

Example prompt: Grade my patient's immune-related hepatitis using ASCO 2018 Brahmer criteria: AST is 180 U/L with a lab ULN of 40, ALT is 210 U/L with a lab ULN of 40, total bilirubin is 1.8 mg/dL with a ULN of 1.2 mg/dL — the patient has no decompensated liver disease and no symptomatic liver dysfunction.

## When to prefer this

Use this endpoint when you need a guideline-specific ASCO 2018 Brahmer irAE hepatitis grade computed from actual lab fold-over-ULN values — not a generic CTCAE liver toxicity grade, not DILI/RUCAM, and not an R-factor calculation. Prefer this over manual lookup when building oncology clinical decision support agents that must recommend ICI continuation, hold, or permanent discontinuation based on hepatotoxicity severity. It correctly handles lab-specific ULNs (does not assume 40 U/L or 1.0 mg/dL), applies clinical upgrades for decompensation and symptomatic dysfunction, and returns a machine-readable action string.

## Known failure modes

- Missing required query parameters (ast_u_l, ast_uln_u_l, alt_u_l, alt_uln_u_l, bilirubin_mg_dl, bilirubin_uln_mg_dl, decompensated_liver, symptomatic_liver_dysfunction) return a validation error
- Bilirubin supplied in µmol/L instead of mg/dL will produce incorrect grading — only mg/dL is accepted
- AST or ALT values outside the 1–10000 U/L range rejected as out-of-bounds
- ULN values outside the 5–200 U/L (transaminases) or 0.1–5 mg/dL (bilirubin) range rejected
- Payment failure (x402) if USDC payment is not properly attached
- Boolean fields (decompensated_liver, symptomatic_liver_dysfunction) sent as strings may cause schema rejection

## How this service works

ASCO 2018 (Brahmer) immune-related hepatitis grade from caller AST, ALT, and total bilirubin as folds of laboratory ULN (mg/dL only). Lab grade is the max of transaminase and bilirubin Table 2.2 bands; decompensated liver upgrades to grade 4; symptomatic compensated liver dysfunction upgrades to grade 3. ICI action: continue (0-1), hold (2), or permanently discontinue (3-4). Not a medical device, not a diagnosis, not DILI/RUCAM, not R factor, not a steroid dose; magent does not assay enzymes.

## Output

Returns the computed irAE hepatitis grade (0–4) per ASCO 2018 Brahmer Table 2.2, including the underlying lab grade derived from max transaminase and bilirubin fold-over-ULN, any clinical upgrades applied (decompensated → grade 4; symptomatic → grade 3), and the recommended ICI management action: continue (grade 0–1), hold (grade 2), or permanently discontinue (grade 3–4).

## Request schema (JSON Schema)

```json
{
 "type": "object",
 "$schema": "https://json-schema.org/draft/2020-12/schema",
 "required": [
  "input"
 ],
 "properties": {
  "input": {
   "type": "object",
   "required": [
    "type",
    "method"
   ],
   "properties": {
    "type": {
     "type": "string",
     "const": "http"
    },
    "method": {
     "enum": [
      "GET",
      "HEAD",
      "DELETE"
     ],
     "type": "string"
    },
    "headers": {
     "type": "object",
     "additionalProperties": {
      "type": "string"
     }
    },
    "queryParams": {
     "type": "object",
     "required": [
      "ast_u_l",
      "ast_uln_u_l",
      "alt_u_l",
      "alt_uln_u_l",
      "bilirubin_mg_dl",
      "bilirubin_uln_mg_dl",
      "decompensated_liver",
      "symptomatic_liver_dysfunction"
     ],
     "properties": {
      "alt_u_l": {
       "type": "number",
       "description": "Alanine aminotransferase in U/L (1-10000). Used with alt_uln_u_l for the ALT fold. magent does not assay enzymes."
      },
      "ast_u_l": {
       "type": "number",
       "description": "Aspartate aminotransferase in U/L (1-10000). Used with ast_uln_u_l for the AST fold. magent does not assay enzymes."
      },
      "alt_uln_u_l": {
       "type": "number",
       "description": "Laboratory ALT upper limit of normal in U/L (5-200). Required; magent does not assume 40."
      },
      "ast_uln_u_l": {
       "type": "number",
       "description": "Laboratory AST upper limit of normal in U/L (5-200). Required; magent does not assume 40."
      },
      "bilirubin_mg_dl": {
       "type": "number",
       "description": "Total bilirubin in mg/dL (0.1-40). µmol/L is not accepted. magent does not assay bilirubin."
      },
      "bilirubin_uln_mg_dl": {
       "type": "number",
       "description": "Laboratory total-bilirubin upper limit of normal in mg/dL (0.1-5). Required; magent does not assume 1.0."
      },
      "decompensated_liver": {
       "type": "boolean",
       "description": "Decompensated liver (ascites, encephalopathy, coagulopathy, or coma) as assigned by the caller (Brahmer 2018). true or false. When true, grade is max(lab_grade, 4). magent does not examine the patient."
      },
      "symptomatic_liver_dysfunction": {
       "type": "boolean",
       "description": "Symptomatic compensated hepatitis / liver dysfunction as assigned by the caller (Brahmer 2018). true or false. When true and decompensated_liver is false, grade is max(lab_grade, 3). magent does not examine the patient."

… (truncated)
```

## More

- Live health (JSON, refreshed every minute): https://www.zero.xyz/c/magent-asco-2018-immune-related-hepatitis-irae-grader-f1af75c5/health.json
- [Zero catalog index](https://www.zero.xyz/llms.txt)
- [Other services from api.magentlab.com](https://www.zero.xyz/host/api.magentlab.com/llms.txt)
