Skip to main content

REST APIs for 24.2.20 and 24.2.10

VEN Statistics APIs

The Dashboard uses the following API to aggregate various data from the system and help you focus on the data you are interested in:

POST api/v2/orgs/:xorg_id/vens/statistics

You can obtain summary statistics for VENs by specifying which statistics you are interested in from a set of options. The API also supports obtaining a count for a specific property value (such as a count of VENs from a specific product version).

VEN information can include: "status", "version", "health", "condition", "os_id", "enforcement_mode", and "ven_type".

VEN Dashboard Reference

This topic contains properties and examples for the VEN dashboard.

Examples of VEN Dashboard APIs

vens_statistics_post

{
    "$schema": "http://json-schema.org/draft-04/schema#",
    "type": "object",
    "required": [
	"property_counts"
    ],
    "properties": {
	"property_counts": {
	    "type": "array",
	    "items": {
		"type": "object",
		"required": [
		    "property"
		],
		"properties": {
		    "property": {
			"type": "string",
			"enum": [
			    "status",
			    "version",
			    "health",
			    "condition",
			    "os_id",
			    "enforcement_mode",
			    "ven_type"
			]
		    },
		    "values": {
			"type": "array",
			"items": {
			    "type": "string"
			}
			},
		    "filters": {
			"type": "array",
			"items": {
			    "type": "object",
			    "required": [
			       "filter_property"
			    ],
			"properties": {
			    "filter_property": {
				"type": "string",
				"enum": [
				    "status",
				    "version",
				    "health",
				    "condition",
				    "os_id",
				    "enforcement_mode",
				    "ven_type"
				]
			    },
			    "values": {
				"type": "array",
				"items": {
				    "type": "string"
				}
			    }
			}
		    }
		}
	    }
	}
    }
}

Sample Request

{
   “property_counts”: [
	{  
	   "property": "version",
	   "values": [
              "19.3", 
              "18.3"]
	   "filters": [
		{  
		   "filter_property": "status",
		   "values": [ 
                      "active", 
                      ""
                  ]
		},
		{  
		   "filter_property": "containerized",
		   "values": [
                     "true"
                  ]
		}
	    ]
   },
   {
	  "property": "version",
	   "filters": [
		{
		"filter_property": "status",
		"values": [
                   "active"]
		}
	   ]
      },
      {
	   "property": "health"
      }  
   ]
}

Sample Response for version and health

{
	“property_counts”: [
	   {  
	      "property": "version",
	      “counts”:[
		{
		   "value": "18.1",
		   "count": 1
		},
		{
		   "value": "18.2",
		   "count": 1
		},
		{
		   "value": "18.3",
		   "count": 2
		},
		{
		   "value": "19.1",
		   "count": 2
		}
	]
},
{
	   "property": "health",
	   “counts”:[
		{
		   "value": "healthy",
		   "count": 3
		},
		{
		   "value": "warning",
		   "count": 3
		},
		{
		   "value": "err",
		   "count": 2
		}
	    ]
	}  
   ]
}

Sample Response for ven_type

[{
	property: "ven_type",
	total_filtered_count: 205,
	counts: [
		filtered_count:422,
		unfiltered_count: 424,
		value: "active",
	]
}]