Camunda API Assign and Count Task Count By Candidate Group

I am creating a workflow in Camunda. I’d like to:

  1. assign tasks to a group, other than a specific user
  2. count the number of tasks per group.

I did not find any guideline from Camunda docs talking about assigning tasks to a group, so I tried Add Identity Link

POST /task/{{taskid}}/identity-links

Request body:

{"groupId": "teamA", "type": "candidate"}

However, when I try Get Task Count By Candidate Group

GET /task/report/candidate-group-count

There was no task assigned to TeamA from the Response body, in contrast, all my desired tasks fell into the group null.

[
    {
        "groupName": "accounting",
        "taskCount": 4
    },
    {
        "groupName": "sales",
        "taskCount": 2
    },
    {
        "groupName": null,
        "taskCount": 6
    }
]

Any advice on how to fix this?