# magent ESUS Classifier

> magent ESUS Classifier 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-13).

Determines whether a stroke meets Hart 2014 Embolic Stroke of Undetermined Source (ESUS) criteria based on five caller-assigned boolean flags.

## Facts

- Endpoint: GET https://api.magentlab.com/api/calc/esus
- Price: $0.005/call
- Payment: x402
- Status: unknown
- Last checked: 2026-09-13
- Activations on Zero: 0
- Tags: x402
- Canonical page: https://www.zero.xyz/c/magent-esus-classifier-f6b0918b
- Structured record (JSON): https://api.zero.xyz/v1/capabilities/cap_MdCpcA6TzVvoCDeVxEkur

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-esus-classifier-f6b0918b
```

Example prompt: Check whether this patient's stroke meets ESUS criteria: the CT shows a non-lacunar infarct (true), there's no ≥50% stenosis supplying the ischemia (true), no major cardioembolic source was found (true), no other specific cause identified (true), and the full Hart 2014 Panel 3 workup is complete including brain MRI, ECG, precordial echo, ≥24-hour automated cardiac monitoring, and both extracranial and intracranial arterial imaging (true).

## When to prefer this

Use this endpoint when you need a fast, deterministic Hart 2014 ESUS criterion check against five explicitly caller-assigned boolean flags. It is the right choice when all clinical assessments (imaging interpretation, cardioembolic source evaluation, workup completeness) have already been performed by a clinician and you need a reliable algorithmic gate. Do not use it to replace clinical imaging interpretation, to diagnose alternative stroke etiologies, or as a substitute for TOAST cryptogenic stroke classification.

## Known failure modes

- Incomplete workup (minimum_workup=false) returns esus=false rather than an error — caller must ensure all five Panel 3 components are genuinely completed
- Missing required query parameters returns HTTP 400
- Caller-assigned flags that do not accurately reflect imaging/clinical findings will produce incorrect classification — magent does not independently read imaging or diagnose
- Telemetry-only cardiac monitoring passed as minimum_workup=true would be an incorrect caller assignment per Hart 2014

## How this service works

ESUS (Hart 2014). True iff all five caller-assigned flags hold: non-lacunar infarct on CT/MRI; no ≥50% stenosis supplying the ischaemia; no major-risk cardioembolic source; no other specific cause; and Panel 3 minimum workup (brain CT/MRI, 12-lead ECG, precordial echo, ≥24 h automated rhythm monitoring (not telemetry), extra- and intracranial arterial imaging). Incomplete workup is not ESUS. Not a stroke diagnosis, not TOAST cryptogenic, not anticoagulation. magent does not read imaging.

## Output

Returns a boolean ESUS field: true if all five Hart 2014 criteria are met (non-lacunar infarct, no ≥50% supplying stenosis, no major-risk cardioembolic source, no other specific cause, complete Panel 3 workup); false if any criterion is false or workup is incomplete. Does not return HTTP 400 for incomplete workup — returns esus false instead.

## 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": [
      "non_lacunar_infarct",
      "no_stenosis_ge_50",
      "no_major_risk_cardioembolic",
      "no_other_specific_cause",
      "minimum_workup"
     ],
     "properties": {
      "minimum_workup": {
       "type": "boolean",
       "description": "Hart 2014 Panel 3 minimum diagnostic assessment, as assigned by the caller. true only if brain CT or MRI, 12-lead ECG, precordial echocardiography, cardiac monitoring for ≥24 h with automated rhythm detection (telemetry is not sufficient), and imaging of both extracranial and intracranial arteries supplying the ischaemic territory have been done. Incomplete workup returns esus false (not HTTP 400). true or false. magent does not read imaging."
      },
      "no_stenosis_ge_50": {
       "type": "boolean",
       "description": "Absence of extracranial or intracranial atherosclerosis causing ≥50% luminal stenosis in arteries supplying the area of ischaemia, as assigned by the caller (Hart 2014 Panel 2). true means no such stenosis. true or false. magent does not read vascular imaging."
      },
      "non_lacunar_infarct": {
       "type": "boolean",
       "description": "Stroke detected by CT or MRI that is not lacunar, as assigned by the caller (Hart 2014 Panel 2). Lacunar = subcortical infarct ≤1.5 cm (≤2.0 cm on MRI diffusion images) in largest dimension, in the distribution of the small penetrating cerebral arteries. true or false. magent does not read imaging."
      },
      "no_other_specific_cause": {
       "type": "boolean",
       "description": "No other specific cause identified, as assigned by the caller (Hart 2014 Panel 2). Paper examples: arteritis, dissection, migraine/vasospasm, drug misuse. true or false. magent does not diagnose an alternative aetiology."
      },
      "no_major_risk_cardioembolic": {
       "type": "boolean",
       "description": "No major-risk cardioembolic source, as assigned by the caller (Hart 2014 P
… (truncated)
```

## More

- Live health (JSON, refreshed every minute): https://www.zero.xyz/c/magent-esus-classifier-f6b0918b/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)
