Table of Contents
About UCC¶
Universal Configuration Console (UCC) is a framework that simplifies the process of add-on creation for developers. You can use UCC to generate UI-based Splunk add-ons. UCC includes UI, REST handlers, modular inputs, OAuth, and alert action templates.
The UCC framework helps you to maintain consistency and a uniform look and feel across different add-ons. You can easily update and modify your add-ons.
The UCC framework is available as a GitHub action. See https://github.com/splunk/addonfactory-ucc-generator-action.
To work with UCC framework, you can also use Splunk Extension. It helps you to create, test, and debug the add-ons in a simple way. For more information, see Visual Studio Code Extension for Splunk.
Libraries¶
UCC-based add-ons are powered by the following Splunk libraries:
solnlib
, see https://github.com/splunk/addonfactory-solutions-library-pythonsplunktaucclib
, see https://github.com/splunk/addonfactory-ucc-library.
For more information, see UCC-related libraries.
Note: Some specific Python libraries (such as
google-cloud-bigquery
) use.so
files to operate.pip
installs OS-specific versions of those.so
files, which makes it impossible to use such add-ons on a Windows machine because it was built for macOS.
What UCC generates¶
When you use UCC to create an add-on, the following elements are generated and stored in the appropriate folders:
- UI is stored in the
appserver
folder, - Python REST handlers that support UI CRUD operations are stored in the
bin
folder, - inputs and their helper modules. For more information, see Inputs and Helper modules,
- OpenAPI description documents are stored in the
appserver/static/openapi.json
file. For more information, see OpenAPI description document, .conf
files. For more information, see .conf files,- Python requirements are installed in the
lib
folder, - metadata files are stored in the
metadata
folder, - the monitoring dashboard. For more information, see Dashboard,
- the necessary files defined for the alert action, if you defined the alert action in the
globalConfig
file. For more information, see Alert actions.
You can extend your add-ons with the following files:
- to extend the UI, use custom codes. For more information, see Custom hook.
- to extend the build process, use the
additional_packaging.py
file. For more information, see additional_packaging.py file.
Getting started¶
Install the UCC framework and start building your first add-on. Then you can build new add-ons from the existing ones.
Prerequisites¶
Make sure that the following software is installed on your machine:
- Python 3.7 or later
- Git
Note: Git is used to generate the add-on version from the Git tags. Alternatively, you can use the
--ta-version
parameter and specify the version by yourself.
Install¶
Create and activate the virtual environment¶
Depending on which operating system you use, follow one of the procedures:
Windows¶
Set up the Python virtual environment:
python3 -m venv .venv
If you use cmd.exe, activate the virtual environment with the following command:
.venv\Scripts\activate.bat
If you use PowerShell, activate the virtual environment with the following command:
.venv\Scripts\activate.ps1
macOS, Linux¶
Set up and activate the Python virtual environment:
python3 -m venv .venv
source .venv/bin/activate
Install UCC package¶
Install UCC package, it is available on PyPI, see https://pypi.org/project/splunk-add-on-ucc-framework/.
pip install splunk-add-on-ucc-framework
Create a new add-on¶
Initialize a new add-on¶
ucc-gen init --addon-name "demo_addon_for_splunk" --addon-display-name "Demo Add-on for Splunk" --addon-input-name demo_input
For more information about the add-ons naming convention, see Naming conventions for apps and add-ons in Splunkbase
The new add-on is located in the demo_addon_for_splunk
folder.
Build the add-on¶
ucc-gen build --source demo_addon_for_splunk/package
Package the add-on¶
ucc-gen package --path output/<add-on-name>
The archive is created on the same level as your globalConfig.json
file.
For more information regarding commands, see Commands.
Install the add-on¶
Go to your Splunk app instance and install this add-on using the generated archive.
After you check that the add-on was loaded correctly and all the basic operations are working, you can extend the functionality of the input by copying and pasting the automatically generated modular inputs file into the package/bin
folder. The generated inputs use the Splunk SDK for Python. See https://github.com/splunk/splunk-sdk-python.
After you update the modular input code, you can run ucc-gen
again, and then ucc-gen
uses updated modular inputs from package/bin
instead of generating new ones.
Commands¶
These are the commands that are available in UCC framework.
ucc-gen build
¶
The ucc-gen build
command builds the add-on. As of now, running ucc-gen
does the same thing as running ucc-gen build
,
but eventually calling ucc-gen
without specifying a subcommand will be
deprecated.
It takes the following parameters:
--source
- [optional] folder containing theapp.manifest
and app source. The default ispackage
.--config
- [optional] path to the configuration file. It defaults to the globalConfig file in the parent directory of the source provided. Only .json and .yaml files are accepted.--ta-version
- [optional] override current version of TA. The default version is version specified inglobalConfig.json
orglobalConfig.yaml
. A Splunkbase compatible version of SEMVER is used by default.-o
/--output
- [optional] output folder to store the build add-on. By default, it is saved in thecurrent directory/output
folder. Absolute paths are accepted as well.--python-binary-name
- [optional] Python binary name to use when installing Python libraries. The default ispython3
.-v
/--verbose
- [optional] shows detailed information about created/copied/modified/conflict files after build is complete. This option is in the experimental mode. The default isFalse
.--pip-version
- [optional] pip version that is used to install python libraries. The default islatest
.--pip-legacy-resolver
- [optional] Use old pip dependency resolver by adding flag ‘–use-deprecated=legacy-resolver’ to pip install command. The default isFalse
. >NOTE: This flag is deprecated and will be removed from pip in the future. Instead of using this flag, the correct solution would be to fix the packages your project depends on to work properly with the new resolver. Additionally, this flag is not compatible with pip version23.2
. Use23.2.1
instead.-
--pip-custom-flag
- [optional] Additional flag(s) that will be added to thepip install
command. By default, all the following flags are added to thepip install
command:--no-compile
,--prefer-binary
and--ignore-installed
. If--pip-custom-flag
is specified these three arguments will be missing so if you still want them in your command add them to the--pip-custom-flag
argument.Example:
--pip-custom-flag="--no-compile --prefer-binary --ignore-installed --report path/to/report.json --progress-bar on"
-
--ui-source-map
- [optional] if present generates front-end source maps (.js.map files), that helps with code debugging.
Verbose mode¶
The verbose mode is available for v5.35.0
and later.
Running ucc-gen build -v
or ucc-gen build --verbose
prints additional information about
what was exactly created / copied / modified / conflicted after the build is complete. It does
not scan the lib
folder due to the nature of the folder.
See the following description of what each state means:
created
: the file is not in the original package and was created during the build process.copied
: the file is in the original package and was copied during the build process.modified
: the file is in the original package and was modified during the build process.conflict
: the file is in the original package and was copied during the build process, but may be generated by UCC itself, so incorrect usage can stop the add-on from working.
ucc-gen init
¶
ucc-gen init
initializes the add-on. This is available on v5.19.0
and later.
The ucc-gen init
command initializes the add-on and bootstraps some code in the
modular input which you, as a developer, can extend for your needs.
Apart from standard files needed for the add-on, it also adds search head
clustering files in the default/server.conf
file and reload triggers in the
default/app.conf
file. Those files will be soon generated automatically by the
ucc-gen build
command itself.
during the add-on development.
It takes the following parameters:
--addon-name
- [required] add-on name. See the official naming convention guide.--addon-rest-root
- [optional] add-on REST root, defaults to--addon-name
if not provided.--addon-display-name
- [required] add-on “official” name.--addon-input-name
- [required] name of the generated input.--addon-version
- [optional] version of the generated add-on, with0.0.1
by default.--overwrite
- [optional] overwrites the already existing folder. By default, you can’t generate a new add-on to an already existing folder.
ucc-gen import-from-aob
¶
Import from AoB (Add-on Builder), from v5.24.0
and later. It is in the
experimental state as of now, meaning that running this command may not
produce a 100% UCC compatible add-on, but we are going to work on future
improvements for the script itself.
Note: the
import-from-aob
command does not currently support Windows.
The import functionality is based on the
ucc_migration_test bash
script.
One of the ways you can use it is to download an AoB-based add-on from
Splunkbase, unarchive the folder, and then use
ucc-gen import-from-aob --addon-name <unarchived-folder-name>
. Or you can
run the same command against your locally developed add-on, but it should be
exported from AoB.
It accepts the following parameters:
--addon-name
- [required] add-on name.
ucc-gen package
¶
ucc-gen package
can be used for v5.30.0
and later. It packages the add-on so it can be installed.
It mimics the basics of the slim package
command. This command can be used for most of the simple cases.
It does not support:
- the
.slimignore
file. - the dependencies section.
It accepts the following parameters:
--path
- [required] path to the built add-on (should include theapp.manifest
file).-o
/--output
- [optional] output folder to store the packaged add-on. By default, it will be saved in thecurrent directory
folder. It accepts absolute paths as well.
.conf files¶
ucc-gen build
generates the following .conf
files in the default
directory.
If any of the .conf
files are present in the source directory, ucc-gen
copies that file to the output folder. The only exception is the app.conf
file.
For most of the use cases, the generated configuration is sufficient. If you need to adjust the file that is generated, contact Splunk with a feature request. Alternatively, create a file in the
default
location, so it will accepted without being generated.
app.conf
¶
ucc-gen
merges the file present in the default
folder with some
additional information generated during the build time. But if you don’t need
anything specific generated, you don’t need to have app.conf
in the source folder.
app.conf uses the app.manifest
file to determine the add-on description, the add-on name,
the add-on title, and the add-on author (taking the first one if multiple are defined).
Make sure that your app.manifest
is up-to-date, so app.conf
will have all relevant information.
Also the triggers
stanza is created by the ucc-gen build
command. ucc-gen build
determines what
the .conf
files are used in the add-on and generates the relevant key-value
pairs.
inputs.conf
¶
ucc-gen
generates a stanza for every input defined in the globalConfig
file and sets python.version
to python3
.
server.conf
¶
ucc-gen
generates the shclustering
stanza. This stanza determines which
.conf
files are used in the add-on and generates the relevant key-value pairs.
web.conf
¶
ucc-gen
generates information about the exposed endpoints from the add-on.
restmap.conf
¶
ucc-gen
generates information about the configuration of every endpoint.
The following table describes the files generated by UCC framework.
File Name | File Location | File Description |
---|---|---|
app.conf | output/<YOUR_ADDON_NAME>/default | Generates app.conf with the details mentioned in globalConfig[meta] |
inputs.conf | output/<YOUR_ADDON_NAME>/default | Generates inputs.conf and inputs.conf.spec file for the services mentioned in globalConfig |
server.conf | output/<YOUR_ADDON_NAME>/default | Generates server.conf for the custom conf files created as per configurations in globalConfig |
restmap.conf | output/<YOUR_ADDON_NAME>/default | Generates restmap.conf for the custom REST handlers that are generated based on configs from globalConfig |
web.conf | output/<YOUR_ADDON_NAME>/default | Generates web.conf to expose the endpoints generated in restmap.conf which is generated based on configurations from globalConfig. |
alert_actions.conf | output/<YOUR_ADDON_NAME>/default | Generates alert_actions.conf and alert_actions.conf.spec file for the custom alert actions defined in globalConfig |
eventtypes.conf | output/<YOUR_ADDON_NAME>/default | Generates eventtypes.conf file if the sourcetype is mentioned in Adaptive Response of custom alert action in globalConfig |
tags.conf | output/<YOUR_ADDON_NAME>/default | Generates tags.conf file based on the eventtypes.conf created for custom alert actions. |
_account.conf | output/<YOUR_ADDON_NAME>/README | Generates <YOUR_ADDON_NAME>_account.conf.spec file for the configuration mentioned in globalConfig |
_settings.conf | output/<YOUR_ADDON_NAME>/README | Generates <YOUR_ADDON_NAME>_settings.conf.spec file for the Proxy, Logging or Custom Tab mentioned in globalConfig |
configuration.xml | output/<YOUR_ADDON_NAME>/default/data/ui/views | Generates configuration.xml file in default/data/ui/views/ folder if globalConfig is present. |
dashboard.xml | output/<YOUR_ADDON_NAME>/default/data/ui/views | Generates dashboard.xml file based on dashboard configuration present in globalConfig in default/data/ui/views folder. |
default.xml | output/<YOUR_ADDON_NAME>/default/data/ui/nav | Generates default.xml file based on configs present in globalConfigin in default/data/ui/nav folder. |
inputs.xml | output/<YOUR_ADDON_NAME>/default/data/ui/views | Generates inputs.xml based on inputs configuration present in globalConfig, in default/data/ui/views/inputs.xml folder |
_redirect.xml | output/<YOUR_ADDON_NAME>/default/data/ui/views | Generates ta_name_redirect.xml file, if oauth is mentioned in globalConfig,in default/data/ui/views/ folder. |
_.html | output/<YOUR_ADDON_NAME>/default/data/ui/alerts | Generates alert_name.html file based on alerts configuration present in globalConfig in default/data/ui/alerts folder. |
Inputs ↵
Inputs¶
The input page stores configuration information for data collection. Multiple inputs can be created on the Inputs page.
Developers are required to add services in the global config file to create a new Input. If multiple services are provided, a dropdown field will appear on the Inputs page. In contrast, a button will be displayed for a single service.
Properties¶
Property | Type | Description |
---|---|---|
title* | string | - |
description | string | It provides a brief summary of an inputs page. |
subDescription | object | It provides broader description of an inputs page. |
menu | object | This property allows you to enable the custom menu feature. |
table | object | It displays input stanzas in a tabular format. |
groupsMenu | array | This property allows you to enable the multi-level menu feature. |
services* | array | It specifies a list of modular inputs. |
readonlyFieldId | string | A field of the boolean entity that UCC checks for each input. If the field’s value is truthful, the corresponding input cannot be edited from the UI. There is no way to change this from the UI; it is supposed to be changed via REST. |
hideFieldId | string | A field of the boolean entity that UCC checks for each input. If the field’s value is truthful, the corresponding input is hidden from the UI. There is no way to change this from the UI; it is supposed to be changed via REST. Check out an example below. |
Services Properties¶
Property | Type | Description |
---|---|---|
name* | string | It defines the particular service name. |
title* | string | It shows the title of the service. |
subTitle | string | It shows the subtitle (or additional information) of the service. |
entity* | array | It is a list of fields and their properties. |
groups | array | It is used to divide forms into distinct sections, each comprising relevant fields. |
style | string | By specifying this property in the global configuration file, the forms can either be opened as a new page or in a dialog. Supported values are “page” or “dialog”. The default value is dialog. |
options | object | This property allows you to enable the saveValidator feature. |
hook | object | It is used to add custom behaviour to forms. Visit the Custom Hook page to learn more. |
warning | object | It is used to add the custom warning message for each of the modes of ‘create’, ‘edit’, ‘config’, and ‘clone’. The message is displayed on the form. |
inputHelperModule | string | A module that contains validate_input and stream_events methods. By default it is not used. |
conf | string | Configuration name for a rest handler. |
restHandlerName | string | It specify name of the REST handler script, that provides fields, models and validators for the fields supported under the specified input and any specific actions to be performed on CRUD operations for the given input. (Do NOT use with restHandlerModule or restHandlerClass) |
restHandlerModule | string | It specify name of the REST handler script that implements the custom actions to be performed on CRUD operations for the given input. (Use with restHandlerClass) |
restHandlerClass | string | It specify name of the class present in the restHandlerModule, which implements methods like handleCreate, handleEdit, handleList, handleDelete and is child class of splunktaucclib.rest_handler.admin_external.AdminExternalHandler. (Use with restHandlerModule) |
hideForPlatform | string | Defines for which platform element should be hidden from UI perspective. Currently only two platforms are supported cloud or enterprise . |
Usage¶
This is how the global configuration looks like without tabs
Expand to see full json code
{
"pages": {
"configuration": {
"title": "",
"tabs": [
{
"name": "a",
"title": "",
"entity": []
}
]
},
"inputs": {
"services": [
{
"name": "demo_input",
"entity": [
{
"type": "text",
"label": "Name",
"validators": [
{
"type": "regex",
"errorMsg": "Input Name must begin with a letter and consist exclusively of alphanumeric characters and underscores.",
"pattern": "^[a-zA-Z]\\w*$"
},
{
"type": "string",
"errorMsg": "Length of input name should be between 1 and 100",
"minLength": 1,
"maxLength": 100
}
],
"field": "name",
"help": "A unique name for the data input.",
"required": true
},
{
"type": "text",
"label": "Interval",
"validators": [
{
"type": "regex",
"errorMsg": "Interval must be an integer.",
"pattern": "^\\-[1-9]\\d*$|^\\d*$"
}
],
"defaultValue": "300",
"field": "interval",
"help": "Time interval of the data input, in seconds.",
"required": true
},
{
"type": "singleSelect",
"field": "select1",
"label": "Select 1",
"help": "Default value is Numeric 1",
"defaultValue": 1,
"options": {
"autoCompleteFields": [
{
"value": 1,
"label": "Numeric 1"
}
]
}
},
{
"type": "singleSelect",
"field": "select2",
"label": "Select 2",
"help": "Default value is Numeric 3",
"defaultValue": 3,
"options": {
"autoCompleteFields": [
{
"value": 3,
"label": "Numeric 3"
}
]
}
},
{
"type": "multipleSelect",
"field": "multipleselect1",
"label": "MultiSelect 1",
"help": "Default value is Numeric 1",
"defaultValue": "1",
"options": {
"items": [
{
"value": 1,
"label": "Numeric 1"
}
]
}
},
{
"type": "singleSelect",
"label": "Account to use",
"options": {
"autoCompleteFields": [
{
"value": "value1",
"label": "Value1"
},
{
"value": "value2",
"label": "Value2"
}
]
},
"help": "Account to use for this input.",
"field": "account",
"required": true
},
{
"type": "text",
"label": "sometext",
"validators": [
{
"type": "string",
"errorMsg": "Length of input name should be between 1 and 100",
"minLength": 1,
"maxLength": 1000
}
],
"field": "sometext",
"help": "A unique text for the data input.",
"required": true
},
{
"type": "singleSelect",
"label": "Some Select Dropdown",
"options": {
"disableSearch": true,
"autoCompleteFields": [
{
"value": "DEBUG",
"label": "DEBUG"
},
{
"value": "INFO",
"label": "INFO"
},
{
"value": "WARN",
"label": "WARN"
},
{
"value": "ERROR",
"label": "ERROR"
},
{
"value": "CRITICAL",
"label": "CRITICAL"
}
]
},
"defaultValue": "INFO",
"field": "someselectdropdown"
},
{
"type": "checkboxGroup",
"label": "CheckboxGroupTitle",
"field": "api3",
"options": {
"groups": [
{
"label": "Group 1",
"options": {
"isExpandable": true,
"expand": true
},
"fields": [
"rowUnderGroup1"
]
},
{
"label": "Group 3",
"options": {
"isExpandable": true,
"expand": true
},
"fields": [
"field223", "160validation"
]
}
],
"rows": [
{
"field": "rowWithoutGroup",
"input": {
"defaultValue": 1,
"required": true
}
},
{
"field": "rowUnderGroup1",
"checkbox": {
"label": "Row under Group 1",
"defaultValue": true
},
"input": {
"defaultValue": 1200,
"required": false
}
},
{
"field": "field223",
"checkbox": {
"label": "Required field",
"defaultValue": true
},
"input": {
"required": true
}
},
{
"field": "160validation",
"checkbox": {
"label": "from 1 to 60 validation"
},
"input": {
"validators": [
{
"type": "number",
"range": [1, 60]
}
]
}
}
]
}
}
],
"title": "demo_input"
},
{
"name": "demo_input_page",
"style": "page",
"entity": [
{
"type": "text",
"label": "Name",
"validators": [
{
"type": "regex",
"errorMsg": "Input Name must begin with a letter and consist exclusively of alphanumeric characters and underscores.",
"pattern": "^[a-zA-Z]\\w*$"
},
{
"type": "string",
"errorMsg": "Length of input name should be between 1 and 100",
"minLength": 1,
"maxLength": 100
}
],
"field": "name",
"help": "A unique name for the data input.",
"required": true
},
{
"field": "config2_help_link",
"label": "",
"type": "helpLink",
"options": {
"text": "SSL configuration documentation",
"link": "https://ta-jira-service-desk-simple-addon.readthedocs.io/en/latest/configuration.html"
}
},
{
"type": "checkbox",
"label": "Hide in UI boolean value",
"field": "hide_in_ui",
"options": {
"display": false
}
},
{
"type": "checkbox",
"label": "Is input readonly?",
"field": "hard_disabled",
"options": {
"display": false
}
},
{
"type": "text",
"label": "Interval",
"validators": [
{
"type": "regex",
"errorMsg": "Interval must be an integer.",
"pattern": "^\\-[1-9]\\d*$|^\\d*$"
}
],
"defaultValue": "300",
"field": "interval",
"help": "Time interval of the data input, in seconds.",
"required": true
},
{
"type": "singleSelect",
"label": "Account to use",
"options": {
"autoCompleteFields": [
{
"value": "value1",
"label": "Value1"
},
{
"value": "value2",
"label": "Value2"
}
]
},
"help": "Account to use for this input.",
"field": "account",
"required": true
},
{
"type": "text",
"label": "sometext",
"validators": [
{
"type": "string",
"errorMsg": "Length of input name should be between 1 and 100",
"minLength": 1,
"maxLength": 1000
}
],
"field": "sometext",
"help": "A unique text for the data input.",
"required": true
},
{
"type": "singleSelect",
"label": "Some Select Dropdown",
"options": {
"disableSearch": true,
"autoCompleteFields": [
{
"value": "DEBUG",
"label": "DEBUG"
},
{
"value": "INFO",
"label": "INFO"
},
{
"value": "WARN",
"label": "WARN"
},
{
"value": "ERROR",
"label": "ERROR"
},
{
"value": "CRITICAL",
"label": "CRITICAL"
}
]
},
"defaultValue": "INFO",
"field": "someselectdropdown"
},
{
"type": "checkboxGroup",
"label": "CheckboxGroupTitle",
"field": "api3",
"options": {
"groups": [
{
"label": "Group 1",
"options": {
"isExpandable": true,
"expand": true
},
"fields": [
"rowUnderGroup1"
]
},
{
"label": "Group 3",
"options": {
"isExpandable": true,
"expand": true
},
"fields": [
"field223", "160validation"
]
}
],
"rows": [
{
"field": "rowWithoutGroup",
"input": {
"defaultValue": 1,
"required": true
}
},
{
"field": "rowUnderGroup1",
"checkbox": {
"label": "Row under Group 1",
"defaultValue": true
},
"input": {
"defaultValue": 1200,
"required": false
}
},
{
"field": "field223",
"checkbox": {
"label": "Required field",
"defaultValue": true
},
"input": {
"required": true
}
},
{
"field": "160validation",
"checkbox": {
"label": "from 1 to 60 validation"
},
"input": {
"validators": [
{
"type": "number",
"range": [1, 60]
}
]
}
}
]
}
}
],
"title": "Demo input page"
}
],
"title": "Inputs",
"description": "Manage your data inputs",
"table": {
"actions": ["edit", "delete", "search", "clone"],
"header": [
{
"label": "Name",
"field": "name"
},
{
"label": "Interval",
"field": "interval"
},
{
"label": "Index",
"field": "index"
},
{
"label": "Status",
"field": "disabled"
},
{
"label": "Select Dropdown",
"field": "someselectdropdown1"
}
],
"moreInfo": [
{
"label": "Name",
"field": "name"
},
{
"label": "Interval",
"field": "interval"
},
{
"label": "Index",
"field": "index"
},
{
"label": "Status",
"field": "disabled",
"mapping": {
"1": "Disabled",
"true": "Disabled",
"false": "Enabled"
}
},
{
"label": "Exported",
"field": "hard_disabled",
"mapping": {
"1": "Yes",
"0": "No",
"f": "No"
}
},
{
"label": "Select Dropdown",
"field": "someselectdropdown2"
}
]
},
"readonlyFieldId": "hard_disabled",
"hideFieldId": "hide_in_ui"
},
"dashboard": {
"panels": [
{
"name": "default"
}
]
}
},
"meta": {
"name": "demo_addon_for_splunk",
"restRoot": "demo_addon_for_splunk",
"version": "5.32.0R0e2087fe",
"displayName": "Demo Add-on for Splunk",
"schemaVersion": "0.0.3"
}
}
Output¶
Tabs¶
This feature allows you to separate inputs based on their service name. Use the tabs feature when multiple inputs services are provided in the global configuration file, and you want to display each input service in a separate tab (and table).
The table
property must be present in the services to use the tabs feature.
If title
and description
are provided in the global configuration file, then it would change when changing the tab.
Usage¶
"pages": {
"inputs": {
"title": "Inputs",
"services": [
{
"name": "example_input_one",
"description": "This is a description for Input One",
"title": "Example Input",
"entity": [],
"table": {
"actions": [
"edit",
"delete",
"clone"
],
"header": [],
"moreInfo": []
},
"warning": {
"create": "Warning text for create mode",
"edit": "Warning text for edit mode",
"clone": "Warning text for clone mode",
"config": "Warning text for config mode",
}
},
{
"name": "example_input_two",
"description": "This is a description for Input Two",
"title": "Example Input Two",
"entity": [],
"table": {
"actions": [
"edit",
"delete",
"clone"
],
"header": [],
"moreInfo": [],
"customRow":{
"type": "external",
"src": "custom_row"
}
}
}
]
}
},
Note:
When using the Tabs feature, if the
table
ordescription
property is provided in theinputs
, the errorinstance.pages.inputs is not one of [subschema 0], [subschema 1]
will be displayed.Custom Menu is not supported with the tabs feature.
Output¶
This is how it looks like in the UI:
Input Helper Module¶
Input scripts are regenerated during every build step, in order to keep the arguments
and options up to date with the global config. To not discard changes made by developers,
additional helper modules were introduced. Those modules must contain
validate_input
and stream_events
methods (see example below).
They are created if they do not exist, but they are not updated by UCC.
A script then imports such a module and calls the two methods.
Helper files are placed in the bin
directory. In order to use helper files, specify
inputHelperModule
parameter. This will create a new file: {inputHelperModule}.py
.
Usage¶
"pages": {
"inputs": {
"services": [
{
"name": "example_input_one",
"title": "Example Input",
"entity": [],
"inputHelperModule": "my_module"
}
]
}
},
This will create my_module.py
(if it does not exist) file in the bin
directory.
The input script example_input_one
will import this module and call its methods.
Module content¶
The file must contain the following two functions:
validate_input(definition: smi.ValidationDefinition)
stream_events(inputs: smi.InputDefinition, event_writer: smi.EventWriter)
from splunklib import modularinput as smi
def validate_input(definition: smi.ValidationDefinition):
...
def stream_events(inputs: smi.InputDefinition, event_writer: smi.EventWriter):
...
The two methods’ bodies should be filled by the developer.
Ended: Inputs
Configuration ↵
Configuration¶
The Configuration
tab can have multiple subtabs, for example, a tab for
account configuration (to configure the account by adding account credentials),
proxy configuration, and logging level configuration.
Configuration Properties¶
Property | Type | Description |
---|---|---|
title* | string | - |
description | string | To provide a brief summary of an configuration page. |
subDescription | object | To provide broader description of an configuration page |
tabs* | array | To specify a list of tab. |
Tabs properties¶
Property | Type | Description |
---|---|---|
name* | string | To define the particular tab name. |
title* | string | To show the title of the tab. |
entity* | array | A list of fields and their properties. |
groups | array | It is used to divide forms into distinct sections, each comprising relevant fields. |
table | object | To display accounts stanza in table |
style | string | By specifying this property in the global config file, the forms can either be opened as a new page or in a dialog. Supported values are “page” or “dialog”. Default value is dialog. |
options | object | This property allows you to enable the saveValidator feature. |
hook | object | It is used to add custom behaviour to forms. Visit the Custom Hook page to learn more. |
warning | object | It is used to add custom warning message for each of modes (‘create’, ‘edit’, ‘config’, ‘clone’), message is displayed on form |
conf | string | Configuration name for a rest handler. |
restHandlerName | string | It specify name of the REST handler script, that provides fields, models and validators for the fields supported under the specified input and any specific actions to be performed on CRUD operations for the given input. (Do NOT use with restHandlerModule or restHandlerClass) |
restHandlerModule | string | It specify name of the REST handler script that implements the custom actions to be performed on CRUD operations for the given input. (Use with restHandlerClass) |
restHandlerClass | string | It specify name of the class present in the restHandlerModule, which implements methods like handleCreate, handleEdit, handleList, handleDelete and is child class of splunktaucclib.rest_handler.admin_external.AdminExternalHandler. (Use with restHandlerModule) |
customTab | Object | This property allows you to enable the custom tab feature. |
hideForPlatform | string | Defines for which platform element should be hidden from UI perspective. Currently only two platforms are supported cloud or enterprise . |
Tab components¶
Instead of specifying a tab from scratch with above fields, you can add a predefined tab.
Currently available tab components:
Usage¶
"configuration": {
"title": "Configuration",
"description": "Set up your add-on",
"tabs": [
{
"name": "account",
"title": "Account",
"table": {},
"entity": []
},
{
"name": "proxy",
"title": "Proxy",
"entity": [],
"options": {
"saveValidator": ""
}
},
{
"type": "loggingTab"
}
]
}
Note: The example above creates a Configuration page with two empty tabs: Account and Proxy.
Specify your properties in "table"
and "entity"
.
Output¶
This is how table looks in the UI:
This is how form looks in the UI:
More information about how to set Proxy tab, can be found here.
Logging¶
The logging tab is a predefined component that allows to create the page for changing
the log level. It is added in the pages.configuration.tabs
array
Minimal definition¶
{
"type": "loggingTab"
}
This creates the tab seen in the image above with log levels:
DEBUG, INFO, WARNING, ERROR, CRITICAL. INFO is the default level.
The value is saved in loglevel
config parameter.
Usage¶
It is placed just like every other configuration tab.
{
"pages": {
"configuration": {
"tabs": [
{
"type": "loggingTab"
}
],
"title": "Configuration",
"description": "..."
}
}
}
Optional Fields¶
Field Name | Description |
---|---|
name | Tab name. Default is logging |
title | Tab title. Default is Logging |
label | Label text displayed next to the log level dropdown. Default is Log level |
field | Configuration field name. Default is loglevel |
levels | List of all possible log levels. Default is ["DEBUG", "INFO", "WARNING", "ERROR", "CRITICAL"] |
defaultLevel | Default log level at the beginning. Default is INFO |
help | It is displayed directly below the input field. By default it is not shown. |
Example¶
{
"type": "loggingTab",
"name": "logging_other",
"title": "Logging other",
"label": "Log level",
"field": "loglevel",
"levels": ["DEBUG", "INFO", "WARNING", "ERROR", "CRITICAL"],
"defaultLevel": "INFO",
"help": "The logging level you want to use"
}
Proxy¶
There are fields that need to be specified in order to enable proxy.
Fields¶
Field Name | Description |
---|---|
proxy_enabled | Whether proxy should be enabled. |
proxy_type | Proxy type. Available values: http, http_no_tunnel, socks4, socks5 |
proxy_url | Host |
proxy_port | Port |
proxy_username | Username used to access the proxy server |
proxy_password | Password assigned for that username |
proxy_rdns | Whether reverse DNS resolution should be used |
Example Tab¶
{
"name": "proxy",
"title": "Proxy",
"entity": [
{
"type": "checkbox",
"label": "Enable",
"field": "proxy_enabled"
},
{
"type": "singleSelect",
"label": "Proxy Type",
"options": {
"disableSearch": true,
"autoCompleteFields": [
{
"value": "http",
"label": "http"
},
{
"value": "socks4",
"label": "socks4"
},
{
"value": "socks5",
"label": "socks5"
}
]
},
"defaultValue": "http",
"field": "proxy_type"
},
{
"type": "text",
"label": "Host",
"validators": [
{
"type": "string",
"errorMsg": "Max host length is 4096",
"minLength": 0,
"maxLength": 4096
}
],
"field": "proxy_url"
},
{
"type": "text",
"label": "Port",
"validators": [
{
"type": "number",
"range": [
1,
65535
]
}
],
"field": "proxy_port"
},
{
"type": "text",
"label": "Username",
"validators": [
{
"type": "string",
"errorMsg": "Max length of username is 50",
"minLength": 0,
"maxLength": 50
}
],
"field": "proxy_username"
},
{
"type": "text",
"label": "Password",
"validators": [
{
"type": "string",
"errorMsg": "Max length of password is 8192",
"minLength": 0,
"maxLength": 8192
}
],
"encrypted": true,
"field": "proxy_password"
},
{
"type": "checkbox",
"label": "Reverse DNS resolution",
"field": "proxy_rdns"
}
],
"options": {
"saveValidator": "function(formData) { if(!formData.proxy_enabled || formData.proxy_enabled === '0') {return true; } if(!formData.proxy_url) { return 'Proxy Host can not be empty'; } if(!formData.proxy_port) { return 'Proxy Port can not be empty'; } return true; }"
}
}
The example above creates the following form:
Ended: Configuration
Dashboard¶
Overview¶
UCC introduces a monitoring dashboard page, which is available from v5.42.0.
Page is fully based on the UDF framework (Unified Dashboard Framework) and Splunk UI components. More information can be found here.
The dashboard page configuration is generated if the ucc-gen init
command is used.
The dashboard page is optional, you can delete it from configuration if you
don’t need it in your add-on.
The dashboard page provides some additional information about the add-on operations to increase the visibility into what the add-on is actually doing under the hood.
As of now, 4 pre-built panels are supported:
- Overview
- Data ingestion
- Errors in the add-on.
- Resource consumption.
IMPORTANT:
- To fully use the panels available on the monitoring dashboard, use the
solnlib.log
’sevents_ingested
function, to record events. Due to some changes in dashboard queries in UCC version 5.49.0, you must usesolnlib
in at least version 5.2.0. - Sometimes, especially with a short data collection period, the first chart in the overview section may not display data when the all time period is selected.
This is because the
join
function used to aggregate data volume and number of ingested events does not have a default span for the all time range. Over time, the problem should automatically disappear.
The above events_ingested
function takes 5 positional parameters which are:
logger
modular_input_name
sourcetype
n_events
index
and 2 optional named parameters:
account
host
license_usage_source
(available from version 5.2)
If you additionally provide account
and host
arguments - you will get a better visibility in your dashboard.
Please note that as a modular_input_name
you should pass the full input in the format: demo_input://my_input_1
.
If for your add-on license usage
file writes data in a source format that doesn’t fit the above, the events_ingested
function in solnlib v5.2
has an additional, optional parameter license_usage_source
that allows for proper data correlation
between license usage and data written by the events_ingested
function.
Example of an events_ingested
function:
from solnlib import log
log.events_ingested(
logger,
"demo_input://my_input1",
"my_sourcetype",
2,
"my_index",
account="my_account"
)
as a reference, you can check the input in the demo add-on described here.
IMPORTANT: From version v5.46.0 the error section has been expanded to include a division into error categories. This solution is based on additional exception logging functions:
log_connection_error
log_configuration_error
log_permission_error
log_authentication_error
log_server_error
Above functions take 2 mandatory parameters:
logger
- your add-on loggerexc
- exception thrown
and 3 optional parameters:
full_msg
- if set to True, full traceback will be logged. Default: Truemsg_before
- custom message before exception traceback. Default: Nonemsg_after
- custom message after exception traceback. Default: None
Additionally, function log_exception
has a new, mandatory parameter exc_label
thanks to which you can log your own, non-standard types.
All of the above is available in the log
module of the solnlib
library from version 5.0. Please make sure you are using this version of solnlib
library if you want to take full advantage of the extended error panel.
Example of a logging functions:
from solnlib import log
...
except MyCustomException as e:
log.log_exception(logger, e, "my custom error")
except UnauthorisedError as e:
log.log_authentication_error(logger, e)
except PermissionError as e:
log.log_permission_error(logger, e, msg_after="test after")
except ConnectionError as e:
log.log_connection_error(logger, e, msg_before="test before", msg_after="test after")
except AddonConfigurationError as e:
log.log_configuration_error(logger, e, full_msg=False, msg_before="test before")
except ServiceServerError as e:
log.log_server_error(logger, e)
except Exception as e:
log.log_exception(logger, e, "Other")
By default, the error section displays events logged with the ERROR level, but since version 5.50 UCC allows the user to define what level of logs should be displayed in this section. There are two levels to choose from:
- ERROR
- CRITICAL
"dashboard": {
"panels": [
{
"name": "default"
}
],
"settings": {
"error_panel_log_lvl": [
"ERROR",
"CRITICAL"
]
}
}
Configuration¶
To be able to add a monitoring dashboard page to an existing add-on, you need to adjust your globalConfig file and include a new “dashboard” page there. See the following example:
{
"pages": {
"configuration": {
"tabs": [
...
],
"title": "Configuration",
"description": "Set up your add-on"
},
"inputs": {
"services": [
...
],
"title": "Inputs",
"description": "Manage your data inputs",
"table": {
...
}
},
"dashboard": {
"panels": [
{
"name": "default"
}
]
}
},
"meta": {
...
}
}
Migration path¶
Default, XML-based dashboard will be migrated during the build process. All the necessary changes will be made automatically.
Custom components¶
UCC also supports adding your own components to the dashboard. To do this, create a custom_dashboard.json file in the add-on’s root directory (at the same level as globalConfig.json).
This definition json file must be created according to the UDF framework standards described here
custom_dashboard.json location:
<TA>
├── package
...
├── custom_dashboard.json
├── globalConfig.json
...
Sample custom_dashboard.json structure:
{
"visualizations": {
"custom_dashboard_main_label": {
"type": "splunk.markdown",
"options": {
"markdown": "# My custom dashboard",
"fontSize": "extraLarge"
}
},
"custom_addon_version_label": {
"type": "splunk.markdown",
"options": {
"markdown": "# Add-on version:",
"fontSize": "large"
}
},
"custom_addon_version": {
"type": "splunk.singlevalue",
"options": {
"majorFontSize": 34,
"backgroundColor": "transparent"
},
"dataSources": {
"primary": "custom_addon_version_ds"
}
},
"custom_events_ingested_label": {
"type": "splunk.markdown",
"options": {
"markdown": "# Events ingested by sourcetype:",
"fontSize": "default"
}
},
"custom_events_ingested": {
"type": "splunk.line",
"options": {
"xAxisVisibility": "hide",
"seriesColors": [
"#A870EF"
],
"yAxisTitleText": "Events ingested"
},
"title": "Events ingested by sourcetype",
"dataSources": {
"primary": "custom_events_ingested_ds"
}
}
},
"dataSources": {
"custom_addon_version_ds": {
"type": "ds.search",
"options": {
"query": "| rest services/apps/local/demo_addon_for_splunk splunk_server=local | fields version"
}
},
"custom_events_ingested_ds": {
"type": "ds.search",
"options": {
"query": "index=_internal source=*demo_addon* action=events_ingested\n| timechart sum(n_events) by sourcetype_ingested",
"queryParameters": {
"earliest": "$events_ingested_time.earliest$",
"latest": "$events_ingested_time.latest$"
}
}
}
},
"inputs": {
"custom_events_ingested_input": {
"options": {
"defaultValue": "-7d,now",
"token": "events_ingested_time"
},
"title": "Time",
"type": "input.timerange"
}
},
"layout": {
"type": "grid",
"globalInputs": [
"custom_events_ingested_input"
],
"structure": [
{
"item": "custom_dashboard_main_label",
"position": {
"x": 20,
"y": 500,
"w": 300,
"h": 50
}
},
{
"item": "custom_addon_version_label",
"position": {
"x": 20,
"y": 530,
"w": 100,
"h": 50
}
},
{
"item": "custom_addon_version",
"position": {
"x": 80,
"y": 515,
"w": 100,
"h": 50
}
},
{
"item": "custom_events_ingested_label",
"position": {
"x": 20,
"y": 550,
"w": 100,
"h": 50
}
},
{
"item": "custom_events_ingested",
"position": {
"x": 20,
"y": 580,
"w": 600,
"h": 150
}
}
]
}
}
Next, you have to add the custom panel to your dashboard page in globalConfig.json.
{
...
"dashboard": {
"panels": [
{
"name": "default"
},
{
"name": "custom"
}
]
}
...
}
By default, the custom dashboard will be added as an additional tab under the overview section called Custom
.
If you would like to change the tab name from Custom to any other value, you can do it in the globalConfig.json
.
Global config, from UCC version v5.47.0, has an additional settings
parameter for the dashboard section. To change the name of a custom tab, add the custom_tab_name
attribute in the settings
.
{
...
"dashboard": {
"panels": [
{
"name": "custom"
}
],
"settings": {
"custom_tab_name": "My custom tab name"
}
},
...
}
It is possible to enable only a custom panel. To do this, remove the “default” element from globalConfig.json.
{
...
"dashboard": {
"panels": [
{
"name": "custom"
}
]
}
...
}
Data volume¶
To obtain information on data volume usage, the monitoring dashboard uses logs saved in the license_usage.log
file.
By default, data filtering for a specific add-on is based on the source
(s) and names of individual inputs.
e.g.
...source=*license_usage.log type=Usage (s IN (demo_addon_release_2*,my_input_2*))...
If data is saved in your add-on with different, non-standard values or if filtering logs
using the source is not possible, UCC v5.47 offers the ability to define how the search engine should
find data regarding a given add-on.
To do this, you need to add the custom_license_usage
parameter in globalconfig in the dashboard -> settings section.
This parameter takes 2 mandatory items:
determine_by
-> is used to determine the filtering basis. It can take one of 4 possible arguments: (“source”, “sourcetype”, “host”, “index”).search_condition
-> list of strings type parameter where you can provide elements that will be used to filter events in the license usage file.
e.g. of globalConfig.json:
{
...
"dashboard": {
"panels": [
{
"name": "custom"
}
],
"settings": {
"custom_license_usage": {
"determine_by": "sourcetype",
"search_condition": [
"*addon123*",
"my_custom_condition*"
]
}
}
},
...
}
the above configuration will create the following filter query:
...source=*license_usage.log type=Usage (st IN ("*addon123*","my_custom_condition*"))...
Note:
- In the Data Ingestion table, the first column displays the
View by
options list. When you click on any row in this column, a modal opens, showing detailed information such asData volume
and theNumber of events
over time, visualized in charts. The modal allows you to adjust the options via a dropdown to view data for different View by options. This enables dynamic exploration of data trends for various selected inputs.
Alert actions ↵
Alert Actions¶
The alert action can help a user to take action on the alerts that have been triggered. The knowledge from Splunk can be sent to an outside service or to pull additional or detailed information related to the trigger details. An add-on can have multiple alert actions based on the use cases the add-on provides. You can know more about alert actions from this documentation.
Developers are required to add alerts in the global config file to create an Alert Action. All the alerts (belonging to all the add-ons and apps) present on a Splunk instance would be shown in the “Trigger Actions” section when creating an alert.
Properties¶
Property | Type | Description |
---|---|---|
name* | string | Alphanumeric name that would be used to generate the Python file for the alert action. |
label* | string | User-friendly name of the alert action that would be seen in the Trigger Actions. |
entity* | array | Array of inputs that would be available in the alert action. |
iconFileName | string | The name of the icon to be shown in the Alert Action UI. It has to be present in <YOUR_ADD-ON_NAME>/appserver/static/ directory. Default file name (and icon): alerticon.png that comes with UCC framework. |
description* | string | Description of the alert action. |
activeResponse | object | Define only if the alert action will be visible for AR in Splunk Enterprise Security app. Note: DEPRECATED. Use adaptiveResponse instead. |
adaptiveResponse | object | Define only if the alert action will be visible for AR in Splunk Enterprise Security app. Refer this section for complete details. |
customScript | string | A Python script that would have validation and logic for alert action execution. The script should be present at <YOUR_ADD-ON_NAME>/bin/ . Refer this section for more information. |
Alert Properties¶
Property | Type | Description |
---|---|---|
type* | string | The type of the user input in the alert. Available choices: “text”, “textarea”, “checkbox”, “singleSelect”, “radio”, “singleSelectSplunkSearch”. |
label* | string | The text that would be shown in the alert action UI. |
field* | string | The field that would be used in the scripts to get the value from the user input. These are defined as param.<field_mentioned> in the alert_actions.conf . |
options | array | Static choices that a user can select in the alert action UI. |
required | boolean | Whether the mentioned field is required or not. Default: false |
help | string | Help text to be shown under the field of the alert. |
search | string | A Splunk SPL that would query and return some result. Query the REST API, a lookup table, or indexed data. |
valueField | string | Field name to use for drop-down option values that correspond to the option labels. In some cases, you can use the same results field for the label-field and value-field. In other cases, you might need to display human-readable labels from one field and use the corresponding values from another field. Note: Applicable when a search property is defined. |
labelField | string | Field name to use for drop-down option labels. Labels generated from this field are visible in the drop-down interface. Note: Applicable when a search property is defined. |
Usage¶
This is how the global configuration looks like for an alert action:
"alerts": [
{
"name": "test_alert",
"label": "Test Alert",
"description": "Description for your Alert Action",
"entity": [
{
"type": "singleSelectSplunkSearch",
"label": "Select Account",
"field": "account",
"search": "| rest /servicesNS/nobody/Splunk_TA_UCCExample/splunk_ta_uccexample_account splunk_server=local | dedup title",
"options": {
"items": [
{
"label": "earliest",
"value": "-4@h"
},
{
"label": "latest",
"value": "now"
}
]
},
"valueField": "title",
"labelField": "title",
"help": "Select an account from the dropdown",
"required": true
},
{
"type": "text",
"label": "Name",
"field": "name",
"defaultValue": "my_name",
"required": true,
"help": "Please enter your Name"
},
{
"type": "checkbox",
"label": "Run for All",
"field": "run_for_all",
"defaultValue": 0,
"required": false,
"help": "Check if you want to run alert action for all "
},
{
"type": "singleSelect",
"label": "Item List",
"field": "item_list",
"options": {
"items": [
{
"value": "option_1",
"label": "Option 1"
},
{
"value": "option_2",
"label": "Option 2"
}
]
},
"help": "Select any one option from the list",
"required": false,
"defaultValue": "option_1"
},
{
"type": "radio",
"label": "Action:",
"field": "action",
"options": {
"items": [
{
"value": "update",
"label": "Update"
},
{
"value": "insert",
"label": "Insert"
}
]
},
"help": "Select the action you want to perform",
"required": true,
"defaultValue": "insert"
}
]
}
]
Output¶
This is how the alert action looks like in the UI:
Refer the Alert Scripts section to know what all files are created and how they can be updated to achieve the use case of your add-on.
Alert Action Scripts¶
The following files would be created/ updated in the output folder once you executed the ucc-gen
command:
File Location | Content Description | Action |
---|---|---|
output/<YOUR_ADD-ON_NAME>/bin/<NAME_OF_THE_ALERT>.py | The logic that will be executed when the alert action would be executed. | Created |
output/<YOUR_ADD-ON_NAME>/default/alert_actions.conf | Helps Splunk determine the parameters supported by the alert action when using sendalert Splunk command. |
A stanza with the name as <NAME_OF_THE_ALERT> is created in this conf file. |
output/<YOUR_ADD-ON_NAME>/default/data/ui/alerts/<NAME_OF_THE_ALERT>.html | HTML page of the Alert Action that will be rendered in the UI. | Created |
In the python file that is created, below are the methods that you can use or override for varying use cases:
process_event()
- This is the start point of where you require to write the logic of sending data from Splunk to any other
service via its APIs. Additionally, you can validate the parameters that are provided in the alert action
as client side validation (via JavaScript) isn’t allowed in Splunk’s alert action’s HTML page for
security reasons.
Note: This method must be overwritten.
- This is the start point of where you require to write the logic of sending data from Splunk to any other
service via its APIs. Additionally, you can validate the parameters that are provided in the alert action
as client side validation (via JavaScript) isn’t allowed in Splunk’s alert action’s HTML page for
security reasons.
get_events()
-> List[dict]- Used to get the events that triggered the alert. It returns a list of dictionary. A dictionary points to an event that triggered the alert, and each dictionary has the fields extracted by Splunk.
addevent(raw: str, sourcetype: str)
- If you are bringing additional information from an outer service, you can write that information using this method. You write a single record using the method. This method will append all the records and will dump it to Splunk when
writeevents()
method is called.
- If you are bringing additional information from an outer service, you can write that information using this method. You write a single record using the method. This method will append all the records and will dump it to Splunk when
writeevents(index: str, host: str, source: str)
- All the events added to the queue using
addevent()
method are written to Splunk with the details passed in the arguments.
- All the events added to the queue using
An example of a script with validations:
import import_declare_test
import sys
from splunktaucclib.alert_actions_base import ModularAlertBase
from splunk_ta_uccexample import modalert_test_alert_helper
class AlertActionWorkertest_alert(ModularAlertBase):
def __init__(self, ta_name, alert_name):
super(AlertActionWorkertest_alert, self).__init__(ta_name, alert_name)
def validate_params(self):
if not self.get_param("name"):
self.log_error('name is a mandatory parameter, but its value is None.')
return False
if not self.get_param("action"):
self.log_error('action is a mandatory parameter, but its value is None.')
return False
if not self.get_param("account"):
self.log_error('account is a mandatory parameter, but its value is None.')
return False
return True
def process_event(self, *args, **kwargs):
status = 0
try:
if not self.validate_params():
return 3
status = modalert_test_alert_helper.process_event(self, *args, **kwargs)
except (AttributeError, TypeError) as ae:
self.log_error("Error: {}. Please double check spelling and also verify that a "
"compatible version of Splunk_SA_CIM is installed.".format(str(ae)))
return 4
except Exception as e:
msg = "Unexpected error: {}."
if str(e):
self.log_error(msg.format(str(e)))
else:
import traceback
self.log_error(msg.format(traceback.format_exc()))
return 5
return status
if __name__ == "__main__":
exitcode = AlertActionWorkertest_alert("Splunk_TA_UCCExample", "test_alert").run(sys.argv)
sys.exit(exitcode)
In this example, modalert_test_alert_helper
’s process_event()
method contains the logic of the actions to be
performed when the alert is triggered. It could either be fetch additional information from a service
into Splunk or to send any data from Splunk to a service via its APIs.
Custom Script for Alert Action¶
Alternatively, you can provide the process_event()
and validate_params()
in the script you mentioned in
the customScript
parameter in the globalConfig. If the parameter isn’t provided in the globalConfig, UCC framework would provide a boiler plate code that you can leverage in writing your logic for alert action.
This script should be present at <YOUR_ADD-ON_REPOSITORY_PACKAGE>/bin/
in your respository and it should
have process_event()
function defined. An example declaration could be:
def my_custom_validation(helper):
# custom validation logic for the params that are passed
return 0 # for successful custom validations
def process_event(helper, *args, **kwargs):
if not my_custom_validation(helper):
return 3
helper.log_info("Alert action test_alert started.")
# TODO: Implement your alert action logic here
# if clean execution, return 0,
# else non-zero number
return 0
This function then can have validations and the alert action logic required for your add-on. The preliminary check for required field validations is already provided by the UCC framework. However, if you have any other validations or pre-checks, you can call that function from process_event()
.
The helper
variable would be an object of splunktaucclib.alert_actions_base.ModularAlertBase
class.
This script would be then be copied to output/
directory after you execute the ucc-gen
command.
Adaptive Response¶
The Adaptive Response framework provides a mechanism for running preconfigured actions within the Splunk platform or by integrating with external applications. These actions can be automatically triggered by correlation search results or manually run on an ad hoc basis from the Incident Review dashboard inside the Enterpise Security app. You can read more about this framework here.
In case your add-on is integrated with Enterprise Security, you can define the configurations in
the alert action details in your add-on’s globalConfig
and it will create the necessary triggers for it.
Adaptive Response Properties¶
Property | Type | Description |
---|---|---|
task* | string | The function or functions performed by the modular action. |
subject* | string | The object or objects that the modular action’s task(s) can be performed on (i.e. “endpoint.file”). |
category* | array | The category or categories the modular action belongs to. |
technology* | string | The technology or technologies that the modular action supports. |
supportsAdhoc | boolean | Specifies if the modular action supports adhoc invocations. Default: false |
supportsCloud | boolean | Specifies if the modular actions supports the “cloud” model. Default: true |
drilldownUri | string | Specifies a custom target for viewing the events outputted as a result of the action. Custom target can specify app and/or view depending on syntax. |
sourcetype | string | The sourcetype in which the result of the AR alert action would be written to. The value is updated in the alert action script. If you don’t specify any value you can update your alert action script manually once it is generated. |
An example of adaptive response in globalConfig:
"alerts": [
{
"name": "test_alert",
"label": "Test Alert",
"description": "Description for test Alert Action",
"iconFileName": "test icon.png",
"adaptiveResponse": {
"task": [
"Create",
"Update"
],
"supportsAdhoc": true,
"supportsCloud": true,
"subject": [
"endpoint"
],
"category": [
"Information Conveyance",
"Information Portrayal"
],
"technology": [
{
"version": [
"1.0.0"
],
"product": "Test Incident Update",
"vendor": "Splunk"
}
],
"drilldownUri": "search?q=search%20index%3D\"_internal\"&earliest=0&latest=",
"sourcetype": "test:incident"
},
"entity": [ "..." ]
}
]
The above would create an attribute in output/<YOUR_ADDON_NAME>/default/alert_action.conf
as following:
[test_alert]
label = Test Alert
description = Description for test Alert Action
icon_path = test icon.png
is_custom = 1
param._cam = {"task": ["Create", "Update"], "subject": ["endpoint"], "category": ["Information Conveyance", "Information Portrayal"], "technology": [{"version": ["1.0.0"], "product": "Test Incident Update", "vendor": "Splunk"}], "supports_adhoc": true, "supports_cloud": true, "drilldown_uri": "search?q=search%20index%3D\"_internal\"&earliest=0&latest="}
# ... rest of the properties mentioned in the alert action configuration
You can refer this dev documentation for details on updating alert action scripts such that they can be used in the Adaptive Response framework.
Ended: Alert actions
Entity ↵
Entity¶
Entity Properties¶
Property | Type | Description | Default Value |
---|---|---|---|
field* | string | To define a particular entity field. | - |
label* | string | It represents a caption for a field in a user interface. | - |
type* | string | To specify the type of entity to be rendered in inputs or configuration form. | - |
help | string | Help text gives context about a fields input, such as how the input will be used. It is displayed directly below an input field. | - |
tooltip | string | Displays a tooltip beside the label. | - |
defaultValue | string, number or boolean | The initial input value. | - |
options | object | To specify an additional attribute for a particular type of entity, such as items for a radio bar. |
- |
required | boolean | To specify whether the field is required or not. | false |
encrypted | boolean | To encrypt that particular field. | false |
validators | array | It is used to validate the values of fields using various validators. It is strongly advised to specify validators for every entity. | - |
modifyFieldsOnValue | array | It is used to specify values and parameters that will influence visually other entities. | - |
Placeholder deprecation
The Placeholder attribute is deprecated and renounced.
The placeholder text is no longer displayed in the UI. Instead, use the help
attribute.
Common Options¶
This section describes common options that can be used within the options
object in entity properties.
Property | Type | Description | Default Value |
---|---|---|---|
display | boolean | It chooses whether or not to display the field. | true |
disableonEdit | boolean | When the form is in edit mode, the field becomes unable to be edited. | false |
enable | boolean | The enable property sets whether a field is enabled or not. | true |
requiredWhenVisible | boolean | It makes the field required on the UI when it appears. It is used only for visibility. | false |
hideForPlatform | string | Defines for which platform element should be hidden from UI perspective. Currently only two platforms are supported cloud or enterprise . |
- |
placeholder | string | (Renounced ) The grey text is shown when the input is empty. |
- |
Components supported by UCC¶
Components are used by UCC to render the Inputs and Configuration pages. See the following list of the supported components.
For a detailed look at our component implementations and to interact with them in a live environment, visit our Storybook library.
Text
¶
See the underlying @splunk/react-ui
component: Text
.
See the following example usage:
{
"type": "text",
"label": "Name",
"validators": [
{
"type": "string",
"errorMsg": "Length of Name should be between 1 to 50 characters.",
"minLength": 1,
"maxLength": 50
},
{
"type": "regex",
"errorMsg": "Name must begin with a letter and consist exclusively of alphanumeric characters and underscores.",
"pattern": "^[a-zA-Z]\\w*$"
}
],
"field": "name",
"help": "Enter a unique name for this account.",
"required": true
}
This is how it looks in the UI:
Text Area
¶
See the underlying @splunk/react-ui
component: TextArea
.
The textarea
component is very similar to the text
component, but allows you to have a multi-line input for text.
Options¶
Property | Type | Description | Default Value |
---|---|---|---|
rowsMax | number | Maximum number of rows to display. | 12 |
rowsMin | number | Minimum number of rows to display. | 8 |
See the following example:
{
"type": "textarea",
"label": "Textarea Field",
"field": "textarea_field",
"help": "Help message",
"options": {
"rowsMin": 3,
"rowsMax": 15
},
"required": true
}
This is how it looks in the UI:
Single Select
¶
A singleSelect
is a feature that combines a drop-down box, and/or editable text field, giving the user multiple ways to input or select the desired information.
See the underlying @splunk/react-ui
components: Select
or Combo Box
depending on the createSearchChoice
option.
When the createSearchChoice
option is set to true, the Singleselect component becomes a text input with auto-complete.
A clear button is visible to the right of the dropdown when this field is marked as required.
Options¶
Property | Type | Description | Default Value |
---|---|---|---|
disableSearch | boolean | It determines whether to show the filter box. When false, the children are automatically filtered based on the label. | false |
createSearchChoice | boolean | It allows the user to add arbitrary values. | false |
referenceName | string | Dropdown options will be generated via an API call to the service’s restHandler. | - |
endpointUrl | string | Dropdown options will be generated via an API call to that endpoint. | - |
allowList | string | It only accepts options that match the regex based on the name attribute when received via an API call using endpointUrl and referenceName . It is applied before denyList. |
- |
denyList | string | It filters options that don’t match the regex based on the name attribute when received via an API call using endpointUrl and referenceName . |
- |
labelField | string | If you use endpointUrl and your data are not simple text data, you can specify here which property of retrieved object should be used as label for each item.item.content?.[labelField] |
- |
valueField | string | If you use endpointUrl and your data are not simple text data, you can specify here which property of retrieved object should be used as value for each item.item.content?.[valueField] |
- |
dependencies | array | It is used to update the options via an API call when the value of any field in the dependencies list is updated. | - |
When using Boolean values on any form inside configuration page, consider that inside splunk values like ‘TRUE’, ‘T’, ‘Y’, ‘YES’, true will be converted into ‘1’ and values like ‘FALSE’, ‘F’, ‘N’, ‘NO’, ‘NONE’, false will be converted into ‘0’.
Consider using values ‘0’ and ‘1’ as false and true values.
See the following example usage¶
Using referenceName option¶
{
"type": "singleSelect",
"label": "Example Account",
"options": {
"referenceName": "account"
},
"help": "",
"field": "account",
"required": true
}
This is how it looks in the UI:
Using autoCompleteFields Options¶
{
"type": "singleSelect",
"label": "Proxy Type",
"options": {
"disableSearch": true,
"autoCompleteFields": [
{
"value": "http",
"label": "http"
},
{
"value": "socks5",
"label": "socks5"
}
]
},
"defaultValue": "http",
"field": "proxy_type"
}
This is how it looks in the UI:
Using createSearchChoice option¶
{
"type": "singleSelect",
"label": "Index",
"validators": [
{
"type": "string",
"errorMsg": "Length of index name should be between 1 to 80 characters.",
"minLength": 1,
"maxLength": 80
}
],
"defaultValue": "default",
"options": {
"endpointUrl": "data/indexes",
"denyList": "^_.*$",
"createSearchChoice": true
},
"field": "index",
"required": true
}
This is how it looks in the UI:
Using autoCompleteFields option with groups¶
{
"field": "singleSelectTest",
"label": "Single Select Group Test",
"type": "singleSelect",
"options": {
"createSearchChoice": true,
"autoCompleteFields": [
{
"label": "Group1",
"children": [
{
"value": "one",
"label": "One"
},
{
"value": "two",
"label": "Two"
}
]
},
{
"label": "Group2",
"children": [
{
"value": "three",
"label": "Three"
},
{
"value": "four",
"label": "Four"
}
]
}
]
}
}
This is how it looks in the UI:
Checkbox
¶
See the underlying @splunk/react-ui
component: Switch
.
See the following example usage:
{
"type": "checkbox",
"label": "Enable",
"field": "proxy_enabled"
}
This is how it looks in the UI:
CheckboxGroup
¶
See the following example usage:
{
"type": "checkboxGroup",
"label": "CheckboxGroupTitle",
"field": "api3",
"options": {
"groups": [
{
"label": "Group 1",
"options": {
"isExpandable": true,
"expand": true
},
"fields": ["rowUnderGroup1"]
},
{
"label": "Group 3",
"options": {
"isExpandable": true,
"expand": true
},
"fields": ["field223", "160validation"]
}
],
"rows": [
{
"field": "rowWithoutGroup",
"input": {
"defaultValue": 1,
"required": true
}
},
{
"field": "rowUnderGroup1",
"checkbox": {
"label": "Row under Group 1",
"defaultValue": true
},
"input": {
"defaultValue": 1200,
"required": false
}
},
{
"field": "field223",
"checkbox": {
"label": "Required field",
"defaultValue": true
},
"input": {
"required": true
}
},
{
"field": "160validation",
"checkbox": {
"label": "from 1 to 60 validation"
},
"input": {
"validators": [
{
"type": "number",
"range": [1, 60]
}
]
}
}
]
}
}
This is how it looks in the UI:
The component maps and unmaps values into a single field in the format fieldName1/fieldValue1,fieldName2/fieldValue2
, but only for checked rows. For the given example, it emits the following value: rowUnderGroup1/1200,requiredField/10
.
Multiple Select
¶
See the underlying @splunk/react-ui
component: Multiselect
.
Multiselect allows the user to select multiple options at once.
Options¶
Property | Type | Description | Default Value |
---|---|---|---|
items | array | An array of options with a label and a value. | - |
delimiter | string | It delimits each value of the field with a predefined character. For example, In the data option_a|option_b, a vertical bar (the pipe character) delimits the two data items option_a and option_b. |
comma(, ) |
createSearchChoice | boolean | It allows the user to add arbitrary values. | false |
referenceName | string | Dropdown options will be generated via an API call to the service’s restHandler. | - |
endpointUrl | string | Dropdown options will be generated via an API call to that endpoint. | - |
allowList | string | It only accepts options that match the regex based on the name attribute when received via API call using endpointUrl and referenceName . It is applied before denyList. |
- |
denyList | string | It filters options that don’t match the regex based on the name attribute when received via API call using endpointUrl and referenceName . |
- |
labelField | string | If you use endpointUrl and your data are not simple text data, you can specify here which property of retrieved object should be used as label for each item.item.content?.[labelField] |
- |
valueField | string | If you use endpointUrl and your data are not simple text data, you can specify here which property of retrieved object should be used as value for each item.item.content?.[valueField] |
- |
dependencies | array | It is used to update options via an API call when the value of any field in the dependencies list is updated. | - |
autoCompleteFields | array | It is used to add options in the Single select or Multiple select component. | - |
See the following example usage:
{
"type": "multipleSelect",
"field": "test_multiselect",
"label": "Test Multiselect",
"options": {
"delimiter": "|",
"items": [
{
"value": "option_a",
"label": "Option A"
},
{
"value": "option_b",
"label": "Option B"
}
]
}
}
This is how it looks in the UI:
Radio Bar
¶
See the underlying @splunk/react-ui
component: RadioBar
.
RadioBar is a component that provides the ability to select one option out of a group. It can be used when we need to select a field value from a few options.
Options¶
Property | Type | Description | Default Value |
---|---|---|---|
items* | array | This property is an array of options with a label and a value. | - |
See the following example usage:
{
"field": "test_radio",
"label": "Test Radio",
"type": "radio",
"defaultValue": "Yes",
"required": false,
"options": {
"items": [
{
"value": "yes",
"label": "Yes"
},
{
"value": "no",
"label": "No"
}
],
"display": true
}
}
This is how it looks in the UI:
When using Boolean values on any form inside configuration page, consider that inside splunk values like ‘TRUE’, ‘T’, ‘Y’, ‘YES’, true will be converted into ‘1’ and values like ‘FALSE’, ‘F’, ‘N’, ‘NO’, ‘NONE’, false will be converted into ‘0’.
Consider using values ‘0’ and ‘1’ as false and true values.
Help Link
¶
See the underlying @splunk/react-ui
component: Link
.
It will open the link in a new tab.
Options¶
Property | Type | Description | Default Value |
---|---|---|---|
text* | string | It is a message to be displayed. | - |
link* | string | It is a link where the user will be redirected. | - |
See the following example usage:
{
"field": "example_help_link",
"label": "",
"type": "helpLink",
"options": {
"text": "Help Link",
"link": "https://docs.splunk.com/Documentation",
}
}
This is how it looks in the UI:
File
¶
See the underlying @splunk/react-ui
component: File
.
By default it supports files that can be opened in text mode or with a text editor, which are files with extensions such as txt, json, xml, yaml, pem, key, crt, etc.
It only sends file content to the server by reading it using the readAsArrayBuffer method of the FileReader class, and then decoding it into UTF-8 format, using the decode method of the TextDecoder class.
If options
property contains useBase64Encoding is set up as true, then readAsArrayBuffer method is replaced with readAsDataURL and obtained data are correctly proceeded to store only file content (beggining of result is removed, as it contains unwanted informations and pure encoded file content is saved). With that approach any file is stored in Base64 format.
The file content can be validated using in-built validators such as string and regex, and a custom validator can also be implemented using a custom hook and saveValidator.
This feature allows you to upload a single file.
Options¶
Property | Type | Description | Default Value |
---|---|---|---|
fileSupportMessage | string | It displays a message inside a file component. | - |
supportedFileTypes* | array | It is a list of the file types that the user can upload. | - |
maxFileSize | number | It sets the maximum file size in KB that a user can upload. | 500KB |
useBase64Encoding | boolean | It defines used encoding for files. If true base64 will be used, if false utf-8 is applied. | false |
See the following example usage:
{
"type": "file",
"label": "SA certificate",
"help": "Upload service account's certificate",
"field": "service_account",
"options": {
"fileSupportMessage": "Support message",
"supportedFileTypes": ["pem", "txt"],
"maxFileSize": 100,
"useBase64Encoding": false
},
"validators": [
{
"type": "regex",
"pattern": "(-----BEGIN CERTIFICATE-----(\n|\r|\r\n)([0-9a-zA-Z\+\/=]{64}(\n|\r|\r\n))*([0-9a-zA-Z\+\/=]{1,63}(\n|\r|\r\n))?-----END CERTIFICATE-----)"
}
],
"encrypted": true,
"required": true
}
This is how it looks in the UI:
OAuth
¶
The Oauth type entity enables us to use Oauth2.0 for user authentication. Visit the Oauth Support page to learn more.
Interval
¶
A Text field used to specify interval value, i.e. a number greater than or equal to 0, CRON interval or -1.
Options
Property | Type | Description |
---|---|---|
range | list of numbers (2 elements) | Range of allowed values |
Supported CRON schedule:
- “
“ - Cron special characters are acceptable. (“*”, “,”, “/”, “-” )
Names of months or days are not supported.
Note: Range option is not supposed to be used with CRON interval.
See the following example:
{
"type": "interval",
"label": "Interval",
"field": "interval",
"options": {
"range": [10, 20]
}
}
Index
¶
A field used to specify index.
Attributes
Property | Type | Description |
---|---|---|
type* | string | To specify the type of entity to be rendered in inputs or configuration form. |
field* | string | To define a particular entity field. |
label* | string | Text displayed next to entity field. |
defaultValue | string | The initial input value. |
help | string | Help text gives context about a fields input, such as how the input will be used. It is displayed directly below an input field. |
required | string | To specify whether the field is required or not. |
See the following examples:
Only required attributes provided:
{
"type": "index",
"field": "index",
"label": "Index"
}
All attributes provided:
{
"type": "index",
"field": "index",
"label": "Index",
"help": "An index is a type of data repository. Select the index in which you want to collect the events.",
"defaultValue": "main",
"required": true
}
Index field has two internal validators:
- REGEX that forces index names to start with a letter or digit and can only contain letters, numbers, underscores or hyphens.
- LENGTH which allows for an index name to have of 1 to 80 characters.
endpointUrl
for that entity is data/indexes?search=isInternal=0+disabled=0
During the build process, new index field will be converted to a full definition and saved in the globalConfig in the output directory.
Custom
¶
Custom type entity enables us to create our own custom inputs within the Form components. As a result, we may include our own custom input fields on the form. Visit the Custom Control page to learn more.
Validators¶
Validators define acceptable values for fields.
Specifying validators for all applicable entities is strongly recommended. Omitting validators can expose forms to security risks and cause unexpected behavior. If the value is validated and encapsulated downstream, add an empty array to suppress the warning:
"validators": []
Common Properties¶
type
* specifies which validator type to use.errorMsg
is an optional parameter used to specify a custom error message that displays when validation fails. UCC provides default error messages.
String¶
Properties
minLength
* specifies the minimum number of characters allowed.maxLength
* specifies the maximum number of characters allowed.
See the following example usage:
{
"type": "text",
"label": "Index Name",
"validators": [
{
"type": "string",
"errorMsg": "Length of index name should be between 1 to 80 characters.",
"minLength": 1,
"maxLength": 80
}
],
"field": "index_name"
}
Regex¶
Properties
pattern
* is a Regex pattern.
See the following example usage:
{
"type": "text",
"label": "Name",
"validators": [
{
"type": "regex",
"errorMsg": "Input Name must begin with a letter and consist exclusively of alphanumeric characters and underscores.",
"pattern": "^[a-zA-Z]\\w*$"
}
],
"field": "name_field"
}
Number¶
Properties
range
* is the range within which the target value should fall.isInteger
is the boolean which target only integer value if sets true. Default value is false
See the following example usage:
{
"type": "text",
"label": "Port",
"validators": [
{
"type": "number",
"range": [1, 65535],
"isInteger": true
}
],
"field": "port"
}
URL¶
No parameters are needed.
If you’re using a regexp internally, this regex checks whether a field value is a URL or not.
See the following example usage:
{
"type": "text",
"label": "Url",
"validators": [
{
"type": "url",
}
],
"field": "url"
}
Email¶
No parameters are needed.
Using a regexp internally is recommended by WHATWG.
See the following example usage:
{
"type": "text",
"label": "Email",
"validators": [
{
"type": "email",
}
],
"field": "email"
}
IPV4¶
No parameters are needed.
Internally, it checks the IPV4 address using this regex.
See the following example usage:
{
"field": "testIpv4",
"label": "Test Ipv4",
"type": "text",
"validators": [
{
"type": "ipv4"
}
]
}
Date¶
No parameters are needed.
It is validated if the field’s value is a date in the ISO 8601 format. It uses the regex from moment.js.
See the following example usage:
{
"field": "testDate",
"label": "Test Date",
"type": "text",
"validators": [
{
"type": "date"
}
]
}
Combinations¶
You can combine multiple validators in a single array.
Example:
{
"field": "https_url",
"label": "HTTPS only URL",
"type": "text",
"validators": [
{
"type": "url"
},
{
"type": "regex",
"errorMsg": "HTTPS only",
"pattern": "^https:\/\/"
}
]
}
Modify Fields On Change¶
This feature allows to specify conditions to modify other fields based on current field value change.
Modification Object Properties¶
Property | Type | Description |
---|---|---|
fieldValue* | string | Value that will trigger the update, put [[any_other_value]] to trigger update for any other values than specified |
mode | string | Mode that adds possibility to use modification only on certain mode |
fieldsToModify | array | List of fields modifications that will be applied after com ponent value will match |
fieldsToModify Properties¶
Property | Type | Description |
---|---|---|
fieldId* | string | Used to identify field that modifications will be applied to |
display | boolean | Declares display property of target component |
value | string, number or boolean | Declares current value of target component |
disabled | boolean | Declares if component should be disabled (enable = false) |
required | boolean | Declares if component should be required |
help | string | Declares help text |
label | string | Declares label text |
markdownMessage | object | Declares markdown message to display |
markdownMessage Properties¶
Property | Type | Description |
---|---|---|
markdownType* | string | Declare type of markdown. Accepts: “text”, “hybrid”, “link” |
text* | string | Used for all types to declare message content |
color | string | Used for “text” type to specify color of displayied text. Accepts all CSS colors |
token | string | Used for “hybrid” type to declare string that will be swapped into link |
linkText | string | Used for “hybrid” type to declare string that will put in place of token |
link | string | Used for “hybrid” and “link” types to declare url that will use for redirection |
Usage¶
{
"type": "checkbox",
"label": "Example Checkbox",
"field": "account_checkbox",
"help": "This is an example checkbox for the account entity",
"modifyFieldsOnValue": [
{
"fieldValue": 1,
"fieldsToModify": [
{
"fieldId": "account_radio",
"disabled": false
},
{
"fieldId": "endpoint",
"display": true
}
]
},
{
"fieldValue": 0,
"mode": "edit",
"fieldsToModify": [
{
"fieldId": "account_radio",
"disabled": true
},
{
"fieldId": "endpoint",
"display": false
}
]
}
]
},
{
"label": "Username",
"type": "text",
"help": "Enter the username for this account.",
"field": "username",
"modifyFieldsOnValue": [
{
"fieldValue": "[[any_other_value]]",
"fieldsToModify": [
{
"fieldId": "some_other_field",
"disabled": false,
"display": true,
"label": "New label for other values",
"value": "New value for other values",
"help": "New help for other values",
"markdownMessage": {
"markdownType": "text",
"text": "New markdown message for other values",
"color": "red"
},
"required": false
}
]
},
{
"fieldValue": "a",
"fieldsToModify": [
{
"fieldId": "some_other_field",
"display": true,
"disabled": true,
"label": "New label for value 'a' as username",
"value": "New value for value 'a' as username",
"help": "New help for value 'a' as username",
"markdownMessage": {
"markdownType": "link",
"text": "New markdown message for value 'a' as username",
"link": "https://splunk.github.io/addonfactory-ucc-generator/"
},
"required": true
}
]
},
{
"fieldValue": "aa",
"fieldsToModify": [
{
"fieldId": "some_other_field",
"disabled": false,
"display": false,
"label": "New label for value 'aa' as username",
"value":"New value for value 'aa' as username",
"help": "New help for value 'aa' as username",
"required": true
}
]
},
{
"fieldValue": "aaa",
"fieldsToModify": [
{
"fieldId": "some_other_field",
"disabled": true,
"display": true,
"label": "New label for value 'aaa' as username",
"value": "New value for value 'aaa' as username",
"help": "New help for value 'aaa' as username",
"markdownMessage": {
"markdownType": "hybrid",
"text": "New markdown message token 'aaa' as username",
"link": "https://splunk.github.io/addonfactory-ucc-generator/",
"token": "token",
"linkText": "for value"
},
"required": true
}
]
},
{
"fieldValue": "aaaa",
"mode": "edit",
"fieldsToModify": [
{
"fieldId": "some_other_field",
"disabled": false,
"display": false,
"label": "New label for value 'aaaa' as username used only when editing entity",
"value": "New value for value 'aaaa' as username used only when editing entity",
"help": "New help for value 'aaaa' as username used only when editing entity",
"markdownMessage": {
"markdownType": "text",
"text": "markdown message plain text used only when editing entity"
},
"required": false
}
]
}
]
},
Ended: Entity
Table¶
This is a common feature that is used to display the account and input stanzas on the Inputs and Configuration pages, respectively.
Tables include many built-in features such as sorting, filtering, and pagination.
Properties¶
header
* (Array Objects) specifies the list of columns in the table.field
* is he name of the field where the column data will be displayed.label
* is the title of the column.- mapping is used to map field values to more meaningful values.
- customCell is used to modify the default cell values.
actions
* (Array) specifies what type of action can be performed on the stanza. The supported types areedit
,clone
, anddelete
.moreInfo
(Array Objects) specifies the list of fields that will be displayed in row form when the user clicks the Row Expand button.field
is used to dispaly the data in a column.label
is the title of the column.- mapping is used to map field values to more meaningful values.
- customRow can be used to customise the moreInfo Component.
List of built-in table fields for Modular Input¶
If your add-on has multiple modular inputs and you want to show the input type of each one, use the following in-built field:
Field Name | description |
---|---|
serviceName | It indicates the name of the Input service to be displayed in the table, for example, “example_input_one”. |
serviceTitle | It indicates the title of the Input service to be displayed in the table, for example, “Example Input One”. |
Usage¶
"table": {
"header": [
{
"label": "Name",
"field": "name"
},
{
"label": "Account",
"field": "account"
},
{
"label": "Input Type",
"field": "serviceTitle"
},
{
"label": "Status",
"field": "disabled"
}
],
"moreInfo": [
{
"label": "Name",
"field": "name"
},
{
"label": "Interval",
"field": "interval"
},
{
"label": "Index",
"field": "index"
},
{
"label": "Status",
"field": "disabled",
"mapping": {
"true": "Disabled",
"false": "Enabled"
}
},
{
"label": "Example Account",
"field": "account"
}
],
"actions": ["edit", "delete", "clone"]
}
Output¶
This is how it looks in the UI:
additional_packaging.py
file¶
To extend the build process, you can create a additional_packaging.py
file in the same file level where you have your globalConfig file.
This file should at least have:
- the
cleanup_output_files
function, which acceptsoutput_path
(str),add-on name
(str) as its arguments. - the
additional_packaging
function, which acceptsadd-on name
(str) as its only argument.
First the cleanup_output_files
function would be called from ucc-gen
build process and then additional_packaging
function.
See the following example for proper usage:
- Build custom UI after
ucc-gen
finishes all its necessary steps. - Use a workaround for a
ucc-gen
feature that has not been implemented.
Example¶
Below is an example of additional_packaging.py containing both the implementations of functions.
from os.path import sep, exists, dirname, realpath, join
from os import remove, system, _exit, WEXITSTATUS
def cleanup_output_files(output_path: str, ta_name: str) -> None:
"""
prepare a list for the files to be deleted after the source code has been copied to output directory
"""
files_to_delete = []
files_to_delete.append(sep.join([output_path, ta_name, "default", "redundant.conf"]))
files_to_delete.append(sep.join([output_path, ta_name, "bin", "splunk_ta_uccexample_rh_example_input_two.py"]))
files_to_delete.append(sep.join([output_path, ta_name, "bin", "example_input_one.py"]))
files_to_delete.append(sep.join([output_path, ta_name, "bin", "splunk_ta_uccexample_rh_example_input_one.py"]))
files_to_delete.append(sep.join([output_path, ta_name, "bin", "file_does_not_exist.py"]))
files_to_delete.append(sep.join([output_path, ta_name, "default", "nav", "views", "file_copied_from_source_code.xml"]))
for delete_file in files_to_delete:
try:
remove(delete_file)
except (FileNotFoundError):
# simply pass if the file doesn't exist
pass
.uccignore
file¶
Deprecation Notice
This feature has been deprecated from UCC framework as of v5.53.0 as the feature is ambiguous. You can achieve the same functionality using additional_packaging.py. The cleanup_output_files
provides a feature to clean up files after the source code has been copied.
This feature can be used to remove files from the output after the UCC template files were copied and before the source of the add-on recursively overrides the output folder.
Place it in the same folder as the globalConfig
file to have the effect.
Uccignore supports wildcard expressions, thanks to which we can find all files matching a specific pattern.
e.g. for given file structure
...
└── lib
└── 3rdparty
│ ├── linux
│ ├  └── pycache.pyc
│ ├── linux_with_deps
│ ├  └── pycache.pyc
│ └── windows
│ └── pycache.pyc
└── requests
│ └── pycache.pyc
└── urllib
└── pycache.pyc
we can remove all .pyc
files by adding lib/**/pycache.pyc
to the .uccignore file.
If we want to remove all .pyc
files just from the 3rdparty
directory, we need to change pattern to lib/3rdparty/**/pycache.pyc
.
If we want to remove only for one specific platform, we need to provide the exact path e.g. lib/3rdparty/windows/pycache.pyc
.
In case no file is found for the specified pattern, you will see an appropriate warning message.
OpenAPI description document¶
OpenAPI’s description document is generated using the ucc-gen
command.
There has to be defined, valid globalConfig.json
and app.manifest
to have the document (appserver/static/openapi.json
file) generated.
How to find the document?¶
Once ucc-gen
command is executed, OpenAPI description document is located in the appserver/static
output subdirectory.
One way to download it is through the button displayed on the top right corner of the configuration page.
When add-on is installed to Splunk instance, it is exposed via web and management interface, so is available under following addresses accordingly:
- [protocol]://[domain]:[port]/en-GB/static/app/[appname]/openapi.json
(eg. http://localhost:8000/en-GB/static/app/Splunk_TA_cisco_meraki/openapi.json)
See the following resources for more information on working with the Splunk REST API (for example, how to authenticate):
Where can it be used?¶
The OpenAPI Description document can be used to create:
- interactive documentation that generates simple curl requests to all documented endpoints (check this section for the relevant instructions).
- automation that uses the simple requests to create more complex solutions such as:
- orchestration
- mass load or migration
- automated tests.
Check swagger or other tools for more possibilities.
How to get curl commands and use them?¶
Prerequisites¶
- docker running
- Splunk with your add-on installed
Instructions¶
-
Open https://editor.swagger.io/ - Alternatively, you can run your own instance of Swagger Editor by running the following command in terminal:
docker run -p 8081:8080 swaggerapi/swagger-editor
Then go to: http://localhost:8081/
-
Load the OpenAPI description document (File > Import file)
- Check domain and port values for your Splunk instance and Authorize
- Select method-path pair (eg. GET - /splunk_ta_snow_settings/logging ) and “Try it out”
- Define parameters and “Execute”
- Copy curl value, paste to your terminal, ADD
-k
PARAMETER, and run
See Swagger Editor documentation for questions related to the tool.
Troubleshooting¶
- SSL certificate problem
Make sure you added -k
parameter to the curl command.
- Unauthorized
Make sure you clicked the Authorize button, gave the username and password, and then clicked Authorize.
How do you generate Python client and then use it?¶
Prerequisites¶
- Docker running
- Python installed
- Splunk with your add-on installed
Instruction¶
- Go to the directory where you downloaded
openapi.json
file -
Run the following command:
docker run --rm -v ${PWD}:/local openapitools/openapi-generator-cli generate -i /local/openapi.json -g python -o /local/restapi_client
- make sure
openapi.json
is in the current directory - you can generate clients for other languages as well - run
docker run --rm openapitools/openapi-generator-cli generate list
to see the list of supported languages
- make sure
-
The client should appear in
restapi_client
. Open that directory (cd restapi_client
) - Install the client (
pip install .
) - See
README.md
for an example of usage
Troubleshooting¶
In case of an SSL error (e.g. when connecting to localhost), you can disable verification:
configuration = openapi_client.Configuration(
host = "https://localhost:8089/servicesNS/-/addon-name",
username = "user",
password = "pass",
)
configuration.verify_ssl = False
This option should only be used when connecting to a non-prod Splunk instance.
Custom UI extensions ↵
Overview¶
The UCC package simplifies the deployment of React applications featuring the Splunk UI by eliminating the need for NodeJS, Yarn, or front-end dependencies installation. The core requirement for deployment is a globalConfig.json
file. While UCC is designed to support a broad spectrum of use cases, there may be scenarios where the provided API options do not fully meet your needs.
For such instances, UCC has a runtime custom JavaScript loading mechanism. This feature allows for the invocation of specific functionalities at pivotal moments within the application lifecycle, including onChange
and onRender
events.
Integrating Custom JavaScript¶
Example globalConfig.json
configuration for custom JS files located at:
appserver/static/js/build/custom/CustomHookJSFile.js
appserver/static/js/build/custom/CustomInputJSFile.js
{
"inputs": {
"title": "Inputs",
"description": "Manage your data inputs",
"services": [
{
"name": "example_input_one",
"title": "Example Input One",
"hook": {
"src": "CustomHookJSFile",
"type": "external"
},
"entity": [{
"field": "custom_input_field",
"label": "My Custom Input",
"type": "custom",
"options": {
"src": "CustomInputJSFile",
"type": "external"
}
}]
}
]
}
}
Note: Specify the type
key as external
to indicate that these scripts should use the ESM syntax for module exporting and importing. Scripts not marked as external or without the type specified will default to the RequireJS (AMD) syntax. Additionally, custom JavaScript files and their modules will not be processed by Webpack.
React Component Extension¶
While UCC does not directly support React components due to its design choices, it’s possible to integrate React through JavaScript:
CustomComponent.js¶
export default class CustomComponent {
constructor (globalConfig, el) {
}
render () {
ReactDOM.render(
<CustomReactInputComponent />,
this.el
)
return this
}
}
You might also need to adjust webpack/rollup config to output files without chunking:
module.exports = {
//...
output: {
path: path.join(__dirname, '../output/Splunk_TA_Name/appserver/static/js/build/custom/'),
filename: '[name].js',
},
}
Custom Hook¶
Custom Hook is a JavaScript function that allows us to reuse some code throughout the app. It is used to validate form/dialog inputs.
Hook is nothing more than a Javascript event handling on the events onCreate
, onChange
, onRender
, onSave
, onSaveSuccess
, onSaveFail
, and onEditLoad
.
Hooks can be used inside the services and tabs that are placed next to the entity tag.
The type
key needs to be set as external to webpack the custom extensions. UCC expects scripts marked as external to follow the ESM syntax for exporting and importing modules. Any other value, or not specifying type, will default to the old requireJS (AMD) import syntax. Aditionally, the custom javascript file and the imported modules will not get webpack-ed.
Properties¶
Property | Description |
---|---|
globalConfig | It is a hierarchical object that contains the globalConfig file’s properties and values. |
serviceName | It is the name of the service/tab specified in the globalConfig. |
state | state is an object that represents the actual state value of the components in the service/tab when the hook’s constructor is called. Updating this object will not update the state of the page. Use the util.setState method to update the page’s state. The state object contains the actual state data along with the errorMsg and warningMsg properties. |
mode | There are three possible modes: Edit, Clone, and Delete. These are used in service/tab components. |
util | This is a utility object with various functions that can be used to manipulate the page UI. There are 4 associated methods:
|
groupName | The name of the menu group from which the inputs service is called. This parameter should only be used with the multi-level menu feature. |
Methods¶
We can use these methods to overirde existing methods according to the desired functionality:
Property | Description |
---|---|
onCreate | is called when we click on the “Add/Create” button to create a new record on the page. |
debounce | is used to create another special method which does not get executed on every call. This functionality can be useful when listening for an event. For Example, if you might want to show the help text/error when the user has stopped typing for 500ms in a text-box, instead of every key press. In this scenario, the debounce method will induce a time wait every time a key is pressed and the method will only execute when there is no other call to it within that wait time. |
onChange | is called when the value of any field is changed. |
onRender | is called once whenever the user clicks on an “Add”, “Edit”, or “Clone” button. |
onSave | is called when the user clicks the “Save” button after creating, editing, or cloning a record. |
onSaveSuccess | is called when a record has been successfully saved. |
onSaveFail | is called when a record fails to save due to any error. |
onEditLoad | is called when the user clicks on an “Edit” button for an existing record. |
Usage¶
{
"inputs": {
"title": "Inputs",
"description": "Manage your data inputs",
"services": [
{
"name": "example_input_one",
"title": "Example Input One",
"hook": {
"src": "input_hook",
"type": "external"
},
"entity": []
}
]
}
}
Example¶
import _ from "underscore"; // example of a ESM import
class Hook {
/**
* Form hook
* @constructor
* @param {Object} globalConfig - Global configuration.
* @param {string} serviceName - Service name
* @param {object} state - object with state of the components on the servcice/page
* @param {string} mode - edit,create or clone
* @param {object} util - the utility object
*/
constructor(globalConfig, serviceName, state, mode, util, groupName) {
this.globalConfig = globalConfig;
this.serviceName = serviceName;
this.state = state;
this.mode = mode;
this.util = util;
this.groupName = groupName;
this._debouncedNameChange = this.debounce(this._nameChange.bind(this), 200);
console.log('Inside Hook mode: ', mode);
}
onCreate() {
if (this.mode == "create") {
console.log('in Hook: onCreate');
// This is an example of how to store groupName value for a particular form field.
this.util.setState((prevState) => {
let data = { ...prevState.data };
data.test_field.value = this.groupName;
return { data };
});
}
}
debounce(func, wait) {
let timeout;
// This is the function that is returned and will be executed many times
// We spread (...args) to capture any number of parameters we want to pass
return function executedFunction(...args) {
// The callback function to be executed after
// the debounce time has elapsed
// This will reset the waiting every function execution.
// This is the step that prevents the function from
// being executed because it will never reach the
// inside of the previous setTimeout
clearTimeout(timeout);
// Restart the debounce waiting period.
// setTimeout returns a truthy value
timeout = setTimeout(() => {func(...args)}, wait);
}
}
onChange(field, value, dataDict) {
console.log('in Hook: onChange ', field, ' value : ', value);
console.log('in Hook: onChange state: ', this.state);
if (field === "name") {
this._debouncedNameChange(dataDict)
}
}
onRender() {
console.log('in Hook: onRender');
}
/*
Put form validation logic here.
Return ture if validation pass, false otherwise.
Call displayErrorMsg when validtion failed.
*/
onSave(dataDict) {
console.log('in Hook: onSave with data: ', dataDict);
var accountname = dataDict.name;
var auth_type = dataDict.auth_type;
var endpoint = dataDict.url;
this.util.setState((prevState) => {
/*
Example usage of util.clearAllErrorMsg. It just returns the modified state object after clearing the error messages.
It won't update the UI.
*/
let new_state = this.util.clearAllErrorMsg(prevState);
return new_state
});
if (accountname === null || accountname.trim().length === 0) {
var msg = "Field account name is required";
this.util.setErrorMsg(msg);
return false;
} else if (endpoint === null || endpoint.trim().length === 0) {
var msg = "Field URL is required";
this.util.setErrorMsg(msg);
return false;
} else if (endpoint.indexOf("https://") !== 0) {
var msg =
"URL should start with 'https://' as only secure URLs are supported.";
this.util.setErrorFieldMsg("url", msg);
return false;
} else if (auth_type == "oauth") {
endpoint = endpoint.replace("https://", ""); //removing the https schema from the endpoint
this.util.setState((prevState) => {
let data = { ...prevState.data };
data.endpoint.value = endpoint;
return { data };
});
}
return true;
}
onSaveSuccess() {
console.log('in Hook: onSaveSuccess');
}
onSaveFail() {
console.log('in Hook: onSaveFail');
}
/*
Put logic here to execute javascript after loading edit UI.
*/
onEditLoad() {
console.log('in Hook: onEditLoad');
}
_nameChange(dataDict) {
console.log('in Hook: _nameChange');
}
}
export default Hook;
Note: The Javascript file for the custom control should be saved in the custom folder at
appserver/static/js/build/custom/
.
Custom Control¶
The Custom Control feature allows you to display any customised input component in a form. The developer can easily design and render any complex input component with this feature. Modern add-ons frequently require the use of complex input components, and this feature will allow you to use the custom component in the form that is best suited to your needs, without relying on newer releases of UCC for support.
Properties¶
Property | Description |
---|---|
globalConfig | It is a hierarchical object that contains the globalConfig file’s properties and values. |
el | The el is used to render a custom input element in a form. |
data | The data object holds details regarding the execution: |
setValue | This method is used to set the value of the custom component. Usage: setValue(newValue) |
util | This is a utility object with various functions that can be used to manipulate the UI. There are 4 associated methods:
|
Methods¶
Property | Description |
---|---|
render | is a method which should have logic for the custom component, and it will be executed automatically when the create, edit, or clone actions are performed. |
validation | This method should contain the validation logic for the value of the custom component. |
Usage¶
{
"name": "account",
"table": {},
"entity": [
{
"type": "custom",
"label": "Example Custom Control",
"field": "custom_control_field",
"help": "This is an example multipleSelect for account entity",
"options":{
"src": "custom_control",
"type": "external"
},
"required": true
},
{
"type": "text",
"label": "Name",
"field": "name",
"help": "Enter a unique name for this account.",
"required": true
},
]
}
Example¶
class CustomControl {
/**
*
* @constructor
* @param {object} globalConfig - Global configuration.
* @param {element} el - The element of the custom row.
* @param {object} data - Mode, serviceName, and value.
* @param {string} data.mode - one of `create`, `edit`, `clone`, or `config`
* @param {string | boolean | number | undefined} data.value - current value of custom field
* @param {string} data.serviceName - name of service in which custom field is rendered
* @param {object} util - The utility object.
* @param {function} setValue - set value of the custom field.
*/
constructor(globalConfig, el, data, setValue, util) {
this.globalConfig = globalConfig;
this.el = el;
this.data = data;
this.util = util;
this.setValue = setValue;
this.onSelectOptionChange = this.onSelectOptionChange.bind(this);
}
onSelectOptionChange(event) {
this.setValue(event.target.value);
}
validation(field, value) {
// Validation logic for value. Return the error message if failed.
if (value === 'input_two') {
return 'Wrong value selected.';
}
}
render() {
let content_html = `
<select id="custom_control">
<option value="input_one">Input One</option>
<option value="input_two">Input Two</option>
</select>
`;
this.el.innerHTML = content_html;
this.el.addEventListener('change', this.onSelectOptionChange);
return this;
}
}
export default CustomControl;
Note: The Javascript file for the custom control should be saved in the custom folder at
appserver/static/js/build/custom/
.
Output¶
This is how it looks in the UI:
Properties usage¶
clearAllErrorMsg¶
this.util.clearAllErrorMsg(newState) // newState is updated form state
or
this.util.clearAllErrorMsg()
setErrorFieldMsg¶
this.util.setErrorFieldMsg('customFieldKey', 'Custom Field was filed incorrectly')
this.util.setErrorFieldMsg('otherFieldValue', 'Due to custom field changes, action on otherFieldValue is required')
setErrorMsg¶
this.util.setErrorMsg('New Error message for current custom field.')
setState¶
this.util.setState((oldState) => {
const newState = {...oldState}
newState.data.fieldKey = newFieldValue;
return newState
})
Custom Row¶
When a row is expanded on the Inputs table or Configuration Table, Custom Row is utilized to incorporate a customized element. By clicking on the icon provided on the left side of each row, the input-specific details are displayed.
Properties¶
Property | Description |
---|---|
globalConfig | is a hierarchical object that contains the globalConfig file’s properties and values. |
el | is used to render a customized element on the Inputs table when a row is expanded. |
serviceName | is the name of the service/tab specified in the globalConfig file. |
row | is the object of the record for which the CustomRowInput constructor is called. |
Methods¶
Property | Description |
---|---|
render | is a method which contains the logic to display the custom row component. This method is automatically executed when the row is expanded |
getDLRows | is a method which contains the logic to update the custom row values, return a key-value pair. |
Note
- Atleast one method should be present
- If both method is present then the getDLRows method have the high priority.
Usage¶
"inputs": {
"title": "Inputs",
"description": "Manage your data inputs",
"services": [],
"table": {
"actions": ["edit", "delete", "clone"],
"header": [],
"customRow": {
"src": "custom_input_row",
"type": "external"
}
}
}
Example¶
class CustomInputRow {
/**
* Custom Row Cell
* @constructor
* @param {Object} globalConfig - Global configuration.
* @param {string} serviceName - Input service name.
* @param {element} el - The element of the custom cell.
* @param {Object} row - custom row object,
* use this.row.<field_name>, where <field_name> is a field name
*/
constructor(globalConfig, serviceName, el, row) {
this.globalConfig = globalConfig;
this.serviceName = serviceName;
this.el = el;
this.row = row;
}
getDLRows() {
return Object.fromEntries(
Object.entries(this.row).map(([key, value]) => [
key,
key === "interval" ? `${value} sec` : value,
])
);
}
render() {
const content_html_template = "Custom Input Row";
this.el.innerHTML = content_html_template;
return this;
}
}
export default CustomInputRow;
Note:
- The content should be included in the JavaScript file named by customRow.src property in globalConfig (see usage for details).
- The Javascript file for the custom control should be saved in the custom folder at
appserver/static/js/build/custom/
.
Output¶
This is how it looks in the UI:
Custom Cell¶
A Custom Cell is used to update the content of a table cell.
customCell
attribute will be used in the table header on the inputs and configuration page.
Properties¶
Property | Description |
---|---|
globalConfig | is a hierarchical object that contains the globalConfig file’s properties and values. |
el | is used to render a custom cell element in a table. |
serviceName | is the name of the service/tab specified in the globalConfig file. |
row | is the object of the record for which the CustomRowInput constructor is called. |
field | is the name of the field as specified in the globalConfig file. |
Methods¶
Property | Description |
---|---|
render | is a method which should have logic for the custom cell component, and it will be executed automatically when the create, edit, or clone actions performed. |
Usage¶
{
"name": "account",
"title": "Account",
"entity": [],
"table": {
"actions": ["edit", "delete", "clone"],
"header": [{
"label": "Name",
"field": "name"
}, {
"label": "Auth Type",
"field": "auth_type"
}, {
"label": "Test Custom Cell",
"field": "test_custom_cell",
"customCell": {
"src": "CustomInputCell",
"type": "external"
}
}]
}
}
Example¶
class CustomInputCell {
/**
* Custom Row Cell
* @constructor
* @param {Object} globalConfig - Global configuration.
* @param {string} serviceName - Input service name.
* @param {element} el - The element of the custom cell.
* @param {Object} row - custom row object.
* @param {string} field - The cell field name.
*/
constructor(globalConfig, serviceName, el, row, field) {
this.globalConfig = globalConfig;
this.serviceName = serviceName;
this.el = el;
this.row = row;
this.field = field;
}
render() {
let html = "";
// Check for missing configuration in account
if (this.row.account_multiple_select === "one") {
html = "Option One";
} else if (this.row.account_multiple_select === "two"){
html = "Option Two";
} else {
html = "Option is not available"
}
this.el.innerHTML = html;
return this;
}
}
export default CustomInputCell;
Note: The Javascript file for the custom cell should be saved in the custom folder at
appserver/static/js/build/custom/
.
Output¶
This is how it looks in the UI:
Custom Tab¶
Custom Tab feature can be used to render any customized UI component in the Configuration tabs. With this feature, you can design and render any complex input with ease. This is an advanced feature and can be leveraged with limitless functionalities. Modern add-ons are receiving complex use cases and this feature will allow you to design the UI perfectly for your case without having to depend on newer releases of UCC for support.
Properties¶
Property | Description |
---|---|
tab | is an object with the properties and values of a custom tab object from the global config file. |
el | is used to render a customized component on the Configuration tabs. |
Methods¶
Property | Description |
---|---|
render | is a method which should have logic for the custom component, and it will be executed automatically when the configuration page is rendered. |
Usage¶
"configuration": {
"title": "Configuration",
"descriptions": "Set up your add-on",
"tabs": [
{
"name": "account",
"title": "Account",
"entity": [],
"table": {}
},
{
"name": "logging",
"title": "Logging",
"entity": []
},
{
"name": "proxy",
"title": "Proxy",
"entity": []
},
{
"name": "custom_tab",
"title": "Customized Tab",
"customTab": {
"src": "custom_tab",
"type": "external"
}
}
]
}
Example¶
class CustomTab {
/**
* Custom Tab
* @constructor
* @param {Object} tab - Tab details.
* @param {element} el - The element of the custom menu.
*/
constructor(tab, el) {
this.tab = tab;
this.el = el;
}
render() {
this.el.innerHTML = `<h1 style="margin-top: 20px">${this.tab.title} - This is a custom component rendered from the TA</h1>`
}
}
export default CustomTab;
Note: The Javascript file for the custom tab should be saved in the custom folder at
appserver/static/js/build/custom/
.
Output¶
This is how it looks in the UI:
Ended: Custom UI extensions
Advanced ↵
Custom Mapping¶
We can use this feature to map each field with meaningful value to display in the table. For example, the category field contains 1, 2, and 4 values, but when those values are displayed, the user might get confused as those values do not signify the meaning of their mapping. To avoid this confusion, the user can map each field with meaningful value as shown in the following example:
If you have fields that are not mandatory but you would like to display them inside table, you can use default value option by providing "[[default]]"
as one of parameters (check example bellow). It is a way to provide some meaningful information for form fields that have not been filled (fill empty cells in table).
Usage¶
{
"name": "account",
"title": "Account",
"table": {
"header": [
{
"field": "name",
"label": "Name"
},
{
"field": "key_id",
"label": "Key ID"
},
{
"field": "category",
"label": "Region Category",
"mapping": {
"1": "Global",
"2": "US Gov",
"4": "China",
"[[default]]": "Unknown"
}
}
],
"actions": [
"edit",
"delete"
]
},
"entity": [
{
"field": "name",
"label": "Name",
"type": "text",
"required": true,
},
{
"field": "key_id",
"label": "Key ID",
"type": "text",
},
{
"field": "category",
"label": "Region Category",
"type": "singleSelect",
"required": false,
"defaultValue": 1,
"options": {
"disableSearch": true,
"autoCompleteFields": [
{
"label": "Global",
"value": 1
},
{
"label": "GovCloud",
"value": 2
},
{
"label": "China",
"value": 4
}
]
}
}
]
}
Output¶
This is how it looks in the UI:
Dependent Dropdown¶
This feature allows dynamic loading options for the singleSelect
and the multipleSelect
fields when the options for that field depend on other fields’ values. It loads options via an API call to the endpoint mentioned in endpointUrl
under options when any dependencies field is updated and all required dependencies fields are non-null.
All non-required dependencies fields can be of any type, but all required dependencies fields should only be of single-select type.
All dependencies fields’ values are added to the endpoint URL as query parameters.
If endpoint is refering to internal endpoint, remember to update restmap.conf and web.conf accordingly.
If endpoint is refering to external endpoint remember to share content in correct format adjusted to splunk APIs. Remember to provide data in format where data are nested inside entry and content object.
Usage¶
{
"field": "bucket_name",
"label": "S3 Bucket",
"type": "singleSelect",
"required": true,
"options": {
"disableonEdit": true,
"dependencies": [
"aws_account",
"aws_iam_role",
"aws_s3_region",
"private_endpoint_enabled",
"sts_private_endpoint_url",
"s3_private_endpoint_url"
],
"endpointUrl": "splunk_ta_aws/splunk_ta_aws_s3buckets"
}
}
Note: When using the text type field, add debounce using the custom hook to reduce the number of API calls.
Data format¶
Simplest format with just name¶
If you won’t add any specification regarding label or value name
property will be used for both.
Example data:
{
"entry": [
{
"name": "firstEntry"
},
{
"name": "secondEntry"
}
]
}
Values in dropdown:
First entry => label firstEntry
, value firstEntry
Second entry => label secondEntry
, value secondEntry
Format with custom label and value¶
If you will pass labelField
or valueField
to component configuration, data retrieved from entry.content
will be used as corresponding values. For label data from entry.content[labelField]
will be assigned. For value data from entry.content[valueField]
will be assigned.
Example dropdown label configuration:
"options": {
"labelField": "uniqueName",
"valueField": "calculatedValue"
}
Example data:
{
"entry": [
{
"name": "firstEntry",
"content": {
"uniqueName": "First entry",
"calculatedValue": "123456"
}
},
{
"name": "secondEntry",
"content": {
"uniqueName": "Second entry",
"calculatedValue": "654321"
}
}
]
}
Values in dropdown:
First entry => label First entry
, value 123456
Second entry => label Second entry
, value 654321
OAuth Support¶
UCC allows you to add Auth support in the configuration page. In UCC, OAuth2.0 of the Authorization Code Flow grant
type is used. It only supports the standard parameters specified in RFCP749 for obtaining an authorization code.
Auth can be used inside the entity tag. Use type: "oauth"
in the entity list and specify the options
next to the type: "oauth"
.
Properties¶
type
field value must be oauth.-
options
:auth_type
must be present. It can have either [“basic”, “oauth”] (If we want basic and oauth both support) or [“oauth”] (If we want oauth support only).basic
must be present only if the auth_type is [“basic”].- This will have a list of fields for you to add in the basic authentication flow. In the given example, it is username, password, and security_token.
- Note: As of now, if you are selecting basic as auth_type, then the username and password fields are mandatory.
oauth
will have a list of fields for you to add in the oauth authentication flow. In the given example, it isclient_id
,client_secret
,redirect_url
,scope
, andendpoint
.- These fields are mandatory:
client_id
is the client id for applying auth to your app or apps.client_secret
is the client secret for applying auth to your app or apps.redirect_url
will show the redirect url, which needs to be put in the app’s redirect url.endpoint
will be the endpoint for you to build oauth support. For example, for salesforce, it will either be “login.salesforce.com”, “test.salesforce.com”, or any other custom endpoint.- There is also the ability to specify separate endpoints for authorize and token. To do this, instead of the single ‘endpoint’ field, use two separate ones:
endpoint_authorize
specifies the endpoint used for authorization, for example, login.salesforce.com.endpoint_token
specifies the endpoint used for the token acqusition, for example, api.login.salesforce.com.
- There is also the ability to specify separate endpoints for authorize and token. To do this, instead of the single ‘endpoint’ field, use two separate ones:
auth_code_endpoint
must be present and its value should be the endpoint value for getting the auth_code using the app. If the url to get the auth_code is https://login.salesforce.com/services/oauth2/authorize, then this will have the value /services/oauth2/authorize.access_token_endpoint
must be present and its value should be the endpoint value for getting the ccess_token using the auth_code received. If the url to get the access token is https://login.salesforce.com/services/oauth2/token, then it will have the value /services/oauth2/token.auth_label
allows the user to have the custom label for the Auth Type dropdown.oauth_popup_width
is the width in pixels of the pop-up window that will open for oauth authentication (Optional, defaults to 600).oauth_popup_height
is the height in pixels of the pop-up window that will open for oauth authentication (Optional, defaults to 600).oauth_timeout
is the timeout in seconds for oauth authentication (Optional, defaults to 180 seconds).oauth_state_enabled
is used to include the state for oauth authentication (default value is false).-
auth_endpoint_token_access_type
is an optional parameter that is mapped into the value of the token_access_type query param in the authorisation url. -
The fields allowed in the basic and oauth fields are the following:
oauth_field
should be kept as it is and without any change.label
can be changed if the user wants to change the label of the field in UI.field
must keep it as it is for mandatory fields as mentioned before.help
can be changed the if user wants to change the help text displayed below the field.encrypted
should be true if the user wants that particular field encrypted, otherwise, there is no need to have this parameter.required
specifies whether the field is required or not. The default value is true.defaultValue
is the initial input value (string, number, or boolean).validators
array that is used to validate the values of fields using various validators. It is strongly advised to specify validators for every entity.options
:placeholder
: (RENOUNCED) The placeholder for the field.disableonEdit
: When the form is in edit mode, the field becomes unable to be edited. The default value is false.enable
: The enable property sets whether a field is enabled or not. The default value is true.
Placeholder deprecation
The Placeholder attribute is deprecated and renounced. Instead, we recommend to use the “help” attribute.
Usage¶
"configuration": {
"title": "Configurations",
"description": "Configure your servers and templates.",
"tabs": [
{
"name": "account",
"title": "Account",
"entity": [
{
"field": "name",
"label": "Name",
"type": "text",
"required": true,
"help": "Enter a unique name for each Crowdstrike falcon host account.",
},
{
"type": "oauth",
"field": "oauth",
"label": "Not used",
"options": {
"auth_type": [
"basic",
"oauth"
],
"basic": [
{
"oauth_field": "username",
"label": "User Name",
"field": "username",
"help": "Enter Account name."
},
{
"oauth_field": "password",
"label": "Password",
"field": "password",
"encrypted": true,
"help": "Enter Password."
},
{
"oauth_field": "security_token",
"label": "Securtiy Token",
"field": "security_token",
"encrypted": true,
"help": "Enter Security Token."
}
],
"oauth": [
{
"oauth_field": "client_id",
"label": "Client Id",
"field": "client_id",
"help": "Enter Client Id."
},
{
"oauth_field": "client_secret",
"label": "Client Secret",
"field": "client_secret",
"encrypted": true,
"help": "Enter Client Secret."
},
{
"oauth_field": "redirect_url",
"label": "Redirect url",
"field": "redirect_url",
"help": "Please add this redirect URL in your app."
},
{
"oauth_field": "scope",
"label": "Scope",
"field": "scope",
"help": "Enter the scope for the authorization code with ',' separating each scope.",
"required": false
},
{
"oauth_field": "endpoint",
"label": "Endpoint",
"field": "endpoint",
"help": "Enter Endpoint"
}
],
"auth_label": "Auth Type",
"oauth_popup_width": 600,
"oauth_popup_height": 600,
"oauth_timeout": 180,
"auth_code_endpoint": "/services/oauth2/authorize",
"access_token_endpoint": "/services/oauth2/token",
"auth_endpoint_token_access_type": "offline"
}
}
],
}
]
}
Output¶
This is how the Add Account modal looks after adding the above code to the globalConfig.json file:
This is how Add Account looks when the auth_type is basic
:
This is how Add Account looks when the auth_type is oauth
:
Custom REST Handlers¶
It is possible to extend the default behaviour of the UCC-generated REST handlers.
For example, if your add-on requires an API key to operate and you want to validate this API key during its creation, you might want to use the custom REST handlers to achieve that.
Note:
ucc-gen
will not override the REST handler code if you use the correct file name under thebin
folder.
See the following example of how it can be done. It contains a REST handler for creating an organization, with the organization_id
and organization_api_key
fields, which are not custom ones, generated by ucc-gen
. But, also in the example, there is a custom handler, CustomRestHandler
class which has additional steps for configuration creation and edit operations, specifically handleEdit
and handleCreate
methods:
import import_declare_test
import logging
from splunktaucclib.rest_handler import admin_external, util
from splunktaucclib.rest_handler.admin_external import AdminExternalHandler
from splunktaucclib.rest_handler.endpoint import (
RestModel,
SingleModel,
field,
validator,
)
util.remove_http_proxy_env_vars()
fields = [
field.RestField(
"organization_id",
required=True,
encrypted=False,
default=None,
validator=validator.AllOf(
validator.String(
max_len=50,
min_len=1,
),
validator.Pattern(
regex=r"""^\d+$""",
),
),
),
field.RestField(
"organization_api_key",
required=True,
encrypted=True,
default=None,
validator=validator.AllOf(
validator.String(
max_len=50,
min_len=1,
),
validator.Pattern(
regex=r"""^[a-z0-9]+$""",
),
),
),
]
model = RestModel(fields, name=None)
endpoint = SingleModel(
"addon_name_organization", model, config_name="organization"
)
def _validate_organization(organization_id, organization_api_key):
# Some code to validate the API key.
# Should return nothing if the configuration is valid.
# Should raise an exception splunktaucclib.rest_handler.error.RestError if the configuration is not valid.
...
class CustomRestHandler(AdminExternalHandler):
def __init__(self, *args, **kwargs):
AdminExternalHandler.__init__(self, *args, **kwargs)
def handleList(self, confInfo):
AdminExternalHandler.handleList(self, confInfo)
def handleEdit(self, confInfo):
_validate_organization(
self.payload.get("organization_id"),
self.payload.get("organization_api_key"),
)
AdminExternalHandler.handleEdit(self, confInfo)
def handleCreate(self, confInfo):
_validate_organization(
self.payload.get("organization_id"),
self.payload.get("organization_api_key"),
)
AdminExternalHandler.handleCreate(self, confInfo)
def handleRemove(self, confInfo):
AdminExternalHandler.handleRemove(self, confInfo)
if __name__ == "__main__":
logging.getLogger().addHandler(logging.NullHandler())
admin_external.handle(
endpoint,
handler=CustomRestHandler,
)
Native support from UCC for Modular Inputs¶
UCC 5.18.0 natively supports custom REST handlers for the modular inputs.
One common scenario is to delete a checkpoint after you delete an input in the Inputs page. Otherwise, users may face strange consequences if they create an input with the same name as the input that was deleted, and this newly created input will reuse the old checkpoint, because the names of the inputs are the same. We would like to avoid this situation in the add-on.
This can be done without a need to modify the REST handler code
automatically by running ucc-gen
.
See the following automatically generated REST handler code for a modular input REST handler:
import import_declare_test
from splunktaucclib.rest_handler.endpoint import (
field,
validator,
RestModel,
DataInputModel,
)
from splunktaucclib.rest_handler import admin_external, util
from splunktaucclib.rest_handler.admin_external import AdminExternalHandler
import logging
util.remove_http_proxy_env_vars()
fields = [
field.RestField(
'interval',
required=True,
encrypted=False,
default=None,
validator=validator.Pattern(
regex=r"""^\-[1-9]\d*$|^\d*$""",
)
),
field.RestField(
'disabled',
required=False,
validator=None
)
]
model = RestModel(fields, name=None)
endpoint = DataInputModel(
'example_input_one',
model,
)
if __name__ == '__main__':
logging.getLogger().addHandler(logging.NullHandler())
admin_external.handle(
endpoint,
handler=AdminExternalHandler,
)
New file needs to be created in the bin
folder of the add-on. Let’s call it
splunk_ta_uccexample_delete_checkpoint_rh.py
(name can be different).
And put the following content into the file.
import import_declare_test
from splunktaucclib.rest_handler.admin_external import AdminExternalHandler
class CustomRestHandlerDeleteCheckpoint(AdminExternalHandler):
def __init__(self, *args, **kwargs):
AdminExternalHandler.__init__(self, *args, **kwargs)
def handleList(self, confInfo):
AdminExternalHandler.handleList(self, confInfo)
def handleEdit(self, confInfo):
AdminExternalHandler.handleEdit(self, confInfo)
def handleCreate(self, confInfo):
AdminExternalHandler.handleCreate(self, confInfo)
def handleRemove(self, confInfo):
# Add your code here to delete the checkpoint!
AdminExternalHandler.handleRemove(self, confInfo)
Then, in globalConfig file you need to change the behaviour of the UCC to reuse the REST handler that was just created.
{
"name": "example_input_one",
"restHandlerModule": "splunk_ta_uccexample_delete_checkpoint_rh", <----- new field
"restHandlerClass": "CustomRestHandlerDeleteCheckpoint", <----- new field
"entity": [
"..."
],
"title": "Example Input One"
}
After ucc-gen
command is executed again, the generated REST handler for this
input will be changed to the following.
import import_declare_test
from splunktaucclib.rest_handler.endpoint import (
field,
validator,
RestModel,
DataInputModel,
)
from splunktaucclib.rest_handler import admin_external, util
from splunk_ta_uccexample_delete_checkpoint_rh import CustomRestHandlerDeleteCheckpoint # <----- changed
import logging
util.remove_http_proxy_env_vars()
fields = [
field.RestField(
'interval',
required=True,
encrypted=False,
default=None,
validator=validator.Pattern(
regex=r"""^\-[1-9]\d*$|^\d*$""",
)
),
field.RestField(
'disabled',
required=False,
validator=None
)
]
model = RestModel(fields, name=None)
endpoint = DataInputModel(
'example_input_one',
model,
)
if __name__ == '__main__':
logging.getLogger().addHandler(logging.NullHandler())
admin_external.handle(
endpoint,
handler=CustomRestHandlerDeleteCheckpoint, # <----- changed
)
Native support from UCC for Configuration Page¶
UCC 5.41.0 natively supports custom REST handlers for the configuration page
As mentioned at the top, when the API key provided by a user in your add-on and it needs to be validated, you can now directly mention the name of the file that contains the validating code and the class name of it. Hence, your validation script now becomes something as below:
import import_declare_test
from splunktaucclib.rest_handler.admin_external import AdminExternalHandler
# any other imports required for validation
def _validate_organization(organization_id, organization_api_key):
# Some code to validate the API key.
# Should return nothing if the configuration is valid.
# Should raise an exception splunktaucclib.rest_handler.error.RestError if the configuration is not valid.
...
class CustomAccountValidator(AdminExternalHandler):
def __init__(self, *args, **kwargs):
AdminExternalHandler.__init__(self, *args, **kwargs)
def handleList(self, confInfo):
AdminExternalHandler.handleList(self, confInfo)
def handleEdit(self, confInfo):
_validate_organization(
self.payload.get("organization_id"),
self.payload.get("organization_api_key"),
)
AdminExternalHandler.handleEdit(self, confInfo)
def handleCreate(self, confInfo):
_validate_organization(
self.payload.get("organization_id"),
self.payload.get("organization_api_key"),
)
AdminExternalHandler.handleCreate(self, confInfo)
def handleRemove(self, confInfo):
AdminExternalHandler.handleRemove(self, confInfo)
Place the above content in a file in the bin
folder of the add-on. Let’s call it
splunk_ta_uccexample_account_validator_rh.py
(name can be different).
Then, in globalConfig file you need to change the behaviour of the UCC to reuse the REST handler that was just created.
{
"configuration": {
"tabs": [
{
"name": "account",
"title": "Account",
"restHandlerModule": "splunk_ta_uccexample_account_validator_rh", <----- new field
"restHandlerClass": "CustomAccountValidator", <----- new field
"table": {
"..." : "..."
},
"entity": [
"..."
]
}
]
}
}
After ucc-gen
command is executed again, the generated REST handler for this
configuration page will be updated to the following.
import import_declare_test
from splunktaucclib.rest_handler.endpoint import (
field,
validator,
RestModel,
SingleModel,
)
from splunktaucclib.rest_handler import admin_external, util
from splunk_ta_uccexample_account_validator_rh import CustomAccountValidator # <----- changed
import logging
util.remove_http_proxy_env_vars()
fields = [
# all the fields and its validators mentioned in globalConfig in the configuration page
# that are auto generated by UCC framework
]
model = RestModel(fields, name=None)
endpoint = SingleModel(
"addon_name_account", model, config_name="account"
)
if __name__ == '__main__':
logging.getLogger().addHandler(logging.NullHandler())
admin_external.handle(
endpoint,
handler=CustomAccountValidator, # <----- changed
)
Groups Feature¶
Using this functionality, the Inputs page form can be divided into distinct sections, each comprising relevant fields. If the isExpandable
property is set to true in the global configuration file, the group will be in the collapsible panel type.
The groups will be displayed at the bottom of the form.
Properties¶
label
displays the title of a specific group.fields
specifies the list of fields in a group. All fields must be present in the entity.options
:isExpandable
can be used to hide/show fields of the group. The default value is false.expand
can be used to show all fields of the group while opening the form. The default value is false.
Usage¶
{
"name": "aws_config",
"title": "Config",
"groups": [
{
"label": "AWS Input Configuration",
"options": {
"isExpandable": false
},
"fields": [
"name",
"aws_account"
]
},
{
"label": "Splunk-related Configuration",
"options": {
"isExpandable": false
},
"fields": [
"sourcetype",
"index"
]
},
{
"label": "Advanced Settings",
"options": {
"expand": false,
"isExpandable": true
},
"fields": [
"polling_interval"
]
}
],
"entity": []
},
Output¶
This is how it looks in the UI:
Save Validator¶
This feature allows you to pass a Javascript function as a string to apply customized validation to form data.
By using this approach, you can write custom JavaScript code where you can write your business logic, and validating can return error messages which will be displayed at the top of the form.
This custom javascript function has a parameter, (for example, dataDict), which contains the form data object.
This function will be called after all validators have validated the data form.
Usage¶
{
"name": "example_input_one",
"title": "Example Input One",
"entity": [],
"options": {
"saveValidator": "function start_data_validator(dataDict) { const provided_datetime = new Date(dataDict['start_date']).getTime(); const current_datetime = new Date().getTime(); if (provided_datetime > current_datetime) { return 'Start date should not be in future'; }}"
}
}
OS-dependent libraries¶
This feature allows you to download and unpack libraries with appropriate binaries for the indicated operating system during the build process. To do this, you need to expand the meta section in the global configuration with the os-dependentLibraries field. This field takes the following attributes:
Property | Type | Description | default value |
---|---|---|---|
name* | string | is the name of the library we want to download. | - |
version* | string | is the specific version of the given library. | - |
dependencies | boolean | (Optional) is the parameter which determines whether the --no-deps flag will be used when installing the package from pip . When the value is set to true , the library will be installed along with all its dependencies. When the value is set to false (default) {name}={version} , it must be present in packages requirements.txt . |
false |
platform* | string | is the platform for downloading the specified library. The value depends on the available wheels for a given library, for example, for this wheel, cryptography-41.0.5-cp37-abi3-manylinux_2_28_x86_64.whl, the platform is manylinux_2_28_x86_64. | - |
python_version* | string | is the python version compatible with the library. | - |
target* | string | is the Path where the selected library will be unpacked. | - |
os* | string | is the name of the operating system which the library is intended for. Using this parameter, an appropriate insert into sys.path will be created. It takes 3 values windows, linux, and darwin. | - |
About wheels files¶
Generally, the wheel name convention is
{distribution}-{version}(-{build tag})?-{python tag}-{abi tag}-{platform tag}.whl.
For example, for this particular library,
grpcio-1.54.2-cp37-cp37m-manylinux_2_17_x86_64.manylinux2014_x86_64.whl
,
your pip parameters are:
- name = grpcio
- version = 1.54.2
- platform = manylinux_2_17_x86_64 or manylinux2014_x86_64
- python_version = 37
- target = your/path/to/target
- os = linux
and your pip command should look like this:
pip install --no-deps --platform manylinux_2_17_x86_64 --python-version 37 --target your/path/to/target --only-binary=:all: grpcio==1.54.2
A dot in the platform part indicates that a given distribution supports several platforms. In this case, “.” in manylinux_2_17_x86_64.manylinux2014_x86_64 means this distribution supports both manylinux_2_17_x86_64 and manylinux2014_x86_64.
Currently supported python versions are “3.7” and “3.9”. Syntax without dots (“37” or “39”) is also supported.
If there are libraries specified for different python versions, they must have different target paths.
"os-dependentLibraries": [
{
"name": "cryptography",
"version": "41.0.5",
"platform": "manylinux2014_x86_64",
"python_version": "37",
"os": "linux",
"target": "3rdparty/linux_libs"
},
{
"name": "cryptography",
"version": "41.0.5",
"dependencies": true,
"platform": "manylinux2014_x86_64",
"python_version": "3.9",
"os": "linux",
"target": "3rdparty/linux_lib_py39"
},
For more informations, see .whl and manylinux platform.
Usage¶
...
"meta": {
"name": "<TA name>",
"restRoot": "<restRoot>",
"version": "<TA version>",
"displayName": "<TA display name>",
"schemaVersion": "<schema version>",
"os-dependentLibraries": [
{
"name": "cryptography",
"version": "41.0.5",
"platform": "manylinux2014_x86_64",
"python_version": "37",
"os": "linux",
"target": "3rdparty/linux"
},
{
"name": "cryptography",
"version": "41.0.5",
"platform": "win_amd64",
"python_version": "37",
"os": "windows",
"target": "3rdparty/windows"
},
{
"name": "cryptography",
"version": "41.0.5",
"dependencies": true,
"platform": "manylinux2014_x86_64",
"python_version": "37",
"os": "linux",
"target": "3rdparty/linux_with_deps"
},
{
"name": "cffi",
"version": "1.15.1",
"platform": "win_amd64",
"python_version": "37",
"os": "windows",
"target": "3rdparty/windows"
}
]
}
Result¶
Running the build for the above configuration will result in the creation of the following structure:
output
└──<TA>
├── bin
...
└── lib
└── 3rdparty
├── linux
│  ├── cryptography
│  └── cryptography-41.0.5.dist-info
├── linux_with_deps
│  ├── _cffi_backend.cpython-37m-x86_64-linux-gnu.so
│  ├── cffi
│  ├── cffi-1.15.1.dist-info
│  ├── cryptography
│  ├── cryptography-41.0.5.dist-info
│  ├── pycparser
│  └── pycparser-2.21.dist-info
└── windows
├── _cffi_backend.cp37-win_amd64.pyd
├── cffi
├── cffi-1.15.1.dist-info
├── cryptography
└── cryptography-41.0.5.dist-info
During the build process, a python script “import_declare_test.py” will be created in output/ta_name/bin to manipulate system paths.
In each input using the specified libraries, this script must be imported.
Currently, three operating systems are supported: Windows, Linux, and Darwin.
If, for development purposes, there is a need to create other custom manipulations on sys.path,
create your own script called “import_declare_test.py” and place it in the package/bin folder.
This way, when building the TA, the default script will be replaced with the one created by the developer.
The default script for this configuration will look like this:
import os
import sys
import re
from os.path import dirname
ta_name = 'demo_addon_for_splunk'
pattern = re.compile(r'[\\/]etc[\\/]apps[\\/][^\\/]+[\\/]bin[\\/]?$')
new_paths = [path for path in sys.path if not pattern.search(path) or ta_name in path]
new_paths.insert(0, os.path.join(dirname(dirname(__file__)), "lib"))
new_paths.insert(0, os.path.sep.join([os.path.dirname(__file__), ta_name]))
sys.path = new_paths
bindir = os.path.dirname(os.path.realpath(os.path.dirname(__file__)))
libdir = os.path.join(bindir, "lib")
platform = sys.platform
if platform.startswith("linux"):
sys.path.insert(0, os.path.join(libdir, "3rdparty/linux_with_deps"))
sys.path.insert(0, os.path.join(libdir, "3rdparty/linux"))
if platform.startswith("win"):
sys.path.insert(0, os.path.join(libdir, "3rdparty/windows"))
Sub Description¶
This feature allows us to pass a broader description on the Input and Configuration pages displayed under main description.
Sub Descritpion Properties¶
Property | Type | Description |
---|---|---|
text* | string | is text used for the description, you can put \n to add a breakline. |
links | object | enables including links inside description |
Links¶
Property | Type | Description |
---|---|---|
slug* | string | is used to identify the place for the link to appear. Put it inside the text, surrounded by 2 squared brackets. |
link* | string | is the link to be used. |
linkText* | string | is the text to be inserted, instead of slug. |
Usage¶
{
"name": "example_input_one",
"title": "Example Input One",
"entity": [],
"subDescription": {
"text": "Ingesting data from to Splunk Cloud?\nRead our [[blogPost]] to learn more about Data Manager and it's availability on your Splunk Cloud instance.",
"links": [
{
"slug": "blogPost",
"link": "https://splk.it/31oy2b2",
"linkText": "blog post"
}
]
}
}
Custom Warning¶
This feature allows us to pass broarder description on Input and Configuration page displayed under main description.
Warning Properties¶
Property | Type | Description |
---|---|---|
create | object | Warning object definition for create form |
edit | object | Warning object definition for edit form |
clone | object | Warning object definition for clone form |
config | object | Warning object definition for config form |
Warning Object Properties¶
Property | Type | Description |
---|---|---|
message* | string | Text used for that description, you can put \n to add a breakline |
alwaysDisplay | boolean | Force warning to be always displayed, even after input changes. Default value is false. |
Usage¶
"warning": {
"create": {
"message": "Some warning for create form",
"alwaysDisplay": true
},
"edit": {
"message": "Some warning for edit form "
},
"clone": {
"message": "Some warning for clone form"
}
},
Ended: Advanced
Troubleshooting¶
General troubleshooting¶
To be able to troubleshoot the Python part of the add-on, you can use remote_pdb
. This can be used for the local development when you have locally installed the Splunk instance and add-on there.
Steps to set up:
- Put this file in the
bin
folder - Put this line, (
import remote_pdb; remote_pdb.RemotePdb(host="0.0.0.0", port=4444).set_trace()
), before the line that needs troubleshooting. - Go to the console and run
telnet 127.0.0.1 4444
. It will open apdb
console, where you can start troubleshooting. Refer to thepdb
documentation for the available commands.
Splunk calls your modular input only once¶
If Splunk calls your modular input only once, however, you are
specifying an interval within, it should call your script. Check the
use_single_instance
variable in the get_scheme
method of your modular
input class. It should be set to False so that Splunk can schedule the
input accordingly.
Search for “index=_internal ExecProcessor” and look for “interval: run once” near your script name in order to understand that Splunk does not schedule your modular input script.
ModuleNotFoundError: No module named ‘<library-name>‘¶
If you see this message in Splunk when your modular input is being run, it means that Splunk could not find a library that you are trying to import.
It can be because:
- there is no such library in the
package/lib
folder. Check yourpackage/lib/requirements.txt
file to make sure that you have it as part of the requirements. - there is no
import import_declare_test
at the top of your modular input file. Add the mentioned import to the top of your modular input file.
urllib3 >= 2¶
If you are getting an error (in splunkd.log
)
ImportError: urllib3 v2.0 only supports OpenSSL 1.1.1+, currently the 'ssl' module is compiled with OpenSSL 1.0.2k-fips 26 Jan 2017.
See: https://github.com/urllib3/urllib3/issues/2168
when your modular input is running, you need to use urllib3 < 2
in your requirements.txt
file.
Compare add-ons generated by 2 different versions of the ucc-gen build
¶
scripts
folder has a script, compare_different_ucc_versions_output.sh
, which
can be used to compare the output of the add-on built by two different versions of
the ucc-gen build
command.
To run it, copy the script to the add-on folder, and then read the instructions in the script itself. If it does not work for your particular case, feel free to adjust it yourself, or file a feature request for us to improve something.
Something went wrong¶
During the creation of the add-on, an error, such as incorrect import, unhandled exception etc., can be made in the code of modinput scripts. When the add-on is built, this error is not caught and a package can be installed in Splunk without any problems. However, when you try to enter the add-on page, you will see the message presented above. As this message is not clear, it is not helpful in finding the root cause of the problem.
Fortunately, most errors are logged in Splunk on the internal indexes. One of these indexes is _internal
.
First, search the _internal
index for the word ERROR
or stderr
.
Usually the source of these logs is the splunkd
process, so it can be used to pre-filter data.
index = _internal source=*splunkd* ERROR
or index = _internal source=*splunkd* stderr
In the case of small infrastructures, this simple query can return information you need.
When the instances are large and they have many applications, each of them can have errors. In addition, some errors are recorded only once when the add-on is installed, so it can be difficult to determine the correct time range.
In this case, you can narrow your search to a specific add-on. This may not be easy because no unique parameter is logged
that would easily filter out data for a specific add-on. However, you can use the scheme
parameter, which is directly correlated with the names of inputs in the add-on.
The example of a logged error:
Schema logs the input name with a colon at the end, so use an asterisk after entering the name:
index = _internal source=*splunkd* (component=ModularInputs stderr) OR component=ExecProcessor (scheme IN (example_input_one*, example_input_two*, example_input_three_abc*))
Or you can use a shortened version, using the wildcard mechanic:
index = _internal source=*splunkd* (component=ModularInputs stderr) OR component=ExecProcessor (scheme IN (*example_input*))
Since in this example we are talking about errors coming from the modular input scripts,
another filtering factor, the ModularInputs
component, is added. The ExecProcessor
component is also included. It is responsible for running and managing scripts.
Contributing Guidelines¶
We welcome contributions from the community! This guide will help you understand our contribution process and requirements.
Development guidelines¶
- Small PRs (blogpost)
- When fixing a bug, include a test that reproduces the issue in the same pull request (the test should fail without your changes)
- If you are refactoring, ensure adequate test coverage exists for the target area. If coverage is insufficient, create tests in a separate pull request first. This approach provides a safety net for validating current behavior and simplifies code reviews.
Build and Test¶
Prerequisites:
- Node.js® LTS version (download here)
- Yarn Classic (
npm install --global yarn
) - Poetry 1.5.1. Installation guide
If you are interested in contributing to the UI, the ui
folder has a separate README.md.
Script for building the backend, frontend, and spinning up the Docker container all at once:
./scripts/quick_start_ui.sh
Build the UI in the ui/dist
folder and copy the files to the static folder of the UCC.
./scripts/build_ui.sh
Build a new local version of ucc-gen
:
poetry build
Unit tests¶
poetry run pytest tests/unit
UI tests¶
If you need to run UI tests for the PR, add a “run-ui-tests” label before the PR is created.
UI tests will run automatically for any PR towards the main
/ develop
branches, and on the main
/ develop
branch as well.
-
With local version of ucc-gen, create a UCCExample add-on for the output directory:
poetry run ucc-gen build --source tests/testdata/test_addons/package_global_config_everything/package
-
Install docker, and run containerized Splunk Enterprise using script:
./scripts/run_splunk.sh
There are mapped default Splunk ports to host. To use a different configuration, see docker-splunk. Remember to mount the output package to the Splunk apps directory.
-
Install any browser specific to this browser driver, such as chromedriver for Chrome.
-
Run tests using the following command:
poetry run pytest tests/ui
Default test parameters use Splunk connection details and credentials from the earlier step, and chromedriver
is used as a default webdriver.
To use a different browser or Splunk configuration, set the proper parameters according to the smartx-ui-test-library documentation.
Linting and Type-checking¶
ucc-gen
uses the pre-commit
framework for linting and type-checking.
Consult with pre-commit
documentation about what is the best way to install the software.
To run it locally:
pre-commit run --all-files
Building TA with the Local Version of UCC¶
UCC is a tool for Technology Add-ons (TAs), so it’s important to test TA generation while developing UCC locally.
Overview¶
- Install Dependencies for Your TA
- Build the TA Using Your Local UCC Version
- Package the TA into a .tar.gz file using
ucc-gen package
Installing TA Dependencies¶
The method for installing dependencies may vary among different TAs. Common approaches include running Poetry, but please refer to your TA’s documentation for specific instructions.
# These variables would be used in the further steps
ta_repo=/path/to/ta
ta_name=TA_Name_From_app.manifest
poetry install --directory=$ta_repo
mkdir -p $ta_repo/package/lib
# Export dependencies to 'requirements.txt'
poetry export --without-hashes -o $ta_repo/package/lib/requirements.txt --directory $ta_repo
Note: ucc-gen expects dependencies to be listed in
package/lib/requirements.txt
.
Building TA¶
poetry run ucc-gen build --source $ta_repo/package
Ensure you specify the package
folder, not the repository root. Monitor the build process for any errors.
Caveat: The build command may run scripts from the TA repository that may not be tested if running from a non-TA repository. For example, build-ui.sh
may use relative paths for building custom components. You might need to manually run the script and/or copy the files to the output directory of UCC.
# in case if TA has custom UI components
mkdir -p output/$ta_name/appserver/static/js/build
cp -a $ta_repo/output/$ta_name/appserver/static/js/build/custom output/$ta_name/appserver/static/js/build
Packaging TA¶
poetry run ucc-gen package --path output/$ta_name
This command will generate a packaged TA (.tar.gz file) that you can install into Splunk.
Documentation changes¶
Documentation changes are also welcome!
To verify changes locally:
poetry run mkdocs serve -a localhost:8001
Issues and bug reports¶
If you’re seeing some unexpected behavior with ucc-gen
, create an issue on GitHub. You can click on “New Issue” and use the template provided.
Pull requests¶
We love to see pull requests!
PR Title¶
We follow Conventional Commits for PR titles. The title format is crucial as we squash commits during merge, and this PR title will be used in the release notes (for feat and fix types). Here’s a short TL;DR of the format:
<type>(<scope>): <description>
Types:
- feat: New feature (user facing)
- fix: Bug fix (user facing)
- docs: Documentation changes (user facing)
- style: Code style changes (formatting, etc.)
- refactor: Code changes that neither fix bugs nor add features
- perf: Performance improvements
- test: Adding or updating tests
- chore: Maintenance tasks
Example: feat(ui): add new input validation for text fields
PR Description¶
Includes:
- Motivation behind the changes (any reference to issues or user stories)
- High level description of code changes
- Description of changes in user experience if applicable.
- Screenshots for UI changes (before and after)
- Steps to reproduce the issue or test the new feature, if possible. This will speed up the review process.
After submitting your PR, GitHub will automatically add relevant reviewers, and CI checks will run automatically.
Note:
semgrep
andfossa
checks might fail for external contributors. This is expected and will be handled by maintainers.
Release flow¶
The instructions below utilize the GitHub CLI tool, which you can install via HomeBrew:
brew install gh
gh auth login
- The default development branch is
develop
. Use this branch for creating pull requests (PRs) for your features, fixes, documentation updates, etc. PRs to thedevelop
branch should be merged using the squash option on GitHub. - When it’s time for a release (handled by the UCC team), create a PR from
develop
tomain
using the following commands:
gh pr create --title "chore: merge develop into main" --body "" --head develop --base main
# set automerge with merge commit to avoid accidentally squashing PR
gh pr merge develop --auto --merge
- Ensure CI passes and await team review.
- PR should be merged using merge commit option in GitHub (already included in the command)
- Releases are made automatically (both on GitHub and PyPI), and a bot will push a commit to
main
with all necessary changes (i.e. like this) - If necessary, update release notes and CHANGELOG.md accordingly to the content of the release.
- If any issue was solved by this release, remove waiting-for-release label from it and then close the issue.
- After the release, backport the bot’s changes to the
develop
branch (i.e. #974):
gh pr create --title "chore: merge main into develop" --body "" --head main --base develop
# set automerge with merge commit to avoid accidentally squashing PR
gh pr merge main --auto --merge
-
If a release encounters issues requiring a quick bug fix (handled by the UCC team):
- Create a PR to the main branch with the fix, including tests that reproduce and then fix the issue.
- Ensure CI passes and await team review.
- Merge the PR using the merge commit option on GitHub.
- Backport the bug fix PR to the develop branch.
-
After release is done, announce it to community on slack channels:
5.53.0 (2024-11-13)¶
Bug Fixes¶
- Dropdown: fix showing selected option when value is numeric (#1439) (9e7394a)
- generate oauth authentication fields for OpenAPI integration (#1425) (beb561b)
- table: custom mapping for values in Status column (#1451) (4721738)
Features¶
- add ability to provide custom pip flags (#1447) (718c897)
- add grouping to configuration page (#1432) (b94b228)
- deprecate .uccignore and upgrade additional_package (#1415) (f6dd96f)
5.52.0 (2024-10-30)¶
Bug Fixes¶
- generate basic authentication fields for OpenAPI integration (#1407) (584b832)
- remove support for the “enable” action in table inputs (#1386) (26a4bb9)
Features¶
- print warning when entity does not have validators (#1409) (ad12cea)
- require splunktaucclib 6.4.0 during the build phase (#1412) (0d20269)
5.51.1 (2024-10-22)¶
Bug Fixes¶
5.51.0 (2024-10-16)¶
Bug Fixes¶
Features¶
- allow validators for oauth fields (#1355) (ef3b6a9)
- hide elements for cloud or enterprise (#1364) (21aa28f)
- modal implementation for data ingestion table (#1244) (8246870)
- server side validation of name field based on globalConfig (#1362) (4e43c27)
- support CRON as interval (#1346) (8c5a981)
5.50.1 (2024-10-04)¶
Bug Fixes¶
5.50.0 (2024-10-02)¶
Bug Fixes¶
- boolean values are converted to 1 and 0 only on configuration page (#1347) (d0d0c11)
- custom row loading on many tabs (#1336) (f124b5e)
- globalConfig: update name and rest root convention (#1335) (bdfa8c3), closes #1333
Features¶
- dashboard: add possibility to display CRITICAL log lvl in dashboard (#1337) (d937986)
- option for configuring is_visible from globalConfig.json (#1345) (04c80e3), closes #1334
- provide support for Python 3.9 for OS-dependent libraries (#1338) (5cfc889)
- restructure conf and spec file generation (#1328) (bc6a36b)
- restructure html file generation (#1311) (ed2c2bd)
- restructure xml file generation (#1312) (a171c8d)
5.49.0 (2024-08-21)¶
Bug Fixes¶
Features¶
- add basic textarea field to alerts (#1308) (cc1706f)
- add new index entity (#1313) (df77f51)
- add required as modifiable property (#1309) (a94cdc9)
- default value for custom mapping (#1304) (8c5a3a6), closes #1282
- use log_level in dashboard queries (#1289) (3fc86c3)
5.48.2 (2024-07-25)¶
Bug Fixes¶
- inputs: fix parsing ‘0’ as false for readonlyField and hideField (#1290) (ec676a1)
- NumberValidator: Number validators allows integer value (#1293) (dbd287c), closes #876
5.48.1 (2024-07-11)¶
Bug Fixes¶
5.48.0 (2024-07-10)¶
Bug Fixes¶
- allow using globalConfig validator regardless of the default encoding (#1276) (480798f)
- correctly map truly and falsy values for inputs (#1270) (2b8c2c2)
Features¶
- theme: add dark theme support (#1257) (8bd5d33)
- inputs: add hidable or readonly inputs (#1258) (8c70476)
- remove placeholder option from globalConfig (#1256) (044c2d0)
- update add-on generated by ucc-gen init command (#1263) (76e8e52)
- select entity: allow custom mapping for values (#1265) (202f046)
5.47.0 (2024-06-25)¶
Bug Fixes¶
- allow 2 blank lines in markdown (3832c3c)
Features¶
- custom_row: pass default row value to custom row component (#1218) (1fdebfa)
- dashboard: add custom filtering options for the license_usage file (#1247) (3e8d864)
- dashboard: add globalconfig configuration for custom dashboard tab name (#1239) (fce1df4)
5.46.0 (2024-06-13)¶
Bug Fixes¶
Features¶
- allow developers to choose the default view (#1197) (21610e2), closes #1041
- configuration: display UCC version (#1221) (a63d8b3)
- dashboard: add error categories to chart and event table in the error panel (#1225) (cd2907a)
- dashboard: add resource monitoring tab and information about input status (#1209) (e8acfd9)
- globalConfig file passed through
--config
accepts only JSON or YAML formats (#1216) (f661475) - sort table by visible text (#1205) (8561e0f)
5.45.0 (2024-05-28)¶
Bug Fixes¶
Features¶
- add built-in interval entity (#1179) (10ae8e3)
- add flag to add UI source map files during the build process (#1183) (6e4944b)
- Improve input helper module init scripts (#1204) (9abb12c)
5.44.0 (2024-05-14)¶
Bug Fixes¶
- alert: graceful handle for usage of activeResponse (#1185) (c43f38f)
- style: fix label overflow issue for ‘OpenAPI.json’ button in configuration page (#1181) (917f9c9)
Features¶
- auto-gen: notify users for existing features of UCC framework (#1177) (305dbbd)
- file input component, supports base64 encoding (#1167) (46417c2)
- helper modules for modular inputs (#1126) (fde1a33), closes #331
- search: relocate button from dropdown to action column In input page (#1148) (696e5a9)
5.43.0 (2024-04-30)¶
Bug Fixes¶
Features¶
5.42.1 (2024-04-22)¶
Bug Fixes¶
5.42.0 (2024-04-19)¶
Bug Fixes¶
- add customScript for alert action (#1143) (12d8392)
- add schema version update for alert action (#1150) (94f3070)
- update idna to 3.7 (#1146) (ece8f65)
Features¶
- adaptiveResponse: add verbose details for AR alert action (#1135) (b19d678)
- add iconFileName for alert action (#1134) (5a76706), closes #1105
- CheckboxGroup: add support for required field (#1131) (e101aa3)
- create a playground for global config (#1144) (791a6dc)
- enhanced monitoring dashboard (#1125) (2d2b143)
5.41.0 (2024-04-02)¶
Bug Fixes¶
Features¶
5.40.0 (2024-03-21)¶
Bug Fixes¶
- allow using only one Configuration tab (#1106) (f6a7fbd)
- custom value passed to component (#1104) (729f661)
Features¶
5.39.1 (2024-03-05)¶
Bug Fixes¶
5.39.0 (2024-02-20)¶
Bug Fixes¶
- a11y: associate labels with inputs (#1055) (a880c45)
- Add page for proxy configuration (#1057) (a76c0c2)
- return back div wrapper that shifts layout (#1061) (c6a42c6), closes #1055
Features¶
- add async on save to entity page (#1080) (abe8f96)
- add possibility to use async onSave method (#1079) (7dd6640)
- ADDON-57381 hide implementation details from user-facing error messages (#987) (5467ed9)
- modify fields on value (#1066) (1cd25b5)
5.38.0 (2024-02-06)¶
Bug Fixes¶
- EntityModal: prevent Enter from submitting the form in Modal window (#1047) (b7f179a), closes #875
- OpenAPI schema generator fixes for when multiple inputs are defined (#1016) (332db43)
Features¶
- add UCC version to globalConfig (#984) (e1229b4)
- ADDON-67533 implement support for oauth autorize and token urls (#1009) (aada373)
- allow wildcards in .uccignore file (#1012) (04b847f), closes #1011
- change avg() to sum() in PANEL_EVENTS_INGESTED_BY_SOURCETYPE_TEMPLATE panel (#1028) (c738634)
- customizing version of pip in build, add legacy resolver as optional (#1035) (751990c)
- default warning hidden after any input (#1024) (d0d69ee)
5.37.0 (2024-01-31)¶
Features¶
5.36.2 (2024-01-12)¶
Bug Fixes¶
- table and references (29e69bb)
5.36.1 (2024-01-12)¶
Bug Fixes¶
5.36.0 (2024-01-10)¶
Bug Fixes¶
- enable for entities and add it for oauth (#964) (21bb7f8)
- no-compile missing from os-dependentLibraries packages (#999) (537d450)
- pass disabled props for radio bar component (#997) (a4eb6f9)
- typo in the error message (#1004) (312c8be)
- update axios along with follow redirect (#1003) (7bc5a35)
Features¶
- add support for custom dashboards (#979) (7fe3d58)
- ADDON-67093 add custom warning message for forms (#970) (64daa77)
- buildtime version check for os-dependentLibraries (#981) (cbe923d)
- custom sub description for pages - ADDON-67014 (#982) (b3a32c5)
- require variable only when displayed ADDON-67013 (#985) (6873164)
5.35.1 (2023-12-14)¶
Bug Fixes¶
5.35.0 (2023-12-13)¶
Bug Fixes¶
Features¶
- add support for downloading os-dependent libraries (#963) (6cfb5a3)
- build commands produces detailed output of what happened (#927) (3fad1a2)
5.34.1 (2023-12-06)¶
Bug Fixes¶
5.34.0 (2023-11-28)¶
Bug Fixes¶
- change location of openapi.json generated file (#958) (e0d38b7)
- globalConfig validator respects numbers in values in autoCompleteFields (#957) (1716494)
- revert to static width of modal (#955) (aec869f)
- update urllib3 (#922) (11ff4c6)
Features¶
- add optional label for helpLink component (#939) (e3a9b40)
- add support for disableonEdit in oauth (#953) (d948128)
- additional validations for the groups feature (#926) (29c1251)
- ADDON-64844 better spacing in modal (#935) (b385759)
- ADDON-65107 implement download button for openapi (#932) (f71d7ec)
- schema.json: make entity schemas more specific (#938) (24c667b)
5.33.0 (2023-11-14)¶
Features¶
5.32.0 (2023-10-13)¶
Features¶
5.31.1 (2023-10-06)¶
Bug Fixes¶
5.31.1-beta.1 (2023-10-06)¶
Bug Fixes¶
5.31.0 (2023-10-05)¶
It’s a technical release to conclude the migration of UCC UI into this repository and we also happen to release 1 feature.
Features¶
- “Enable all” / “Disable all” buttons for Inputs page (https://github.com/splunk/addonfactory-ucc-base-ui/pull/437 nad https://github.com/splunk/addonfactory-ucc-base-ui/pull/443)
5.30.0 (2023-10-01)¶
Features¶
5.29.0 (2023-09-22)¶
Features¶
5.28.6 (2023-09-13)¶
Bug Fixes¶
5.28.5 (2023-09-06)¶
Bug Fixes¶
5.28.4 (2023-07-19)¶
Bug Fixes¶
5.28.3 (2023-07-17)¶
Bug Fixes¶
5.28.2 (2023-07-07)¶
Bug Fixes¶
5.28.1 (2023-06-22)¶
Bug Fixes¶
5.28.0 (2023-06-22)¶
Features¶
5.27.3 (2023-06-06)¶
Bug Fixes¶
5.27.2 (2023-06-02)¶
Bug Fixes¶
5.27.1 (2023-05-26)¶
Bug Fixes¶
5.27.0 (2023-05-17)¶
Features¶
- release v5.27.0 (#765) (5b55833), closes #749 #750 #751 #752 #753 #754 /dev.splunk.com/enterprise/reference/packagingtoolkit/pkgtoolkitappmanifest/#JSON-schema-200 #755
5.26.0 (2023-05-02)¶
Features¶
- create openapi such way that generated client code allows to update configuration and inputs (#740) (c412a60)
- GET methods and responses allow to get data (#742) (6fe35cd)
5.25.0 (2023-04-18)¶
Features¶
5.24.0 (2023-04-04)¶
Features¶
5.23.2 (2023-03-23)¶
Bug Fixes¶
5.23.1 (2023-03-20)¶
Bug Fixes¶
5.23.0 (2023-03-20)¶
Features¶
5.22.0 (2023-03-09)¶
Features¶
- v5.22.0 release (#678) (9efc0c2), closes #662 #663 #664 #665 #666 #667 #668 #669 #670 #672 #673 #671 #674 #677 #679 #680 #681 #682 #683 #684 #685 #686 #688 #689 #687 #690 #691 #693 #694 #695 #692 #697
5.21.0 (2023-02-22)¶
Features¶
5.20.0 (2023-02-13)¶
Features¶
- release v5.20.0 (#634) (e2a389d), closes #624 #626 #615 #618 #612 #629 #632 #633
- trigger v5.20.0 release (#635) (d07f487)
5.19.0 (2023-01-03)¶
Features¶
- release v5.19.0 (#601) (2dc1ae1), closes #593 #594 #595 /github.com/splunk/addonfactory-ucc-base-ui/blob/283d5abcf8f462ac10de876464bc1719fd19ff90/src/main/webapp/util/uccConfigurationValidators.js#L170-L184 #584
5.18.0 (2022-12-12)¶
Features¶
5.17.1 (2022-11-30)¶
Bug Fixes¶
5.17.0 (2022-11-29)¶
Features¶
5.16.1 (2022-11-28)¶
Bug Fixes¶
5.16.0 (2022-11-23)¶
Features¶
5.15.1 (2022-11-09)¶
Bug Fixes¶
- build add-on if config param is present (536634a)
5.15.0 (2022-11-07)¶
Features¶
5.14.2 (2022-11-02)¶
Bug Fixes¶
5.14.1 (2022-10-18)¶
Bug Fixes¶
5.14.0 (2022-10-18)¶
Features¶
5.13.0 (2022-08-02)¶
Features¶
5.12.0 (2022-07-08)¶
Features¶
5.11.0 (2022-07-08)¶
Features¶
5.10.4 (2022-07-04)¶
Bug Fixes¶
5.10.3 (2022-07-03)¶
Bug Fixes¶
5.10.2 (2022-02-01)¶
Bug Fixes¶
5.10.1 (2021-11-29)¶
Bug Fixes¶
5.10.0 (2021-11-16)¶
Features¶
- migrate to separate conf-parser library (2ab9fe9)
5.9.0 (2021-10-04)¶
Features¶
- trigger v5.9.0 release (a01259c)
5.8.2 (2021-08-18)¶
Bug Fixes¶
- add icon_path to each modular alert conf (c6828b9)
5.8.1 (2021-08-17)¶
Bug Fixes¶
- alert html generation (7dc8860)
5.8.0 (2021-08-16)¶
Features¶
- delete
apiVersion
from globalConfig.json and bump schemaVersion (6c22704)
5.7.0 (2021-08-14)¶
Bug Fixes¶
Features¶
5.6.2 (2021-08-10)¶
Bug Fixes¶
- dump dunamai to 1.5.5 version (6cc76bd)
5.6.1 (2021-08-09)¶
Bug Fixes¶
- do not ignore UCC UI folder (25cec26)
5.6.0 (2021-08-09)¶
Bug Fixes¶
- update ucc ui version to 1.8.4 (2daa655)
Features¶
- remove splunktaucclib (661eb64)
5.5.8 (2021-07-27)¶
Bug Fixes¶
- splunktaucclib update (26eb068)
5.5.7 (2021-07-26)¶
Bug Fixes¶
- remove non-valid Python code (b7adf48)
5.5.6 (2021-07-20)¶
Bug Fixes¶
5.5.5 (2021-07-19)¶
Bug Fixes¶
- TABConfigParser.remove_section() is not working read() (8c82a45)
- update ucc ui version to 1.8.3 (49a89d5)
5.5.3 (2021-07-12)¶
Bug Fixes¶
5.5.2 (2021-07-07)¶
Bug Fixes¶
5.5.1 (2021-07-07)¶
Bug Fixes¶
- broken import after modular alert code generation (#255) (a3138ec)
- remove unnecessary dependencies (6bd263f)
- update ucc ui version (e3e5cba)
- update ucc ui version to 1.7.7 (1f82472)
- update ucc ui version to 1.8.2 (300ca6a)
- update ucc version to 1.7.6 (2e47cc3)
- update ucc version to 1.8.1 (d7fa1c6)
Features¶
- support app.manifest file with comments (70eb38e), closes /github.com/splunk/appinspect/blob/fabd1387cf41e087edd86fb7f28e2f9e69a1467c/splunk_appinspect/checks/check_support_and_installation_standards.py#L169-L180
- update ucc ui version (cf04fa7)
5.3.1 (2021-06-15)¶
Bug Fixes¶
5.3.0 (2021-06-14)¶
Bug Fixes¶
Features¶
5.2.1 (2021-06-13)¶
Bug Fixes¶
- switch to slim docker image (7bde41c)
5.2.0 (2021-06-12)¶
Features¶
5.1.0 (2021-06-09)¶
Features¶
- Include notice file in distribution (#220) (fdfdf2b)
- ucc as a library (#218) (7f06c29)
- update ucc ui version (df8687e)
5.0.3 (2021-06-08)¶
Bug Fixes¶
- include schema and notice file in pip package (7b67c81)
- include schema and notice file in pip package (92d0ad6)
- quick fix for ta-version argument (e26e8bf)
- Replace Circle CI with Github actions (aa07fcf)
- support for ta-version argument (710452a)
- ucc-gen to replace token for redirect.xml (1128842)
- use defusedxml instead of xml library (c3fdfc0)
5.0.0-develop.1 (2021-05-31)¶
Bug Fixes¶
Features¶
- migrated to splunk-ui (aab1012)
- migrated to splunk-ui (42b9a20)
- update splunktaucclib to 4.2.0 (be831af)
BREAKING CHANGES¶
- Migrate UI to SplunkUI framework
- Migrate UI to SplunkUI framework
4.4.0 (2021-04-14)¶
Bug Fixes¶
- add interationalization to added changes (cf70a0f)
- add missing react-toast-notifications dep (88a1ce9)
- commented oauth realated logic from ucc-gen temporarily (6d08509)
- error handling and migrated to functional component (3e2d15d)
- error handling in errorboundary (b1ed49b)
- filter issue in table (86fffbe)
- initial default tab query param (2d4d7dd)
- internationalization fixes and code deduplication (b41f33d)
- make minor modifications for form submit on single page form (1501401)
- minor fixes and comments (be8dabd)
- refactored table header as separate component (0c386de)
- remove temporary test change for error boundary (baa54e7)
- removed multiple calls to endpoint in tab navigation for configuration page, addded conditional rendering of moreInfo based on globalConfig and fixed single input type dropdown filter (f1c2545)
- routing history with query params (9c5cc2f)
- title in input and configuration page templates (6328fdf)
- ucc_ui_lib: asynchronous state updates for status toggle button (4e63041)
- update ucc ui version (31ac853)
- update ucc ui version (8b077dc)
- update ucc ui version (b6dc8b4)
- update ucc ui version (e340376)
- use primitive type in useEffect for query param updates to reduce executions (a4a0542)
Features¶
- add page style dialog and its routing (a475235)
- Added button for create new input (979b058)
- added configuration page integration for table and single page form (b7a4d50)
- Added Create Input button in input_page (b2b3562)
- Added custom cell feature in the table and fixed sorting issue (3711846)
- Added error modal component (bbde4cf)
- Added localization in titles (24f663b)
- Added parsing and validation functionality for globalConfig.json file (e690000)
- added routing for record and tab name (748ab74)
- Added schemaGenerator.py file (be0b945)
- Added table component with actions button (f550769)
- build: Move ucc-ui-lib to a new repo (71db6b1)
- Custom row feature implemented (308d847)
- Data flow using react context api (ddfaf41)
- Fixed issue (887f419)
- Fixed prop type validation issue (b0643e6)
- Fixed the delete model issue (71743ae)
- Fixed typo (9d5d0ee)
- Fixed typo (3ce2363)
- Fixed typo (668d2a5)
- Form design changes (3f34bfa)
- formatted file (ec3c0a6)
- Implemented filter functionality in the table component (4a77545)
- Implemented styled component (503aeb4)
- Pagination component implemented (ab41e36)
- Refactored table component (4206ce3)
- Removed commented code (bbdda12)
- Removed id from custom table (2afdc83)
- Removed key (f80499d)
- Removed log line (1f51cb4)
- Removed logs (6763ef9)
- Removed logs (36476ac)
- Removed patch file (ef065dc)
- Resolved comments (5a6088b)
- Set configuration page to default (6b7150a)
- update splunktaucclib to 4.2.0 (be831af)
- Update the way to store data in the context (8d11e7d)
- update ucc ui version (d562bea)
- Updated custom cell file (0479106)
- Updated file name (8640413)
- Used i18n in custom cell (06d0f02)
- validate JSON configuration before generating build (0c80d62)
4.4.0 (2021-04-14)¶
Bug Fixes¶
- add interationalization to added changes (cf70a0f)
- add missing react-toast-notifications dep (88a1ce9)
- commented oauth realated logic from ucc-gen temporarily (6d08509)
- error handling and migrated to functional component (3e2d15d)
- error handling in errorboundary (b1ed49b)
- filter issue in table (86fffbe)
- initial default tab query param (2d4d7dd)
- internationalization fixes and code deduplication (b41f33d)
- make minor modifications for form submit on single page form (1501401)
- minor fixes and comments (be8dabd)
- refactored table header as separate component (0c386de)
- remove temporary test change for error boundary (baa54e7)
- removed multiple calls to endpoint in tab navigation for configuration page, addded conditional rendering of moreInfo based on globalConfig and fixed single input type dropdown filter (f1c2545)
- routing history with query params (9c5cc2f)
- title in input and configuration page templates (6328fdf)
- ucc_ui_lib: asynchronous state updates for status toggle button (4e63041)
- update ucc ui version (8b077dc)
- update ucc ui version (b6dc8b4)
- update ucc ui version (e340376)
- use primitive type in useEffect for query param updates to reduce executions (a4a0542)
Features¶
- add page style dialog and its routing (a475235)
- Added button for create new input (979b058)
- added configuration page integration for table and single page form (b7a4d50)
- Added Create Input button in input_page (b2b3562)
- Added custom cell feature in the table and fixed sorting issue (3711846)
- Added error modal component (bbde4cf)
- Added localization in titles (24f663b)
- Added parsing and validation functionality for globalConfig.json file (e690000)
- added routing for record and tab name (748ab74)
- Added schemaGenerator.py file (be0b945)
- Added table component with actions button (f550769)
- build: Move ucc-ui-lib to a new repo (71db6b1)
- Custom row feature implemented (308d847)
- Data flow using react context api (ddfaf41)
- Fixed issue (887f419)
- Fixed prop type validation issue (b0643e6)
- Fixed the delete model issue (71743ae)
- Fixed typo (9d5d0ee)
- Fixed typo (3ce2363)
- Fixed typo (668d2a5)
- Form design changes (3f34bfa)
- formatted file (ec3c0a6)
- Implemented filter functionality in the table component (4a77545)
- Implemented styled component (503aeb4)
- Pagination component implemented (ab41e36)
- Refactored table component (4206ce3)
- Removed commented code (bbdda12)
- Removed id from custom table (2afdc83)
- Removed key (f80499d)
- Removed log line (1f51cb4)
- Removed logs (6763ef9)
- Removed logs (36476ac)
- Removed patch file (ef065dc)
- Resolved comments (5a6088b)
- Set configuration page to default (6b7150a)
- Update the way to store data in the context (8d11e7d)
- update ucc ui version (d562bea)
- Updated custom cell file (0479106)
- Updated file name (8640413)
- Used i18n in custom cell (06d0f02)
- validate JSON configuration before generating build (0c80d62)
4.4.0 (2021-04-14)¶
Features¶
- validate JSON configuration before generating build (0c80d62)
4.3.0 (2021-04-06)¶
Bug Fixes¶
- added support for additional packaging (f9acc98)
- bump splunktaucclib to 4.0.13 (51a07f0)
- license: Correct License reference to Apache-2 (1996410)
- location of files was incorrect on commit (47d494d)
- Update CI to new standard (fe6b46b)
Features¶
4.1.9-b.1 (2020-11-13)¶
4.1.8-b.1 (2020-11-13)¶
4.1.6-a.7 (2020-11-09)¶
4.1.1-b.1 (2020-10-08)¶
4.1.1-a.3 (2020-10-08)¶
4.1.1-a.2 (2020-10-08)¶
4.1.1-a.1 (2020-10-08)¶
4.0.5-a.9 (2020-09-23)¶
4.0.5-a.8 (2020-09-22)¶
4.0.5-a.7 (2020-09-22)¶
Reverts¶
- Revert “Modified include in pyproject.toml with a glob” (14304e3)
4.0.5-a.5 (2020-09-19)¶
4.0.5-a.2 (2020-09-19)¶
4.0.5-a.1 (2020-09-19)¶
4.0.4 (2020-09-17)¶
Metadata¶
Metadata contains general information about add-on build.
Metadata Properties¶
Property | Type | Description |
---|---|---|
displayName* | string | Name displayed for end user. |
name* | string | Name used for API endpoints and all code references separating endpoints from any other app. Please refer to app.conf/[package]/id for more details. |
restRoot* | string | String used to create API endpoints, allows alphanumeric and - characters. |
apiVersion | string | [Deprecated] Version of used API. |
version* | string | Version of the add-on. |
schemaVersion | string | Version of JSON schema used in build process. |
_uccVersion | string | Version of UCC used during build process. Set by UCC itself. |
hideUCCVersion | boolean | Hide the label ‘Made with UCC’ on the Configuration page. |
checkForUpdates | boolean | Ability to configure app.conf->package.check_for_updates from globalConfig file. Default true . |
defaultView | string | Define which view should be loaded on TA load. One of "inputs" , "configuration" , "dashboard" or "search" . Default configuration . |
os-dependentLibraries | 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. Default: true if globalConfig file exists in the repository, else false. |
UI Tests ↵
Configuration Page ↵
General¶
TestConfigurationPage
¶
Bases: UccTester
Source code in tests/ui/test_configuration_page.py
11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 |
|
test_configuration_page_title_and_description(ucc_smartx_selenium_helper, ucc_smartx_rest_helper)
¶
Verifies the title and description of the page
Source code in tests/ui/test_configuration_page.py
12 13 14 15 16 17 18 19 20 21 22 23 24 25 |
|
test_openapi_json_download_button(ucc_smartx_selenium_helper, ucc_smartx_rest_helper)
¶
Verifies the OpenAPI json download button
Source code in tests/ui/test_configuration_page.py
27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 |
|
test_ucc_credits_label_exists(ucc_smartx_selenium_helper, ucc_smartx_rest_helper)
¶
Verifies the UCC label is rendered on the page
Source code in tests/ui/test_configuration_page.py
47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 |
|
Account¶
TestAccount
¶
Bases: UccTester
Source code in tests/ui/test_configuration_page_account_tab.py
59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 159 160 161 162 163 164 165 166 167 168 169 170 171 172 173 174 175 176 177 178 179 180 181 182 183 184 185 186 187 188 189 190 191 192 193 194 195 196 197 198 199 200 201 202 203 204 205 206 207 208 209 210 211 212 213 214 215 216 217 218 219 220 221 222 223 224 225 226 227 228 229 230 231 232 233 234 235 236 237 238 239 240 241 242 243 244 245 246 247 248 249 250 251 252 253 254 255 256 257 258 259 260 261 262 263 264 265 266 267 268 269 270 271 272 273 274 275 276 277 278 279 280 281 282 283 284 285 286 287 288 289 290 291 292 293 294 295 296 297 298 299 300 301 302 303 304 305 306 307 308 309 310 311 312 313 314 315 316 317 318 319 320 321 322 323 324 325 326 327 328 329 330 331 332 333 334 335 336 337 338 339 340 341 342 343 344 345 346 347 348 349 350 351 352 353 354 355 356 357 358 359 360 361 362 363 364 365 366 367 368 369 370 371 372 373 374 375 376 377 378 379 380 381 382 383 384 385 386 387 388 389 390 391 392 393 394 395 396 397 398 399 400 401 402 403 404 405 406 407 408 409 410 411 412 413 414 415 416 417 418 419 420 421 422 423 424 425 426 427 428 429 430 431 432 433 434 435 436 437 438 439 440 441 442 443 444 445 446 447 448 449 450 451 452 453 454 455 456 457 458 459 460 461 462 463 464 465 466 467 468 469 470 471 472 473 474 475 476 477 478 479 480 481 482 483 484 485 486 487 488 489 490 491 492 493 494 495 496 497 498 499 500 501 502 503 504 505 506 507 508 509 510 511 512 513 514 515 516 517 518 519 520 521 522 523 524 525 526 527 528 529 530 531 532 533 534 535 536 537 538 539 540 541 542 543 544 545 546 547 548 549 550 551 552 553 554 555 556 557 558 559 560 561 562 563 564 565 566 567 568 569 570 571 572 573 574 575 576 577 578 579 580 581 582 583 584 585 586 587 588 589 590 591 592 593 594 595 596 597 598 599 600 601 602 603 604 605 606 607 608 609 610 611 612 613 614 615 616 617 618 619 620 621 622 623 624 625 626 627 628 629 630 631 632 633 634 635 636 637 638 639 640 641 642 643 644 645 646 647 648 649 650 651 652 653 654 655 656 657 658 659 660 661 662 663 664 665 666 667 668 669 670 671 672 673 674 675 676 677 678 679 680 681 682 683 684 685 686 687 688 689 690 691 692 693 694 695 696 697 698 699 700 701 702 703 704 705 706 707 708 709 710 711 712 713 714 715 716 717 718 719 720 721 722 723 724 725 726 727 728 729 730 731 732 733 734 735 736 737 738 739 740 741 742 743 744 745 746 747 748 749 750 751 752 753 754 755 756 757 758 759 760 761 762 763 764 765 766 767 768 769 770 771 772 773 774 775 776 777 778 779 780 781 782 783 784 785 786 787 788 789 790 791 792 793 794 795 796 797 798 799 800 801 802 803 804 805 806 807 808 809 810 811 812 813 814 815 816 817 818 819 820 821 822 823 824 825 826 827 828 829 830 831 832 833 834 835 836 837 838 839 840 841 842 843 844 845 846 847 848 849 850 851 852 853 854 855 856 857 858 859 860 861 862 863 864 865 866 867 868 869 870 871 872 873 874 875 876 877 878 879 880 881 882 883 884 885 886 887 888 889 890 891 892 893 894 895 896 897 898 899 900 901 902 903 904 905 906 907 908 909 910 911 912 913 914 915 916 917 918 919 920 921 922 923 924 925 926 927 928 929 930 931 932 933 934 935 936 937 938 939 940 941 942 943 944 945 946 947 948 949 950 951 952 953 954 955 956 957 958 959 960 961 962 963 964 965 966 967 968 969 970 971 972 973 974 975 976 977 978 979 980 981 982 983 984 985 986 987 988 989 990 991 992 993 994 995 996 997 998 999 1000 1001 1002 1003 1004 1005 1006 1007 1008 1009 1010 1011 1012 1013 1014 1015 1016 1017 1018 1019 1020 1021 1022 1023 1024 1025 1026 1027 1028 1029 1030 1031 1032 1033 1034 1035 1036 1037 1038 1039 1040 1041 1042 1043 1044 1045 1046 1047 1048 1049 1050 1051 1052 1053 1054 1055 1056 1057 1058 1059 1060 1061 1062 1063 1064 1065 1066 1067 1068 1069 1070 1071 1072 1073 1074 1075 1076 1077 1078 1079 1080 1081 1082 1083 1084 1085 1086 1087 1088 1089 1090 1091 1092 1093 1094 1095 1096 1097 1098 1099 1100 1101 1102 1103 1104 1105 1106 1107 1108 1109 1110 1111 1112 1113 1114 1115 1116 1117 1118 1119 1120 1121 1122 1123 1124 1125 1126 1127 1128 1129 1130 1131 1132 1133 1134 1135 1136 1137 1138 1139 1140 1141 1142 1143 1144 1145 1146 1147 1148 1149 1150 1151 1152 1153 1154 1155 1156 1157 1158 1159 1160 1161 1162 1163 1164 1165 1166 1167 1168 1169 1170 1171 1172 1173 1174 1175 1176 1177 1178 1179 1180 1181 1182 1183 1184 1185 1186 1187 1188 1189 1190 1191 1192 1193 1194 1195 1196 1197 1198 1199 1200 1201 1202 1203 1204 1205 1206 1207 1208 1209 1210 1211 1212 1213 1214 1215 1216 1217 1218 1219 1220 1221 1222 1223 1224 1225 1226 1227 1228 1229 1230 1231 1232 1233 1234 1235 1236 1237 1238 1239 1240 1241 1242 1243 1244 1245 1246 1247 1248 1249 1250 1251 1252 1253 1254 1255 1256 1257 1258 1259 1260 1261 1262 1263 1264 1265 1266 1267 1268 1269 1270 1271 1272 |
|
test_account_action_values(ucc_smartx_selenium_helper, ucc_smartx_rest_helper, _add_account)
¶
Verifies action items for accout page
Source code in tests/ui/test_configuration_page_account_tab.py
1066 1067 1068 1069 1070 1071 1072 1073 1074 1075 1076 1077 1078 |
|
test_account_add_backend_validation(ucc_smartx_selenium_helper, ucc_smartx_rest_helper)
¶
Verifies the account in backend after adding account from frontend
Source code in tests/ui/test_configuration_page_account_tab.py
917 918 919 920 921 922 923 924 925 926 927 928 929 930 931 932 933 934 935 936 937 938 939 940 941 942 943 944 945 |
|
test_account_add_cancel_entity(ucc_smartx_selenium_helper, ucc_smartx_rest_helper)
¶
Verifies cancel functionality at time of add
Source code in tests/ui/test_configuration_page_account_tab.py
212 213 214 215 216 217 218 219 220 221 |
|
test_account_add_close_entity(ucc_smartx_selenium_helper, ucc_smartx_rest_helper)
¶
Verifies close functionality at time of add
Source code in tests/ui/test_configuration_page_account_tab.py
201 202 203 204 205 206 207 208 209 210 |
|
test_account_add_frontend_validation(ucc_smartx_selenium_helper, ucc_smartx_rest_helper)
¶
Verifies the frontend after adding account
Source code in tests/ui/test_configuration_page_account_tab.py
799 800 801 802 803 804 805 806 807 808 809 810 811 812 813 814 815 816 817 818 819 820 821 822 823 |
|
test_account_add_reserved_value_account_name(ucc_smartx_selenium_helper, ucc_smartx_rest_helper)
¶
Select the all the values from single select and verifies the selected value
Source code in tests/ui/test_configuration_page_account_tab.py
1157 1158 1159 1160 1161 1162 1163 1164 1165 1166 1167 1168 1169 1170 1171 1172 1173 1174 1175 |
|
test_account_add_valid_title(ucc_smartx_selenium_helper, ucc_smartx_rest_helper)
¶
Verifies the title of the ‘Add Entity’
Source code in tests/ui/test_configuration_page_account_tab.py
145 146 147 148 149 150 151 152 153 154 155 156 157 |
|
test_account_basic_fields_label_entity(ucc_smartx_selenium_helper, ucc_smartx_rest_helper)
¶
Verifies basic account field label
Source code in tests/ui/test_configuration_page_account_tab.py
391 392 393 394 395 396 397 398 399 400 401 402 403 404 405 406 407 408 409 410 411 412 413 414 415 416 |
|
test_account_checked_example_checkbox(ucc_smartx_selenium_helper, ucc_smartx_rest_helper)
¶
Verifies Check/Uncheck in example checkbox
Source code in tests/ui/test_configuration_page_account_tab.py
652 653 654 655 656 657 658 659 660 661 662 663 664 |
|
test_account_clone_backend_validation(ucc_smartx_selenium_helper, ucc_smartx_rest_helper, _add_account)
¶
Verifies the account in backend after cloning account from frontend
Source code in tests/ui/test_configuration_page_account_tab.py
979 980 981 982 983 984 985 986 987 988 989 990 991 992 993 994 995 996 997 998 999 1000 1001 1002 1003 1004 1005 1006 1007 1008 1009 |
|
test_account_clone_cancel_entity(ucc_smartx_selenium_helper, ucc_smartx_rest_helper, _add_account)
¶
Verifies cancel functionality at time of clone
Source code in tests/ui/test_configuration_page_account_tab.py
285 286 287 288 289 290 291 292 293 294 |
|
test_account_clone_close_entity(ucc_smartx_selenium_helper, ucc_smartx_rest_helper, _add_account)
¶
Verifies close functionality at time of clone
Source code in tests/ui/test_configuration_page_account_tab.py
274 275 276 277 278 279 280 281 282 283 |
|
test_account_clone_default_values(ucc_smartx_selenium_helper, ucc_smartx_rest_helper, _add_account)
¶
Verifies the frontend default fields at time of clone
Source code in tests/ui/test_configuration_page_account_tab.py
894 895 896 897 898 899 900 901 902 903 904 905 906 907 908 909 910 911 912 913 914 915 |
|
test_account_clone_frontend_validation(ucc_smartx_selenium_helper, ucc_smartx_rest_helper, _add_account)
¶
Verifies the frontend clone functionality
Source code in tests/ui/test_configuration_page_account_tab.py
868 869 870 871 872 873 874 875 876 877 878 879 880 881 882 883 884 885 886 887 888 889 890 891 892 |
|
test_account_clone_valid_title(ucc_smartx_selenium_helper, ucc_smartx_rest_helper, _add_account)
¶
Verifies the title of the ‘Clone Entity’
Source code in tests/ui/test_configuration_page_account_tab.py
173 174 175 176 177 178 179 180 181 182 183 184 185 |
|
test_account_count(ucc_smartx_selenium_helper, ucc_smartx_rest_helper, _add_multiple_account)
¶
Verifies count on table
Source code in tests/ui/test_configuration_page_account_tab.py
87 88 89 90 91 92 93 94 95 96 97 98 |
|
test_account_credentials_encrypted_value(ucc_smartx_selenium_helper, ucc_smartx_rest_helper, _add_account)
¶
Verifies the default number of rows in the table
Source code in tests/ui/test_configuration_page_account_tab.py
777 778 779 780 781 782 783 784 785 786 787 788 789 790 791 792 793 794 795 796 797 |
|
test_account_default_rows_in_table(ucc_smartx_selenium_helper, ucc_smartx_rest_helper)
¶
Verifies the default number of rows in the table
Source code in tests/ui/test_configuration_page_account_tab.py
60 61 62 63 64 65 66 67 68 |
|
test_account_default_value_auth_type(ucc_smartx_selenium_helper, ucc_smartx_rest_helper)
¶
Verifies default value of auth type
Source code in tests/ui/test_configuration_page_account_tab.py
627 628 629 630 631 632 633 634 635 636 |
|
test_account_default_value_example_environment(ucc_smartx_selenium_helper, ucc_smartx_rest_helper)
¶
Verifies default value of example environment
Source code in tests/ui/test_configuration_page_account_tab.py
601 602 603 604 605 606 607 608 609 610 611 612 |
|
test_account_default_value_example_radio(ucc_smartx_selenium_helper, ucc_smartx_rest_helper)
¶
Verifies default value of example radio
Source code in tests/ui/test_configuration_page_account_tab.py
722 723 724 725 726 727 728 729 730 731 |
|
test_account_delete_account_in_use(ucc_smartx_selenium_helper, ucc_smartx_rest_helper, _add_account)
¶
Verifies by deleting the input used account
Source code in tests/ui/test_configuration_page_account_tab.py
1039 1040 1041 1042 1043 1044 1045 1046 1047 1048 1049 1050 1051 1052 1053 |
|
test_account_delete_cancel_entity(ucc_smartx_selenium_helper, ucc_smartx_rest_helper, _add_account)
¶
Verifies cancel functionality at time of delete
Source code in tests/ui/test_configuration_page_account_tab.py
237 238 239 240 241 242 243 244 245 246 247 248 249 250 |
|
test_account_delete_close_entity(ucc_smartx_selenium_helper, ucc_smartx_rest_helper, _add_account)
¶
Verifies close functionality at time of delete
Source code in tests/ui/test_configuration_page_account_tab.py
223 224 225 226 227 228 229 230 231 232 233 234 235 |
|
test_account_delete_row_backend_validation(ucc_smartx_selenium_helper, ucc_smartx_rest_helper, _add_account)
¶
Verifies the account in backend after deleting the account from frontend
Source code in tests/ui/test_configuration_page_account_tab.py
1011 1012 1013 1014 1015 1016 1017 1018 1019 1020 1021 1022 1023 1024 1025 1026 |
|
test_account_delete_row_frontend_validation(ucc_smartx_selenium_helper, ucc_smartx_rest_helper, _add_account)
¶
Verifies the frontend delete functionlity
Source code in tests/ui/test_configuration_page_account_tab.py
753 754 755 756 757 758 759 760 761 762 763 764 |
|
test_account_delete_valid_prompt_message(ucc_smartx_selenium_helper, ucc_smartx_rest_helper, _add_account)
¶
Verifies the prompt message of the ‘Delete Entity’
Source code in tests/ui/test_configuration_page_account_tab.py
296 297 298 299 300 301 302 303 304 305 306 307 308 309 310 311 312 |
|
test_account_delete_valid_title(ucc_smartx_selenium_helper, ucc_smartx_rest_helper, _add_account)
¶
Verifies the title of the ‘Delete Entity’
Source code in tests/ui/test_configuration_page_account_tab.py
187 188 189 190 191 192 193 194 195 196 197 198 199 |
|
test_account_displayed_columns(ucc_smartx_selenium_helper, ucc_smartx_rest_helper)
¶
Verifies headers of account table
Source code in tests/ui/test_configuration_page_account_tab.py
1055 1056 1057 1058 1059 1060 1061 1062 1063 1064 |
|
test_account_edit_backend_validation(ucc_smartx_selenium_helper, ucc_smartx_rest_helper, _add_account)
¶
Verifies the account in backend after editing account from frontend
Source code in tests/ui/test_configuration_page_account_tab.py
947 948 949 950 951 952 953 954 955 956 957 958 959 960 961 962 963 964 965 966 967 968 969 970 971 972 973 974 975 976 977 |
|
test_account_edit_cancel_entity(ucc_smartx_selenium_helper, ucc_smartx_rest_helper, _add_account)
¶
Verifies cancel functionality at time of edit
Source code in tests/ui/test_configuration_page_account_tab.py
263 264 265 266 267 268 269 270 271 272 |
|
test_account_edit_close_entity(ucc_smartx_selenium_helper, ucc_smartx_rest_helper, _add_account)
¶
Verifies close functionality at time of edit
Source code in tests/ui/test_configuration_page_account_tab.py
252 253 254 255 256 257 258 259 260 261 |
|
test_account_edit_default_values(ucc_smartx_selenium_helper, ucc_smartx_rest_helper, _add_account)
¶
Verification of default values in fields at time of edit
Source code in tests/ui/test_configuration_page_account_tab.py
1080 1081 1082 1083 1084 1085 1086 1087 1088 1089 1090 1091 1092 1093 1094 1095 1096 1097 1098 1099 1100 1101 1102 |
|
test_account_edit_frontend_validation(ucc_smartx_selenium_helper, ucc_smartx_rest_helper, _add_account)
¶
Verifies the frontend edit functionality
Source code in tests/ui/test_configuration_page_account_tab.py
825 826 827 828 829 830 831 832 833 834 835 836 837 838 839 840 841 842 843 844 845 846 847 848 849 850 |
|
test_account_edit_uneditable_field_name(ucc_smartx_selenium_helper, ucc_smartx_rest_helper, _add_account)
¶
Verifies the frontend uneditable fields at time of edit of the account
Source code in tests/ui/test_configuration_page_account_tab.py
766 767 768 769 770 771 772 773 774 775 |
|
test_account_edit_valid_title(ucc_smartx_selenium_helper, ucc_smartx_rest_helper, _add_account)
¶
Verifies the title of the ‘Edit Entity’
Source code in tests/ui/test_configuration_page_account_tab.py
159 160 161 162 163 164 165 166 167 168 169 170 171 |
|
test_account_encrypted_field_client_secret(ucc_smartx_selenium_helper, ucc_smartx_rest_helper)
¶
Verifies if the password field is masked or not in the Textbox
Source code in tests/ui/test_configuration_page_account_tab.py
540 541 542 543 544 545 546 547 548 549 550 551 |
|
test_account_encrypted_field_password(ucc_smartx_selenium_helper, ucc_smartx_rest_helper)
¶
Verifies if the password field is masked or not in the Textbox
Source code in tests/ui/test_configuration_page_account_tab.py
356 357 358 359 360 361 362 363 364 365 366 |
|
test_account_filter_functionality_negative(ucc_smartx_selenium_helper, ucc_smartx_rest_helper, _add_account)
¶
Verifies the filter functionality (Negative)
Source code in tests/ui/test_configuration_page_account_tab.py
100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 |
|
test_account_filter_functionality_positive(ucc_smartx_selenium_helper, ucc_smartx_rest_helper, _add_account)
¶
Verifies the filter functionality (Positive)
Source code in tests/ui/test_configuration_page_account_tab.py
116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 |
|
test_account_help_text_entity(ucc_smartx_selenium_helper, ucc_smartx_rest_helper)
¶
Verifies help text for the field name
Source code in tests/ui/test_configuration_page_account_tab.py
444 445 446 447 448 449 450 451 452 453 454 455 456 457 458 459 460 461 462 463 464 465 466 467 468 469 470 471 472 473 474 475 476 477 |
|
test_account_helplink(ucc_smartx_selenium_helper, ucc_smartx_rest_helper)
¶
Verifies whether the table help link redirects to the correct URL
Source code in tests/ui/test_configuration_page_account_tab.py
1028 1029 1030 1031 1032 1033 1034 1035 1036 1037 |
|
test_account_list_auth_type(ucc_smartx_selenium_helper, ucc_smartx_rest_helper)
¶
Verifies auth type list dropdown
Source code in tests/ui/test_configuration_page_account_tab.py
638 639 640 641 642 643 644 645 646 647 648 649 650 |
|
test_account_list_example_environment(ucc_smartx_selenium_helper, ucc_smartx_rest_helper)
¶
Verifies example environment list dropdown
Source code in tests/ui/test_configuration_page_account_tab.py
614 615 616 617 618 619 620 621 622 623 624 625 |
|
test_account_list_example_multiple_select(ucc_smartx_selenium_helper, ucc_smartx_rest_helper)
¶
Verifies example multiple select list dropdown
Source code in tests/ui/test_configuration_page_account_tab.py
678 679 680 681 682 683 684 685 686 687 688 689 690 |
|
test_account_oauth_fields_label_entity(ucc_smartx_selenium_helper, ucc_smartx_rest_helper)
¶
Verifies oauth account field label
Source code in tests/ui/test_configuration_page_account_tab.py
418 419 420 421 422 423 424 425 426 427 428 429 430 431 432 433 434 435 436 437 438 439 440 441 442 |
|
test_account_pagination(ucc_smartx_selenium_helper, ucc_smartx_rest_helper, _add_multiple_account)
¶
Verifies pagination list
Source code in tests/ui/test_configuration_page_account_tab.py
132 133 134 135 136 137 138 139 140 141 142 143 |
|
test_account_required_field_client_id(ucc_smartx_selenium_helper, ucc_smartx_rest_helper)
¶
Verifies required field client id
Source code in tests/ui/test_configuration_page_account_tab.py
500 501 502 503 504 505 506 507 508 509 510 511 512 513 514 515 516 517 518 |
|
test_account_required_field_client_secret(ucc_smartx_selenium_helper, ucc_smartx_rest_helper)
¶
Verifies required field client secret
Source code in tests/ui/test_configuration_page_account_tab.py
520 521 522 523 524 525 526 527 528 529 530 531 532 533 534 535 536 537 538 |
|
test_account_required_field_example_multiple_select(ucc_smartx_selenium_helper, ucc_smartx_rest_helper)
¶
Verifies required field example multiple select
Source code in tests/ui/test_configuration_page_account_tab.py
479 480 481 482 483 484 485 486 487 488 489 490 491 492 493 494 495 496 497 498 |
|
test_account_required_field_name(ucc_smartx_selenium_helper, ucc_smartx_rest_helper)
¶
Verifies required field name
Source code in tests/ui/test_configuration_page_account_tab.py
368 369 370 371 372 373 374 375 376 377 378 379 380 381 382 383 384 385 386 387 388 389 |
|
test_account_required_field_password(ucc_smartx_selenium_helper, ucc_smartx_rest_helper)
¶
Verifies required field password
Source code in tests/ui/test_configuration_page_account_tab.py
335 336 337 338 339 340 341 342 343 344 345 346 347 348 349 350 351 352 353 354 |
|
test_account_required_field_username(ucc_smartx_selenium_helper, ucc_smartx_rest_helper)
¶
Verifies required field username
Source code in tests/ui/test_configuration_page_account_tab.py
314 315 316 317 318 319 320 321 322 323 324 325 326 327 328 329 330 331 332 333 |
|
test_account_search_value_example_multiple_select(ucc_smartx_selenium_helper, ucc_smartx_rest_helper)
¶
Verifies example multiple select search functionality
Source code in tests/ui/test_configuration_page_account_tab.py
707 708 709 710 711 712 713 714 715 716 717 718 719 720 |
|
test_account_select_value_auth_type(ucc_smartx_selenium_helper, ucc_smartx_rest_helper)
¶
Select the all the values from single select and verifies the selected value
Source code in tests/ui/test_configuration_page_account_tab.py
1139 1140 1141 1142 1143 1144 1145 1146 1147 1148 1149 1150 1151 1152 1153 1154 1155 |
|
test_account_select_value_example_environment(ucc_smartx_selenium_helper, ucc_smartx_rest_helper)
¶
Verifies example environment select value
Source code in tests/ui/test_configuration_page_account_tab.py
666 667 668 669 670 671 672 673 674 675 676 |
|
test_account_select_value_example_multiple_select(ucc_smartx_selenium_helper, ucc_smartx_rest_helper)
¶
Verifies example multiple select value
Source code in tests/ui/test_configuration_page_account_tab.py
692 693 694 695 696 697 698 699 700 701 702 703 704 705 |
|
test_account_sort_functionality(ucc_smartx_selenium_helper, ucc_smartx_rest_helper, _add_multiple_account)
¶
Verifies sorting functionality for name column
Source code in tests/ui/test_configuration_page_account_tab.py
70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 |
|
test_account_title_and_description(ucc_smartx_selenium_helper, ucc_smartx_rest_helper)
¶
Verifies title and discription
Source code in tests/ui/test_configuration_page_account_tab.py
1104 1105 1106 1107 1108 1109 1110 1111 1112 1113 1114 1115 1116 |
|
test_account_url_validation(ucc_smartx_selenium_helper, ucc_smartx_rest_helper)
¶
Source code in tests/ui/test_configuration_page_account_tab.py
1177 1178 1179 1180 1181 1182 1183 1184 1185 1186 1187 1188 1189 1190 1191 |
|
test_account_valid_account_name(ucc_smartx_selenium_helper, ucc_smartx_rest_helper)
¶
Verifies whether adding special characters, number in starting of name field displays validation error
Source code in tests/ui/test_configuration_page_account_tab.py
553 554 555 556 557 558 559 560 561 562 563 564 565 566 567 568 569 570 571 572 573 574 575 576 577 578 579 580 581 |
|
test_account_valid_input_account_name(ucc_smartx_selenium_helper, ucc_smartx_rest_helper)
¶
Verifies validation of field account_name
Source code in tests/ui/test_configuration_page_account_tab.py
1118 1119 1120 1121 1122 1123 1124 1125 1126 1127 1128 1129 1130 1131 1132 1133 1134 1135 1136 1137 |
|
test_account_valid_length_name(ucc_smartx_selenium_helper, ucc_smartx_rest_helper)
¶
Verifies the name field should not be more than 50 characters
Source code in tests/ui/test_configuration_page_account_tab.py
583 584 585 586 587 588 589 590 591 592 593 594 595 596 597 598 599 |
|
test_add_account_duplicate_name(ucc_smartx_selenium_helper, ucc_smartx_rest_helper, _add_account)
¶
Verifies by saving an entity with duplicate name at time of add it displays and error
Source code in tests/ui/test_configuration_page_account_tab.py
733 734 735 736 737 738 739 740 741 742 743 744 745 746 747 748 749 750 751 |
|
test_clone_account_duplicate_name(ucc_smartx_selenium_helper, ucc_smartx_rest_helper, _add_account)
¶
Verifies by saving an entity with duplicate name at time of clone it displays and error
Source code in tests/ui/test_configuration_page_account_tab.py
852 853 854 855 856 857 858 859 860 861 862 863 864 865 866 |
|
test_example_validation_of_oauth_fields_too_short(ucc_smartx_selenium_helper, ucc_smartx_rest_helper)
¶
Verifies required field client id
Source code in tests/ui/test_configuration_page_account_tab.py
1193 1194 1195 1196 1197 1198 1199 1200 1201 1202 1203 1204 1205 1206 1207 1208 1209 1210 1211 1212 1213 1214 1215 |
|
test_example_validation_of_oauth_fields_wrong_characters(ucc_smartx_selenium_helper, ucc_smartx_rest_helper)
¶
Verifies required field client id
Source code in tests/ui/test_configuration_page_account_tab.py
1217 1218 1219 1220 1221 1222 1223 1224 1225 1226 1227 1228 1229 1230 1231 1232 1233 1234 1235 1236 1237 1238 1239 1240 1241 |
|
test_example_validation_of_oauth_valid(ucc_smartx_selenium_helper, ucc_smartx_rest_helper)
¶
Verifies required field client id
Source code in tests/ui/test_configuration_page_account_tab.py
1243 1244 1245 1246 1247 1248 1249 1250 1251 1252 1253 1254 1255 1256 1257 1258 1259 1260 1261 1262 1263 1264 1265 1266 1267 1268 1269 1270 1271 1272 |
|
Custom¶
TestCustomPage
¶
Bases: UccTester
Source code in tests/ui/test_configuration_page_custom_tab.py
23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 159 160 161 162 163 164 165 166 167 168 169 170 171 172 173 174 175 176 177 178 179 180 181 182 183 184 185 186 187 188 189 190 191 192 193 194 195 196 197 198 199 200 201 202 203 204 205 206 207 208 209 210 211 212 213 214 215 216 217 218 219 220 221 222 223 224 225 226 227 228 229 230 231 232 233 234 |
|
test_custom_fields_label_entity(ucc_smartx_selenium_helper, ucc_smartx_rest_helper)
¶
Verifies custom fields label
Source code in tests/ui/test_configuration_page_custom_tab.py
24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 |
|
test_custom_frontend_backend_validation(ucc_smartx_selenium_helper, ucc_smartx_rest_helper, _reset_configuration)
¶
This test case checks the validates frontend save in custom tab
Source code in tests/ui/test_configuration_page_custom_tab.py
40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 |
|
test_custom_valid_input_test_date(ucc_smartx_selenium_helper, ucc_smartx_rest_helper)
¶
This test case checks test date field should be in ISO 8601 format
Source code in tests/ui/test_configuration_page_custom_tab.py
195 196 197 198 199 200 201 202 203 204 205 206 207 208 209 210 211 212 213 |
|
test_custom_valid_input_test_email(ucc_smartx_selenium_helper, ucc_smartx_rest_helper)
¶
This test case checks test email field should be email
Source code in tests/ui/test_configuration_page_custom_tab.py
158 159 160 161 162 163 164 165 166 167 168 169 170 171 172 173 174 |
|
test_custom_valid_input_test_ipv4(ucc_smartx_selenium_helper, ucc_smartx_rest_helper)
¶
This test case checks test ipv4 field should be valid ipv4
Source code in tests/ui/test_configuration_page_custom_tab.py
176 177 178 179 180 181 182 183 184 185 186 187 188 189 190 191 192 193 |
|
test_custom_valid_input_test_number(ucc_smartx_selenium_helper, ucc_smartx_rest_helper)
¶
This test case checks test number field should be integer
Source code in tests/ui/test_configuration_page_custom_tab.py
101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 |
|
test_custom_valid_input_test_regex(ucc_smartx_selenium_helper, ucc_smartx_rest_helper)
¶
This test case checks regex of test regex field
Source code in tests/ui/test_configuration_page_custom_tab.py
141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 |
|
test_custom_valid_input_test_url(ucc_smartx_selenium_helper, ucc_smartx_rest_helper)
¶
This test case checks test url field should be valid url
Source code in tests/ui/test_configuration_page_custom_tab.py
215 216 217 218 219 220 221 222 223 224 225 226 227 228 229 230 231 232 233 234 |
|
test_custom_valid_length_test_string_greater(ucc_smartx_selenium_helper, ucc_smartx_rest_helper)
¶
This test case checks length of test string field should be greater than 4
Source code in tests/ui/test_configuration_page_custom_tab.py
71 72 73 74 75 76 77 78 79 80 81 82 83 84 |
|
test_custom_valid_length_test_string_less(ucc_smartx_selenium_helper, ucc_smartx_rest_helper)
¶
This test case checks length of test string field should be less than 11
Source code in tests/ui/test_configuration_page_custom_tab.py
86 87 88 89 90 91 92 93 94 95 96 97 98 99 |
|
test_custom_valid_range_test_number(ucc_smartx_selenium_helper, ucc_smartx_rest_helper)
¶
This test case checks range of test number field should be between 1 to 10
Source code in tests/ui/test_configuration_page_custom_tab.py
117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 |
|
Logging¶
TestLoggingPage
¶
Bases: UccTester
Source code in tests/ui/test_configuration_page_logging_tab.py
17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 |
|
test_logging_default_log_level(ucc_smartx_selenium_helper, ucc_smartx_rest_helper)
¶
Source code in tests/ui/test_configuration_page_logging_tab.py
18 19 20 21 22 23 24 25 26 27 28 |
|
test_logging_label_log_level(ucc_smartx_selenium_helper, ucc_smartx_rest_helper)
¶
Verifies the label of log level
Source code in tests/ui/test_configuration_page_logging_tab.py
73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 |
|
test_logging_list_log_levels(ucc_smartx_selenium_helper, ucc_smartx_rest_helper)
¶
Source code in tests/ui/test_configuration_page_logging_tab.py
30 31 32 33 34 35 36 37 38 39 40 |
|
test_logging_select_random_log_level(ucc_smartx_selenium_helper, ucc_smartx_rest_helper, _reset_configuration)
¶
Source code in tests/ui/test_configuration_page_logging_tab.py
42 43 44 45 46 47 48 49 50 51 52 53 54 55 |
|
test_logging_selected_log_level_frontend_backend(ucc_smartx_selenium_helper, ucc_smartx_rest_helper, _reset_configuration)
¶
Source code in tests/ui/test_configuration_page_logging_tab.py
57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 |
|
Proxy¶
TestProxyPage
¶
Bases: UccTester
Source code in tests/ui/test_configuration_page_proxy_tab.py
10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 159 160 161 162 163 164 165 166 167 168 169 170 171 172 173 174 175 176 177 178 179 180 181 182 183 184 185 186 187 188 189 190 191 192 193 194 195 196 197 198 199 200 201 202 203 204 205 206 207 208 209 210 211 212 213 214 215 216 217 218 219 220 221 222 223 224 225 226 227 228 229 230 231 232 233 234 235 236 237 238 239 240 241 242 243 244 245 246 247 248 249 250 251 252 253 254 255 256 257 258 259 260 261 262 263 264 265 266 267 268 269 270 271 272 273 274 275 276 277 278 279 280 281 282 283 284 285 286 287 288 289 290 291 292 293 294 |
|
test_proxy_encrypted_field_password(ucc_smartx_selenium_helper, ucc_smartx_rest_helper)
¶
Source code in tests/ui/test_configuration_page_proxy_tab.py
167 168 169 170 171 172 173 174 175 176 177 178 179 180 181 182 183 184 185 186 187 188 189 190 191 192 193 194 |
|
test_proxy_frontend_backend_validation(ucc_smartx_selenium_helper, ucc_smartx_rest_helper)
¶
Source code in tests/ui/test_configuration_page_proxy_tab.py
239 240 241 242 243 244 245 246 247 248 249 250 251 252 253 254 255 256 257 258 259 260 261 262 263 264 265 266 267 268 269 270 271 272 |
|
test_proxy_host_field_length_validation(ucc_smartx_selenium_helper, ucc_smartx_rest_helper)
¶
Source code in tests/ui/test_configuration_page_proxy_tab.py
65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 |
|
test_proxy_host_valid_input(ucc_smartx_selenium_helper, ucc_smartx_rest_helper)
¶
Verification of host throwing error msg when containing special characters
Source code in tests/ui/test_configuration_page_proxy_tab.py
274 275 276 277 278 279 280 281 282 283 284 285 286 287 288 289 290 291 292 293 294 |
|
test_proxy_misc(ucc_smartx_selenium_helper, ucc_smartx_rest_helper)
¶
Source code in tests/ui/test_configuration_page_proxy_tab.py
11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 |
|
test_proxy_password_field_length_validation(ucc_smartx_selenium_helper, ucc_smartx_rest_helper)
¶
Source code in tests/ui/test_configuration_page_proxy_tab.py
217 218 219 220 221 222 223 224 225 226 227 228 229 230 231 232 233 234 235 236 237 |
|
test_proxy_port_field_numeric_values(ucc_smartx_selenium_helper, ucc_smartx_rest_helper)
¶
Source code in tests/ui/test_configuration_page_proxy_tab.py
107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 |
|
test_proxy_port_field_valid_integer(ucc_smartx_selenium_helper, ucc_smartx_rest_helper)
¶
Source code in tests/ui/test_configuration_page_proxy_tab.py
147 148 149 150 151 152 153 154 155 156 157 158 159 160 161 162 163 164 165 |
|
test_proxy_port_field_valid_range(ucc_smartx_selenium_helper, ucc_smartx_rest_helper)
¶
Source code in tests/ui/test_configuration_page_proxy_tab.py
127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 |
|
test_proxy_required_field_host(ucc_smartx_selenium_helper, ucc_smartx_rest_helper)
¶
Source code in tests/ui/test_configuration_page_proxy_tab.py
41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 |
|
test_proxy_required_field_port(ucc_smartx_selenium_helper, ucc_smartx_rest_helper)
¶
Source code in tests/ui/test_configuration_page_proxy_tab.py
85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 |
|
test_proxy_username_field_length_validation(ucc_smartx_selenium_helper, ucc_smartx_rest_helper)
¶
Source code in tests/ui/test_configuration_page_proxy_tab.py
196 197 198 199 200 201 202 203 204 205 206 207 208 209 210 211 212 213 214 215 |
|
Ended: Configuration Page
Alert Action Page¶
TestAlertActions
¶
Bases: UccTester
Source code in tests/ui/test_alert_actions_page.py
15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 159 160 161 162 163 164 165 166 167 168 169 170 171 172 173 174 175 176 177 178 179 180 181 |
|
test_account_functionality(ucc_smartx_selenium_helper, add_delete_account)
¶
Source code in tests/ui/test_alert_actions_page.py
42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 |
|
test_action_in_list(ucc_smartx_selenium_helper)
¶
Source code in tests/ui/test_alert_actions_page.py
16 17 18 19 20 21 22 23 24 25 26 27 |
|
test_alert_action_label_entity(ucc_smartx_selenium_helper, ucc_smartx_rest_helper)
¶
Verifies the alert field labels
Source code in tests/ui/test_alert_actions_page.py
163 164 165 166 167 168 169 170 171 172 173 174 175 176 177 178 179 180 181 |
|
test_alert_action_save(ucc_smartx_selenium_helper, _clean_alert, add_delete_account)
¶
Source code in tests/ui/test_alert_actions_page.py
108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 |
|
test_alert_help_text_entity(ucc_smartx_selenium_helper)
¶
Source code in tests/ui/test_alert_actions_page.py
136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 159 160 161 |
|
test_checkbox(ucc_smartx_selenium_helper)
¶
Source code in tests/ui/test_alert_actions_page.py
65 66 67 68 69 70 71 72 73 74 75 76 77 |
|
test_dropdown_list(ucc_smartx_selenium_helper)
¶
Source code in tests/ui/test_alert_actions_page.py
29 30 31 32 33 34 35 36 37 38 39 40 |
|
test_single_select(ucc_smartx_selenium_helper)
¶
Source code in tests/ui/test_alert_actions_page.py
79 80 81 82 83 84 85 86 87 88 89 90 91 92 |
|
test_toggle(ucc_smartx_selenium_helper)
¶
Source code in tests/ui/test_alert_actions_page.py
94 95 96 97 98 99 100 101 102 103 104 105 106 |
|
Input Page¶
TestInputPage
¶
Bases: UccTester
Source code in tests/ui/test_input_page.py
128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 159 160 161 162 163 164 165 166 167 168 169 170 171 172 173 174 175 176 177 178 179 180 181 182 183 184 185 186 187 188 189 190 191 192 193 194 195 196 197 198 199 200 201 202 203 204 205 206 207 208 209 210 211 212 213 214 215 216 217 218 219 220 221 222 223 224 225 226 227 228 229 230 231 232 233 234 235 236 237 238 239 240 241 242 243 244 245 246 247 248 249 250 251 252 253 254 255 256 257 258 259 260 261 262 263 264 265 266 267 268 269 270 271 272 273 274 275 276 277 278 279 280 281 282 283 284 285 286 287 288 289 290 291 292 293 294 295 296 297 298 299 300 301 302 303 304 305 306 307 308 309 310 311 312 313 314 315 316 317 318 319 320 321 322 323 324 325 326 327 328 329 330 331 332 333 334 335 336 337 338 339 340 341 342 343 344 345 346 347 348 349 350 351 352 353 354 355 356 357 358 359 360 361 362 363 364 365 366 367 368 369 370 371 372 373 374 375 376 377 378 379 380 381 382 383 384 385 386 387 388 389 390 391 392 393 394 395 396 397 398 399 400 401 402 403 404 405 406 407 408 409 410 411 412 413 414 415 416 417 418 419 420 421 422 423 424 425 426 427 428 429 430 431 432 433 434 435 436 437 438 439 440 441 442 443 444 445 446 447 448 449 450 451 452 453 454 455 456 457 458 459 460 461 462 463 464 465 466 467 468 469 470 471 472 473 474 475 476 477 478 479 480 481 482 483 484 485 486 487 488 489 490 491 492 493 494 495 496 497 498 499 500 501 502 503 504 505 506 507 508 509 510 511 512 513 514 515 516 517 518 519 520 521 522 523 524 525 526 527 528 529 530 531 532 533 534 535 536 537 538 539 540 541 542 543 544 545 546 547 548 549 550 551 552 553 554 555 556 557 558 559 560 561 562 563 564 565 566 567 568 569 570 571 572 573 574 575 576 577 578 579 580 581 582 583 584 585 586 587 588 589 590 591 592 593 594 595 596 597 598 599 600 601 602 603 604 605 606 607 608 609 610 611 612 613 614 615 616 617 618 619 620 621 622 623 624 625 626 627 628 629 630 631 632 633 634 635 636 637 638 639 640 641 642 643 644 645 646 647 648 649 650 651 652 653 654 655 656 657 658 659 660 661 662 663 664 665 666 667 668 669 670 671 672 673 674 675 676 677 678 679 680 681 682 683 684 685 686 687 688 689 690 691 692 693 694 695 696 697 698 699 700 701 702 703 704 705 706 707 708 709 710 711 712 713 714 715 716 717 718 719 720 721 722 723 724 725 726 727 728 729 730 731 732 733 734 735 736 737 738 739 740 741 742 743 744 745 746 747 748 749 750 751 752 753 754 755 756 757 758 759 760 761 762 763 764 765 766 767 768 769 770 771 772 773 774 775 776 777 778 779 780 781 782 783 784 785 786 787 788 789 790 791 792 793 794 795 796 797 798 799 800 801 802 803 804 805 806 807 808 809 810 811 812 813 814 815 816 817 818 819 820 821 822 823 824 825 826 827 828 829 830 831 832 833 834 835 836 837 838 839 840 841 842 843 844 845 846 847 848 849 850 851 852 853 854 855 856 857 858 859 860 861 862 863 864 865 866 867 868 869 870 871 872 873 874 875 876 877 878 879 880 881 882 883 884 885 886 887 888 889 890 891 892 893 894 895 896 897 898 899 900 901 902 903 904 905 906 907 908 909 910 911 912 913 914 915 916 917 918 919 920 921 922 923 924 925 926 927 928 929 930 931 932 933 934 935 936 937 938 939 940 941 942 943 944 945 946 947 948 949 950 951 952 953 954 955 956 957 958 959 960 961 962 963 964 965 966 967 968 969 970 971 972 973 974 975 976 977 978 979 980 981 982 983 984 985 986 987 988 989 990 991 992 993 994 995 996 997 998 999 1000 1001 1002 1003 1004 1005 1006 1007 1008 1009 1010 1011 1012 1013 1014 1015 1016 1017 1018 1019 1020 1021 1022 1023 1024 1025 1026 1027 1028 1029 1030 1031 1032 1033 1034 1035 1036 1037 1038 1039 1040 1041 1042 1043 1044 1045 1046 1047 1048 1049 1050 1051 1052 1053 1054 1055 1056 1057 1058 1059 1060 1061 1062 1063 1064 1065 1066 1067 1068 1069 1070 1071 1072 1073 1074 1075 1076 1077 1078 1079 1080 1081 1082 1083 1084 1085 1086 1087 1088 1089 1090 1091 1092 1093 1094 1095 1096 1097 1098 1099 1100 1101 1102 1103 1104 1105 1106 1107 1108 1109 1110 1111 1112 1113 1114 1115 1116 1117 1118 1119 1120 1121 1122 1123 1124 1125 1126 1127 1128 1129 1130 1131 1132 1133 1134 1135 1136 1137 1138 1139 1140 1141 1142 1143 1144 1145 1146 1147 1148 1149 1150 1151 1152 1153 1154 1155 1156 1157 1158 1159 1160 1161 1162 1163 1164 1165 1166 1167 1168 1169 1170 1171 1172 1173 1174 1175 1176 1177 1178 1179 1180 1181 1182 1183 1184 1185 1186 1187 1188 1189 1190 1191 1192 1193 1194 1195 1196 1197 1198 1199 1200 1201 1202 1203 1204 1205 1206 1207 1208 1209 1210 1211 1212 1213 1214 1215 1216 1217 1218 1219 1220 1221 1222 1223 1224 1225 1226 1227 1228 1229 1230 1231 1232 1233 1234 1235 1236 1237 1238 1239 1240 1241 1242 1243 1244 1245 1246 1247 1248 1249 1250 1251 1252 1253 1254 1255 1256 1257 1258 1259 1260 1261 1262 1263 1264 1265 1266 1267 1268 1269 1270 1271 1272 1273 1274 1275 1276 1277 1278 1279 1280 1281 1282 1283 1284 1285 1286 1287 1288 1289 1290 1291 1292 1293 1294 1295 1296 1297 1298 1299 1300 1301 1302 1303 1304 1305 1306 1307 1308 1309 1310 1311 1312 1313 1314 1315 1316 1317 1318 1319 1320 1321 1322 1323 1324 1325 1326 1327 1328 1329 1330 1331 1332 1333 1334 1335 1336 1337 1338 1339 1340 1341 1342 1343 1344 1345 1346 1347 1348 1349 1350 1351 1352 1353 1354 1355 1356 1357 1358 1359 1360 1361 1362 1363 1364 1365 1366 1367 1368 1369 1370 1371 1372 1373 1374 1375 1376 1377 1378 1379 1380 1381 1382 1383 1384 1385 1386 1387 1388 1389 1390 1391 1392 1393 1394 1395 1396 1397 1398 1399 1400 1401 1402 1403 1404 1405 1406 1407 1408 1409 1410 1411 1412 1413 1414 1415 1416 1417 1418 1419 1420 1421 1422 1423 1424 1425 1426 1427 1428 1429 1430 1431 1432 1433 1434 1435 1436 1437 1438 1439 1440 1441 1442 1443 1444 1445 1446 1447 1448 1449 1450 1451 1452 1453 1454 1455 1456 1457 1458 1459 1460 1461 1462 1463 1464 1465 1466 1467 1468 1469 1470 1471 1472 1473 1474 1475 1476 1477 1478 1479 1480 1481 1482 1483 1484 1485 1486 1487 1488 1489 1490 1491 1492 1493 1494 1495 1496 1497 1498 1499 1500 1501 1502 1503 1504 1505 1506 1507 1508 1509 1510 1511 1512 1513 1514 1515 1516 1517 1518 1519 1520 1521 1522 1523 1524 1525 1526 1527 1528 1529 1530 1531 1532 1533 1534 1535 1536 1537 1538 1539 1540 1541 1542 1543 1544 1545 1546 1547 1548 1549 1550 1551 1552 1553 1554 1555 1556 1557 1558 1559 1560 1561 1562 1563 1564 1565 1566 1567 1568 1569 1570 1571 1572 1573 1574 1575 1576 1577 1578 1579 1580 1581 1582 1583 1584 1585 1586 1587 1588 1589 1590 1591 1592 1593 1594 1595 1596 1597 1598 1599 1600 1601 1602 1603 1604 1605 1606 1607 1608 1609 1610 1611 1612 1613 1614 1615 1616 1617 1618 1619 1620 1621 1622 1623 1624 1625 1626 1627 1628 1629 1630 1631 1632 1633 1634 1635 1636 1637 1638 1639 1640 1641 1642 1643 1644 1645 1646 1647 1648 1649 1650 1651 1652 1653 1654 1655 1656 1657 1658 1659 1660 1661 1662 1663 1664 1665 1666 1667 1668 1669 1670 1671 1672 1673 1674 1675 1676 1677 1678 1679 1680 1681 1682 1683 1684 1685 1686 1687 1688 1689 1690 1691 1692 1693 1694 1695 1696 1697 1698 1699 1700 1701 1702 1703 1704 1705 1706 1707 1708 1709 1710 1711 1712 1713 1714 1715 1716 1717 1718 1719 1720 1721 1722 1723 1724 1725 1726 1727 1728 1729 1730 1731 1732 1733 1734 1735 1736 1737 1738 1739 1740 1741 1742 1743 1744 1745 1746 1747 1748 1749 1750 1751 1752 1753 1754 1755 1756 1757 1758 1759 1760 1761 1762 1763 1764 1765 1766 1767 1768 1769 1770 1771 1772 1773 1774 1775 1776 1777 1778 1779 1780 1781 1782 1783 1784 1785 1786 1787 1788 1789 1790 1791 1792 1793 1794 1795 1796 1797 1798 1799 1800 1801 1802 1803 1804 1805 1806 1807 1808 1809 1810 1811 1812 1813 1814 1815 1816 1817 1818 1819 1820 1821 1822 1823 1824 1825 1826 1827 1828 1829 1830 1831 1832 1833 1834 1835 1836 1837 1838 1839 1840 1841 1842 1843 1844 1845 1846 1847 1848 1849 1850 1851 1852 1853 1854 1855 1856 1857 1858 1859 1860 1861 1862 1863 1864 1865 1866 1867 1868 1869 1870 1871 1872 1873 1874 1875 1876 1877 1878 1879 1880 1881 1882 1883 1884 1885 1886 1887 1888 1889 1890 1891 1892 1893 1894 1895 1896 1897 1898 1899 1900 1901 1902 1903 1904 1905 1906 1907 1908 1909 1910 1911 1912 1913 1914 1915 1916 1917 1918 1919 1920 1921 1922 1923 1924 1925 1926 1927 1928 1929 1930 1931 1932 1933 1934 1935 1936 1937 1938 1939 1940 1941 1942 1943 1944 1945 1946 1947 1948 1949 1950 1951 1952 1953 1954 1955 1956 1957 1958 1959 1960 1961 1962 1963 1964 1965 1966 1967 1968 1969 1970 1971 1972 1973 1974 1975 1976 1977 1978 1979 1980 1981 1982 1983 1984 1985 1986 1987 1988 1989 1990 1991 1992 1993 1994 1995 1996 1997 1998 1999 2000 2001 2002 2003 2004 2005 2006 2007 2008 2009 2010 2011 2012 2013 2014 2015 2016 2017 2018 2019 2020 2021 2022 2023 2024 2025 2026 2027 2028 2029 2030 2031 2032 2033 2034 2035 2036 2037 2038 2039 2040 2041 2042 2043 2044 2045 2046 2047 2048 2049 2050 2051 2052 2053 2054 2055 2056 2057 2058 2059 2060 2061 2062 2063 2064 2065 2066 2067 2068 2069 2070 2071 2072 2073 2074 2075 2076 2077 2078 2079 2080 2081 2082 2083 2084 2085 2086 2087 2088 2089 2090 2091 2092 2093 2094 2095 2096 2097 2098 2099 2100 2101 2102 2103 2104 2105 2106 2107 2108 2109 2110 2111 2112 2113 2114 2115 2116 2117 2118 2119 2120 2121 2122 2123 2124 2125 2126 2127 2128 2129 2130 2131 2132 2133 2134 2135 2136 2137 2138 2139 2140 2141 2142 2143 2144 2145 2146 2147 2148 2149 2150 2151 2152 2153 2154 2155 2156 2157 2158 2159 2160 2161 2162 2163 2164 2165 2166 2167 2168 2169 2170 2171 2172 2173 2174 2175 2176 2177 2178 2179 2180 2181 2182 2183 2184 2185 2186 2187 2188 2189 2190 2191 2192 2193 2194 2195 2196 2197 2198 2199 2200 2201 2202 2203 2204 2205 2206 2207 2208 2209 2210 2211 2212 2213 2214 2215 2216 2217 2218 2219 2220 2221 2222 2223 2224 2225 2226 2227 2228 2229 2230 2231 2232 2233 2234 2235 2236 2237 2238 2239 2240 2241 2242 2243 2244 2245 2246 2247 2248 2249 2250 2251 2252 2253 2254 2255 2256 2257 2258 2259 2260 2261 2262 2263 2264 2265 2266 2267 2268 2269 2270 2271 2272 2273 2274 2275 2276 2277 2278 2279 2280 2281 2282 2283 2284 2285 2286 2287 2288 2289 2290 2291 2292 2293 2294 2295 2296 2297 2298 2299 2300 2301 2302 2303 2304 2305 2306 2307 2308 2309 2310 2311 2312 2313 2314 2315 2316 2317 2318 2319 2320 2321 2322 2323 2324 2325 2326 2327 2328 2329 2330 2331 2332 2333 2334 2335 2336 2337 2338 2339 2340 2341 2342 2343 2344 2345 2346 2347 2348 2349 2350 2351 2352 2353 2354 2355 2356 2357 2358 2359 2360 2361 2362 2363 2364 2365 2366 2367 2368 2369 2370 2371 2372 2373 2374 2375 2376 2377 2378 2379 2380 2381 2382 2383 2384 2385 2386 2387 2388 2389 2390 2391 2392 2393 2394 2395 2396 2397 2398 2399 2400 2401 2402 2403 2404 2405 2406 2407 2408 2409 2410 2411 2412 2413 2414 2415 2416 2417 2418 2419 2420 2421 2422 2423 2424 2425 2426 2427 2428 2429 2430 2431 2432 2433 2434 2435 2436 2437 2438 2439 2440 2441 2442 2443 2444 2445 2446 2447 2448 2449 2450 2451 2452 2453 2454 2455 2456 2457 2458 2459 2460 2461 2462 2463 2464 2465 2466 2467 2468 2469 2470 2471 2472 2473 2474 2475 2476 2477 2478 2479 2480 2481 2482 2483 2484 2485 2486 2487 2488 2489 2490 2491 2492 2493 2494 2495 2496 2497 2498 2499 2500 2501 2502 2503 2504 2505 2506 2507 2508 2509 2510 2511 2512 2513 2514 2515 2516 2517 2518 2519 2520 2521 2522 2523 2524 2525 2526 2527 2528 2529 2530 2531 2532 2533 2534 2535 2536 2537 2538 2539 2540 2541 2542 2543 2544 2545 2546 2547 2548 2549 2550 2551 2552 2553 2554 2555 2556 2557 2558 2559 2560 2561 2562 2563 2564 2565 2566 2567 2568 2569 2570 2571 2572 2573 2574 2575 2576 2577 2578 2579 2580 2581 2582 2583 2584 2585 2586 2587 2588 2589 2590 2591 2592 2593 2594 2595 2596 2597 2598 2599 2600 2601 2602 2603 2604 2605 2606 2607 2608 2609 2610 2611 2612 2613 2614 2615 |
|
test_example_input_one_add_cancel_entity(ucc_smartx_selenium_helper, ucc_smartx_rest_helper)
¶
Verifies cancel functionality at time of add
Source code in tests/ui/test_input_page.py
1333 1334 1335 1336 1337 1338 1339 1340 1341 1342 1343 |
|
test_example_input_one_add_close_entity(ucc_smartx_selenium_helper, ucc_smartx_rest_helper)
¶
Verifies close functionality at time of add
Source code in tests/ui/test_input_page.py
1270 1271 1272 1273 1274 1275 1276 1277 1278 1279 1280 |
|
test_example_input_one_add_duplicate_names(ucc_smartx_selenium_helper, ucc_smartx_rest_helper, _add_input_one)
¶
Verifies by saving an entity with duplicate name it displays and error
Source code in tests/ui/test_input_page.py
1381 1382 1383 1384 1385 1386 1387 1388 1389 1390 1391 1392 1393 1394 1395 1396 1397 |
|
test_example_input_one_add_frontend_backend_validation(ucc_smartx_selenium_helper, ucc_smartx_rest_helper)
¶
Verifies the frontend and backend after adding an Example Input One
Source code in tests/ui/test_input_page.py
1043 1044 1045 1046 1047 1048 1049 1050 1051 1052 1053 1054 1055 1056 1057 1058 1059 1060 1061 1062 1063 1064 1065 1066 1067 1068 1069 1070 1071 1072 1073 1074 1075 1076 1077 1078 1079 1080 1081 1082 1083 1084 1085 1086 1087 1088 1089 1090 1091 1092 1093 1094 1095 1096 1097 1098 1099 |
|
test_example_input_one_add_valid_title(ucc_smartx_selenium_helper, ucc_smartx_rest_helper)
¶
Verifies the title of the ‘Add Entity’
Source code in tests/ui/test_input_page.py
1417 1418 1419 1420 1421 1422 1423 1424 1425 1426 1427 1428 1429 1430 |
|
test_example_input_one_checked_example_checkbox(ucc_smartx_selenium_helper, ucc_smartx_rest_helper)
¶
Verifies checked in example checkbox in example input one
Source code in tests/ui/test_input_page.py
615 616 617 618 619 620 621 622 623 624 625 626 |
|
test_example_input_one_clone_cancel_entity(ucc_smartx_selenium_helper, ucc_smartx_rest_helper, _add_input_one)
¶
Verifies cancel functionality at time of clone
Source code in tests/ui/test_input_page.py
1356 1357 1358 1359 1360 1361 1362 1363 1364 1365 |
|
test_example_input_one_clone_close_entity(ucc_smartx_selenium_helper, ucc_smartx_rest_helper, _add_input_one)
¶
Verifies close functionality at time of clone
Source code in tests/ui/test_input_page.py
1293 1294 1295 1296 1297 1298 1299 1300 1301 1302 |
|
test_example_input_one_clone_default_values(ucc_smartx_selenium_helper, ucc_smartx_rest_helper, _add_input_one)
¶
Verifies the frontend default fields at time of clone for example input one entity
Source code in tests/ui/test_input_page.py
1172 1173 1174 1175 1176 1177 1178 1179 1180 1181 1182 1183 1184 1185 1186 1187 1188 1189 1190 1191 1192 1193 1194 1195 1196 1197 |
|
test_example_input_one_clone_duplicate_names(ucc_smartx_selenium_helper, ucc_smartx_rest_helper, _add_input_one)
¶
Verifies by saving an entity with duplicate name at time of clone it displays and error
Source code in tests/ui/test_input_page.py
1399 1400 1401 1402 1403 1404 1405 1406 1407 1408 1409 1410 1411 1412 1413 1414 1415 |
|
test_example_input_one_clone_frontend_backend_validation(ucc_smartx_selenium_helper, ucc_smartx_rest_helper, _add_input_one)
¶
Verifies the frontend and backend clone functionality of the example input one entity
Source code in tests/ui/test_input_page.py
1199 1200 1201 1202 1203 1204 1205 1206 1207 1208 1209 1210 1211 1212 1213 1214 1215 1216 1217 1218 1219 1220 1221 1222 1223 1224 1225 1226 1227 1228 1229 1230 1231 1232 1233 1234 1235 1236 1237 1238 1239 1240 1241 1242 1243 1244 1245 1246 1247 1248 1249 |
|
test_example_input_one_clone_save_entity(ucc_smartx_selenium_helper, ucc_smartx_rest_helper, _add_input_one)
¶
Verifies required field name in example input one at time of clone
Source code in tests/ui/test_input_page.py
1304 1305 1306 1307 1308 1309 1310 1311 1312 1313 1314 1315 1316 1317 |
|
test_example_input_one_clone_valid_title(ucc_smartx_selenium_helper, ucc_smartx_rest_helper, _add_input_one)
¶
Verifies the title of the ‘Clone Entity’
Source code in tests/ui/test_input_page.py
1446 1447 1448 1449 1450 1451 1452 1453 1454 1455 1456 1457 1458 |
|
test_example_input_one_default_value_example_checkbox(ucc_smartx_selenium_helper, ucc_smartx_rest_helper)
¶
Verifies default value of example checkbox in example input one
Source code in tests/ui/test_input_page.py
590 591 592 593 594 595 596 597 598 599 600 |
|
test_example_input_one_default_value_example_radio(ucc_smartx_selenium_helper, ucc_smartx_rest_helper)
¶
Verifies default value of example radio in example input one
Source code in tests/ui/test_input_page.py
628 629 630 631 632 633 634 635 636 637 638 |
|
test_example_input_one_default_value_index(ucc_smartx_selenium_helper, ucc_smartx_rest_helper)
¶
Verifies default value of field index in example input one
Source code in tests/ui/test_input_page.py
724 725 726 727 728 729 730 731 732 733 734 735 |
|
test_example_input_one_default_value_limit(ucc_smartx_selenium_helper, ucc_smartx_rest_helper)
¶
Verifies default value of field limit in example input one
Source code in tests/ui/test_input_page.py
1016 1017 1018 1019 1020 1021 1022 1023 1024 1025 1026 1027 |
|
test_example_input_one_default_value_multiple_select_test(ucc_smartx_selenium_helper, ucc_smartx_rest_helper)
¶
Verifies default values of Multiple Select Test dropdown in example input one
Source code in tests/ui/test_input_page.py
488 489 490 491 492 493 494 495 496 497 498 499 500 501 |
|
test_example_input_one_default_value_order_by(ucc_smartx_selenium_helper, ucc_smartx_rest_helper)
¶
Verifies default value of field Order By in example input one
Source code in tests/ui/test_input_page.py
835 836 837 838 839 840 841 842 843 844 845 846 |
|
test_example_input_one_delete_cancel_entity(ucc_smartx_selenium_helper, ucc_smartx_rest_helper, _add_input_one)
¶
Verifies cancel functionality at time of delete
Source code in tests/ui/test_input_page.py
1367 1368 1369 1370 1371 1372 1373 1374 1375 1376 1377 1378 1379 |
|
test_example_input_one_delete_close_entity(ucc_smartx_selenium_helper, ucc_smartx_rest_helper, _add_input_one)
¶
Verifies close functionality at time of delete
Source code in tests/ui/test_input_page.py
1319 1320 1321 1322 1323 1324 1325 1326 1327 1328 1329 1330 1331 |
|
test_example_input_one_delete_row_frontend_backend_validation(ucc_smartx_selenium_helper, ucc_smartx_rest_helper, _add_input_one)
¶
Verifies the frontend and backend delete functionality
Source code in tests/ui/test_input_page.py
1251 1252 1253 1254 1255 1256 1257 1258 1259 1260 1261 1262 1263 1264 1265 1266 1267 1268 |
|
test_example_input_one_delete_valid_prompt_message(ucc_smartx_selenium_helper, ucc_smartx_rest_helper, _add_input_one)
¶
Verifies the prompt message of the ‘Delete Entity’
Source code in tests/ui/test_input_page.py
1474 1475 1476 1477 1478 1479 1480 1481 1482 1483 1484 1485 1486 |
|
test_example_input_one_delete_valid_title(ucc_smartx_selenium_helper, ucc_smartx_rest_helper, _add_input_one)
¶
Verifies the title of the ‘Delete Entity’
Source code in tests/ui/test_input_page.py
1460 1461 1462 1463 1464 1465 1466 1467 1468 1469 1470 1471 1472 |
|
test_example_input_one_deselect_multiple_select_test(ucc_smartx_selenium_helper, ucc_smartx_rest_helper)
¶
Verifies deselect in Multiple Select Test dropdown in example input one
Source code in tests/ui/test_input_page.py
556 557 558 559 560 561 562 563 564 565 566 567 568 569 570 571 |
|
test_example_input_one_edit_cancel_entity(ucc_smartx_selenium_helper, ucc_smartx_rest_helper, _add_input_one)
¶
Verifies cancel functionality at time of edit
Source code in tests/ui/test_input_page.py
1345 1346 1347 1348 1349 1350 1351 1352 1353 1354 |
|
test_example_input_one_edit_close_entity(ucc_smartx_selenium_helper, ucc_smartx_rest_helper, _add_input_one)
¶
Verifies close functionality at time of edit
Source code in tests/ui/test_input_page.py
1282 1283 1284 1285 1286 1287 1288 1289 1290 1291 |
|
test_example_input_one_edit_frontend_backend_validation(ucc_smartx_selenium_helper, ucc_smartx_rest_helper, _add_input_one)
¶
Verifies the frontend and backend edit functionality of the example input one entity
Source code in tests/ui/test_input_page.py
1112 1113 1114 1115 1116 1117 1118 1119 1120 1121 1122 1123 1124 1125 1126 1127 1128 1129 1130 1131 1132 1133 1134 1135 1136 1137 1138 1139 1140 1141 1142 1143 1144 1145 1146 1147 1148 1149 1150 1151 1152 1153 1154 1155 1156 1157 1158 1159 1160 1161 1162 1163 1164 1165 1166 1167 1168 1169 1170 |
|
test_example_input_one_edit_uneditable_field_name(ucc_smartx_selenium_helper, ucc_smartx_rest_helper, _add_input_one)
¶
Verifies the frontend uneditable fields at time of edit of the example input one entity
Source code in tests/ui/test_input_page.py
1101 1102 1103 1104 1105 1106 1107 1108 1109 1110 |
|
test_example_input_one_edit_valid_title(ucc_smartx_selenium_helper, ucc_smartx_rest_helper, _add_input_one)
¶
Verifies the title of the ‘Edit Entity’
Source code in tests/ui/test_input_page.py
1432 1433 1434 1435 1436 1437 1438 1439 1440 1441 1442 1443 1444 |
|
test_example_input_one_fields_label_entity(ucc_smartx_selenium_helper, ucc_smartx_rest_helper)
¶
Verifies example input one field label
Source code in tests/ui/test_input_page.py
873 874 875 876 877 878 879 880 881 882 883 884 885 886 887 888 889 890 891 892 893 894 895 896 897 898 899 900 901 902 903 904 905 906 907 908 909 910 911 912 913 |
|
test_example_input_one_help_link(ucc_smartx_selenium_helper, ucc_smartx_rest_helper)
¶
Verifies whether the help link redirects to the correct URL
Source code in tests/ui/test_input_page.py
1029 1030 1031 1032 1033 1034 1035 1036 1037 1038 1039 1040 1041 |
|
test_example_input_one_help_text_entity(ucc_smartx_selenium_helper, ucc_smartx_rest_helper)
¶
Verifies help text for the field name
Source code in tests/ui/test_input_page.py
944 945 946 947 948 949 950 951 952 953 954 955 956 957 958 959 960 961 962 963 964 965 966 967 968 969 970 971 972 973 974 975 976 977 978 979 980 981 982 983 984 985 986 987 988 989 990 991 |
|
test_example_input_one_list_multiple_select_test(ucc_smartx_selenium_helper, ucc_smartx_rest_helper)
¶
Verifies values of Multiple Select Test dropdown in example input one
Source code in tests/ui/test_input_page.py
503 504 505 506 507 508 509 510 511 512 513 514 515 516 517 518 |
|
test_example_input_one_list_single_select_group_test(ucc_smartx_selenium_helper, ucc_smartx_rest_helper)
¶
Verifies values Single Select Group Test dropdown in example input one
Source code in tests/ui/test_input_page.py
440 441 442 443 444 445 446 447 448 449 450 451 452 453 454 |
|
test_example_input_one_required_field_example_account(ucc_smartx_selenium_helper, ucc_smartx_rest_helper)
¶
Verifies required field Example Account in example input one
Source code in tests/ui/test_input_page.py
737 738 739 740 741 742 743 744 745 746 747 748 749 750 751 752 753 754 755 756 757 758 759 |
|
test_example_input_one_required_field_index(ucc_smartx_selenium_helper, ucc_smartx_rest_helper)
¶
Verifies required field index in example input one
Source code in tests/ui/test_input_page.py
698 699 700 701 702 703 704 705 706 707 708 709 710 711 712 713 714 715 716 717 718 719 720 721 722 |
|
test_example_input_one_required_field_interval(ucc_smartx_selenium_helper, ucc_smartx_rest_helper)
¶
Verifies required field interval in example input one
Source code in tests/ui/test_input_page.py
653 654 655 656 657 658 659 660 661 662 663 664 665 666 667 668 669 670 671 672 673 674 675 |
|
test_example_input_one_required_field_name(ucc_smartx_selenium_helper, ucc_smartx_rest_helper)
¶
Verifies required field name in example input one
Source code in tests/ui/test_input_page.py
381 382 383 384 385 386 387 388 389 390 391 392 393 394 395 396 397 398 399 400 401 402 403 |
|
test_example_input_one_required_field_object(ucc_smartx_selenium_helper, ucc_smartx_rest_helper)
¶
Verifies required field Object in example input one
Source code in tests/ui/test_input_page.py
761 762 763 764 765 766 767 768 769 770 771 772 773 774 775 776 777 778 779 780 781 782 783 |
|
test_example_input_one_required_field_object_fields(ucc_smartx_selenium_helper, ucc_smartx_rest_helper)
¶
Verifies required field Object Fields in example input one
Source code in tests/ui/test_input_page.py
785 786 787 788 789 790 791 792 793 794 795 796 797 798 799 800 801 802 803 804 805 806 807 |
|
test_example_input_one_required_field_order_by(ucc_smartx_selenium_helper, ucc_smartx_rest_helper)
¶
Verifies required field Order By in example input one
Source code in tests/ui/test_input_page.py
809 810 811 812 813 814 815 816 817 818 819 820 821 822 823 824 825 826 827 828 829 830 831 832 833 |
|
test_example_input_one_required_field_textarea(ucc_smartx_selenium_helper, ucc_smartx_rest_helper)
¶
Verifies required field textarea in example input one
Source code in tests/ui/test_input_page.py
848 849 850 851 852 853 854 855 856 857 858 859 860 861 862 863 864 865 866 867 868 869 870 871 |
|
test_example_input_one_search_value_multiple_select_test(ucc_smartx_selenium_helper, ucc_smartx_rest_helper)
¶
Verifies multiple select search functionality properly
Source code in tests/ui/test_input_page.py
573 574 575 576 577 578 579 580 581 582 583 584 585 586 587 588 |
|
test_example_input_one_search_value_single_select_group_test(ucc_smartx_selenium_helper, ucc_smartx_rest_helper)
¶
Verifies singleSelect search functionality
Source code in tests/ui/test_input_page.py
472 473 474 475 476 477 478 479 480 481 482 483 484 485 486 |
|
test_example_input_one_select_multiple_values_multiple_select_test(ucc_smartx_selenium_helper, ucc_smartx_rest_helper)
¶
Verifies selected multiple values of Multiple Select Test dropdown in example input one
Source code in tests/ui/test_input_page.py
538 539 540 541 542 543 544 545 546 547 548 549 550 551 552 553 554 |
|
test_example_input_one_select_value_example_radio(ucc_smartx_selenium_helper, ucc_smartx_rest_helper)
¶
Verifies selected value of example radio in example input one
Source code in tests/ui/test_input_page.py
640 641 642 643 644 645 646 647 648 649 650 651 |
|
test_example_input_one_select_value_multiple_select_test(ucc_smartx_selenium_helper, ucc_smartx_rest_helper)
¶
Verifies selected single value of Multiple Select Test dropdown in example input one
Source code in tests/ui/test_input_page.py
520 521 522 523 524 525 526 527 528 529 530 531 532 533 534 535 536 |
|
test_example_input_one_select_value_single_select_group_test(ucc_smartx_selenium_helper, ucc_smartx_rest_helper)
¶
Verifies selected value of Single Select Group Test dropdown in example input one
Source code in tests/ui/test_input_page.py
456 457 458 459 460 461 462 463 464 465 466 467 468 469 470 |
|
test_example_input_one_unchecked_example_checkbox(ucc_smartx_selenium_helper, ucc_smartx_rest_helper)
¶
Verifies Uncheck in example checkbox in example input one
Source code in tests/ui/test_input_page.py
602 603 604 605 606 607 608 609 610 611 612 613 |
|
test_example_input_one_valid_input_interval(ucc_smartx_selenium_helper, ucc_smartx_rest_helper)
¶
Verifies whether adding non numeric values, interval field displays validation error
Source code in tests/ui/test_input_page.py
677 678 679 680 681 682 683 684 685 686 687 688 689 690 691 692 693 694 695 696 |
|
test_example_input_one_valid_input_name(ucc_smartx_selenium_helper, ucc_smartx_rest_helper)
¶
Verifies whether adding special characters, name field displays validation error
Source code in tests/ui/test_input_page.py
423 424 425 426 427 428 429 430 431 432 433 434 435 436 437 438 |
|
test_example_input_one_valid_input_query_start_date(ucc_smartx_selenium_helper, ucc_smartx_rest_helper)
¶
Verifies whether adding wrong format, Query Start Date field displays validation error
Source code in tests/ui/test_input_page.py
993 994 995 996 997 998 999 1000 1001 1002 1003 1004 1005 1006 1007 1008 1009 1010 1011 1012 1013 1014 |
|
test_example_input_one_valid_length_name(ucc_smartx_selenium_helper, ucc_smartx_rest_helper)
¶
Verifies the name field should not be more than 100 characters
Source code in tests/ui/test_input_page.py
405 406 407 408 409 410 411 412 413 414 415 416 417 418 419 420 421 |
|
test_example_input_two_add_cancel_entity(ucc_smartx_selenium_helper, ucc_smartx_rest_helper)
¶
Verifies cancel functionality at time of add
Source code in tests/ui/test_input_page.py
2098 2099 2100 2101 2102 2103 2104 2105 2106 2107 2108 |
|
test_example_input_two_add_close_entity(ucc_smartx_selenium_helper, ucc_smartx_rest_helper)
¶
Verifies close functionality at time of add
Source code in tests/ui/test_input_page.py
2050 2051 2052 2053 2054 2055 2056 2057 2058 2059 2060 |
|
test_example_input_two_add_duplicate_names(ucc_smartx_selenium_helper, ucc_smartx_rest_helper, _add_input_two)
¶
Verifies by saving an entity with duplicate name it displays and error
Source code in tests/ui/test_input_page.py
2146 2147 2148 2149 2150 2151 2152 2153 2154 2155 2156 2157 2158 2159 2160 2161 2162 |
|
test_example_input_two_add_frontend_backend_validation(ucc_smartx_selenium_helper, ucc_smartx_rest_helper)
¶
Verifies the frontend and backend after adding an Example Input Two
Source code in tests/ui/test_input_page.py
1854 1855 1856 1857 1858 1859 1860 1861 1862 1863 1864 1865 1866 1867 1868 1869 1870 1871 1872 1873 1874 1875 1876 1877 1878 1879 1880 1881 1882 1883 1884 1885 1886 1887 1888 1889 1890 1891 1892 1893 1894 1895 1896 1897 1898 1899 1900 1901 1902 |
|
test_example_input_two_add_valid_title(ucc_smartx_selenium_helper, ucc_smartx_rest_helper)
¶
Verifies the title of the ‘Add Entity’
Source code in tests/ui/test_input_page.py
2182 2183 2184 2185 2186 2187 2188 2189 2190 2191 2192 2193 2194 2195 |
|
test_example_input_two_checked_example_checkbox(ucc_smartx_selenium_helper, ucc_smartx_rest_helper)
¶
Verifies Check in example checkbox in Example Input Two
Source code in tests/ui/test_input_page.py
1771 1772 1773 1774 1775 1776 1777 1778 1779 1780 1781 |
|
test_example_input_two_clone_cancel_entity(ucc_smartx_selenium_helper, ucc_smartx_rest_helper, _add_input_two)
¶
Verifies cancel functionality at time of clone
Source code in tests/ui/test_input_page.py
2121 2122 2123 2124 2125 2126 2127 2128 2129 2130 |
|
test_example_input_two_clone_close_entity(ucc_smartx_selenium_helper, ucc_smartx_rest_helper, _add_input_two)
¶
Verifies close functionality at time of clone
Source code in tests/ui/test_input_page.py
2073 2074 2075 2076 2077 2078 2079 2080 2081 2082 |
|
test_example_input_two_clone_default_values(ucc_smartx_selenium_helper, ucc_smartx_rest_helper, _add_input_two)
¶
Verifies the frontend default fields at time of clone for Example Input Two entity
Source code in tests/ui/test_input_page.py
1963 1964 1965 1966 1967 1968 1969 1970 1971 1972 1973 1974 1975 1976 1977 1978 1979 1980 1981 1982 1983 1984 1985 |
|
test_example_input_two_clone_duplicate_names(ucc_smartx_selenium_helper, ucc_smartx_rest_helper, _add_input_two)
¶
Verifies by saving an entity with duplicate name at time of clone it displays and error
Source code in tests/ui/test_input_page.py
2164 2165 2166 2167 2168 2169 2170 2171 2172 2173 2174 2175 2176 2177 2178 2179 2180 |
|
test_example_input_two_clone_frontend_backend_validation(ucc_smartx_selenium_helper, ucc_smartx_rest_helper, _add_input_two)
¶
Verifies the frontend and backend clone functionality of the Example Input Two entity
Source code in tests/ui/test_input_page.py
1987 1988 1989 1990 1991 1992 1993 1994 1995 1996 1997 1998 1999 2000 2001 2002 2003 2004 2005 2006 2007 2008 2009 2010 2011 2012 2013 2014 2015 2016 2017 2018 2019 2020 2021 2022 2023 2024 2025 2026 2027 2028 2029 |
|
test_example_input_two_clone_valid_input_name(ucc_smartx_selenium_helper, ucc_smartx_rest_helper, _add_input_two)
¶
Verifies whether adding special characters, name field displays validation error while cloning a row
Source code in tests/ui/test_input_page.py
1548 1549 1550 1551 1552 1553 1554 1555 1556 1557 1558 1559 1560 1561 1562 1563 |
|
test_example_input_two_clone_valid_title(ucc_smartx_selenium_helper, ucc_smartx_rest_helper, _add_input_two)
¶
Verifies the title of the ‘Clone Entity’
Source code in tests/ui/test_input_page.py
2212 2213 2214 2215 2216 2217 2218 2219 2220 2221 2222 2223 2224 2225 |
|
test_example_input_two_default_value_index(ucc_smartx_selenium_helper, ucc_smartx_rest_helper)
¶
Verifies default value of field index in Example Input Two
Source code in tests/ui/test_input_page.py
1630 1631 1632 1633 1634 1635 1636 1637 1638 1639 1640 1641 |
|
test_example_input_two_delete_cancel_entity(ucc_smartx_selenium_helper, ucc_smartx_rest_helper, _add_input_two)
¶
Verifies cancel functionality at time of delete
Source code in tests/ui/test_input_page.py
2132 2133 2134 2135 2136 2137 2138 2139 2140 2141 2142 2143 2144 |
|
test_example_input_two_delete_close_entity(ucc_smartx_selenium_helper, ucc_smartx_rest_helper, _add_input_two)
¶
Verifies close functionality at time of delete
Source code in tests/ui/test_input_page.py
2084 2085 2086 2087 2088 2089 2090 2091 2092 2093 2094 2095 2096 |
|
test_example_input_two_delete_row_frontend_backend_validation(ucc_smartx_selenium_helper, ucc_smartx_rest_helper, _add_input_two)
¶
Verifies the frontend and backend delete functionality
Source code in tests/ui/test_input_page.py
2031 2032 2033 2034 2035 2036 2037 2038 2039 2040 2041 2042 2043 2044 2045 2046 2047 2048 |
|
test_example_input_two_delete_valid_prompt_message(ucc_smartx_selenium_helper, ucc_smartx_rest_helper, _add_input_two)
¶
Verifies the prompt message of the ‘Delete Entity’
Source code in tests/ui/test_input_page.py
2241 2242 2243 2244 2245 2246 2247 2248 2249 2250 2251 2252 2253 |
|
test_example_input_two_delete_valid_title(ucc_smartx_selenium_helper, ucc_smartx_rest_helper, _add_input_two)
¶
Verifies the title of the ‘Delete Entity’
Source code in tests/ui/test_input_page.py
2227 2228 2229 2230 2231 2232 2233 2234 2235 2236 2237 2238 2239 |
|
test_example_input_two_edit_cancel_entity(ucc_smartx_selenium_helper, ucc_smartx_rest_helper, _add_input_two)
¶
Verifies cancel functionality at time of edit
Source code in tests/ui/test_input_page.py
2110 2111 2112 2113 2114 2115 2116 2117 2118 2119 |
|
test_example_input_two_edit_close_entity(ucc_smartx_selenium_helper, ucc_smartx_rest_helper, _add_input_two)
¶
Verifies close functionality at time of edit
Source code in tests/ui/test_input_page.py
2062 2063 2064 2065 2066 2067 2068 2069 2070 2071 |
|
test_example_input_two_edit_frontend_backend_validation(ucc_smartx_selenium_helper, ucc_smartx_rest_helper, _add_input_two)
¶
Verifies the frontend and backend edit functionality of the Example Input Two entity
Source code in tests/ui/test_input_page.py
1916 1917 1918 1919 1920 1921 1922 1923 1924 1925 1926 1927 1928 1929 1930 1931 1932 1933 1934 1935 1936 1937 1938 1939 1940 1941 1942 1943 1944 1945 1946 1947 1948 1949 1950 1951 1952 1953 1954 1955 1956 1957 1958 1959 1960 1961 |
|
test_example_input_two_edit_uneditable_field_name(ucc_smartx_selenium_helper, ucc_smartx_rest_helper, _add_input_two)
¶
Verifies the frontend uneditable fields at time of edit of the Example Input Two entity
Source code in tests/ui/test_input_page.py
1904 1905 1906 1907 1908 1909 1910 1911 1912 1913 1914 |
|
test_example_input_two_edit_valid_title(ucc_smartx_selenium_helper, ucc_smartx_rest_helper, _add_input_two)
¶
Verifies the title of the ‘Edit Entity’
Source code in tests/ui/test_input_page.py
2197 2198 2199 2200 2201 2202 2203 2204 2205 2206 2207 2208 2209 2210 |
|
test_example_input_two_fields_label_entity(ucc_smartx_selenium_helper, ucc_smartx_rest_helper)
¶
Verifies example input two field label
Source code in tests/ui/test_input_page.py
915 916 917 918 919 920 921 922 923 924 925 926 927 928 929 930 931 932 933 934 935 936 937 938 939 940 941 942 |
|
test_example_input_two_help_text_entity(ucc_smartx_selenium_helper, ucc_smartx_rest_helper)
¶
Verifies help text for the field name
Source code in tests/ui/test_input_page.py
1741 1742 1743 1744 1745 1746 1747 1748 1749 1750 1751 1752 1753 1754 1755 1756 1757 1758 1759 1760 1761 1762 1763 1764 1765 1766 1767 1768 1769 |
|
test_example_input_two_list_example_multiple_select(ucc_smartx_selenium_helper, ucc_smartx_rest_helper)
¶
Verifies values of Multiple Select Test dropdown in Example Input Two
Source code in tests/ui/test_input_page.py
1689 1690 1691 1692 1693 1694 1695 1696 1697 1698 1699 1700 1701 1702 1703 |
|
test_example_input_two_required_field_example_example_account(ucc_smartx_selenium_helper, ucc_smartx_rest_helper)
¶
Verifies required field Account in Example Input Two
Source code in tests/ui/test_input_page.py
1643 1644 1645 1646 1647 1648 1649 1650 1651 1652 1653 1654 1655 1656 1657 1658 1659 1660 1661 1662 1663 1664 |
|
test_example_input_two_required_field_example_multiple_select(ucc_smartx_selenium_helper, ucc_smartx_rest_helper)
¶
Verifies required field Example Multiple Select in Example Input Two
Source code in tests/ui/test_input_page.py
1666 1667 1668 1669 1670 1671 1672 1673 1674 1675 1676 1677 1678 1679 1680 1681 1682 1683 1684 1685 1686 1687 |
|
test_example_input_two_required_field_example_radio(ucc_smartx_selenium_helper, ucc_smartx_rest_helper)
¶
Verifies default value of example radio in Example Input Two
Source code in tests/ui/test_input_page.py
1796 1797 1798 1799 1800 1801 1802 1803 1804 1805 1806 1807 1808 1809 1810 1811 1812 1813 1814 1815 1816 1817 |
|
test_example_input_two_required_field_index(ucc_smartx_selenium_helper, ucc_smartx_rest_helper)
¶
Verifies required field index in Example Input Two
Source code in tests/ui/test_input_page.py
1606 1607 1608 1609 1610 1611 1612 1613 1614 1615 1616 1617 1618 1619 1620 1621 1622 1623 1624 1625 1626 1627 1628 |
|
test_example_input_two_required_field_interval(ucc_smartx_selenium_helper, ucc_smartx_rest_helper)
¶
Verifies required field interval in Example Input Two
Source code in tests/ui/test_input_page.py
1565 1566 1567 1568 1569 1570 1571 1572 1573 1574 1575 1576 1577 1578 1579 1580 1581 1582 1583 1584 1585 1586 |
|
test_example_input_two_required_field_name(ucc_smartx_selenium_helper, ucc_smartx_rest_helper)
¶
Verifies required field name in Example Input Two
Source code in tests/ui/test_input_page.py
1488 1489 1490 1491 1492 1493 1494 1495 1496 1497 1498 1499 1500 1501 1502 1503 1504 1505 1506 1507 1508 1509 1510 1511 |
|
test_example_input_two_select_multiple_values_example_multiple_select(ucc_smartx_selenium_helper, ucc_smartx_rest_helper)
¶
Verifies selected multiple values of Multiple Select Test dropdown in Example Input Two
Source code in tests/ui/test_input_page.py
1723 1724 1725 1726 1727 1728 1729 1730 1731 1732 1733 1734 1735 1736 1737 1738 1739 |
|
test_example_input_two_select_select_value_example_multiple_select(ucc_smartx_selenium_helper, ucc_smartx_rest_helper)
¶
Verifies selected single value of Multiple Select Test dropdown in Example Input Two
Source code in tests/ui/test_input_page.py
1705 1706 1707 1708 1709 1710 1711 1712 1713 1714 1715 1716 1717 1718 1719 1720 1721 |
|
test_example_input_two_select_value_example_radio(ucc_smartx_selenium_helper, ucc_smartx_rest_helper)
¶
Verifies default value of example radio in Example Input Two
Source code in tests/ui/test_input_page.py
1819 1820 1821 1822 1823 1824 1825 1826 1827 1828 1829 1830 |
|
test_example_input_two_unchecked_example_checkbox(ucc_smartx_selenium_helper, ucc_smartx_rest_helper)
¶
Verifies Uncheck in example checkbox in Example Input Two
Source code in tests/ui/test_input_page.py
1783 1784 1785 1786 1787 1788 1789 1790 1791 1792 1793 1794 |
|
test_example_input_two_valid_input_interval(ucc_smartx_selenium_helper, ucc_smartx_rest_helper)
¶
Verifies whether adding non numeric values, interval field displays validation error
Source code in tests/ui/test_input_page.py
1588 1589 1590 1591 1592 1593 1594 1595 1596 1597 1598 1599 1600 1601 1602 1603 1604 |
|
test_example_input_two_valid_input_name(ucc_smartx_selenium_helper, ucc_smartx_rest_helper)
¶
Verifies whether adding special characters, name field displays validation error
Source code in tests/ui/test_input_page.py
1531 1532 1533 1534 1535 1536 1537 1538 1539 1540 1541 1542 1543 1544 1545 1546 |
|
test_example_input_two_valid_input_query_start_date(ucc_smartx_selenium_helper, ucc_smartx_rest_helper)
¶
Verifies whether adding wrong format, Query Start Date field displays validation error
Source code in tests/ui/test_input_page.py
1832 1833 1834 1835 1836 1837 1838 1839 1840 1841 1842 1843 1844 1845 1846 1847 1848 1849 1850 1851 1852 |
|
test_example_input_two_valid_length_name(ucc_smartx_selenium_helper, ucc_smartx_rest_helper)
¶
Verifies the name field should not be more than 100 characters
Source code in tests/ui/test_input_page.py
1513 1514 1515 1516 1517 1518 1519 1520 1521 1522 1523 1524 1525 1526 1527 1528 1529 |
|
test_example_inputs_with_not_valid_interval(ucc_smartx_selenium_helper, ucc_smartx_rest_helper, interval)
¶
Source code in tests/ui/test_input_page.py
2585 2586 2587 2588 2589 2590 2591 2592 2593 2594 2595 2596 2597 2598 2599 2600 2601 2602 2603 2604 2605 2606 2607 2608 2609 2610 2611 2612 2613 2614 2615 |
|
test_example_inputs_with_valid_interval(ucc_smartx_selenium_helper, ucc_smartx_rest_helper, interval)
¶
Source code in tests/ui/test_input_page.py
2537 2538 2539 2540 2541 2542 2543 2544 2545 2546 2547 2548 2549 2550 2551 2552 2553 2554 2555 2556 2557 2558 2559 2560 2561 2562 2563 2564 2565 2566 2567 2568 2569 2570 2571 2572 2573 2574 2575 2576 2577 2578 2579 2580 2581 2582 2583 |
|
test_inputs_count(ucc_smartx_selenium_helper, ucc_smartx_rest_helper, _add_input_one, _add_input_two)
¶
Verifies count on table
Source code in tests/ui/test_input_page.py
351 352 353 354 355 356 357 358 359 360 361 362 363 364 365 366 |
|
test_inputs_create_new_input_list_values(ucc_smartx_selenium_helper, ucc_smartx_rest_helper)
¶
Verifies input list dropdown
Source code in tests/ui/test_input_page.py
243 244 245 246 247 248 249 250 251 252 253 254 255 256 257 258 259 260 |
|
test_inputs_default_rows_in_table(ucc_smartx_selenium_helper, ucc_smartx_rest_helper)
¶
Verifies the default number of rows in the table
Source code in tests/ui/test_input_page.py
233 234 235 236 237 238 239 240 241 |
|
test_inputs_disable_all_close(ucc_smartx_selenium_helper, ucc_smartx_rest_helper, _add_input_one)
¶
Verifies that closing the ‘Deactivate All’ prompt behaves correctly.
Source code in tests/ui/test_input_page.py
2312 2313 2314 2315 2316 2317 2318 2319 2320 2321 2322 2323 |
|
test_inputs_disable_all_deny(ucc_smartx_selenium_helper, ucc_smartx_rest_helper, _add_input_one)
¶
Verifies that when ‘Deactivate All’ is followed by ‘Deny,’ inputs remain enabled.
Source code in tests/ui/test_input_page.py
2345 2346 2347 2348 2349 2350 2351 2352 2353 2354 2355 2356 2357 2358 |
|
test_inputs_disable_all_enable_all_input_one_input_two(ucc_smartx_selenium_helper, ucc_smartx_rest_helper, _add_input_one, _add_input_two)
¶
Verifies that various types of inputs are correctly disabled and enabled when using the ‘Deactivate All’ and ‘Activate All’ buttons. This test covers scenarios with both Input One and Input Two added.
Source code in tests/ui/test_input_page.py
2381 2382 2383 2384 2385 2386 2387 2388 2389 2390 2391 2392 2393 2394 2395 2396 2397 2398 2399 2400 2401 2402 2403 2404 2405 2406 2407 2408 |
|
test_inputs_disable_all_some_already_disabled(ucc_smartx_selenium_helper, ucc_smartx_rest_helper, _add_input_one, _add_input_two)
¶
Verifies that all inputs are disabled correctly. This test covers scenario where one input is already disabled.
Source code in tests/ui/test_input_page.py
2436 2437 2438 2439 2440 2441 2442 2443 2444 2445 2446 2447 2448 2449 2450 2451 2452 2453 2454 2455 2456 2457 2458 2459 2460 2461 2462 2463 |
|
test_inputs_disable_all_title_message(ucc_smartx_selenium_helper, ucc_smartx_rest_helper, _add_input_one)
¶
Verifies title and message of disable all prompt
Source code in tests/ui/test_input_page.py
2277 2278 2279 2280 2281 2282 2283 2284 2285 2286 2287 2288 2289 2290 2291 2292 2293 2294 2295 2296 2297 |
|
test_inputs_disable_enable_all(ucc_smartx_selenium_helper, ucc_smartx_rest_helper, _add_multiple_inputs)
¶
Verifies that all inputs are disabled after clicking ‘Deactivate all’
Source code in tests/ui/test_input_page.py
2360 2361 2362 2363 2364 2365 2366 2367 2368 2369 2370 2371 2372 2373 2374 2375 2376 2377 2378 2379 |
|
test_inputs_displayed_columns(ucc_smartx_selenium_helper, ucc_smartx_rest_helper)
¶
Verifies headers of input table
Source code in tests/ui/test_input_page.py
129 130 131 132 133 134 135 136 137 138 |
|
test_inputs_enable_all_close(ucc_smartx_selenium_helper, ucc_smartx_rest_helper, _add_input_one)
¶
Verifies that closing the ‘Activate All’ prompt behaves correctly.
Source code in tests/ui/test_input_page.py
2299 2300 2301 2302 2303 2304 2305 2306 2307 2308 2309 2310 |
|
test_inputs_enable_all_deny(ucc_smartx_selenium_helper, ucc_smartx_rest_helper, _add_input_one)
¶
Verifies that when ‘Activate All’ is followed by ‘Deny,’ inputs remain disabled.
Source code in tests/ui/test_input_page.py
2325 2326 2327 2328 2329 2330 2331 2332 2333 2334 2335 2336 2337 2338 2339 2340 2341 2342 2343 |
|
test_inputs_enable_all_some_already_enabled(ucc_smartx_selenium_helper, ucc_smartx_rest_helper, _add_input_one, _add_input_two)
¶
Verifies that all inputs are enabled correctly. This test covers scenario where one input is already enabled.
Source code in tests/ui/test_input_page.py
2410 2411 2412 2413 2414 2415 2416 2417 2418 2419 2420 2421 2422 2423 2424 2425 2426 2427 2428 2429 2430 2431 2432 2433 2434 |
|
test_inputs_enable_all_title_message(ucc_smartx_selenium_helper, ucc_smartx_rest_helper, _add_input_one)
¶
Verifies title and message of enable all prompt
Source code in tests/ui/test_input_page.py
2255 2256 2257 2258 2259 2260 2261 2262 2263 2264 2265 2266 2267 2268 2269 2270 2271 2272 2273 2274 2275 |
|
test_inputs_enable_disable(ucc_smartx_selenium_helper, ucc_smartx_rest_helper, _add_input_one)
¶
Verifies enable and disable functionality of the input
Source code in tests/ui/test_input_page.py
322 323 324 325 326 327 328 329 330 331 332 333 334 335 336 337 338 339 340 341 342 343 344 345 346 347 348 349 |
|
test_inputs_filter_functionality_negative(ucc_smartx_selenium_helper, ucc_smartx_rest_helper, _add_input_one, _add_input_two)
¶
Verifies the filter functionality (Negative)
Source code in tests/ui/test_input_page.py
193 194 195 196 197 198 199 200 201 202 203 204 205 206 207 208 209 210 211 |
|
test_inputs_filter_functionality_positive(ucc_smartx_selenium_helper, ucc_smartx_rest_helper, _add_input_one, _add_input_two)
¶
Verifies the filter functionality (Positive)
Source code in tests/ui/test_input_page.py
213 214 215 216 217 218 219 220 221 222 223 224 225 226 227 228 229 230 231 |
|
test_inputs_input_type_list_values(ucc_smartx_selenium_helper, ucc_smartx_rest_helper, _add_input_one, _add_input_two)
¶
Verifies input type filter list
Source code in tests/ui/test_input_page.py
262 263 264 265 266 267 268 269 270 271 272 273 274 275 276 277 278 279 280 281 282 283 284 285 286 287 288 289 |
|
test_inputs_more_info(ucc_smartx_selenium_helper, ucc_smartx_rest_helper, _add_input_one)
¶
Verifies the expand functionality of the inputs table
Source code in tests/ui/test_input_page.py
291 292 293 294 295 296 297 298 299 300 301 302 303 304 305 306 307 308 309 310 311 312 313 314 315 316 317 318 319 320 |
|
test_inputs_pagination(ucc_smartx_selenium_helper, ucc_smartx_rest_helper, _add_multiple_inputs)
¶
Verifies pagination functionality by creating 100 accounts
Source code in tests/ui/test_input_page.py
153 154 155 156 157 158 159 160 161 162 163 164 165 166 167 168 169 |
|
test_inputs_pagination_list(ucc_smartx_selenium_helper, ucc_smartx_rest_helper)
¶
Verifies pagination list
Source code in tests/ui/test_input_page.py
140 141 142 143 144 145 146 147 148 149 150 151 |
|
test_inputs_sort_functionality(ucc_smartx_selenium_helper, ucc_smartx_rest_helper, _add_input_one, _add_input_two)
¶
Verifies sorting functionality for name column
Source code in tests/ui/test_input_page.py
171 172 173 174 175 176 177 178 179 180 181 182 183 184 185 186 187 188 189 190 191 |
|
test_inputs_textarea_big_input(ucc_smartx_selenium_helper, ucc_smartx_rest_helper, _add_input_one)
¶
Verifies that textarea can handle big inputs
Source code in tests/ui/test_input_page.py
2497 2498 2499 2500 2501 2502 2503 2504 2505 2506 2507 2508 2509 2510 2511 2512 2513 2514 2515 |
|
test_inputs_textarea_height(ucc_smartx_selenium_helper, ucc_smartx_rest_helper, _add_input_one)
¶
Verifies that textarea height values.
Source code in tests/ui/test_input_page.py
2465 2466 2467 2468 2469 2470 2471 2472 2473 2474 2475 2476 2477 2478 2479 2480 2481 2482 2483 2484 2485 2486 2487 2488 2489 2490 2491 2492 2493 2494 2495 |
|
test_inputs_textarea_scroll(ucc_smartx_selenium_helper, ucc_smartx_rest_helper, _add_input_one)
¶
Verifies that textarea height values
Source code in tests/ui/test_input_page.py
2517 2518 2519 2520 2521 2522 2523 2524 2525 2526 2527 2528 2529 2530 2531 2532 2533 2534 2535 |
|
test_inputs_title_and_description(ucc_smartx_selenium_helper, ucc_smartx_rest_helper)
¶
Verifies the title and description of the page
Source code in tests/ui/test_input_page.py
368 369 370 371 372 373 374 375 376 377 378 379 |
|