From terminal:
/tool user-manager session remove [find]
This will remove all available, as well as all active sessions. Again, keep in mind that this includes advance payments... Your users are likely going to be pissed off with you.
You can remove specific sessions by fine tuning the "find" part in the command above. So for example, to remove all "active" sessions only, but allow users to use other sessions they have assigned to them, you can use
/tool user-manager session remove [find where active=yes]
or conversely, if you want to remove all "extra" sessions, but ensure logged in users stay logged in until their time is up, replace the "yes" above with "no".
Doing the same with my PHP API client is analogous:
<?php
use PEAR2\Net\RouterOS;
require_once 'PEAR2_Net_RouterOS-1.0.0b5.phar';
$util = new RouterOS\Util($client = new RouterOS\Client('192.168.88.1', 'admin', 'password'));
$util->setMenu('/tool user-manager session')->remove($util->find(RouterOS\Query::where('active', 'yes')));