Korely

Users & agents

List users

List your distinct end-user namespaces, each with its active memory count, active fact count, and last-active time, sorted most-recently-active first.

GET /v1/users

SDK: korely.users(...). Each end user you scope a write to (the user_id namespace) shows up here once it has at least one active memory or fact. Use it to render an account list, audit who Korely is remembering, or drive a per-user dashboard.

Authentication

HTTP header, required: Authorization: Bearer kor_live_....

Query parameters

ParameterTypeRequiredDescription
agent_idstringOptionalFilter to one agent namespace. Defaults to none (all agents). When set, both the memory and fact aggregates are restricted to that agent_id.
limitintegerOptionalPage size. Default 50, between 1 and 200.
offsetintegerOptionalPagination offset. Default 0, must be >= 0.

Example request

Terminal window
curl "https://api.korely.ai/v1/users?agent_id=support-bot&limit=50&offset=0" \
-H "Authorization: Bearer kor_live_..."

Response

200 OK. A page of end-user namespaces, plus the total count of distinct end users across the full aggregated set.

{
"users": [
{
"user_id": "customer-giulia-4812",
"memories": 14,
"facts": 31,
"last_active": "2026-03-02T11:02:10+00:00"
},
{
"user_id": "customer-marco-2207",
"memories": 3,
"facts": 5,
"last_active": "2026-02-18T08:40:00+00:00"
}
],
"total": 2
}
FieldTypeDescription
usersarray<UserScope>The page of end users. Each UserScope has user_id (the end-user namespace), memories (active memory count), facts (active fact count), and last_active (ISO 8601 timestamp, nullable).
totalintegerTotal distinct end users, the length of the full aggregated set, before pagination is applied.

Errors

StatusCodeCause
401invalid_keyMissing or invalid kor_live_ key, Authorization header absent or unverifiable.
403forbiddenThe key lacks the memories:read scope required to read user namespaces.
429quota_exceededMonthly query quota exceeded. Resets at the next billing cycle, or upgrade.
429rate_limit_exceededPer-key rate limit exceeded. Honor the Retry-After header and back off.
422invalid_requestlimit is outside 1..200, or offset is below 0.

Notes

  • Memory-only and fact-only users both appear. The counts aggregate active memories (deleted_at IS NULL) and direct fact writes (invalid_at IS NULL), so an end user that only has facts still shows up.
  • The default namespace is omitted. Writes made without a user_id (the null end-user namespace) are not listed here.
  • Sort order. Most-recently-active first; users with no timestamp (last_active: null) sort last.
  • Pagination. The page is sliced after aggregation (users[offset:offset+limit]); total always reflects the full set length, independent of limit and offset.
  • Counts as a read. Each call draws from your monthly query quota.

Related