Skip to content

API Reference parrot.handlers.threads

github-actions[bot] edited this page Dec 2, 2026 · 4 revisions

parrot.handlers.threads

View source

REST handler for thread management.

Provides endpoints for conversation thread CRUD operations with DynamoDB backend support. Uses ChatStorage (DynamoDB) for thread and turn persistence, and ArtifactStore for cascade deletes.

FEAT-103: agent-artifact-persistency — Module 7.

Alias ConversationDeletedError

Re-exported from parrot.storage.errors.ConversationDeletedError.

Alias StorageError

Re-exported from parrot.storage.errors.StorageError.

Class ThreadDetailView

Detail operations on a single conversation thread.

GET /api/v1/threads/{session_id} — load turns PATCH /api/v1/threads/{session_id} — update metadata DELETE /api/v1/threads/{session_id} — delete + cascade

Method ThreadDetailView.get

Load turns for a conversation thread.

Query params: agent_id (optional): Agent/bot identifier. limit (optional): Max turns to return (default 10).

get() -> web.Response

Returns: web.Response

Method ThreadDetailView.patch

Update thread metadata (title, pinned, tags).

Body: title (optional): New title. pinned (optional): Pin/unpin flag. tags (optional): List of tags. agent_id (required): Agent/bot identifier for DynamoDB PK.

patch() -> web.Response

Returns: web.Response

Method ThreadDetailView.delete

Delete a thread and cascade-delete all artifacts.

Query params: agent_id (optional): Agent/bot identifier.

delete() -> web.Response

Returns: web.Response

Class ThreadListView

List and create conversation threads.

GET /api/v1/threads?agent_id=X&limit=N — list threads POST /api/v1/threads — create thread

Method ThreadListView.get

List conversation threads for the authenticated user.

get() -> web.Response

Returns: web.Response

Method ThreadListView.post

Create a new conversation thread.

post() -> web.Response

Returns: web.Response

Architecture

Clients

Bots & Agents

Memory

Knowledge

Tools & Toolkits

Flows

Experts

Skills

Stores & Loaders

MCP & A2A

Server & APIs

Integrations

Outputs & A2UI

Prompts

Security

Operations

Migration

SDD Tooling

LLM Wiki

Deployment

Decisions

API Reference

Clone this wiki locally