# magent BARS Score Lookup

> magent BARS Score Lookup 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).

Returns the Swift 2002 Behavioural Activity Rating Scale (BARS) label and max score for a caller-assigned integer 1–7 describing patient sedation/agitation level.

## Facts

- Endpoint: GET https://api.magentlab.com/api/calc/bars
- 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-bars-score-lookup-72c35f32
- Structured record (JSON): https://api.zero.xyz/v1/capabilities/cap_IYulOLIRaeoZ5il5ddVl0

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-bars-score-lookup-72c35f32
```

Example prompt: The patient is extremely and continuously active but doesn't require restraint — can you look up the BARS score and label for that level using the Swift 2002 scale? That should be a 6.

## When to prefer this

Use this endpoint when you need a standardized, stable label for a caller-assigned Swift 2002 BARS integer within an automated or agentic clinical documentation workflow. Prefer it over RASS-based endpoints when the assessment protocol specifically calls for the Behavioural Activity Rating Scale. Not a substitute for direct clinical observation or diagnosis.

## Known failure modes

- Input integer outside 1–7 range returns an error or unexpected result
- Non-integer input (e.g. decimal or string) may fail schema validation
- Missing required 'bars' query parameter results in a request error
- Payment failure (x402 protocol) prevents response

## How this service works

Swift 2002 Behavioural Activity Rating Scale (BARS): caller-assigned integer 1-7 (difficult or unable to rouse; asleep but responds normally to verbal or physical contact; drowsy, appears sedated; quiet and awake, normal activity; signs of overt physical or verbal activity, calms with instructions; extremely or continuously active, not requiring restraint; violent, requires restraint). Returns score, max 7, and a stable label. Not RASS and not a diagnosis. magent does not observe the patient.

## Output

Returns the BARS integer score as provided, the maximum possible BARS score (7), and a stable clinical label corresponding to the input integer (e.g. 'quiet and awake, normal level of activity' for a score of 4). No diagnosis is generated; magent does not observe the patient.

## 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": [
      "bars"
     ],
     "properties": {
      "bars": {
       "type": "integer",
       "description": "Swift 2002 Behavioural Activity Rating Scale integer 1, 2, 3, 4, 5, 6, or 7 as assigned by the caller (1 difficult or unable to rouse; 2 asleep but responds normally to verbal or physical contact; 3 drowsy, appears sedated; 4 quiet and awake, normal level of activity; 5 signs of overt physical or verbal activity, calms with instructions; 6 extremely or continuously active, not requiring restraint; 7 violent, requires restraint). magent does not observe the patient."
      }
     }
    }
   },
   "additionalProperties": false
  },
  "output": {
   "type": "object",
   "required": [
    "type"
   ],
   "properties": {
    "type": {
     "type": "string"
    },
    "example": {
     "type": "object"
    }
   }
  }
 }
}
```

## More

- Live health (JSON, refreshed every minute): https://www.zero.xyz/c/magent-bars-score-lookup-72c35f32/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)
