Get query spec results
Last updated
Was this helpful?
Last updated
Was this helpful?
GetAssessmentQuerySpecResult Returns the total count of results for a query specification.
The response will include a number_value
representing the total number of results.
Sample request:
curl -X 'POST' \
"$BASE_URL/api/v1/assessments/query_spec:result" \
-H "authorization: Bearer $VEZA_TOKEN" \
--data-raw '{
"query_type": "SOURCE_TO_DESTINATION",
"source_node_types": {
"nodes": [
{
"node_type": "OktaUser",
"tags": [],
"conditions": [],
"condition_expression": null,
"node_id": "",
"excluded_tags": [],
"count_conditions": [],
"direct_relationship_only": false,
"node_type_grouping_constraint": null
}
],
"nodes_operator": "AND"
},
"destination_node_types": null,
"required_intermediate_node_types": null,
"avoided_intermediate_node_types": null,
"raw_permissions": null,
"effective_permissions": null,
"customized_variables": [],
"no_relation": false,
"snapshot_id": "0",
"access_filter": null,
"node_relationship_type": "EFFECTIVE_ACCESS",
"relates_to_exp": {
"specs": [
{
"node_types": {
"nodes": [
{
"node_type": "SnowflakeRole",
"tags": [],
"conditions": [],
"condition_expression": {
"specs": [
{
"fn": "EQ",
"property": "id",
"value": "dn44266.us-east-2.aws.snowflakecomputing.com/role/BILLING",
"not": false,
"value_property_name": "",
"value_property_from_other_node": false
}
],
"child_expressions": [],
"operator": "AND",
"not": false
},
"node_id": "",
"excluded_tags": [],
"count_conditions": [],
"direct_relationship_only": false,
"node_type_grouping_constraint": null
}
],
"nodes_operator": "AND"
},
"required_intermediate_node_types": null,
"avoided_intermediate_node_types": null,
"raw_permissions": null,
"effective_permissions": {
"values": [],
"operator": "OR"
},
"no_relation": false,
"direction": "ANY_DIRECTION"
}
],
"child_expressions": [
{
"specs": [
{
"node_types": {
"nodes": [
{
"node_type": "SnowflakeRole",
"tags": [],
"conditions": [],
"condition_expression": {
"specs": [
{
"fn": "EQ",
"property": "id",
"value": "dn44266.us-east-2.aws.snowflakecomputing.com/role/AUDITOR",
"not": false,
"value_property_name": "",
"value_property_from_other_node": false
}
],
"child_expressions": [],
"operator": "AND",
"not": false
},
"node_id": "",
"excluded_tags": [],
"count_conditions": [],
"direct_relationship_only": false,
"node_type_grouping_constraint": null
}
],
"nodes_operator": "AND"
},
"required_intermediate_node_types": null,
"avoided_intermediate_node_types": null,
"raw_permissions": null,
"effective_permissions": {
"values": [],
"operator": "OR"
},
"no_relation": false,
"direction": "ANY_DIRECTION"
},
{
"node_types": {
"nodes": [
{
"node_type": "SnowflakeRole",
"tags": [],
"conditions": [],
"condition_expression": {
"specs": [
{
"fn": "EQ",
"property": "id",
"value": "dn44266.us-east-2.aws.snowflakecomputing.com/role/ROLE_A",
"not": false,
"value_property_name": "",
"value_property_from_other_node": false
}
],
"child_expressions": [],
"operator": "AND",
"not": false
},
"node_id": "",
"excluded_tags": [],
"count_conditions": [],
"direct_relationship_only": false,
"node_type_grouping_constraint": null
}
],
"nodes_operator": "AND"
},
"required_intermediate_node_types": null,
"avoided_intermediate_node_types": null,
"raw_permissions": null,
"effective_permissions": {
"values": [],
"operator": "OR"
},
"no_relation": false,
"direction": "ANY_DIRECTION"
}
],
"child_expressions": [],
"operator": "OR",
"not": false,
"and_op_type": "INFERRED"
}
],
"operator": "AND",
"not": false,
"and_op_type": "SOURCE_INTERSECT"
},
"path_summary_node_types": null,
"all_entity_condition": null,
"page_size": "0",
"page_token": ""
}'
Sample response:
The response will contain a number_value
of total results:
{
"number_value": 97
}
SYSTEM_CREATED
Available options: EFFECTIVE_ACCESS
Available options: A boolean expression describing the "relates to" types.
AssessmentQueryResultValueType determines which of the fields (values
or path_values
) will be populated
in the resulting AssessmentQueryNodesResponse message.
UNDEFINED is a valid selection and is intended for backward compatibility.
When UNDEFINED is selected, the actual result value type will be determined by the backend (BE).
values
field containing source nodes and their destination countspath_values
with source and destination nodes, excluding path summary.path_values
along with path summary.UNDEFINED
Available options: The maximum number of results to be returned. Fewer results may be returned even when more pages exist.
The token specifying the specific page of results to retrieve.
POST /api/v1/assessments/query_spec:result HTTP/1.1
Host:
Bearer: YOUR_API_KEY
Content-Type: application/json
Accept: */*
Content-Length: 10136
{
"query_type": "SYSTEM_CREATED",
"source_node_types": {
"nodes": [
{
"node_type": "text",
"tags": [
{
"key": "text",
"value": "text"
}
],
"conditions": [
{
"fn": "EQ",
"property": "text",
"value": null,
"not": true,
"value_property_name": "text",
"value_property_from_other_node": true
}
],
"condition_expression": {
"specs": [
{
"fn": "EQ",
"property": "text",
"value": null,
"not": true,
"value_property_name": "text",
"value_property_from_other_node": true
}
],
"child_expressions": [
"[Circular Reference]"
],
"operator": "AND",
"not": true
},
"node_id": "text",
"excluded_tags": [
{
"key": "text",
"value": "text"
}
],
"count_conditions": [
{
"fn": "EQ",
"value": "text",
"value_as": "COUNT"
}
],
"direct_relationship_only": true,
"node_type_grouping_constraint": {
"node_types": [
"text"
],
"constraint_type": "EXCLUDE"
},
"properties_to_get": [
"text"
]
}
],
"nodes_operator": "AND"
},
"destination_node_types": {
"nodes": [
{
"node_type": "text",
"tags": [
{
"key": "text",
"value": "text"
}
],
"conditions": [
{
"fn": "EQ",
"property": "text",
"value": null,
"not": true,
"value_property_name": "text",
"value_property_from_other_node": true
}
],
"condition_expression": {
"specs": [
{
"fn": "EQ",
"property": "text",
"value": null,
"not": true,
"value_property_name": "text",
"value_property_from_other_node": true
}
],
"child_expressions": [
"[Circular Reference]"
],
"operator": "AND",
"not": true
},
"node_id": "text",
"excluded_tags": [
{
"key": "text",
"value": "text"
}
],
"count_conditions": [
{
"fn": "EQ",
"value": "text",
"value_as": "COUNT"
}
],
"direct_relationship_only": true,
"node_type_grouping_constraint": {
"node_types": [
"text"
],
"constraint_type": "EXCLUDE"
},
"properties_to_get": [
"text"
]
}
],
"nodes_operator": "AND"
},
"required_intermediate_node_types": {
"nodes": [
{
"node_type": "text",
"tags": [
{
"key": "text",
"value": "text"
}
],
"conditions": [
{
"fn": "EQ",
"property": "text",
"value": null,
"not": true,
"value_property_name": "text",
"value_property_from_other_node": true
}
],
"condition_expression": {
"specs": [
{
"fn": "EQ",
"property": "text",
"value": null,
"not": true,
"value_property_name": "text",
"value_property_from_other_node": true
}
],
"child_expressions": [
"[Circular Reference]"
],
"operator": "AND",
"not": true
},
"node_id": "text",
"excluded_tags": [
{
"key": "text",
"value": "text"
}
],
"count_conditions": [
{
"fn": "EQ",
"value": "text",
"value_as": "COUNT"
}
],
"direct_relationship_only": true,
"node_type_grouping_constraint": {
"node_types": [
"text"
],
"constraint_type": "EXCLUDE"
},
"properties_to_get": [
"text"
]
}
],
"nodes_operator": "AND"
},
"avoided_intermediate_node_types": {
"nodes": [
{
"node_type": "text",
"tags": [
{
"key": "text",
"value": "text"
}
],
"conditions": [
{
"fn": "EQ",
"property": "text",
"value": null,
"not": true,
"value_property_name": "text",
"value_property_from_other_node": true
}
],
"condition_expression": {
"specs": [
{
"fn": "EQ",
"property": "text",
"value": null,
"not": true,
"value_property_name": "text",
"value_property_from_other_node": true
}
],
"child_expressions": [
"[Circular Reference]"
],
"operator": "AND",
"not": true
},
"node_id": "text",
"excluded_tags": [
{
"key": "text",
"value": "text"
}
],
"count_conditions": [
{
"fn": "EQ",
"value": "text",
"value_as": "COUNT"
}
],
"direct_relationship_only": true,
"node_type_grouping_constraint": {
"node_types": [
"text"
],
"constraint_type": "EXCLUDE"
},
"properties_to_get": [
"text"
]
}
],
"nodes_operator": "AND"
},
"raw_permissions": {
"values": [
"text"
],
"operator": "AND"
},
"effective_permissions": {
"values": [
"METADATA_WRITE"
],
"operator": "AND"
},
"customized_variables": [
{
"key": "text",
"value": "text"
}
],
"no_relation": true,
"snapshot_id": "text",
"node_relationship_type": "EFFECTIVE_ACCESS",
"relates_to_exp": {
"specs": [
{
"node_types": {
"nodes": [
{
"node_type": "text",
"tags": [
{
"key": "text",
"value": "text"
}
],
"conditions": [
{
"fn": "EQ",
"property": "text",
"value": null,
"not": true,
"value_property_name": "text",
"value_property_from_other_node": true
}
],
"condition_expression": {
"specs": [
{
"fn": "EQ",
"property": "text",
"value": null,
"not": true,
"value_property_name": "text",
"value_property_from_other_node": true
}
],
"child_expressions": [
"[Circular Reference]"
],
"operator": "AND",
"not": true
},
"node_id": "text",
"excluded_tags": [
{
"key": "text",
"value": "text"
}
],
"count_conditions": [
{
"fn": "EQ",
"value": "text",
"value_as": "COUNT"
}
],
"direct_relationship_only": true,
"node_type_grouping_constraint": {
"node_types": [
"text"
],
"constraint_type": "EXCLUDE"
},
"properties_to_get": [
"text"
]
}
],
"nodes_operator": "AND"
},
"required_intermediate_node_types": {
"nodes": [
{
"node_type": "text",
"tags": [
{
"key": "text",
"value": "text"
}
],
"conditions": [
{
"fn": "EQ",
"property": "text",
"value": null,
"not": true,
"value_property_name": "text",
"value_property_from_other_node": true
}
],
"condition_expression": {
"specs": [
{
"fn": "EQ",
"property": "text",
"value": null,
"not": true,
"value_property_name": "text",
"value_property_from_other_node": true
}
],
"child_expressions": [
"[Circular Reference]"
],
"operator": "AND",
"not": true
},
"node_id": "text",
"excluded_tags": [
{
"key": "text",
"value": "text"
}
],
"count_conditions": [
{
"fn": "EQ",
"value": "text",
"value_as": "COUNT"
}
],
"direct_relationship_only": true,
"node_type_grouping_constraint": {
"node_types": [
"text"
],
"constraint_type": "EXCLUDE"
},
"properties_to_get": [
"text"
]
}
],
"nodes_operator": "AND"
},
"avoided_intermediate_node_types": {
"nodes": [
{
"node_type": "text",
"tags": [
{
"key": "text",
"value": "text"
}
],
"conditions": [
{
"fn": "EQ",
"property": "text",
"value": null,
"not": true,
"value_property_name": "text",
"value_property_from_other_node": true
}
],
"condition_expression": {
"specs": [
{
"fn": "EQ",
"property": "text",
"value": null,
"not": true,
"value_property_name": "text",
"value_property_from_other_node": true
}
],
"child_expressions": [
"[Circular Reference]"
],
"operator": "AND",
"not": true
},
"node_id": "text",
"excluded_tags": [
{
"key": "text",
"value": "text"
}
],
"count_conditions": [
{
"fn": "EQ",
"value": "text",
"value_as": "COUNT"
}
],
"direct_relationship_only": true,
"node_type_grouping_constraint": {
"node_types": [
"text"
],
"constraint_type": "EXCLUDE"
},
"properties_to_get": [
"text"
]
}
],
"nodes_operator": "AND"
},
"raw_permissions": {
"values": [
"text"
],
"operator": "AND"
},
"effective_permissions": {
"values": [
"METADATA_WRITE"
],
"operator": "AND"
},
"no_relation": true,
"direction": "ANY_DIRECTION"
}
],
"child_expressions": [
{
"specs": [
{
"node_types": {
"nodes": [
{
"node_type": "text",
"tags": [
{
"key": "text",
"value": "text"
}
],
"conditions": [
{
"fn": "EQ",
"property": "text",
"value": null,
"not": true,
"value_property_name": "text",
"value_property_from_other_node": true
}
],
"condition_expression": {
"specs": [
{
"fn": "EQ",
"property": "text",
"value": null,
"not": true,
"value_property_name": "text",
"value_property_from_other_node": true
}
],
"child_expressions": [
"[Circular Reference]"
],
"operator": "AND",
"not": true
},
"node_id": "text",
"excluded_tags": [
{
"key": "text",
"value": "text"
}
],
"count_conditions": [
{
"fn": "EQ",
"value": "text",
"value_as": "COUNT"
}
],
"direct_relationship_only": true,
"node_type_grouping_constraint": {
"node_types": [
"text"
],
"constraint_type": "EXCLUDE"
},
"properties_to_get": [
"text"
]
}
],
"nodes_operator": "AND"
},
"required_intermediate_node_types": {
"nodes": [
{
"node_type": "text",
"tags": [
{
"key": "text",
"value": "text"
}
],
"conditions": [
{
"fn": "EQ",
"property": "text",
"value": null,
"not": true,
"value_property_name": "text",
"value_property_from_other_node": true
}
],
"condition_expression": {
"specs": [
{
"fn": "EQ",
"property": "text",
"value": null,
"not": true,
"value_property_name": "text",
"value_property_from_other_node": true
}
],
"child_expressions": [
"[Circular Reference]"
],
"operator": "AND",
"not": true
},
"node_id": "text",
"excluded_tags": [
{
"key": "text",
"value": "text"
}
],
"count_conditions": [
{
"fn": "EQ",
"value": "text",
"value_as": "COUNT"
}
],
"direct_relationship_only": true,
"node_type_grouping_constraint": {
"node_types": [
"text"
],
"constraint_type": "EXCLUDE"
},
"properties_to_get": [
"text"
]
}
],
"nodes_operator": "AND"
},
"avoided_intermediate_node_types": {
"nodes": [
{
"node_type": "text",
"tags": [
{
"key": "text",
"value": "text"
}
],
"conditions": [
{
"fn": "EQ",
"property": "text",
"value": null,
"not": true,
"value_property_name": "text",
"value_property_from_other_node": true
}
],
"condition_expression": {
"specs": [
{
"fn": "EQ",
"property": "text",
"value": null,
"not": true,
"value_property_name": "text",
"value_property_from_other_node": true
}
],
"child_expressions": [
"[Circular Reference]"
],
"operator": "AND",
"not": true
},
"node_id": "text",
"excluded_tags": [
{
"key": "text",
"value": "text"
}
],
"count_conditions": [
{
"fn": "EQ",
"value": "text",
"value_as": "COUNT"
}
],
"direct_relationship_only": true,
"node_type_grouping_constraint": {
"node_types": [
"text"
],
"constraint_type": "EXCLUDE"
},
"properties_to_get": [
"text"
]
}
],
"nodes_operator": "AND"
},
"raw_permissions": {
"values": [
"text"
],
"operator": "AND"
},
"effective_permissions": {
"values": [
"METADATA_WRITE"
],
"operator": "AND"
},
"no_relation": true,
"direction": "ANY_DIRECTION"
}
],
"child_expressions": [
{
"specs": "[Circular Reference]",
"child_expressions": "[Circular Reference]",
"operator": "AND",
"not": true,
"and_op_type": "INFERRED"
}
],
"operator": "AND",
"not": true,
"and_op_type": "INFERRED"
}
],
"operator": "AND",
"not": true,
"and_op_type": "INFERRED"
},
"path_summary_node_types": {
"nodes": [
{
"node_type": "text",
"tags": [
{
"key": "text",
"value": "text"
}
],
"conditions": [
{
"fn": "EQ",
"property": "text",
"value": null,
"not": true,
"value_property_name": "text",
"value_property_from_other_node": true
}
],
"condition_expression": {
"specs": [
{
"fn": "EQ",
"property": "text",
"value": null,
"not": true,
"value_property_name": "text",
"value_property_from_other_node": true
}
],
"child_expressions": [
"[Circular Reference]"
],
"operator": "AND",
"not": true
},
"node_id": "text",
"excluded_tags": [
{
"key": "text",
"value": "text"
}
],
"count_conditions": [
{
"fn": "EQ",
"value": "text",
"value_as": "COUNT"
}
],
"direct_relationship_only": true,
"node_type_grouping_constraint": {
"node_types": [
"text"
],
"constraint_type": "EXCLUDE"
},
"properties_to_get": [
"text"
]
}
],
"nodes_operator": "AND"
},
"all_entity_condition": {
"specs": [
{
"fn": "EQ",
"property": "text",
"value": null,
"not": true,
"value_property_name": "text",
"value_property_from_other_node": true
}
],
"child_expressions": [
{
"specs": [
{
"fn": "EQ",
"property": "text",
"value": null,
"not": true,
"value_property_name": "text",
"value_property_from_other_node": true
}
],
"child_expressions": [
{
"specs": [
{
"fn": "EQ",
"property": "text",
"value": null,
"not": true,
"value_property_name": "text",
"value_property_from_other_node": true
}
],
"child_expressions": "[Circular Reference]",
"operator": "AND",
"not": true
}
],
"operator": "AND",
"not": true
}
],
"operator": "AND",
"not": true
},
"path_summary_count_conditions": {
"conditions": [
{
"fn": "EQ",
"value": "text",
"value_as": "COUNT"
}
]
},
"result_value_type": "UNDEFINED",
"page_size": "text",
"page_token": "text"
}
{
"result_type": "text",
"number_value": "text",
"timestamp_value": "text",
"nodes_value": {
"values": [
{
"id": "text",
"type": "text",
"properties": {},
"destination_node_count": 1,
"permissions": [
{
"id": "text",
"type": "text",
"properties": {},
"destination_node_count": 1,
"permissions": "[Circular Reference]",
"engagement_access_stats": {
"engagement_score": 1,
"over_provisioned_score": 1,
"total_count": "text",
"accessed_count": "text"
},
"access_stats": {
"last_used": "2025-04-18T23:24:25.447Z",
"count": 1,
"concrete_permissions": [
"text"
],
"canonical_permissions": [
"text"
]
},
"destination_node_ids": [
"text"
],
"risk_level": "NONE",
"raw_permissions": [
"text"
],
"effective_permissions": [
"text"
],
"destination_node_percentage_of_total": 1
}
],
"engagement_access_stats": {
"engagement_score": 1,
"over_provisioned_score": 1,
"total_count": "text",
"accessed_count": "text"
},
"access_stats": {
"last_used": "2025-04-18T23:24:25.447Z",
"count": 1,
"concrete_permissions": [
"text"
],
"canonical_permissions": [
"text"
]
},
"destination_node_ids": [
"text"
],
"risk_level": "NONE",
"raw_permissions": [
"text"
],
"effective_permissions": [
"text"
],
"destination_node_percentage_of_total": 1
}
],
"next_page_token": "text",
"has_more": true
}
}