Editing Presence Lock
A presence-based, advisory soft-lock that tracks which analysts currently have a connector open in the editor. The UI uses it to warn about potential collisions when two people edit the same connector.
This lock is advisory only — it never blocks saving or publishing. It just reports who else is present. Entries are stored in Redis with a 45-second TTL and are self-cleaning; entries older than the stale window are filtered out on every read and write, so a crashed tab eventually disappears on its own.
Authorization
- Analyst (or admin) with an analyst profile. Unauthenticated requests receive
401; users without the role/profile receive403.
Because the feature is advisory, runtime/cache errors are swallowed: a failing POST or GET returns { "editors": [] } and a failing DELETE returns { "released": false } rather than a 500. Auth checks still apply.
Path Parameters
| Parameter | Type | Required | Description |
|---|---|---|---|
id | string | Yes | Connector ID |
Editor Object
Every response that lists editors returns only the other analysts (the caller is excluded):
| Field | Type | Description |
|---|---|---|
analystId | string | The other editor's analyst ID |
fullName | string | The other editor's display name |
Register / Refresh Presence
POST /api/connectors/{id}/editing
Registers (or refreshes) the caller's editing presence, bumping its lastSeen timestamp and resetting the TTL. Clients poll this on an interval to stay "present".
Response
{
"editors": [
{ "analystId": "analyst_002", "fullName": "Jane Roe" }
]
}
List Other Editors
GET /api/connectors/{id}/editing
Returns the other analysts currently editing, after pruning stale entries. Does not register the caller.
Response
{
"editors": [
{ "analystId": "analyst_002", "fullName": "Jane Roe" }
]
}
Release Presence
DELETE /api/connectors/{id}/editing
Removes the caller's presence entry (e.g. on tab close). If no other editors remain, the Redis key is deleted entirely.
Response
{ "released": true }
Error Responses
401 Unauthorized
{ "error": { "code": "UNAUTHORIZED", "message": "Authentication required" } }
403 Forbidden
{ "error": { "code": "FORBIDDEN", "message": "Analyst role required" } }