Storage
Collections & Files
Collections are containers for file uploads with versioning, metadata validation, and processing hooks.
Collection properties:
Property | Description |
|---|---|
| Unique identifier |
| JSON Schema that file metadata must conform to |
| Function that runs on upload to approve/reject files |
| Function that runs after upload for processing |
| Per-file size limit (default: 100 MB) |
| Total collection size limit (default: 10 GB) |
File features:
Versioning — Every upload creates a new version. Previous versions are preserved.
Metadata — Each file carries JSON metadata validated against the collection's schema.
Visibility — Files can be
private(owner only) orshared(users with collection:allaccess).Content filtering — Optional function runs on upload that can approve, reject, or modify the file.
Management endpoints:
Runtime file endpoints:
States
States are a persistent key-value store organized by namespace. Agents use states to maintain memory and context across conversations.
Key properties:
Property | Description |
|---|---|
| Organizational grouping (e.g., |
| Unique key within user + namespace |
| Any JSON data |
|
|
| Optional description |
| Tags for filtering and search |
| Priority for context retrieval (0.0–1.0, default: 1.0) |
| If |
| Optional expiration time |
Encrypted states: Set encrypted: true when creating or updating a state to store the value encrypted. The plaintext value is stored in encrypted_value (Fernet-encrypted) while value is set to {}. On read, the value is transparently decrypted. This is useful for storing API keys, tokens, or other secrets.
Agent state access is declared per agent via enabled_stores:
Read-only stores give the agent a retrieve_context tool. Read-write stores additionally provide save_context, update_context, and delete_context.
Endpoints:
Previous
runtime-api-vs-management-api
Next
triggers