cURL
curl --request POST \ --url https://api.duohub.ai/memories/add-files \ --header 'Content-Type: application/json' \ --header 'X-API-Key: <api-key>' \ --data ' { "files": [ "123e4567-e89b-12d3-a456-426614174000", "987fcdeb-51a2-43b7-91fa-987654321000" ], "memoryID": "987fcdeb-51a2-43b7-91fa-987654321000" } '
{ "status": "success", "data": { "id": "456e7890-c12d-34e5-b678-426614174000", "fileID": "123e4567-e89b-12d3-a456-426614174000", "memoryID": "987fcdeb-51a2-43b7-91fa-987654321000", "userID": "user123", "type": "document", "createdAt": "2024-01-01T00:00:00.000Z", "updatedAt": "2024-01-01T00:00:00.000Z" } }
Add a file to a memory
Your duohub API key. Type: str
ID of the file to add to the memory
ID of the memory to add the file to
File added to memory successfully
success
Show child attributes
Unique identifier for the sample
ID of the file
ID of the memory
ID of the user
Type of the sample
human
ai
document
Creation timestamp
Last update timestamp