How do I register callback endpoints for my domain?

Camio can programmatically notify your preferred callback endpoints when important events happen. You define domain-level endpoints that receive callbacks for specific Event Types. The incident.created Event is triggered whenever a stream health counter is greater than zero.

Domain Registration

Your domain must be registered prior to using callback Endpoints, If your domain isn't already registered, then please send the email address you'd like to designate as your primary domain admin to support@camio.com to register your domain.

Domain-level Callback Endpoints

  1. Open https://camio.com/domains after signing in as the domain admin designated above.
  2. Enter your domain and press the Find button.  (You can also specify the domain in the query string like https://camio.com/?domain=acme.com)
    Screen_Shot_2021-03-31_at_11.44.18_PM.png

  3. Enter the HTTP Request to be triggered:
    1. HTTP Method that's typically POST or PUT, but any of the commands are supported.
    2. URL of the new Endpoint
    3. HTTP Headers as JSON key/value pairs. The example below is:
      {
          "Authorization": "token XYZPDQ",
          "Content-Type": "application/json"
      }
    4. Event Types that trigger the requests sent to this new Endpoint.
      Screen_Shot_2021-03-30_at_7.46.17_PM.png

Event Types

The Event Types currently include:

  1. camera.created
  2. camera.updated
  3. camera.deleted
  4. device.deleted
  5. hook.created
  6. hook.deleted
  7. incident.created
  8. zone.created
  9. zone.updated
  10. zone.deleted

incident.created

The types of incidents included in incident.created are counter values greater than zero for:

  1. stream_changed_offline_count
  2. movies_discarded_count
  3. events_purged_count
  4. movies_purged_count
  5. segmentation_process_restart_count (only when greater than 15 within a 15-minute period)

incident.created payload

The payload of the POST to the URL includes "data", "id" and "type" like this example for incident.created caused by a failure to connect to a camera stream on the LAN (AKA segmentation_process_restart_count): 

{
    "data": {
        "object": {
            "incident": {
                "camera_name": "Front Entrance",
                "counter_events": {
                    "segmentation_process_restart_count": {
                        "counter": "segmentation_process_restart_count",
                        "description": "47 \\u003e 0 means the network connection to the video stream is unstable have restarted 47 times in 15 minutes.",
                        "value": 47
                    }
                },
                "date": "2021-04-30T19:13:42.317-0000",
                "type": "incident"
            },
            "user": {
                "email": "hq-cams@acme.com",
                "user_id": "56X126755830642533906524"
            }
        }
    },
    "id": "f58a5ef2-fbc7-407b-bdeb-536bfde767da",
    "type": "incident.created"
}

 

 

See the definition of each counter.

Please see https://api.camio.com/#domains for API documentation.

Have more questions? Submit a request

Comments