Hi there,
I need to create custom FTP accounts through the API, in the same way as you can through the GUI interface. This doesn't seem to be an option in the documentation for the CMD_API_FTP command, even though CMD_API_FTP_SHOW is happy to return information for existing custom FTP accounts, returning "type=custom" and "path=...."
If I set "type" to "custom" and specify a path as in my example below, it says the path is not valid. In fact it says the same thing even if I miss out the path parameter, so I think the path is simply being ignored.
Is there a way to do what I'm trying to do, or alternatively could this be supported please?
thanks,
Danny
$sock->query('/CMD_API_FTP',
array(
'action' => 'create',
'domain' => 'domain.com',
'user' => 'testuser4',
'type' => 'custom',
'path' => '/home/user/domains/domain.com/public_html/custom/',
'passwd' => 'test',
'passwd2' => 'test'
));
$result = $sock->fetch_body();
I need to create custom FTP accounts through the API, in the same way as you can through the GUI interface. This doesn't seem to be an option in the documentation for the CMD_API_FTP command, even though CMD_API_FTP_SHOW is happy to return information for existing custom FTP accounts, returning "type=custom" and "path=...."
If I set "type" to "custom" and specify a path as in my example below, it says the path is not valid. In fact it says the same thing even if I miss out the path parameter, so I think the path is simply being ignored.
Is there a way to do what I'm trying to do, or alternatively could this be supported please?
thanks,
Danny
$sock->query('/CMD_API_FTP',
array(
'action' => 'create',
'domain' => 'domain.com',
'user' => 'testuser4',
'type' => 'custom',
'path' => '/home/user/domains/domain.com/public_html/custom/',
'passwd' => 'test',
'passwd2' => 'test'
));
$result = $sock->fetch_body();