Exception in fetching active tasks using Rest API(POST)

I was getting below exception:

{
    "type": "NotValidException",
    "message": "You should call any of the orderBy methods first before specifying a direction: currentOrderingProperty is null"
}

Payload:

{
  "processDefinitionKey": "workflow",
  "tenantIdIn": [
    "client1"
  ],
  "candidateUser": "1",
  "active": "true",
  "unassigned": "true",
  "sorting": [
    {
      "sortBy": "startTime",
      "sortOrder": "desc"
    }
  ]
}

Sorry. Issue resolved. wrong input supplied. its “created” instead of startTime