Skip to content
English
  • There are no suggestions because the search field is empty.

How to get feed preview images by API

If you want to get the feed preview images from your application, you can implement the feature with following steps.


Query on VIRGA GET /config/worker endpoint
This API returns the configured feeds in JSON list.

      },
      ""feeds"": {
        ""SAFR-Camera-CA110D"": {
          ""name"": ""SAFR-Camera-CA110D"",
          ""mode"": ""Enrolled and Stranger Monitoring"",
          ""directory"": ""main"",
          ""source"": ""Gate-A"",
          ""site"": ""main"",
          ""enabled"": true,
          (...)
          ""capture.deposite-generic-base-url"": ""cvos://sharedStream/video_e79b0b7c-cfa6-49dc-91ec-24e65d1da530"",
           (...)
          ""input.type"": ""stream"",
          ""tracker.reconfirmation-interval"": 1
        }
      },
      ""client-id"": ""SAFR-Camera-CA110D""
    },


Extract the ""capture.deposite-generic-base-url"".


Query on CVOS with GET /sharedStream/{id} API

Use the Request PATH of capture.deposite-generic-base-url. With the above example, send GET request to following URL: http://cvos_host:cvos_port/sharedStream/video_e79b0b7c-cfa6-49dc-91ec-24e65d1da530

The API returns a video preview image of the feed.


curl:

curl -k -X GET ""https://127.0.0.1:8087/sharedStream/video_e79b0b7c-cfa6-49dc-91ec-24e65d1da530"" -H ""accept: */*"" -H ""X-RPC-AUTHORIZATION: $USER:$PASS"" > preview.jpg