# PEDOCS Two-Variable Overcrowding Score (Weiss 2007)

> PEDOCS Two-Variable Overcrowding Score (Weiss 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-09-15).

Calculates the Weiss 2007 PEDOCS two-variable pediatric ED overcrowding score from waiting-room patient count and total registered patient count, returning a 0–200 scale score to one decimal place.

## Facts

- Endpoint: GET https://api.magentlab.com/api/calc/pedocs
- Price: $0.005/call
- Payment: x402
- Status: unknown
- Last checked: 2026-09-15
- Activations on Zero: 0
- Tags: x402
- Canonical page: https://www.zero.xyz/c/pedocs-two-variable-overcrowding-score-weiss-2007-5c02e6bf
- Structured record (JSON): https://api.zero.xyz/v1/capabilities/cap_J2QuUu9uQt3GmN8ZSNjDc

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 pedocs-two-variable-overcrowding-score-weiss-2007-5c02e6bf
```

Example prompt: Calculate the PEDOCS two-variable overcrowding score for our pediatric ED right now — we have 18 patients in the waiting room and 52 total registered patients.

## When to prefer this

Use this endpoint when you need the exact continuous Weiss 2007 PEDOCS two-variable score (0–200, one decimal, no clamping) from caller-supplied waiting-room and total registered patient counts. Prefer it over manual formula application or spreadsheet tools when building automated ED dashboards, crowding-trend logs, or handoff reports in a clinical operations pipeline. Not appropriate as a medical device, diversion order, or ambulance-bypass trigger.

## Known failure modes

- waiting_room_patients exceeds total_registered_patients — violates constraint, likely returns validation error
- non-integer or negative values for either count — schema violation
- waiting_room_patients > 200 or total_registered_patients > 400 — outside documented range, may return error or unexpected result
- missing required query parameters — HTTP 400 or similar bad request response
- network or payment failure — endpoint returns 402 if x402 payment not provided

## How this service works

Weiss 2007 Pediatric Emergency Department Overcrowding Scale (PEDOCS) two-variable model: waiting-room patients and total registered patients. Returns the 1-decimal score on the paper's 0-200 scale without clamping or 20/60/100 named class bands. Caller supplies counts; magent does not count patients. Not a medical device and not a diversion or ambulance-bypass order.

## Output

A single numeric PEDOCS score on the Weiss 2007 0–200 scale, expressed to one decimal place. The score reflects the two-variable model combining waiting-room patients and total registered patients. No named class bands (e.g. 20/60/100 thresholds) are applied; the raw continuous score is returned.

## 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": [
      "waiting_room_patients",
      "total_registered_patients"
     ],
     "properties": {
      "waiting_room_patients": {
       "type": "integer",
       "description": "Patients in the waiting room (integer 0-200). Cannot exceed total_registered_patients. Weiss 2007 two-variable model. magent does not count waiting-room patients."
      },
      "total_registered_patients": {
       "type": "integer",
       "description": "Total patients currently registered in the pediatric ED, including those in the waiting room (integer 0-400). Must be at least waiting_room_patients. Weiss 2007 two-variable model. magent does not count patients."
      }
     }
    }
   },
   "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/pedocs-two-variable-overcrowding-score-weiss-2007-5c02e6bf/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)
