---
title: "List Resources"
method: GET
path: "/api/v1/resources"
tags: ["resources"]
---

# List Resources

`GET /api/v1/resources`

## Request

- Base URL: `https://memory.kagura-ai.com` (the document declares no server; this is the origin it was published from)
- URL: `https://memory.kagura-ai.com/api/v1/resources`
- Auth: none declared

List all resources in the caller's current workspace.

Returns an ordered list (latest activity first) of contexts that have a
non-null ``resource_id``, with aggregated counts joined from the
resource_tokens, memories, resource_schemas, and resource_events tables.

#1863: a resource whose contexts were all deleted is still listed, with
the context fields null, while it has active tokens. Those tokens keep
authenticating ingest, so the owner needs a way to reach and revoke them;
once the last one is revoked the row disappears.

Owner-only (#389): ``WorkspaceOwner`` rejects non-owners with 403.
``get_accessible_contexts`` below is a no-op for owners and retained
as defense-in-depth against a role-gate regression.

Example:
    GET /api/v1/resources

## Headers

- `authorization` string, nullable

## Response `200`

Successful Response

- ResourceListResponse: Workspace resource list response.
  - `resources` ResourceListItem[], required
    - `resource_id` string, required: Resource identifier
    - `context_id` string, nullable: UUID of the context bound to this resource. Null when every context of the resource has been deleted (#1863): such a row is listed only while the resource still has active tokens, so they stay reachable.
    - `context_name` string, nullable: Context name (URL-safe identifier)
    - `context_display_name` string, nullable: Human-readable context name
    - `token_count` integer, required: Number of active resource tokens
    - `memory_count` integer, required: Number of non-deleted memories
    - `current_schema_version` integer, nullable: Latest schema version, or null if no schema registered
    - `created_at` string, required: Context creation time (ISO 8601 UTC)
    - `updated_at` string, required: Most recent activity — GREATEST(last_event_at, context.updated_at, context.created_at) as ISO 8601 UTC
  - `total` integer, required

## Other responses

- `422`: Validation Error

---

[API](https://skmtc.dev/kagura-ai/apis/kagura-memory-cloud.md) · [All operations](https://skmtc.dev/kagura-ai/apis/kagura-memory-cloud/llms.txt) · [OpenAPI document](https://skmtc.dev/kagura-ai/apis/kagura-memory-cloud/revisions/09f17f5ada29?raw)
