Page cover image

HTTP APIs

Getting Started

Before you read this part, please make sure to read How our APIs workto understand the interaction between data in our platform.

Postman Documentation

Click the link below to access Postman Documentation for easier use for our HTTP API:

Streams

This section is used for stream configuration. If you want to create your visualization then this API will help you to connect the camera RTSP / RTMP address to be consumed by our engine.

Get All Streams

This API will give you all streams in all nodes (in case you use clustering deployment).

GEThttp://{{ip}}/streams
Response

Success

Headers
Body
stream_numbernumber
Example: 11
streamsarray of object
Request
const response = await fetch('http://{{ip}}/streams', {
    method: 'GET',
    headers: {},
});
const data = await response.json();
Response
{
  "stream_number": 11,
  "streams": [
    {
      "active": true,
      "stream_address": "rtsp://10.7.2.50:554/VOD/halte_unj_crd.mp4",
      "stream_custom_data": {},
      "stream_id": "c73a1992f67961d1",
      "stream_latitude": 0,
      "stream_longitude": 0,
      "stream_name": "halte slave 11",
      "stream_node_num": 0
    },
    {
      "active": true,
      "stream_address": "rtsp://10.7.2.50:554/VOD/police-shooter-nashville.mp4",
      "stream_custom_data": {},
      "stream_id": "f8c4e792f1606a36",
      "stream_latitude": 0,
      "stream_longitude": 0,
      "stream_name": "Test Node 1 False",
      "stream_node_num": 0
    },
    {
      "active": true,
      "stream_address": "rtsp://10.7.2.50:554/VOD/halte_unj_crd.mp4",
      "stream_custom_data": {},
      "stream_id": "44649ea3b72155e3",
      "stream_latitude": 0,
      "stream_longitude": 0,
      "stream_name": "asdqwe",
      "stream_node_num": 0
    },
    {
      "active": true,
      "stream_address": "rtsp://10.7.2.50:554/VOD/jalan-santai-yapen-selatan-00_01_00-00_02_00.mp4",
      "stream_custom_data": {},
      "stream_id": "1f49ae135b4fa44b",
      "stream_latitude": 0,
      "stream_longitude": 0,
      "stream_name": "Jalan Santai",
      "stream_node_num": 0
    },
    {
      "active": true,
      "stream_address": "rtsp://10.7.2.50:554/VOD/arkadia/ESCALATOR1-LT.GF.mp4",
      "stream_custom_data": {},
      "stream_id": "7b7954701f6e4948",
      "stream_latitude": 0,
      "stream_longitude": 0,
      "stream_name": "Mall",
      "stream_node_num": 0
    },
    {
      "active": true,
      "stream_address": "rtsp://10.7.2.50:554/VOD/drone_dpr_zoom1.mp4",
      "stream_custom_data": {},
      "stream_id": "4b508b81dfccdbb0",
      "stream_latitude": 0,
      "stream_longitude": 0,
      "stream_name": "Drone CE",
      "stream_node_num": 0
    },
    {
      "active": true,
      "stream_address": "rtsp://10.7.2.50:554/VOD/halte_unj_crd.mp4",
      "stream_custom_data": {},
      "stream_id": "78d4cf7639ed1fa7",
      "stream_latitude": 0,
      "stream_longitude": 0,
      "stream_name": "qwe",
      "stream_node_num": 0
    },
    {
      "active": true,
      "stream_address": "rtsp://10.7.2.50:554/VOD/halte_unj_crd.mp4",
      "stream_custom_data": {},
      "stream_id": "45bb1fd40f439797",
      "stream_latitude": 0,
      "stream_longitude": 0,
      "stream_name": "zxc",
      "stream_node_num": 0
    },
    {
      "active": true,
      "stream_address": "rtsp://10.7.2.50:554/VOD/halte_unj_crd.mp4",
      "stream_custom_data": {},
      "stream_id": "fdd3f05f2fdf8c20",
      "stream_latitude": 0,
      "stream_longitude": 0,
      "stream_name": "qqwe",
      "stream_node_num": 0
    },
    {
      "active": true,
      "stream_address": "rtsp://10.7.2.50:554/VOD/halte_unj_crd.mp4",
      "stream_custom_data": {},
      "stream_id": "cd5b759b6f7bfc95",
      "stream_latitude": 0,
      "stream_longitude": 0,
      "stream_name": "zxczxc",
      "stream_node_num": 0
    },
    {
      "active": true,
      "stream_address": "rtsp://10.7.2.50:554/VOD/halte_unj_crd.mp4",
      "stream_custom_data": {},
      "stream_id": "ed9490e28e2d3a8a",
      "stream_latitude": 0,
      "stream_longitude": 0,
      "stream_name": "rtsp://10.7.2.50:554/VOD/halte_unj_crd.mp4",
      "stream_node_num": 0
    }
  ]
}

Get All Stream in a Node

This API will give you all streams in spesific node.

GEThttp://{{ip}}/streams/{node_number}
Path parameters
node_number*string
Response

Success

Headers
Body
stream_numbernumber
Example: 11
streamsarray of object
Request
const response = await fetch('http://{{ip}}/streams/{node_number}', {
    method: 'GET',
    headers: {},
});
const data = await response.json();
Response
{
  "stream_number": 11,
  "streams": [
    {
      "active": true,
      "stream_address": "rtsp://10.7.2.50:554/VOD/halte_unj_crd.mp4",
      "stream_custom_data": {},
      "stream_id": "c73a1992f67961d1",
      "stream_latitude": 0,
      "stream_longitude": 0,
      "stream_name": "halte slave 11",
      "stream_node_num": 0
    },
    {
      "active": true,
      "stream_address": "rtsp://10.7.2.50:554/VOD/police-shooter-nashville.mp4",
      "stream_custom_data": {},
      "stream_id": "f8c4e792f1606a36",
      "stream_latitude": 0,
      "stream_longitude": 0,
      "stream_name": "Test Node 1 False",
      "stream_node_num": 0
    },
    {
      "active": true,
      "stream_address": "rtsp://10.7.2.50:554/VOD/halte_unj_crd.mp4",
      "stream_custom_data": {},
      "stream_id": "44649ea3b72155e3",
      "stream_latitude": 0,
      "stream_longitude": 0,
      "stream_name": "asdqwe",
      "stream_node_num": 0
    },
    {
      "active": true,
      "stream_address": "rtsp://10.7.2.50:554/VOD/jalan-santai-yapen-selatan-00_01_00-00_02_00.mp4",
      "stream_custom_data": {},
      "stream_id": "1f49ae135b4fa44b",
      "stream_latitude": 0,
      "stream_longitude": 0,
      "stream_name": "Jalan Santai",
      "stream_node_num": 0
    },
    {
      "active": true,
      "stream_address": "rtsp://10.7.2.50:554/VOD/arkadia/ESCALATOR1-LT.GF.mp4",
      "stream_custom_data": {},
      "stream_id": "7b7954701f6e4948",
      "stream_latitude": 0,
      "stream_longitude": 0,
      "stream_name": "Mall",
      "stream_node_num": 0
    },
    {
      "active": true,
      "stream_address": "rtsp://10.7.2.50:554/VOD/drone_dpr_zoom1.mp4",
      "stream_custom_data": {},
      "stream_id": "4b508b81dfccdbb0",
      "stream_latitude": 0,
      "stream_longitude": 0,
      "stream_name": "Drone CE",
      "stream_node_num": 0
    },
    {
      "active": true,
      "stream_address": "rtsp://10.7.2.50:554/VOD/halte_unj_crd.mp4",
      "stream_custom_data": {},
      "stream_id": "78d4cf7639ed1fa7",
      "stream_latitude": 0,
      "stream_longitude": 0,
      "stream_name": "qwe",
      "stream_node_num": 0
    },
    {
      "active": true,
      "stream_address": "rtsp://10.7.2.50:554/VOD/halte_unj_crd.mp4",
      "stream_custom_data": {},
      "stream_id": "45bb1fd40f439797",
      "stream_latitude": 0,
      "stream_longitude": 0,
      "stream_name": "zxc",
      "stream_node_num": 0
    },
    {
      "active": true,
      "stream_address": "rtsp://10.7.2.50:554/VOD/halte_unj_crd.mp4",
      "stream_custom_data": {},
      "stream_id": "fdd3f05f2fdf8c20",
      "stream_latitude": 0,
      "stream_longitude": 0,
      "stream_name": "qqwe",
      "stream_node_num": 0
    },
    {
      "active": true,
      "stream_address": "rtsp://10.7.2.50:554/VOD/halte_unj_crd.mp4",
      "stream_custom_data": {},
      "stream_id": "cd5b759b6f7bfc95",
      "stream_latitude": 0,
      "stream_longitude": 0,
      "stream_name": "zxczxc",
      "stream_node_num": 0
    },
    {
      "active": true,
      "stream_address": "rtsp://10.7.2.50:554/VOD/halte_unj_crd.mp4",
      "stream_custom_data": {},
      "stream_id": "ed9490e28e2d3a8a",
      "stream_latitude": 0,
      "stream_longitude": 0,
      "stream_name": "rtsp://10.7.2.50:554/VOD/halte_unj_crd.mp4",
      "stream_node_num": 0
    }
  ]
}

