Created
August 9, 2023 04:39
-
-
Save brendanmckenzie/2fee2bfc742b7492c0cef6cb4c8b033c to your computer and use it in GitHub Desktop.
export list of users from cognito into csv
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
aws \ | |
--output json \ | |
cognito-idp \ | |
list-users \ | |
--user-pool-id __pool_id__ | \ | |
jq -r \ | |
'["id","email","name"], (.Users | .[] | [.Username, (.Attributes[] | select(.Name=="email") | .Value),(.Attributes[] | select(.Name=="name") | .Value)]) | @csv' \ | |
> users.csv |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment