OVERVIEW
The Google Workspace Search Groups or Search Users cards in Okta Workflows produce outputs that do not seem to contain all results in the Google account being searched. All of the results returned are from a single domain in the Google Workspace account, and none of the results reflect any of the alternate domains in the Google Workspace account.
APPLIES TO
-
Okta Workflows
-
Google Workspace Search Users
-
Google Workspace Search Groups
CAUSE
In order to return values from Google Workspace, the Google Workspace Search Users card uses the user.list function in from the Google Workspace API, while the Search Groups card uses the groups.list function.
In both cases, there is a required input parameter of either "domain" or "customer". These inputs are mutually exclusive, but at least one is required.
The Workflows cards automatically use the "domain" parameter and specify the domain of the user account that was used to authorize the connection to Google Workspace, as this is a known variable.
When the domain parameter is used for this call, only records contained within the specified domain are returned. The search must specify the customer parameter to search all domains within a given customer account, but it is not configurable within the built-in Workflows cards.
These cards will always default to searching the domain of the user that authorized the connection by design.
SOLUTION
To return all records in a given Google Workspace account, use the Customer ID parameter in a Custom API action in lieu of the Search Users or Search Groups cards.
To search using the Customer ID parameter, use a Custom API action card and point it to the correct relative URL, /v1/users or /v1/groups respectively, with the correct query parameter inputs.
Attached is a sample flow design that can be used to build the Custom API action and search using the Customer ID parameter.
Please follow the notes in the flow for detailed instructions about usage. For details about how to import the attached folder, please see Use the Import command for folders
