How to Return All Users Using the List Users With Search Card in Okta Workflows
Last Updated:
Overview
When using the List Users With Search card with the Stream Matching Records option and no inputs selected, Okta returns all users except those with a DEPROVISIONED status (deactivated users). To return all users, including deactivated accounts, use the Custom Search Criteria input with a query that includes every user status.
Applies To
- Okta Identity Engine (OIE)
- Okta Classic Engine
- Okta Workflows
- List Users With Search card
Cause
It is expected behavior that the List Users With Search card does not return DEPROVISIONED users when no inputs are specified.
Solution
How is the List Users With Search card configured to return all users?
When using the Status input to search for users with the List Users With Search card, only one status value can be specified. To search for all users using a single List Users With Search card, use the Custom Search Criteria input with search criteria that includes all statuses:
- Click the cogwheel icon on the List Users with Search card, select Choose fields, check the Custom Search Criteria input, and click Save:
- Add the following search criteria to a Compose card prior to the List Users With Search card. Make sure there are no carriage returns before or after the text when pasting it into the Compose card:
status eq "ACTIVE" or status eq "SUSPENDED" or status eq "DEPROVISIONED" or status eq "STAGED" or status eq "PROVISIONED" or status eq "RECOVERY" or status eq "LOCKED_OUT" or status eq "PASSWORD_EXPIRED"
- Map the output of the Compose card into the Custom Search Criteria input on the List Users With Search card:
