Within the com.jamf.connect.actions domain, the following preference keys determine the behavior of the menu. The only required part of each item is the name; all other parts are optional. Consider the following when creating menu bar items:
The result of any command can be passed on to the next. Using
<<result>>as a command option will replace it with the result of the previous command.trueorfalseresults are not passed to the next command.Adding
trueorfalseat the end of the command will cause that command to run only if the previously run command returns accordingly. For example, usingalertTrueas the command name will run thealertcommand only if the previously run command returnstrue.
The result state is persistent, allowing multiple commands to be designated to run or not run depending on a single result. For example, if a result of true is passed to a sequence commands with false modifiers appended to their command names, none of those commands would be run.
Global Preferences
The following table includes the global preferences for a custom menu bar action configuration profile.
Setting | Description | Type |
|---|---|---|
| Determines if the action menu will display a status icon (green, yellow, or red) Note:
| Boolean |
| When set to true, Self Service+ will use the result of the command as the text of the menu item. Note:
| Boolean |
Action Content
Setting | Description | Type |
|---|---|---|
| (Required) The name of the action | String |
| The text used to display the item in the menu bar Note: If unspecified, the Name will be used as the title. | Dictionary |
| Determines if the item is displayed in the menu or not Note: All commands in the Show command must return true for the menu item to display. | Array |
| Contains the action. | Array |
| Determines what happens after the action is run. | Array |
| The unique ID for the action | String |
| Determines if the action set should only be run when connected to an Active Directory domain | Boolean |
| Length in minutes between executing the action | Integer |
| The text displayed when hovering over a menu item | String |
| Creates a visual separator bar in the menu bar |
Commands
Self Service+ has built-in commands that can be used to execute action items. Consider the following about commands:
All options are strings.
All commands can return results.
Results do not persist between commands.
CommandOptionssupport the standard Self Service+ variables such as<<domain>>,<<user>>, and<<email>>.Commands are case sensitive.
Command | Function | Command Options |
|---|---|---|
| Executes a binary at a specific file path | The path to execute |
| Opens an application at a specific file path | The path of the application to open |
| Opens a URL in the user's default browser | The URL to open |
| Pings a host | The host to ping |
| Determine if the current user is a member of an Active Directory group | The group to test |
| Displays a modal dialog to the user
| The alert text Note: If the command options are blank or are either "true" or "false", no alert will display. You can use this to show only errors. |
| Displays a notification in the notification center
| The notification text Note: If the command options are blank or are either "true" or "false", no notification will display. You can use this to show only errors. |
| A command that always returns false. This could be used to clear previous results in a command set | Text |
| A command that always returns true. This could be used to clear previous results in a command set | Text |