PPPoe user disconnection issue help?

Hello,

I’m utilizing the evilfreelancer/routeros-api-php library. My aim is to create a query that can disconnect an active PPPoE user from a MikroTik device. Despite attempting multiple PHP methods for the query, the debug output consistently shows “No Such Command.”

Normally, typing “interface pppoe-server remove ” in the MikroTik terminal removes the user. Additionally, I’ve tried “ppp active remove numbers=” but encountered the same “no such command” response.

Here’s the example query I’m working with:

public function disconnectConnectedUser()
{
$query_ppp_deactive_user = new Query(“/interface/pppoe-server/print”, [‘name’, ‘pppoe-user01’]);
$user = $this->client->query($query_ppp_deactive_user)->read();
$data = $user[0][‘.id’];
$deactive_user = new Query(“/interface/pppoe-server/remove/numbers=$data”);
return $this->client->query($deactive_user)->read();
}

I can successfully retrieve the complete list of active PPPoE users using the API, trying different approaches such as username sessionid. Unfortunately, all methods result in the same “no such command” response from the API.

Could you provide insight into what I might be doing incorrectly?