Python to list users in AWS
2021-07-01 08:07
标签:str class nsf def pytho nbsp www dict get code refer https://www.w3schools.com/python/default.asp Python to list users in AWS 标签:str class nsf def pytho nbsp www dict get 原文地址:https://www.cnblogs.com/oskb/p/9638046.htmlimport boto3
c1=boto3.client(‘iam‘)
#list_users will be a dict
users=c1.list_users()
#transfer dict to list
user_list=list(( r.get(‘UserName‘) for r in users.get(‘Users‘) ))
#print list
print(user_list)
#transfer list to string
for user_name in user_list:
print(user_name)
上一篇:C++实现大数相乘
文章标题:Python to list users in AWS
文章链接:http://soscw.com/index.php/essay/100240.html