Search kit: Document how to get selected ids for non-contact search tasks
Normally when coming from search the id list is populated for you here: https://github.com/civicrm/civicrm-core/blob/a92bc20c51e280141666362eae15d0399fc33555/CRM/Contribute/Form/Task.php#L55 and your existing code is likely expecting that.
For contact searches, searchkit sends cids
instead of id
, and so it gets picked up the same as normal and sets $this->_contactIds so you don't need to do anything extra. But for e.g. contributions you need to retrieve id
yourself.