Dear Members,
I already have a PHP cod that how to reset password by API Class. I need how to get specific user download and upload used in PHP to show below is my code for changing password and in the same context please suggest me a code of download and upload of specific user used in PHP.
My Code for changing password:
require('routeros_api.class.php');
$API = new routeros_api();
$API->debug = true;
if ($API->connect('10.10.0.2', 'user', 'password')) {
$API->write('/tool/user-manager/user/getall', false);
$API->write('=.proplist=username', false);
$API->write('/tool/user-manager/user/set',false);
$API->write('?username=' , $data["EMAIL"]);
$API->write('password=' , $data["vpn_pwd"] );
$READ = $API->read(false);
$ARRAY = $API->parseResponse($READ);
print_r($ARRAY);
$API->disconnect();
}
Change password is working fine we need specific user total download and upload used show via API.