Let Oomnitza be your single source of truth!
You'll get visibility of your assets as data from Oomnitza is automatically transformed into consumable information and actionable insights.
Create an Oomnitza user workflow in minutes
Create configurable workflows to automate tasks relating to Oomnitza users such as:
- Getting a SaaS user’s role
- Returning the assets and SaaS applications assigned to a user
- Deleting a user
Navigation
Before you start
Before you can create workflows that use our internal Oomnitza API, you first need to enter your credentials in Oomnitza and set global variables. For further information, refer to Getting started with the Oomnitza API.
Did you know?
The Oomnitza block is also a convenient way to access our internal Oomnitza APIs. The Oomnitza block provides you with a unified view of all internal Oomnitza APIs, including the APIs used in the below workflow. For more information, refer to the Oomnitza block.
Creating Saas user workflows
You can create the SaaS User workflow by following the steps in Creating Saas user workflows. To locate the available presets, enter Oomnitza in the Select Preset search field and select the Oomnitza User Role preset.
Oomnitza User Role preset
The Oomnitza User Role preset enables you to read a SaaS user’s role from Oomnitza
Prerequisites
Before you create a SaaS user workflow, you should create a software entry for Oomnitza in the Software > SaaS menu.
- Click Configuration > Workflows.
- From the list, select Software Saas Users.
- Click Add
. The Begin and End blocks are added to the sandbox.
- Enter the name and a description of the workflow.
- Edit the Begin block by adding the rules that will trigger the workflow. For example, you could add a Rule in the Begin block to trigger the workflow if the SaaS name Equals Oomnitza.
- Click the Blocks tab, and drag and drop the SaaS User Role retrieval block onto the canvas.
- Click the Edit icon.
- Enter Oomnitza in the search field and choose the Oomnitza User Role preset.
- Click the right arrow.
- Enter your Credentials.
- Your Subdomain should be derived from the variable created in Setting the Oomnitza subdomain as a global variable or entered manually.
- Select the Deactivate User checkbox to deactivate the SaaS user in SaaS > Oomnitza > Users if they are not found in your Oomnitza instance.
- Click SAVE.
- Connect the blocks.
- Save, validate, and activate your workflow.
To view active Oomnitza users in the SaaS Users UI, complete the following steps:
- Click Software from the menu.
- Select the Saas tab, and select your software entry for Oomnitza.
- Click Users in the side pane.
- The Role column will be populated to confirm that this user has been found in your Oomnitza SaaS.
Reference articles for creating workflows
Creating workflows
Creating user workflows with the API block
To reduce your workload and automate complex and repetitive tasks, you can create workflows with the API block by following the steps in Using the API block. To locate the available presets, enter Oomnitza in the Select Preset search field. Select your preset of choice and for every preset enter the following information in the Configure section:
- Your Oomnitza Credentials that you created in Adding the credentials.
- Your Subdomain should be derived from the variable created in Setting the Oomnitza subdomain as a global variable or entered manually.
For information on the specific requirements for each preset, click one of the links below:
- Delete user
- Count assigned assets for user
- Read user details from SaaS user
- Get assigned assets from user
- Get assigned SaaS from user
- Bulk edit assigned assets for user preset
Using the Oomnitza Delete user preset
The Oomnitza Delete user preset enables you to delete/deactivate a user from Oomnitza. Use the Advanced Mode to configure the message payload. To do this,
- Click the Advanced Mode button located in the upper right of the window.
- Select the Information tab.
- The user id is assumed to be stored in the field
{{user_external_id}}. - Select the Response tab. You can access the complete response by inserting
{{response}}in the Response field, and then selecting the Oomnitza field or variable that you want to map to. See Mapping positive and negative responses.
Using the Oomnitza Count assigned assets for user preset
The Oomnitza Count assigned assets for user preset can be used within users workflows to count the number of assets that are assigned to a user. Use the advanced mode to configure the message payload. To do this,
- Click Advanced Mode.
- Select the Information tab. The user id is assumed to be stored in the field
{{username}}. If you do not have a field matching this name, you can create one. To do this click, Configuration > Data Model > Field Configuration and then select Users from the Objects list. - Select a custom numeric or text Oomnitza field to map the count to. To access the Response tab, input the Jinja statement
{{ (response | length ) }}into the Response field. This statement will count all assets that have been assigned to a particular user. From there, choose a custom text or numeric Oomnitza field to associate with the count.
Tip: In some cases, you might want to only count certain assets. To do so, you can customize the URL in the Information tab. For example, if you wish to only count the number of notebooks, you would add
%20AND%20asset_type%20eq%20%27Laptop%27 at the end of the URL.
Using the Oomnitza Read user details from SaaS user preset
The Oomnitza Read user details from SaaS user preset enables you to read the last login field from a SaaS user and add it to SaaS User. When constructing a workflow that uses this preset, the following information is mandatory:
- Map Last Login to Field. A DateTime field which will contain the last login date. The field name should be in lowercase, and spaces replaced with an underscore.
Use the Advanced Mode to configure the message payload. To do this,
- Click the Advanced Mode button located in the upper right of the window.
- Select the Information tab. The user id is assumed to be stored in the field
{{user_id.username}}. - Select the Response tab. You have the option to map the Jinja statement, which gets the users last login, to a custom DateTime Oomnitza field.
Tip: You could use this preset in conjunction with the Slack last login user integration. You would need to create the integration and then run a scheduled workflow using the Slack SaaS user role API and Read user details from SaaS user preset to pull the slack_last_login field into the Oomnitza Last Login to Field.
Using the Oomnitza Get assigned assets from user preset
The Oomnitza Get assigned assets from user preset can be used within workflows to get the assets that are assigned to a user. This preset returns the assets assigned to a user in comma separated format.
When you select this preset, you should enter the Oomnitza field names the JSON response will map to.
-
Map Computer Name to Field. For example,
{{computer_name}}. The computer name of the asset assigned to the user. -
Map Serial Number to Field. For example,
{{serial_number}}. The serial number of the asset assigned to the user.
Next, you can use the Advanced Mode to configure the message payload. To do this,
- Click the Advanced Mode button located in the upper right of the window.
- In the Information tab, you will notice that the user information is assumed to be stored in the
{{email}}field. If you do have have a field matching this name, you can create one. To do this click, Configuration > Data Model > Field Configuration and then select Users from the Objects list. - Select the Response tab.
- You can use Jinja in the API response to configure the response mapping. For example, if you do not have
{{computer_name}}in your API response, but do have a{{model}}, you can add the following to the Response field and map it to a suitable Oomnitza field:
{% if response %}{{ response|map(attribute='model') | list | join(', ') }}{% else %}{% endif %}
Using the Oomnitza Get assigned SaaS from user preset
The Oomnitza Get assigned SaaS from user preset enables you to get a list of SaaS applications assigned to a user.
When you select this preset, you should enter the Oomnitza field names the JSON response will map to.
-
Map Saas Name to Field. For example,
{{saas_name}}. The name of the SaaS application assigned to the user. -
Map Saas ID to Field. For example,
{{saas_id}}. The SaaS id of the application assigned to the user. -
Map Assigned Contract ID to Field. For example,
{{assigned_contract_id}}. The contract id of the SaaS application assigned to the user.
For information on creating Oomnitza fields, see Creating Custom Fields in Oomnitza.
Use the Advanced Mode to configure the message payload. To do this,
- Click the Advanced Mode button located in the upper right of the window.
- Select the Information tab. The user id is assumed to be stored in the field
{{username}}. If you do have have a field matching this name, you can create one. To do this click, Configuration > Data Model > Field Configuration and then select Users from the Objects list. - Select the Response tab. You can map the entire response by placing
{{response}}in the Response field and mapping it to a custom long text Oomnitza field, such as API Response. Once you have the entire response, you can then map individual JSON values (such as{{response[0].assigned_contract_id}},{{response[0].roles[0].role_id}}) to custom fields. See Mapping positive and negative responses.
Example response:
[ { "assigned_contract_id": "string", "available_contracts": [ { "contract_id": "string", "contract_name": "string", "contract_type": "string", "has_free_license_keys": true } ], "roles": [ { "role_id": "string", "role_external_id": "string", "role_external_label": "string" } ], "estimated_spend": 0, "saas_id": "string", "saas_name": "string", "uid": 0 } ]
Using the Oomnitza bulk edit assigned assets for user preset
The Oomnitza Bulk edit assigned assets for user preset enables you to all assets associated with a user.
The user associated with the assets is referenced in the Advanced Mode > Body tab in the property{{username}}.
The edits clause contains the value to be updated. The example below specifies that the department field should be updated, however, this can be changed to another asset field, such as Location, Manufacturer, or Model.
{"filter": "(assigned_to eq '{{username}}')",
"edits": {"department": "{{department.ATTRIBUTE_VALUE}}"}}
Comments
0 comments
Please sign in to leave a comment.