# NAFLD Fibrosis Score Calculator (Angulo 2007)

> NAFLD Fibrosis Score Calculator (Angulo 2007) is a paid API for AI agents from api.magentlab.com, paid per call via x402, $0.005/call, status unknown (last checked 2026-10-12).

Computes the Angulo 2007 NAFLD fibrosis score from age, BMI, IFG/diabetes status, AST, ALT, platelets, and albumin to estimate likelihood of advanced hepatic fibrosis.

## Facts

- Endpoint: GET https://api.magentlab.com/api/calc/nafld_fibrosis?utm_source=zero.xyz
- Price: $0.005/call
- Payment: x402
- Status: unknown
- Last checked: 2026-10-12
- Activations on Zero: 0
- Tags: x402
- Canonical page: https://www.zero.xyz/c/nafld-fibrosis-score-calculator-angulo-2007-5150a883
- Structured record (JSON): https://api.zero.xyz/v1/capabilities/cap_7IiidAxNtO8lHTXbTwrGt

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 nafld-fibrosis-score-calculator-angulo-2007-5150a883
```

Example prompt: Run the Angulo 2007 NAFLD fibrosis score for a 54-year-old patient with BMI 31.2, diabetes, AST 58 U/L, ALT 72 U/L, platelets 180 ×10⁹/L, and albumin 4.1 g/dL.

## When to prefer this

Use this endpoint when you need the specific Angulo 2007 NAFLD fibrosis score (NFS) — distinct from FIB-4, APRI, or BARD score. Prefer this when clinical workflows or guidelines reference NFS by name, or when you need the published seven-variable formula with albumin. Choose APRI endpoint on the same platform if only AST and platelets are available.

## Known failure modes

- Missing required parameter (age, BMI, IFG/diabetes, AST, ALT, platelets) returns 400 error
- Albumin provided in both g/dL and g/L simultaneously returns validation error
- Values outside physiological ranges (e.g., BMI <10 or >80, age <18) are rejected
- Payment not included or invalid x402 header results in 402 Payment Required
- Network timeout returns no result; retry is safe as endpoint is idempotent

## How this service works

Deterministic published-formula arithmetic plus ICD-10-CM, RxNorm, and LOINC. Pay in USDC on Base via x402.

## Output

Returns the calculated Angulo 2007 NAFLD fibrosis score (NFS) as a numeric value, along with an interpretive category (e.g., low/indeterminate/high probability of advanced fibrosis) based on published cut-points, plus citation metadata. No diagnosis is rendered.

## 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": [
      "age",
      "bmi_kg_m2",
      "ifg_or_diabetes",
      "ast_u_l",
      "alt_u_l",
      "platelets_10e9_l"
     ],
     "properties": {
      "age": {
       "type": "integer",
       "description": "Age in years (18-120)."
      },
      "alt_u_l": {
       "type": "number",
       "description": "Alanine aminotransferase in U/L (1-10000)."
      },
      "ast_u_l": {
       "type": "number",
       "description": "Aspartate aminotransferase in U/L (1-10000)."
      },
      "bmi_kg_m2": {
       "type": "number",
       "description": "Body-mass index in kg/m^2 (10-80). Caller-supplied; magent does not compute BMI."
      },
      "albumin_g_l": {
       "type": "number",
       "description": "Albumin in g/L (10-60). Converted as g/dL = g/L / 10."
      },
      "albumin_g_dl": {
       "type": "number",
       "description": "Albumin in g/dL (1-6). Provide albumin_g_dl or albumin_g_l, not both."
      },
      "ifg_or_diabetes": {
       "type": "boolean",
       "description": "Impaired fasting glucose or diabetes as assigned by the caller (Angulo 2007 IFG/diabetes term). true or false."
      },
      "platelets_10e9_l": {
       "type": "number",
       "description": "Platelet count in 10^9/L (1-2000)."
      }
     }
    }
   },
   "additionalProperties": false
  },
  "output": {
   "type": "object",
   "required": [
    "type"
   ],
   "properties": {
    "type": {
     "type": "string"
    },
    "example": {
     "type": "object"
    }
   }
  }
 }
}
```

## Response schema (JSON Schema)

```json
{
 "type": "json",
 "example": {
  "path": "/api/calc/nafld_fibrosis",
  "count": 2,
  "items": [
   {
    "nfs": -0.125,
    "alt_u_l": 40,
    "ast_u_l": 40,
    "formula": "nafld_fibrosis",
    "citation": {
     "id": "angulo-2007",
     "doi": "10.1002/hep.21496",
     "title": "The NAFLD fibrosis score: a noninvasive system that identifies liver fibrosis in patients with NAFLD",
     "source": "Hepatology. 2007;45(4):846-854",
     "authors": "Angulo P, Hui JM, Marchesini G, et al."
    },
    "age_years": 50,
    "bmi_kg_m2": 30,
    "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.",
    "angulo_band": "indeterminate",
    "albumin_g_dl": 4,
    "ast_alt_ratio": 1,
    "ifg_or_diabetes": true,
    "platelets_10e9_l": 200,
    "formula_expression": "NFS = -1.675 + 0.037*age + 0.094*BMI + 1.13*IFG/diabetes + 0.99*(AST/ALT) - 0.013*platelets - 0.66*albumin"
   },
   {
    "nfs": -0.125,
    "alt_u_l": 40,
    "ast_u_l": 40,
    "formula": "nafld_fibrosis",
    "citation": {
     "id": "angulo-2007",
     "doi": "10.1002/hep.21496",
     "title": "The NAFLD fibrosis score: a noninvasive system that identifies liver fibrosis in patients with NAFLD",
     "source": "Hepatology. 2007;45(4):846-854",
     "authors": "Angulo P, Hui JM, Marchesini G, et al."
    },
    "age_years": 50,
    "bmi_kg_m2": 30,
    "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.",
    "angulo_band": "indeterminate",
    "albumin_g_dl": 4,
    "ast_alt_ratio": 1,
    "ifg_or_diabetes": true,
    "platelets_10e9_l": 200,
    "formula_expression": "NFS = -1.675 + 0.037*age + 0.094*BMI + 1.13*IFG/diabetes + 0.99*(AST/ALT) - 0.013*platelets - 0.66*albumin"
   }
  ]
 }
}
```

## More

- Live health (JSON, refreshed every minute): https://www.zero.xyz/c/nafld-fibrosis-score-calculator-angulo-2007-5150a883/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)