Create stream connection

This API will create a stream connection from RTSP address. You can enable or disable camera stream from active boolean value.

POSThttp://{{ip}}/streams/{node_number}
Path parameters
node_number*string
Body
activeboolean
Example: true
stream_addressstring
Example: "rtsp://10.7.2.50:554/VOD/halte_unj_crd.mp4"
stream_namestring
Example: "CCTV Halte - Active"
Response

Create disabled stream connection / Create active stream connection

Headers
Body
activeboolean
Example: false
codenumber
Example: 200
messagestring
Example: "stream successfully created"
node_numnumber
Example: 0
okboolean
Example: true
stream_addressstring
Example: "rtsp://10.7.2.50:554/VOD/halte_unj_crd.mp4"
stream_idstring
Example: "8a871ad5641538ac"
stream_namestring
Example: "CCTV Halte - Disabled"
Request
const response = await fetch('http://{{ip}}/streams/{node_number}', {
    method: 'POST',
    headers: {
      "Content-Type": "application/json"
    },
    body: JSON.stringify({
      "active": true,
      "stream_address": "rtsp://10.7.2.50:554/VOD/halte_unj_crd.mp4",
      "stream_name": "CCTV Halte - Active"
    }),
});
const data = await response.json();
Response
{
  "active": false,
  "code": 200,
  "message": "stream successfully created",
  "node_num": 0,
  "ok": true,
  "stream_address": "rtsp://10.7.2.50:554/VOD/halte_unj_crd.mp4",
  "stream_id": "8a871ad5641538ac",
  "stream_name": "CCTV Halte - Disabled"
}

Get Specific Stream Detail

This API will give you detail information about stream status (from resolution to fps) and also analytics status (how many analytics assigned).

GEThttp://{{ip}}/streams/{node_number}/{stream_id}
Path parameters
node_number*string
stream_id*string
Response

Result without Analytics / Result with Analytics

Headers
Body
activeboolean
Example: true
pipelinesarray of any
seatsarray of any
statusobject
stream_addressstring
Example: "rtsp://10.7.2.50:554/VOD/halte_unj_crd.mp4"
stream_custom_dataobject
stream_idstring
Example: "c73a1992f67961d1"
stream_latitudenumber
Example: 0
stream_longitudenumber
Example: 0
stream_namestring
Example: "halte slave 11"
stream_node_numnumber
Example: 0
stream_statsobject
Request
const response = await fetch('http://{{ip}}/streams/{node_number}/{stream_id}', {
    method: 'GET',
    headers: {},
});
const data = await response.json();
Response
{
  "active": true,
  "pipelines": [],
  "seats": [],
  "status": {
    "pipelines": [],
    "services": []
  },
  "stream_address": "rtsp://10.7.2.50:554/VOD/halte_unj_crd.mp4",
  "stream_custom_data": {},
  "stream_id": "c73a1992f67961d1",
  "stream_latitude": 0,
  "stream_longitude": 0,
  "stream_name": "halte slave 11",
  "stream_node_num": 0,
  "stream_stats": {
    "fps": 15,
    "frame_height": 646,
    "frame_width": 1146,
    "last_error_msg": "Stream is running..",
    "state": "RUNNING"
  }
}

