Create a subflow to add license consumption data to the Subscription Consumption Summaries [sam_saas_consumption_summary] table.

Before you begin

This subflow is applicable to any integration that uses the SaaS license connection framework, including custom integrations.

Role required: flow_designer or admin

Procedure

  1. Navigate to All > Process Automation > Flow Designer.
    The Flow Designer launches in a new tab.
  2. On the Flow Designer home page, click New and then select Subflow.
    The Subflow Properties dialog box opens.
  3. On the dialog box, fill in the following fields.
  4. Click Submit.
    The Flow Designer creates the draft subflow and then redirects you to the subflow configuration page.
  5. From the subflow configuration page, add an integration profile input.
    1. Under INPUTS & OUTPUTS, click the plus icon (+) to add an input for your subflow.
    2. In the Inputs section, click the plus icon (+).
    3. When prompted, enter the following information for your integration profile input.
      Table 2. Inputs
      Label Name Type Mandatory
      Integration profile integration_profile Reference.Integration Profile Yes
    4. Click Done.
  6. Add a data stream action for getting license consumption data.
    1. Under ACTIONS, click the plus icon (+) and then select Action to add a new action.
    2. When prompted, select the Global spoke from the list of INSTALLED SPOKES.
    3. From the list of Default actions, select Get <saas-application> Consumption.
    4. Click Done.
  7. Add an Upsert Consumption action as a child of the Get <saas-application> Consumption action.
    The Upsert Consumption action uploads license consumption data to the Consumption Summary table on your ServiceNow instance.
    1. Under the Get <saas-application> Consumption action, click the plus icon (+) and then select Action.
    2. When prompted, select Software Asset Management from the list of INSTALLED SPOKES.
    3. From the list of Default actions, select Upsert Consumption.
      The Upsert Consumption action inputs appear.
    4. From the Product [Software Product] list, search for and select the software product that you are connecting to with your integration.
      This value must be a reference to the Software Product (samp_sw_product) table. If the product does not exist in the table, add a custom software product.
    5. Use values from the Data panel to fill in the remaining action inputs.
      Your request to the SaaS API may not return data for all inputs. Fill in the inputs that are applicable to your integration.
    6. Click Done.
  8. Verify that your subflow is working properly by clicking Test.
    View the test results and system logs for details about any errors in your subflow. You can view system logs by navigating to System Logs > System Log > All in your ServiceNow instance.
  9. After verifying that the subflow is working as expected, click Publish.
    Tip: You can still edit the subflow after it's published.

What to do next

View analytics such as subscription usage, cost, and compliance of your SaaS applications on SaaS overview dashboard in workspace.