Operators
Update Operator
Update an operator's fields.
PATCH /api/operators/:id
Update an operator's fields. Metadata uses merge semantics.
Auth: Required — MANAGE_OPERATORS permission
Path Parameters
| Parameter | Type | Description |
|---|---|---|
id | UUID | Operator ID |
Request Body
All fields are optional:
| Field | Type | Description |
|---|---|---|
name | string | Operator name |
email | string | Email address |
phone | string | Phone number |
is_active | boolean | Active status |
metadata | object | Arbitrary JSON (merge semantics) |
Example
curl -X PATCH https://api.reten.ai/api/operators/cc0e8400-e29b-41d4-a716-446655440000 \
-H "Authorization: Bearer <token>" \
-H "x-tenant-id: <tenant-id>" \
-H "Content-Type: application/json" \
-d '{
"name": "John Smith",
"phone": "+56987654321",
"metadata": { "region": "north" }
}'import axios from 'axios';
const response = await axios.patch(
'https://api.reten.ai/api/operators/cc0e8400-e29b-41d4-a716-446655440000',
{
name: 'John Smith',
phone: '+56987654321',
metadata: { region: 'north' },
},
{
headers: {
Authorization: 'Bearer <token>',
'x-tenant-id': '<tenant-id>',
},
}
);Response 200 OK
Returns the updated operator object.