Update stream connection

This API will update information for stream connection. Make sure to include all body request when you use this API.

PUThttp://{{ip}}/streams/{node_number}/{stream_id}
Path parameters
node_number*string
stream_id*string
Body
activeboolean
Example: true
stream_addressstring
Example: "rtsp://10.7.2.50:554/VOD/halte_unj_crd.mp4"
stream_latitudenumber
Example: -6.261376228442297
stream_longitudenumber
Example: 106.82364878415255
stream_namestring
Example: "CCTV Halte Jakarta"
Response

Success

Headers
Body
activeboolean
Example: true
codenumber
Example: 200
messagestring
Example: "stream successfully updated"
node_numnumber
Example: 0
stream_addressstring
Example: "rtsp://10.7.2.50:554/VOD/halte_unj_crd.mp4"
stream_idstring
Example: "b90694a235dc4bf3"
stream_namestring
Example: "CCTV Halte Jakarta"
Request
const response = await fetch('http://{{ip}}/streams/{node_number}/{stream_id}', {
    method: 'PUT',
    headers: {
      "Content-Type": "application/json"
    },
    body: JSON.stringify({
      "active": true,
      "stream_address": "rtsp://10.7.2.50:554/VOD/halte_unj_crd.mp4",
      "stream_latitude": -6.261376228442297,
      "stream_longitude": 106.82364878415255,
      "stream_name": "CCTV Halte Jakarta"
    }),
});
const data = await response.json();
Response
{
  "active": true,
  "code": 200,
  "message": "stream successfully updated",
  "node_num": 0,
  "stream_address": "rtsp://10.7.2.50:554/VOD/halte_unj_crd.mp4",
  "stream_id": "b90694a235dc4bf3",
  "stream_name": "CCTV Halte Jakarta"
}

Delete stream connection

This API will delete (permanently) stream connection. If you have analytic assigned from this stream connection, it will automatically delete the analytic.

DELETEhttp://{{ip}}/streams/{node_number}/{stream_id}
Path parameters
node_number*string
stream_id*string
Response

Delete stream connection

Headers
Body
codenumber
Example: 200
messagestring
Example: "stream successfully deleted"
node_numnumber
Example: 0
stream_idstring
Example: "b90694a235dc4bf3"
Request
const response = await fetch('http://{{ip}}/streams/{node_number}/{stream_id}', {
    method: 'DELETE',
    headers: {},
});
const data = await response.json();
Response
{
  "code": 200,
  "message": "stream successfully deleted",
  "node_num": 0,
  "stream_id": "b90694a235dc4bf3"
}

Analytics Pipeline

Pipeline is a process where we assign specific analytic(s) to a stream.

POST Face Recognition Analytic

POST Face Recognition Analytic

POSThttp://{{ip}}/pipeline/{node_number}/{stream_id}/NFV4-FR
Path parameters
node_number*string
stream_id*string
Body
areasarray of object
bbox_filter_activeboolean
Example: true
bbox_filter_thresholdnumber
Example: 3
dumping_confidence_thresholdnumber
Example: 0
dumping_intervalnumber
Example: 0
fr_primary_thresholdnumber
Example: 0.4
fr_secondary_thresholdnumber
Example: 0.4
frontal_onlyboolean
Example: true
matching_iou_thresholdnumber
Example: 0.7
sampling_time_msnumber
Example: 50
Response

Success without blacklist area / Success with blacklist area

