Local integrations and Scripts

API

Connect a local application to the Camera Server integration API. This is a loopback-only pilot for valid PRO licenses and trials.

Persistent camera groups

The public /groups resources are Camera Server's persistent camera zones. API-created groups appear in the normal zone editor. They can include disconnected saved members.

Keep these three concepts separate:

Kind Lifetime and targeting
Persistent camera group/zone Saved in Camera Server; target with zoneId
Generated model group Fleet discovery/targeting aid; target with groupId or groupIds; not mutable through /groups
Timeline-local group Declared inside a timeline; resolves at run start; does not edit persistent zones

Endpoint reference

No token is needed. The connection access rules apply. Send Idempotency-Key on writes, but group creation, reads, updates, and deletion (CRUD) are not protected by the action replay ledger.

Read the current revision before editing. Treat it as an opaque value, not a counter.

Method and path Body Response
GET /groups None {items:[group]}
GET /groups/{id} None One group
POST /groups {name,numbers?} Created group, HTTP 200
PUT /groups/{id} {expectedRevision,name?,description?,numbers?} Updated group
DELETE /groups/{id} {expectedRevision} {deleted:true}

Group records contain the zone's fields, numbers, kind:"zone", and revision. Serial metadata is retained for compatibility and diagnostics. numbers lists the currently assigned numbers of saved members; an unnumbered saved member has no entry in that list. Fleet-supplied fields include counts and system-group metadata.

The revision excludes active/member counts, so a connection-count change alone is not a group edit. Renumbering members changes the revision.

Create and replace members

{"name":"Left side","numbers":[1,2,3]}

name must be nonblank and no longer than 128 characters. Supply the numbers established in Camera List. Camera Server resolves them to saved camera identities, including disconnected saved members. numbers has at most 256 positive integer entries; duplicates are removed. Omit it or send [] to create an empty group. Unknown or ambiguous numbers reject the entire update.

Membership is saved by internal camera identity, not by number. Renumbering a camera does not silently replace a saved group's member with another camera. Reads report the members' current numbers. Existing clients may still supply serials instead of numbers, but never both. Operators do not need to provide serials.

The create handler uses name and numbers, not description. Set a description with a subsequent revision-aware update:

{
  "expectedRevision":"revision-from-group-read",
  "description":"Explicit integration selection",
  "numbers":[1,2,3]
}

PUT changes only supplied fields. numbers replaces the entire member list; it is not an add/remove patch. A supplied description must be a string of at most 512 characters. Renaming checks case-insensitive duplicate names.

OpenAPI uses separate Group creation and GroupUpdate schemas. Creation requires name; update requires expectedRevision, with name optional.

After a lost create response, read the group list and reconcile it before repeating POST. Group creation is not protected by the durable action idempotency ledger.

Restrictions and conflicts

  • Main and other system groups are read-only: 409 system_group.
  • The selected zone cannot be deleted: 409 group_selected. Select another zone in Camera Server first. The API does not select zones because selection can apply remembered settings.
  • A missing or stale expectedRevision on update/delete gives 409 revision_conflict.
  • Unknown group: 404 not_found. Unknown camera number: 404 unknown_camera_number. Ambiguous numbering: 409 ambiguous_camera_number. Unknown legacy serial: 400 unknown_camera.
  • Invalid name, description, or members gives 400 invalid_name, invalid_description, or invalid_members.
  • Duplicate-name checks can return a fleet validation error on creation; PUT explicitly returns 409 duplicate_name.

Creating or editing a group does not execute a timeline or take a photo. Groups are shared by all API clients and the desktop. Re-read membership before executing a physical action if another operator or client may have edited it.

Cameras and direct actions · Local client examples

Updated

Page links