Copy const query = 'query GetApplicationsConditionalFilters($getApplicationsInput: GetApplicationsInput) { getApplicationsConditionalFilters(getApplicationsInput: $getApplicationsInput) { total totalFiltered filters { type items { id filterId label count percent changeNumber policyId extraInfo { key value } } } } }';
fetch("https://api.cloud.ox.security/api/apollo-gateway", {
method: "POST",
headers: {
"Content-Type": "application/json",
"Authorization": "YOUR_API_TOKEN"
},
body: JSON.stringify({
query: query,
// This is an example input showing all available input fields. Only fields marked as required in the schema are mandatory.
variables: {
getApplicationsInput: {
scanId: "c9da693d-8906-4a32-93c9-2ffdb1cebb99",
dateRange: {
from: 1749000000000,
to: 1749900000000
},
orderBy: {
field: "BusinessPriority",
direction: "ASC",
category: "example"
},
limit: 100,
page: 1,
offset: 0,
applicationFilters: ["New"],
irrelevancyFilters: ["Archived"],
systemFilter: {
name: "cicd",
type: "example"
},
owners: ["example"],
tagIds: ["example"],
search: "example",
filterSearch: [
{
fieldName: "example",
value: ["example"]
}
],
isAppIdOnly: true,
appId: "30966426",
topOffset: 42,
scrollDirection: "example",
openItems: ["digest"],
irrelevant: true,
ignoreLimit: true,
conditionalFilters: [
{
condition: "AND",
fieldName: "digest",
values: ["example"],
greaterThan: 13.37,
lessThan: 13.37
}
]
}
}
})
})
.then(response => response.json())
.then(result => console.log(JSON.stringify(result, null, 2)))
.catch(error => console.error('Error:', error));