List alerts, or the episodes they were folded into

The dashboard view.

By default this is one row per breach, in v1's alert shape plus every nest alert field, inside v1's paginate envelope (items, totalItems, page, totalPages, …) with nest's nextCursor beside it. Page with v1's page and limit (a page may start at most 10000 rows in), or walk with cursor: pass nextCursor back verbatim. sort is v1's time-desc (the default) or time-asc; ids narrows to those patients. It works whether or not the tenant has episodicAlerts. Without project it is tenant-wide: a per-facility view must send project, which keeps only patients stamped with it.

?episodes=true answers with episodes instead, as {items, nextCursor}: one row per clinical event, which opens on the first breaching reading, absorbs the rest, and closes on recovery, on going stale, or by hand. That grain REQUIRES project. It defaults to the tenant's feedCodes (PATCH /api/tenant), every code when it lists none; alerts have no code default.

codes, since and acknowledged filter either grain. until, page and ids are alerts only: sending one with episodes=true is a 422, not a filter that silently did nothing. status reads ACTIVE/RESOLVED for alerts and OPEN/CLOSED for episodes.

Episodes are newest first by sort: openedAt, the default, or lastFiringAt, the newest firing reading (the opening, for an episode that has none). since and the cursor use the same time. openedAt never changes, so walking every page lists each episode once. On lastFiringAt an episode that fires mid-walk moves above the cursor: it is never listed twice, but that walk misses it. A sort value from the other grain is a 422.

Recent Requests
Log in to see full request history
TimeStatusUser Agent
Retrieving recent requests…
LoadingLoading…
Query Params
boolean

Return episodes rather than the individual breaches they were folded from.

An episode is one continuous clinical event for a (patient, code) pair: it
opens on the first breaching reading, absorbs the rest, and closes on
recovery, on going stale, or by hand. The default answers one row per
breach, which is the duplication episodes exist to collapse.

Requires project, and changes which of the filters below are accepted.

string

The Medplum project that scopes the read to one facility: only patients
stamped with it. Required with episodes=true; optional on alerts, whose
read is otherwise tenant-wide.

string
length ≤ 200
ids
array of strings

v1's patient filter: only these patients' alerts, by Signals id. Repeat the
parameter or separate with commas. Alerts only.

ids
string
enum

ACTIVE or RESOLVED for alerts; OPEN or CLOSED with episodes=true.

Allowed:
codes
array of strings
length ≤ 32

Restrict to these LOINC codes.

On episodes it defaults to the tenant's feedCodes, every
code when it lists none. Alerts have no default: absent, every alert, including those
that carry no code.

codes
string

Alerts raised, or episodes whose sort time is, at or after this instant:
opened by default, last fired with sort=lastFiringAt.

string

Alerts raised before this instant. Alerts only.

boolean

Filter on whether the episode, or the alert, has been acknowledged.

string
enum

On alerts, v1's order: time-desc (the default) or time-asc.

On episodes, which time they are listed by, newest first; since and
cursor use it too. openedAt (the default) never changes, so a walk of
every page sees each episode once. lastFiringAt is the newest firing
reading, or the opening for an episode that has none; an episode that fires
mid-walk moves above the cursor.

Allowed:
number
≥ 1

v1's 1-based page of limit alerts. A page may start at most 10000 rows
in; walk further with cursor. Alerts only.

number
≥ 1
string
length ≤ 512
string

v1's tag filter: only patients whose tags.key equals one of the comma-separated values, or holds one in an array. Repeat with other keys to require them all. Keys are alphanumeric; tags.key= is accepted too.

Headers
string
enum
Defaults to application/json

Generated from available response content types

Allowed:
Responses

Language
Credentials
Basic
base64
:
LoadingLoading…
Response
Click Try It! to start a request and see the response here! Or choose an example:
application/json
application/problem+json