Headers
Body
analytic_idstring
Example: "NFV4-FR"
codenumber
Example: 200
messagestring
Example: "pipeline successfully created"
node_numnumber
Example: 0
stream_idstring
Example: "1f49ae135b4fa44b"
Request
const response = await fetch('http://{{ip}}/pipeline/{node_number}/{stream_id}/NFV4-FR', {
    method: 'POST',
    headers: {
      "Content-Type": "application/json"
    },
    body: JSON.stringify({
      "areas": [
        {
          "name": "Blacklist Area 1",
          "points": [
            {
              "x": 0,
              "y": 0.5
            },
            {
              "x": 1,
              "y": 0.5
            }
          ]
        }
      ],
      "bbox_filter_active": true,
      "bbox_filter_threshold": 3,
      "dumping_confidence_threshold": 0,
      "dumping_interval": 0,
      "fr_primary_threshold": 0.4,
      "fr_secondary_threshold": 0.4,
      "frontal_only": true,
      "matching_iou_threshold": 0.7,
      "sampling_time_ms": 50
    }),
});
const data = await response.json();
Response
{
  "analytic_id": "NFV4-FR",
  "code": 200,
  "message": "pipeline successfully created",
  "node_num": 0,
  "stream_id": "1f49ae135b4fa44b"
}
Detailed Explanations FR
  • areas: An array of unique blacklist areas per frame, used to remove areas from detection.

    • name: A string indicating the name of the blacklist area, located within the areas array object.

    • points: An array object containing the points defining the blacklist area, nested inside the areas array object.

  • dumping_interval: An integer specifying the minimum time interval for dumping; increasing this value reduces the intensity of dumping.

  • dumping_confidence_threshold: A float that sets the minimum threshold for dumping a certain identity; increasing the value enhances precision but reduces sensitivity.

  • fr_primary_threshold: A float for the primary face detection threshold, customizable to the user's needs.

  • fr_secondary_threshold: A float for the secondary face detection threshold, also customizable.

  • sampling_time_ms: An integer defining the time interval for passing detected faces from the primary to the secondary face detector; modifying this value affects the intensity in the secondary model.

  • frontal_only: A boolean indicating whether to pass only frontal faces to the secondary face detector and facial recognition; turning this off may improve sensitivity on non-frontal cameras/views but could reduce accuracy.

  • matching_iou_threshold: A float determining the minimum value of intersection between primary and secondary detections needed to be considered a true detection; decreasing the IOU (Intersection Over Union) may increase sensitivity.

  • bbox_filter_active: A boolean that activates or deactivates face filtering based on the bounding box; setting it to True activates the filter.

  • bbox_filter_threshold: A float that sets the minimum threshold for categorizing an object as an outlier based on a z-score; a z-score greater than 3.0 means the object is detected as an outlier or excluded from detections.

DELETE Face Recognition Pipeline

DELETE Face Recognition Pipeline

DELETEhttp://{{ip}}/pipeline/{node_number}/{stream_id}/NFV4-FR
Path parameters
node_number*string
stream_id*string
Response

Success delete analytic pipeline

Headers
Body
analytic_idstring
Example: "NFV4-FR"
codenumber
Example: 200
messagestring
Example: "pipeline successfully deleted"
node_numnumber
Example: 0
stream_idstring
Example: "1f49ae135b4fa44b"
Request
const response = await fetch('http://{{ip}}/pipeline/{node_number}/{stream_id}/NFV4-FR', {
    method: 'DELETE',
    headers: {},
});
const data = await response.json();
Response
{
  "analytic_id": "NFV4-FR",
  "code": 200,
  "message": "pipeline successfully deleted",
  "node_num": 0,
  "stream_id": "1f49ae135b4fa44b"
}

POST People Analytics

POST People Analytics

POSThttp://{{ip}}/pipeline/{node_number}/{stream_id}/NFV4-MPA
Path parameters
node_number*string
stream_id*string
Body
sub_analyticsarray of object
Response

Success create all logics / Success create density logic / Success create dwelling logic / Success create counting logic

