Create a Report Listing Groups and Owners for an Okta App in Okta Workflows

In this guide:

  1. Okta Workflows guides
  2. List groups and owners for a Okta app
  3. Related Okta Workflows guides
  4. Okta Workflows resources

Okta Workflows guides

Okta Workflows guides offer questions and answers from Okta Workflows community office hours. They also come from the #okta-workflows channel on the Mac Admins Slack and other places. Read all the other guides.

How do you create a report listing groups and owners for an Okta app?

This guide teaches you how to create a report in Okta Workflows. For a given application, the report lists all the associated groups and each group’s owner, if one is assigned.

List groups and owners for a Okta app

The report uses two flows:

  1. A flow to list all app groups.
  2. A helper flow to list the owner for each group.

A flow to list all app groups

The List app groups flow lists the group assigned to an app:

List application groups flow.

How the flow works

  1. The Helper Flow card has an input to enter an app name. This is the app for which you need to list groups and owners.
  2. The group information and owners are saved in a table. The flow clears the table before each run with the Tables-Clear Table card.
  3. The Okta-Search Applications card finds extra information about the application.
  4. The Text-Compose card creates an API endpoint URL for the next card.
  5. The Okta-Custom API Action card invokes the /api/v1/apps/ID/groups endpoint.
    • The call includes the expand=group parameter. This parameter adds group name for each group in the list.
    • The parameter _embedded.group.profile.name holds the group name.
    • The flow utilizes the Custom API Action cards, as the Okta-Search Groups card doesn’t include group name information.
  6. The flow passes the group list to the List-For Each card to process each group and list the group owner.

A helper flow to list the owner for each group

List group owner helper flow:

List group owner helper flow.
List group owner helper flow.

How the flow works

  1. The main flow passes three fields to the helper flow:
    • Group ID
    • Group name
    • App name
  2. The Text-Compose card creates an API endpoint to list the group owner.
  3. The Okta-Custom API Action card invokes the /api/v1/apps/ID/groups endpoint to list the group owner.
  4. The Object-Get card retrieves the group name.
  5. The Tables-Create Row saves information. It creates a table row with App name, Group name, and Group owner (if set).

The table looks like this:

Table showing groups assigned to an app and group owners.
Table showing groups assigned to an app and group owners.

Okta Workflows resources

🚀 New to Okta Workflows? The Getting Started with Okta Workflows page has all the resources to help you get started.

📺 Like learning from videos? Watch Okta Workflows videos.

❓Have a question? Ask during community office hours, post on the community forum, or email me.

🙋🏻‍♀️ Want to learn from the community? Join the #okta-workflows channel on the Mac Admins Slack.

📖 Want to learn more about Okta and automation? Take the Okta Workflows training on Okta Learning.

Leave a comment