diff --git a/docs/metadata.md b/docs/metadata.md index 57b51d9475..cdf3c50618 100644 --- a/docs/metadata.md +++ b/docs/metadata.md @@ -20,3 +20,4 @@ Metadata contains general information about add-on build. | defaultView | string | Define which view should be loaded on TA load. One of `"inputs"`, `"configuration"`, `"dashboard"` or `"search"`. Default `configuration`. | | [os-dependentLibraries](./advanced/os-dependent_libraries.md) | array | This feature allows you to download and unpack libraries with appropriate binaries for the indicated operating system during the build process. | | supported_themes | array | This feature is allows you provide the themes supported by your add-on. Supported values: `light`, `dark`. No default. | +| isVisible | boolean | This option allows you to create apps which are not visible by default by setting isVisible=false. | \ No newline at end of file diff --git a/splunk_add_on_ucc_framework/commands/build.py b/splunk_add_on_ucc_framework/commands/build.py index 224ce04e5d..d68a0666e8 100644 --- a/splunk_add_on_ucc_framework/commands/build.py +++ b/splunk_add_on_ucc_framework/commands/build.py @@ -642,6 +642,8 @@ def generate( supported_themes = "" if global_config: should_be_visible = True + if global_config.meta.get("isVisible") is not None: + should_be_visible = global_config.meta.get("isVisible") if global_config.meta.get("checkForUpdates") is False: check_for_updates = "false" if global_config.meta.get("supportedThemes") is not None: diff --git a/splunk_add_on_ucc_framework/schema/schema.json b/splunk_add_on_ucc_framework/schema/schema.json index 8bc755dd9c..db3d76941f 100644 --- a/splunk_add_on_ucc_framework/schema/schema.json +++ b/splunk_add_on_ucc_framework/schema/schema.json @@ -1740,6 +1740,11 @@ "default": true, "description": "Ability to configure app.conf->package.check_for_updates from globalConfig file." }, + "isVisible": { + "type": "boolean", + "default": true, + "description": "Ability to configure app.conf->ui.is_visible from globalConfig file." + }, "defaultView": { "type": "string", "description": "Define which view should be loaded on TA load.", diff --git a/ui/src/types/globalConfig/meta.ts b/ui/src/types/globalConfig/meta.ts index d42acea0e6..d8a5fe3b64 100644 --- a/ui/src/types/globalConfig/meta.ts +++ b/ui/src/types/globalConfig/meta.ts @@ -11,6 +11,7 @@ export const meta = z.object({ hideUCCVersion: z.boolean().optional(), checkForUpdates: z.boolean().default(true).optional(), searchViewDefault: z.boolean().default(false).optional(), + isVisible: z.boolean().default(true).optional(), }); export type meta = z.infer;