Memories API
Memories are persistent knowledge bases with vector search capabilities. They can store text, files, and other content for retrieval by neurons.
List Memories
Get a list of memories with optional filtering.
Brain scope required. Include the X-Brain-Id header or configure getBrainId in the public client.
| Header | Type | Description |
|---|
X-Brain-Id | string (UUID) | Required. Brain ID for scoping |
Query Parameters
| Parameter | Type | Description |
|---|
source_type | string | Filter by source type: text, file, etc. |
limit | number | Maximum number of results (default: 20) |
offset | number | Offset for pagination |
sortBy | string | Sort field: created_at, updated_at, name |
Example Request
const memories = await auvy.memories.list({
source_type: 'file'
})
curl https://api.auvy.ai/v1/memories?source_type=file \
-H "Authorization: Bearer YOUR_API_KEY" \
-H "X-Brain-Id: YOUR_BRAIN_ID"
Get Memory
Get a single memory by ID.
Path Parameters
| Parameter | Type | Description |
|---|
id | string | Memory UUID |
Create Memory
Create a new memory.
Request Body
| Field | Type | Required | Description |
|---|
name | string | Yes | Memory name |
description | string | No | Memory description |
source_type | string | Yes | Source type: text or file |
Example Request
const memory = await auvy.memories.create({
name: 'My Memory',
description: 'A sample memory',
source_type: 'text'
})
curl -X POST https://api.auvy.ai/v1/memories \
-H "Authorization: Bearer YOUR_API_KEY" \
-H "Content-Type: application/json" \
-d '{
"name": "My Memory",
"description": "A sample memory",
"source_type": "text"
}'
Ingest Memory
Create a memory by ingesting a file (multipart) or text/URL (JSON). Use one of two request formats.
| Field | Type | Required | Description |
|---|
file | file | Yes | File to ingest |
name | string | No | File name override |
owner_type | string | No | Owner type (e.g. neuron, trace) |
owner_id | string | No | Owner UUID |
Option B — Text or URL (application/json)
Either content (non-empty text) or file_url is required.
| Field | Type | Required | Description |
|---|
content | string | No* | Text content to ingest |
file_url | string (URL) | No* | Any publicly reachable file URL (HTTP/HTTPS; e.g. S3, GCS, or any host) |
name | string | No | Memory name |
description | string | No | Memory description |
owner_type | string | No | Owner type (e.g. neuron, trace) |
owner_id | string (UUID) | No | Owner UUID |
skip_title_description | boolean | No | Skip auto title/description (default: false) |
skip_embedding | boolean | No | Skip embedding job (default: false) |
metadata | object | No | Custom metadata |
* Either content or file_url must be provided.
Example requests
TypeScript (file)
TypeScript (text)
curl (file)
curl (text)
const file = fileInput.files?.[0] // or new File([...], 'doc.pdf', { type: 'application/pdf' })
if (file) {
const { memory, embeddingJobId } = await auvy.memories.ingest(file, {
name: 'document.pdf'
})
}
const { memory, embeddingJobId } = await auvy.memories.ingestText({
content: 'This is sample content to add to the memory.',
name: 'Sample Content'
})
curl -X POST https://api.auvy.ai/v1/memories/ingest \
-H "Authorization: Bearer YOUR_API_KEY" \
-F "file=@document.pdf" \
-F "name=document.pdf"
curl -X POST https://api.auvy.ai/v1/memories/ingest \
-H "Authorization: Bearer YOUR_API_KEY" \
-H "Content-Type: application/json" \
-d '{
"content": "This is sample content to add to the memory.",
"name": "Sample Content"
}'
Get Memory Chunks
Get vector chunks from a memory for search results.
GET /v1/memories/:id/chunks
Path Parameters
| Parameter | Type | Description |
|---|
id | string | Memory UUID |
Query Parameters
| Parameter | Type | Description |
|---|
limit | number | Maximum number of chunks |
offset | number | Offset for pagination |
Bulk Delete Memories
Delete multiple memories at once.
POST /v1/memories/bulk-delete
Request Body
| Field | Type | Required | Description |
|---|
ids | array | Yes | Array of memory UUIDs to delete |
Example Request
const result = await auvy.memories.bulkDelete(['uuid-1', 'uuid-2'])
console.log(`Deleted ${result.deletedCount} memories`)
curl -X POST https://api.auvy.ai/v1/memories/bulk-delete \
-H "Authorization: Bearer YOUR_API_KEY" \
-H "Content-Type: application/json" \
-d '{
"ids": ["uuid-1", "uuid-2"]
}'
Example Response
{
"deletedCount": 2,
"notFoundCount": 0
}