sonar-apps

Retrieves the list of apps registered in Logpresso Sonar. You can filter by app name or description using the keywords option.

Command properties

PropertyDescription
Command typeDriver query
Required permissionAdministrator
License usageCounted
Parallel executionNot supported
Distributed executionNot supported

Syntax

sonar-apps [keywords=STR]

Options

[keywords=STR]
Keywords to search for in the app name or description. If you separate multiple words with spaces, only apps that contain all the words in one field (name or description) are returned. Because the name and description used for the search are based on the locale of the session this command uses internally (fixed to English), the comparison is actually made against the app's English name and English description, case-insensitively.

Output fields

FieldTypeDescription
codestringApp code
namestringApp name
bundle_symbolic_namestringOSGi bundle symbolic name
versionstringApp version
descriptionstringApp description
built_attimestampBuild time
installed_attimestampInstallation time
enabledbooleanWhether the app is enabled

Error codes

Parsing errors
Error codeMessageDescription
300181No permission to enumerate apps.Run by an account without administrator permission
Runtime errors

N/A

Description

The sonar-apps command returns all registered apps if the keywords option is not specified. If keywords is specified, it returns apps where each space-separated word is fully contained in the app name, or fully contained in the app description (an app is included if either the name or the description satisfies the condition, not necessarily both).

This comparison is based on the multilingual name and description, which vary by session locale, but the session this command creates does not specify a locale, so it defaults to English. On the other hand, the name output field returns the app's default name as is, so if an app has a Korean default name set, the name shown on screen and the English name actually used for the keywords search can differ. Therefore, keywords should be given words contained in the app's English name or English description rather than Korean, to reliably match.

Examples

  1. Retrieve the full list of apps

    sonar-apps
    

    Returns the code, name, version, enabled status, and other properties of all registered apps.

  2. Filter apps by keyword

    sonar-apps keywords="sample"
    

    Returns only apps whose English name or description contains sample. Because keywords is compared based on the session locale (fixed to English), specifying a Korean keyword may not match an app even if it is displayed with a Korean name on screen.

  3. Query only disabled apps

    sonar-apps
    | search enabled == false
    

    Filters only apps that are currently disabled.

Change history

The sonar-apps command is available in the Sonar 4.0 series starting with 4.0.2609.0, where the command previously provided by the Experimental app was built into Sonar core. On versions without the built-in command, install the Experimental app to use it.