有谁知道如何在 Swift 中从 AWS Mobile Hub 检索电子邮件和电话号码(如下图所示)?
我只知道如何使用以下代码检索用户名:
let serviceConfiguration = AWSServiceConfiguration(region:.USEast1, credentialsProvider:nil)
let configuration = AWSCognitoIdentityUserPoolConfiguration(clientId: "clientId", clientSecret: "clientSecret", poolId: "poodId")
AWSCognitoIdentityUserPool.register(with: serviceConfiguration, userPoolConfiguration: configuration, forKey: "Users")
let pool = AWSCognitoIdentityUserPool(forKey: "Users")
print(pool.currentUser()?.username)
任何建议,将不胜感激。