Headers
Body
analytic_idstring
Example: "NFV4-MPA"
codenumber
Example: 200
messagestring
Example: "pipeline successfully created"
node_numnumber
Example: 0
stream_idstring
Example: "1f49ae135b4fa44b"
Request
const response = await fetch('http://{{ip}}/pipeline/{node_number}/{stream_id}/NFV4-MPA', {
    method: 'POST',
    headers: {
      "Content-Type": "application/json"
    },
    body: JSON.stringify({
      "sub_analytics": [
        {
          "areas": [
            {
              "bidirection": true,
              "in": true,
              "name": "Area 1",
              "points": [
                {
                  "x": 0,
                  "y": 0.5
                },
                {
                  "x": 1,
                  "y": 0.5
                }
              ]
            }
          ],
          "is_active": true,
          "name": "counting",
          "object_confidence_threshold": 0.7
        }
      ]
    }),
});
const data = await response.json();
Response
{
  "analytic_id": "NFV4-MPA",
  "code": 200,
  "message": "pipeline successfully created",
  "node_num": 0,
  "stream_id": "1f49ae135b4fa44b"
}

POST Vehicle Analytics

POST Vehicle Analytics

POSThttp://{{ip}}/pipeline/{node_number}/{stream_id}/NFV4-MVA
Path parameters
node_number*string
stream_id*string
Body
sub_analyticsarray of object
Response

Success create all logics / Success create density logic / Success create dwelling logic / Success create counting logic

Headers
Body
analytic_idstring
Example: "NFV4-MPA"
codenumber
Example: 200
messagestring
Example: "pipeline successfully created"
node_numnumber
Example: 0
stream_idstring
Example: "1f49ae135b4fa44b"
Request
const response = await fetch('http://{{ip}}/pipeline/{node_number}/{stream_id}/NFV4-MVA', {
    method: 'POST',
    headers: {
      "Content-Type": "application/json"
    },
    body: JSON.stringify({
      "sub_analytics": [
        {
          "areas": [
            {
              "bidirection": true,
              "in": true,
              "name": "Area 1",
              "points": [
                {
                  "x": 0,
                  "y": 0.5
                },
                {
                  "x": 1,
                  "y": 0.5
                }
              ]
            }
          ],
          "is_active": true,
          "name": "counting",
          "object_confidence_threshold": 0.7
        }
      ]
    }),
});
const data = await response.json();
Response
{
  "analytic_id": "NFV4-MPA",
  "code": 200,
  "message": "pipeline successfully created",
  "node_num": 0,
  "stream_id": "1f49ae135b4fa44b"
}

POST License Plate Recognition 2

POST License Plate Recognition 2

POSThttp://{{ip}}/pipeline/{node_number}/{stream_id}/NFV4-LPR2
Path parameters
node_number*string
stream_id*string
Body
areasarray of object
max_group_membernumber
Example: 20
min_group_membernumber
Example: 2
no_input_period_thresholdnumber
Example: 20
plate_cache_lifetimenumber
Example: 5
plate_confidence_thresholdnumber
Example: 0.7
roi_as_blacklistboolean
Example: false
similarity_score_thresholdnumber
Example: 0.7
vehicle_confidence_thresholdnumber
Example: 0.7
Response

Success

Headers
Body
analytic_idstring
Example: "NFV4-LPR2"
codenumber
Example: 200
messagestring
Example: "pipeline successfully created"
node_numnumber
Example: 0
stream_idstring
Example: "0e08b38c86161ae9"
Request
const response = await fetch('http://{{ip}}/pipeline/{node_number}/{stream_id}/NFV4-LPR2', {
    method: 'POST',
    headers: {
      "Content-Type": "application/json"
    },
    body: JSON.stringify({
      "areas": [
        {
          "name": "kiri",
          "points": [
            {
              "x": 0.05,
              "y": 0.05
            },
            {
              "x": 0.05,
              "y": 0.95
            },
            {
              "x": 0.48,
              "y": 0.95
            },
            {
              "x": 0.48,
              "y": 0.05
            }
          ]
        }
      ],
      "max_group_member": 20,
      "min_group_member": 2,
      "no_input_period_threshold": 20,
      "plate_cache_lifetime": 5,
      "plate_confidence_threshold": 0.7,
      "roi_as_blacklist": false,
      "similarity_score_threshold": 0.7,
      "vehicle_confidence_threshold": 0.7
    }),
});
const data = await response.json();
Response
{
  "analytic_id": "NFV4-LPR2",
  "code": 200,
  "message": "pipeline successfully created",
  "node_num": 0,
  "stream_id": "0e08b38c86161ae9"
}
Detailed Explanations for License Plate Recognition
  • areas: An array of unique blacklist areas per frame, used to remove areas from detection.

    • name: A string indicating the name of the blacklist area, located within the areas array object.

    • points: An array object containing the points defining the blacklist area, nested inside the areas array object.

  • max_group_member: Candidates for correct plates (max).

  • min_grup_member: Candidates for correct plates (min).

  • no_input_period_threshold: Time to detect plate (in ms).

  • plate_cache_lifetime: Time required for the plate to be detected (in ms).

  • plate_confidence_threshold: Confidence threshold for plate detection.

  • roi_as_blacklist: TRUE if you have a blacklisted area, FALSE if you don't.

  • similarity_score_threshold: IoU threshold.

  • vehicle_confidence_threshold: Confidence threshold for vehicle detection.

