What is the difference between fikter created in Tasklist and filter created in API? (Camunda 7.4)

Hello, we have recently the following problem.

We are trying to create new filters to be used in a custom-developed frontend (needed to provide some features the built-in Camunda Tasklist does not have).

After I create a filter using REST API, I can never get any results of its execution. When I call /camunda/api/engine/engine/default/filter/7734f05d-4510-11e6-8394-06c5fe21d5b1/list or …/7734f05d-4510-11e6-8394-06c5fe21d5b1/singleResult, it always issues an error:

{"type":"IllegalArgumentException","message":"argument type mismatch"}

However, in the list of filters everything looks fine:

[{
        "id" : "37971bf8-450d-11e6-8394-06c5fe21d5b1",
        "resourceType" : "Task",
        "name" : "My Group Tasks",
        "owner" : null,
        "query" : {
            "candidateGroupsExpression" : "${ currentUserGroups() }",
            "taskVariables" : [],
            "processVariables" : [],
            "caseInstanceVariables" : []
        },
        "resourceType" : "Task",
        "properties" : {
            "color" : "#EEEEEE",
            "priority" : 0,
            "description" : "Tasks where one of my groups is candidateGroup of",
            "showUndefinedVariable" : false,
            "refresh" : false
        }
    }, {
        "id" : "7734f05d-4510-11e6-8394-06c5fe21d5b1",
        "resourceType" : "Task",
        "name" : "FilterMyGroupTasks",
        "owner" : null,
        "query" : {
            "candidateGroupExpression" : "${ currentUserGroups() }",
            "taskVariables" : [],
            "processVariables" : [],
            "caseInstanceVariables" : []
        },
        "resourceType" : "Task",
        "properties" : {}

    }, {
        "id" : "afa5e895-32d4-11e6-934e-06c5fe21d5b1",
        "resourceType" : "Task",
        "name" : "ALL",
        "owner" : null,
        "query" : {
            "taskVariables" : [],
            "processVariables" : [],
            "caseInstanceVariables" : []
        },
        "resourceType" : "Task",
        "properties" : {
            "color" : "#EEEEEE",
            "priority" : 0,
            "showUndefinedVariable" : true,
            "refresh" : false,
            "variables" : [{
                    "name" : "SearchApplicationNumber",
                    "label" : "APP_NO"
                }, {
                    "name" : "SearchIdDocumentNumber",
                    "label" : "ID_NO"
                }
            ]
        }
    }
]

The “funny” thing is that the same filter created manually (name: “My Group Tasks”) with the same condition works correctly; but the same filter “FilterMyGroupTasks” created via REST API returns internal error.

What could be the reason?

Jindra