我有一个客户委托我提供他的卖方中央访问密钥 ID 和秘密访问密钥,但是当我使用它时创建 IAM 角色和用户策略并调用 API。它返回此调用是针对 getOrder 的。
“root 帐户可能不会承担 getOrder 角色”
解决方法是什么?
这是来自 API 的实际响应
Error executing "AssumeRole" on "https://sts.us-east-1.amazonaws.com"; AWS HTTP error: Client error: `POST https://sts.us-east-1.amazonaws.com` resulted in a `403 Forbidden` response:
<ErrorResponse xmlns="https://sts.amazonaws.com/doc/2011-06-15/">
<Error>
<Type>Sender</Type>
`enter code here`<Code>AccessDeni (truncated...)
AccessDenied (client): Roles may not be assumed by root accounts. - <ErrorResponse xmlns="https://sts.amazonaws.com/doc/2011-06-15/">
<Error>
<Type>Sender</Type>
<Code>AccessDenied</Code>
<Message>Roles may not be assumed by root accounts.</Message>
</Error>
<RequestId>0123456789</RequestId>
</ErrorResponse>