For the API below, the body request will be used in People Counting, Vehicle Counting, and Head Counting the only difference is the analytics codification. For People Counting use NFV4-PC, Vehicle Counting use NFV4-VC and Head Counting use NFV4-HC.

POST People Counting

POST People Counting

POSThttp://{{ip}}/pipeline/{node_number}/{stream_id}/NFV4-PC
Path parameters
node_number*string
stream_id*string
Body
areasarray of object
object_confidence_thresholdnumber
Example: 0.7
Response

Success

Headers
Body
analytic_idstring
Example: "NFV4-PC"
codenumber
Example: 200
messagestring
Example: "pipeline successfully created"
node_numnumber
Example: 0
stream_idstring
Example: "0e08b38c86161ae9"
Request
const response = await fetch('http://{{ip}}/pipeline/{node_number}/{stream_id}/NFV4-PC', {
    method: 'POST',
    headers: {
      "Content-Type": "application/json"
    },
    body: JSON.stringify({
      "areas": [
        {
          "bidirection": true,
          "in": true,
          "name": "Area 1",
          "points": [
            {
              "x": 0,
              "y": 0.5
            },
            {
              "x": 1,
              "y": 0.5
            }
          ]
        }
      ],
      "object_confidence_threshold": 0.7
    }),
});
const data = await response.json();
Response
{
  "analytic_id": "NFV4-PC",
  "code": 200,
  "message": "pipeline successfully created",
  "node_num": 0,
  "stream_id": "0e08b38c86161ae9"
}

POST Water Level Monitoring

POST Water Level Monitoring

POSThttp://{{ip}}/pipeline/{node_number}/{stream_id}/NFV4-WLM
Path parameters
node_number*string
stream_id*string
Body
areasarray of object
intervalnumber
Example: 10
Response

Success

Headers
Body
analytic_idstring
Example: "NFV4-WLM"
codenumber
Example: 200
messagestring
Example: "pipeline successfully created"
node_numnumber
Example: 0
stream_idstring
Example: "0e08b38c86161ae9"
Request
const response = await fetch('http://{{ip}}/pipeline/{node_number}/{stream_id}/NFV4-WLM', {
    method: 'POST',
    headers: {
      "Content-Type": "application/json"
    },
    body: JSON.stringify({
      "areas": [
        {
          "name": "Area 1",
          "points": [
            {
              "x": 0.05,
              "y": 0.05
            },
            {
              "x": 0.05,
              "y": 0.95
            },
            {
              "x": 0.48,
              "y": 0.95
            },
            {
              "x": 0.48,
              "y": 0.05
            }
          ]
        }
      ],
      "interval": 10
    }),
});
const data = await response.json();
Response
{
  "analytic_id": "NFV4-WLM",
  "code": 200,
  "message": "pipeline successfully created",
  "node_num": 0,
  "stream_id": "0e08b38c86161ae9"
}

POST Crowd Estimation

POST Crowd Estimation

POSThttp://{{ip}}/pipeline/{node_number}/{stream_id}/NFV4-CE
Path parameters
node_number*string
stream_id*string
Body
areasarray of object
intervalnumber
Example: 10
Response

Success

