API
Приложение имеет API интерфейс для использования его в других приложениях. Интерфейс CLI (Command line interface) предназначен для удобного использования приложения через терминал, а API (Application programming interface) предназначен для удобного использования приложения во всевозможных скриптах, приложениях или расширениях для IDE.
По API можно вызвать справку в приложении через аргумент --help
, так же, как и для других команд.
Команда имеет один аргумент - --route
, он принимает URL в виде строки:
Info
Секретные данные (например пароль) можно передать переменной окружения и API считает данные. Например:
export cli_password="00000"
Для исключения возможных коллизий добавлен префикс cli_
.
Routes
/app
Get information about the application.
Clear cached data.
Get information about versions the application.
Check access to root user.
Authorization in sudo.
/apps
Get available list applications for Aurora OS.
Download application for device or emulator.
/device
Get list devices.
Get info device.
Execute the command on the device.
Upload file to ~/Download directory device.
Run package on the device.
• host - IP address device.
• package - Package name.
• mode [dart, gdb] (optional) - Application launch mode.
• project (optional) - Path to project. The default is the current directory.
Install RPM package on the device.
• host - IP address device.
• path - Path to file.
• apm [default = false, true] - Use APM.
• reinstall [default = false, true] - Reinstall an already installed package.
Remove package from the device.
• host - IP address device.
• package - Package name.
• apm [default = false, true] - Use APM.
• keep_user_data [default = false, true] - Keep user data.
/emulator
Start the emulator.
Take a screenshot of the emulator.
Start recording video from the the emulator.
Stop video recording from the the emulator.
Get info emulator.
Execute the command on the emulator.
Upload file to ~/Download directory emulator.
Run package on the emulator.
• package - Package name.
• mode [dart, gdb] (optional) - Application launch mode.
• project (optional) - Path to project. The default is the current directory.
Install RPM package on the emulator.
/emulator/package/install
• path - Path to file.
• apm [default = false, true] - Use APM.
• reinstall [default = false, true] - Reinstall an already installed package.
Remove package from the emulator.
• package - Package name.
• apm [default = false, true] - Use APM.
• keep_user_data [default = false, true] - Keep user data.
/flutter
Get available version Flutter for Aurora OS.
Get versions of installed Flutter for Aurora OS.
Download and install Flutter for Aurora OS.
Remove Flutter for Aurora OS.
Project formatting.
• version - Installed version of Flutter.
• path - Path to project. The default is the current directory.
Project check format.
• version - Installed version of Flutter.
• path - Path to project. The default is the current directory.
Compile a report of flutter project.
• version - Installed version of Flutter.
• path - Path to project. The default is the current directory.
Gen multiple size icons for application.
• image - Path to image.
• path - Path to project. The default is the current directory.
/psdk
Get available version Aurora Platform SDK.
Get installed list Aurora Platform SDK.
Get info about Aurora Platform SDK.
Get list targets Aurora Platform SDK.
Download Aurora Platform SDK.
Install Aurora Platform SDK.
Remove Aurora Platform SDK.
Remove snapshot target.
• version - Installed version of Aurora Platform SDK.
• target - Target name installed version of Aurora Platform SDK.
Add sudoers permissions Aurora Platform SDK.
Remove sudoers permissions Aurora Platform SDK.
Search installed package in target.
• version - Installed version of Aurora Platform SDK.
• target - Target name installed version of Aurora Platform SDK.
• package - Package name.
Install RPM packages to target.
• version - Installed version of Aurora Platform SDK.
• target - Target name installed version of Aurora Platform SDK.
• path - Path to RPM file.
Remove package from target.
• version - Installed version of Aurora Platform SDK.
• target - Target name installed version of Aurora Platform SDK.
• package - Package name.
Validate RPM packages.
• version - Installed version of Aurora Platform SDK.
• target - Target name installed version of Aurora Platform SDK.
• path - Path to RPM file.
• profile [regular, extended, mdm, antivirus, auth] - Select profile.
Sign (with re-sign) RPM package.
• version - Installed version of Aurora Platform SDK.
• path - Path to RPM file.
• phrase - PEM пароль-фраза.
• key (optional) - The name of key for sign package from config application.
Project formatting.
Project check format.
Gen multiple size icons for application.
• image - Path to image.
• path - Path to project. The default is the current directory.
/sdk
Get available version Aurora SDK.
Get version of the installed Aurora SDK.
Download and run Aurora SDK installation.
• version - Installed version of Aurora Platform SDK.
• offline [default = false, true] - Download offline type installer.
Run maintenance tool (remove, update).
/vscode
Information about VS Code.
Get a list of VS Code extensions.
Install VS Code extension.
Update VS Code settings.
/settings
Display additional application settings.
Clear advanced application settings.
Set the application language.
Controlling the --verbose parameter.
Controlling the --select parameter.
Manage application hints.
/tests
Test answers API.