Automate AnyDesk Management with Command Line Interface: Best Practices and Examples
Automated Implementation with AnyDesk Command Line Interface
The command line interface offers ways to automate many processes related to AnyDesk. Here, you can find some examples of how to use it with AnyDesk.
Automated Deployment
The command line functions can be used in combination with software management/deployment tools to implement and configure AnyDesk on a larger number of devices without the need for manual intervention on each device.
For this case, we recommend providing a customized MSI installation package, as well as pre-configured versions of our .exe Client/Service files that can be easily distributed in this way.
These can be further customized through the custom client generator in my.anydesk.com.
Standard Module Types | Description |
---|---|
Default EXE | EXE version of the standard client from anydesk.com that can initiate and receive connections. |
Client Module EXE | EXE version of a standard client that can only receive connections. |
Service Module EXE | EXE version of a standard client that can only initiate connections. |
These can be automated through a script using the commands described in Installation Commands or through other deployment tools.
A batch script example, which will install AnyDesk, register the license key, and set a password, could look like this:
Uninstalling AnyDesk
If AnyDesk is no longer needed on certain machines, it can be uninstalled through the built-in operating system uninstaller or, alternatively, the command line interface.
This can be done using the --remove or --uninstall command as mentioned in Installation Commands.
--uninstall will initiate the uninstallation process for the AnyDesk client. By using this command, a GUI prompt will guide the user through the uninstallation process.
In case AnyDesk removal needs to occur only through a script or a management software, --remove is the correct parameter to use.
Additionally, if a completely silent removal is desired, adding --silent will prevent any error messages that may occur during the removal process.
An example of a silent removal without additional user input would be:
--remove will only uninstall the AnyDesk application from the Windows operating system, but will not be able to remove any remaining files. Files, such as those found in the following default directories, must be manually removed or through a script:
- C:\Program Files (x86)\AnyDesk
- %appdata%\AnyDesk
- %programdata%\AnyDesk
Connecting through Command Line Interface
If you intend to implement AnyDesk in existing software, connecting through the command line interface using the commands and parameters described in Connection Commands can be a useful tool to achieve this.
Modifying AnyDesk Shortcuts
The parameters found in Connection Commands can be used to modify the shortcuts placed on the desktop through AnyDesk.
This is done by adding a parameter to the “Target” field in the “Properties” of the desktop shortcut. For example:
“C:\Program Files (x86)\AnyDesk\AnyDesk.exe” 123456789 –plain
- Published at