---
title: "GET /vault/shares"
method: GET
path: "/vault/shares"
---

# GET /vault/shares

`GET /vault/shares`

## Request

- Base URL: `https://api.useanima.sh/v1`
- URL: `https://api.useanima.sh/v1/vault/shares`
- Auth: one of:
  - HTTP bearer
  - API key in header `X-API-Key`

## Query parameters

- `agentId` union: Agent identifier. Optional when using an agent API key (resolved automatically); required when using a master key.
  - string
  - string
- `direction` 'granted' | 'received': Filter by share direction
- `cursor` string: Cursor for pagination
- `limit` integer: Maximum entries to return

## Response `200`

OK

- object: Paginated list of credential shares
  - `items` object[], required: List of credential shares
    - `id` string, required: Unique share record identifier
    - `credentialId` string, required: Shared credential identifier
    - `orgId` string, required: Organization identifier
    - `sourceAgentId` string, required: Agent that owns the credential
    - `targetAgentId` string, required: Agent that received access
    - `permission` 'READ' | 'USE' | 'MANAGE', required: Permission level
    - `expiresAt` string, date-time, nullable, required: When the share expires
    - `grantedBy` string, required: Who created the share
    - `revokedAt` string, date-time, nullable, required: When the share was revoked, if applicable
    - `createdAt` string, date-time, required: Timestamp when the share was created
    - `updatedAt` string, date-time, required: Timestamp when the share was last updated
  - `pagination` object, required: Cursor-based pagination metadata
    - `nextCursor` string, nullable, required: Cursor to pass as the `cursor` parameter to retrieve the next page, or null if no more results
    - `hasMore` boolean, required: Whether additional pages of results are available

---

[API](https://skmtc.dev/useanima/apis/anima-api.md) · [All operations](https://skmtc.dev/useanima/apis/anima-api/llms.txt) · [OpenAPI document](https://skmtc.dev/useanima/apis/anima-api/revisions/aaa148188980?raw)
