curl -X POST "https://api.magpipe.ai/functions/v1/update-memory" \
-H "Authorization: Bearer YOUR_API_KEY" \
-H "Content-Type: application/json" \
-d '{
"memory_id": "789e0123-e89b-12d3-a456-426614174000",
"summary": "VIP customer, longtime buyer. Had delivery issue that was resolved.",
"preferences": {
"contact_method": "email",
"best_time": "afternoons",
"vip": true
},
"relationship_notes": "Escalate any issues to manager immediately"
}'
{
"id": "789e0123-e89b-12d3-a456-426614174000",
"summary": "VIP customer, longtime buyer. Had delivery issue that was resolved.",
"key_topics": ["orders", "delivery", "refunds"],
"preferences": {
"contact_method": "email",
"best_time": "afternoons",
"vip": true
},
"relationship_notes": "Escalate any issues to manager immediately",
"last_updated": "2024-01-15T16:00:00Z"
}
{
"error": {
"code": "not_found",
"message": "Memory not found"
}
}
Memory
Update Memory
Update a caller’s memory
POST
/
update-memory
curl -X POST "https://api.magpipe.ai/functions/v1/update-memory" \
-H "Authorization: Bearer YOUR_API_KEY" \
-H "Content-Type: application/json" \
-d '{
"memory_id": "789e0123-e89b-12d3-a456-426614174000",
"summary": "VIP customer, longtime buyer. Had delivery issue that was resolved.",
"preferences": {
"contact_method": "email",
"best_time": "afternoons",
"vip": true
},
"relationship_notes": "Escalate any issues to manager immediately"
}'
{
"id": "789e0123-e89b-12d3-a456-426614174000",
"summary": "VIP customer, longtime buyer. Had delivery issue that was resolved.",
"key_topics": ["orders", "delivery", "refunds"],
"preferences": {
"contact_method": "email",
"best_time": "afternoons",
"vip": true
},
"relationship_notes": "Escalate any issues to manager immediately",
"last_updated": "2024-01-15T16:00:00Z"
}
{
"error": {
"code": "not_found",
"message": "Memory not found"
}
}
Update a caller’s memory record. Only include fields you want to change.
Request Body
string
required
UUID of the memory record to update
string
Updated relationship summary
array
Updated list of key topics
object
Updated caller preferences
string
Updated relationship notes
Response
Returns the updated memory object.curl -X POST "https://api.magpipe.ai/functions/v1/update-memory" \
-H "Authorization: Bearer YOUR_API_KEY" \
-H "Content-Type: application/json" \
-d '{
"memory_id": "789e0123-e89b-12d3-a456-426614174000",
"summary": "VIP customer, longtime buyer. Had delivery issue that was resolved.",
"preferences": {
"contact_method": "email",
"best_time": "afternoons",
"vip": true
},
"relationship_notes": "Escalate any issues to manager immediately"
}'
{
"id": "789e0123-e89b-12d3-a456-426614174000",
"summary": "VIP customer, longtime buyer. Had delivery issue that was resolved.",
"key_topics": ["orders", "delivery", "refunds"],
"preferences": {
"contact_method": "email",
"best_time": "afternoons",
"vip": true
},
"relationship_notes": "Escalate any issues to manager immediately",
"last_updated": "2024-01-15T16:00:00Z"
}
{
"error": {
"code": "not_found",
"message": "Memory not found"
}
}
⌘I