Headers
Body
analytic_idstring
Example: "NFV4-CE"
codenumber
Example: 200
messagestring
Example: "pipeline successfully created"
node_numnumber
Example: 0
stream_idstring
Example: "0e08b38c86161ae9"
Request
const response = await fetch('http://{{ip}}/pipeline/{node_number}/{stream_id}/NFV4-CE', {
    method: 'POST',
    headers: {
      "Content-Type": "application/json"
    },
    body: JSON.stringify({
      "areas": [
        {
          "name": "Area 1",
          "points": [
            {
              "x": 0.05,
              "y": 0.05
            },
            {
              "x": 0.05,
              "y": 0.95
            },
            {
              "x": 0.48,
              "y": 0.95
            },
            {
              "x": 0.48,
              "y": 0.05
            }
          ]
        }
      ],
      "interval": 10
    }),
});
const data = await response.json();
Response
{
  "analytic_id": "NFV4-CE",
  "code": 200,
  "message": "pipeline successfully created",
  "node_num": 0,
  "stream_id": "0e08b38c86161ae9"
}

POST PPE

POST PPE

POSThttp://{{ip}}/pipeline/{node_number}/{stream_id}/NFV4-PPE
Path parameters
node_number*string
stream_id*string
Body
helmet_iou_thresholdnumber
Example: 0.85
interval_msnumber
Example: 5
minimal_countnumber
Example: 10
person_score_thresholdnumber
Example: 0.6
vest_iou_thresholdnumber
Example: 0.85
Response

Success

Headers
Body
analytic_idstring
Example: "NFV4-PPE"
codenumber
Example: 200
messagestring
Example: "pipeline successfully created"
node_numnumber
Example: 0
stream_idstring
Example: "0e08b38c86161ae9"
Request
const response = await fetch('http://{{ip}}/pipeline/{node_number}/{stream_id}/NFV4-PPE', {
    method: 'POST',
    headers: {
      "Content-Type": "application/json"
    },
    body: JSON.stringify({
      "helmet_iou_threshold": 0.85,
      "interval_ms": 5,
      "minimal_count": 10,
      "person_score_threshold": 0.6,
      "vest_iou_threshold": 0.85
    }),
});
const data = await response.json();
Response
{
  "analytic_id": "NFV4-PPE",
  "code": 200,
  "message": "pipeline successfully created",
  "node_num": 0,
  "stream_id": "0e08b38c86161ae9"
}

Others

GET Analytic Configuration

GET Analytic Configuration

GEThttp://{{ip}}/pipeline/0/bd72d9c54a9ea5d7/NFV4-PC
Response

Face Recognition / People Analytics / People Counting

Headers
Body
analytic_idstring
Example: "NFV4-FR"
codenumber
Example: 200
configobject
node_numnumber
Example: 0
stream_idstring
Example: "bd72d9c54a9ea5d7"
Request
const response = await fetch('http://{{ip}}/pipeline/0/bd72d9c54a9ea5d7/NFV4-PC', {
    method: 'GET',
    headers: {},
});
const data = await response.json();
Response
{
  "analytic_id": "NFV4-FR",
  "code": 200,
  "config": {
    "areas": [
      {
        "bidirection": false,
        "name": "Area 1",
        "points": [
          {
            "x": 0.8367892731535757,
            "y": 0.3875
          },
          {
            "x": 0.046636869871043374,
            "y": 0.70625
          }
        ]
      }
    ],
    "sub_analytics": [
      {
        "areas": [
          {
            "bidirection": false,
            "name": "Area 1",
            "points": [
              {
                "x": 0.8625805978898007,
                "y": 0.4
              },
              {
                "x": 0.046636869871043374,
                "y": 0.6666666666666666
              }
            ]
          }
        ],
        "is_active": true,
        "name": "counting"
      }
    ]
  },
  "node_num": 0,
  "stream_id": "bd72d9c54a9ea5d7"
}

GET Resource Statistics

GET Resource Statistics

GEThttp://{{ip}}/resource_stats
Response

Success

Headers
Body
devicesarray of object
Request
const response = await fetch('http://{{ip}}/resource_stats', {
    method: 'GET',
    headers: {},
});