How to execute a conjunction of OR and AND in AEM GraphQL?
I want to have a filter like this:
const value =
{
AND: [
{
OR: [
{ productVisibility_contains_none: ['authenticated', 'eap'] },
{
AND: [
{ productVisibility_contains_all: ['authenticated'] },
{ productVisibility_contains_none: ['eap'] },
],
},
],
},
{ title_exists: true },
{
OR: [
{ title_contains: $arg1 },
{ author_contains: $arg1 },
{ articleSource_contains: $arg1 },
{ articleByline_contains: $arg1 },
{ articleSubtitle_contains: $arg1 },
{ primaryCategoryTag_contains_some: [$arg1, $arg1_cap, $arg1_low] },
{ categoryTags_contains_some: [$arg1, $arg1_cap, $arg1_low] },
],
},
{ primaryCategoryTag_contains: $categoryTitles },
],
};
as you can see there's conjunction of OR and AND operations, however in AEM GQL you only get either OR or AND for all the high level filters. I wanted to know if it would be possible to perform the above in AEM or not?