List Agent's Knowledge Items

Lists all knowledge items attached to a specific agent.

HTTP Request

$GET https://app.resemble.ai/api/v2/agents/{agent_uuid}/knowledge_items

URL Parameters

ParameterTypeDescription
agent_uuidstringThe UUID of the agent

Example Request

$curl --request GET "https://app.resemble.ai/api/v2/agents/agent-uuid-123/knowledge_items" \
> -H "Authorization: Bearer YOUR_API_TOKEN" \
> -H "Content-Type: application/json"

Response

1{
2 "success": true,
3 "items": [
4 {
5 "uuid": "550e8400-e29b-41d4-a716-446655440000",
6 "title": "Product FAQ",
7 "description": "FAQ content",
8 "source_type": "url",
9 "status": "ready",
10 "error_message": null,
11 "chunk_count": 15,
12 "url": "https://example.com/faq",
13 "created_at": "2025-12-01T10:00:00Z",
14 "updated_at": "2025-12-01T10:05:00Z"
15 },
16 {
17 "uuid": "660e8400-e29b-41d4-a716-446655440001",
18 "title": "Product Manual",
19 "description": "Complete product documentation",
20 "source_type": "document",
21 "status": "ready",
22 "error_message": null,
23 "chunk_count": 42,
24 "document_url": "https://storage.example.com/signed-url",
25 "document_filename": "manual.pdf",
26 "created_at": "2025-12-01T09:00:00Z",
27 "updated_at": "2025-12-01T09:15:00Z"
28 }
29 ],
30 "count": 2
31}

Response Body

AttributeTypeDescription
successbooleanIndicates if the request was successful
itemsarrayArray of knowledge item objects
countintegerTotal number of knowledge items attached to this agent
uuidstringUnique identifier for the knowledge item
titlestringDisplay title (max 50 chars)
descriptionstringDescription (max 200 chars)
source_typestringSource type: document, url, or text
statusstringStatus: pending, processing, ready, or failed
error_messagestringError details if status is failed (null otherwise)
chunk_countintegerNumber of chunks created (null until processed)
urlstringSource URL (only for url type)
document_urlstringSigned URL to download document (only for document type, expires after 1 hour)
document_filenamestringOriginal filename (only for document type)
created_atstringISO8601 timestamp of creation
updated_atstringISO8601 timestamp of last update

Error Response (Agent Not Found)

1{
2 "success": false,
3 "errors": {
4 "base": ["Agent not found"]
5 },
6 "message": "Failed to retrieve knowledge items"
7}

Use Cases

Check Agent’s Knowledge

View all knowledge items that an agent can access during conversations:

$curl --request GET "https://app.resemble.ai/api/v2/agents/support-agent-uuid/knowledge_items" \
> -H "Authorization: Bearer YOUR_API_TOKEN"

Audit Knowledge Access

Determine which knowledge sources an agent is using for RAG retrieval:

$# Get all knowledge items for the agent
>curl --request GET "https://app.resemble.ai/api/v2/agents/agent-uuid/knowledge_items" \
> -H "Authorization: Bearer YOUR_API_TOKEN"

Verify Attachments

After attaching knowledge items, confirm they’re properly linked:

$# After calling attach endpoint, verify with list
>curl --request GET "https://app.resemble.ai/api/v2/agents/agent-uuid/knowledge_items" \
> -H "Authorization: Bearer YOUR_API_TOKEN"

Filtering Results

This endpoint returns all knowledge items attached to the agent. To filter:

  • By Status: Filter client-side based on the status field
  • By Source Type: Filter client-side based on the source_type field
  • Ready Items Only: Filter for items with status: "ready" for active knowledge

Knowledge Item Status

Only knowledge items with status: "ready" are actively used by the agent for RAG retrieval:

  • ready: Agent can retrieve chunks from this knowledge item
  • pending/processing: Agent cannot use this item yet (waiting for ingestion)
  • failed: Agent cannot use this item (ingestion failed)

RAG Configuration

The agent’s RAG behavior is controlled by agent-level settings:

  • search_mode: Controls retrieval strategy ("speed" or "accuracy")
  • max_chunks_per_query: Number of chunks to retrieve per query

View these settings via Get Agent with advanced=true query parameter.

See Also