Files
iptv-manager-service/scripts/delete_cognito_user.sh
Stefano a5dfc1b493
All checks were successful
AWS Deploy on Push / build (push) Successful in 4m21s
Added scripts to create and delete users. Moved all scripts to new scripts folder
2025-05-16 14:19:14 -05:00

18 lines
317 B
Bash
Executable File

#!/bin/bash
set -e
if [ "$#" -ne 2 ]; then
echo "Usage: $0 USER_POOL_ID USERNAME"
exit 1
fi
USER_POOL_ID=$1
USERNAME=$2
aws cognito-idp admin-delete-user --no-cli-pager \
--user-pool-id "$USER_POOL_ID" \
--username "$USERNAME" \
--output json > /dev/null 2>&1
echo "User $USERNAME deleted successfully"