Webhook API Fresh
Manage webhooks to receive real-time notifications about memory events.
Base URL: https://api.mem0.ai
Authentication: Authorization: Token <MEM0_API_KEY>
Create Webhook
POST /api/v1/webhooks/projects/{project_id}/
Path Parameters
| Parameter | Type | Required | Description |
|---|---|---|---|
project_id | string | Yes | Project identifier. |
Request Body
| Field | Type | Required | Description |
|---|---|---|---|
url | string | Yes | URL endpoint for the webhook. |
name | string | Optional | Webhook identifier name. |
event_types | array | Optional | Event types to subscribe to. |
is_active | boolean | Optional | Activation status. |
Event Types
memory:addmemory:updatememory:deletememory:categorize
Response (201)
json
{
"webhook_id": "uuid",
"name": "My Webhook",
"url": "https://example.com/webhook",
"event_types": ["memory:add", "memory:update"],
"is_active": true,
"project": "my-project",
"created_at": "2024-07-15T10:30:00Z",
"updated_at": "2024-07-15T10:30:00Z"
}Errors
- 400: Invalid request with error details
- 403:
"You don't have access to this project"
Get Webhooks (List)
GET /api/v1/webhooks/projects/{project_id}/
Response (200)
Returns an array of webhook objects with fields: webhook_id, name, url, event_types, is_active, project, created_at, updated_at.
Update Webhook
PUT /api/v1/webhooks/{webhook_id}/
Path Parameters
| Parameter | Type | Required |
|---|---|---|
webhook_id | string | Yes |
Request Body
| Field | Type | Description |
|---|---|---|
name | string | New webhook name. |
url | string | New URL endpoint. |
event_types | array | Updated event subscriptions. |
Response (200)
json
{ "message": "Webhook updated successfully" }Errors
- 400: Invalid request
- 403:
"You don't have access to this webhook" - 404:
"Webhook not found"
Delete Webhook
DELETE /api/v1/webhooks/{webhook_id}/
Response (200)
json
{ "message": "Webhook deleted successfully" }Errors
- 403:
"You don't have access to this webhook" - 404:
"Webhook not found"