获取角色详情

所属服务

sam

接口方法

GET

请求url

/sam?Action=GetRole&Version=2018-03-22&RoleName=

url 参数

参数名称说明参数类型是否必填备注
RoleName角色名称string
ActionGetRolestring
Version2018-03-22string

返回参数

参数名称说明参数类型是否必填备注
RoleName角色名称string
CodeCodestring
MessageMessagestring
Description角色描述string
AssumeRolePolicyDocument角色授权语言string
CreateTime创建时间string
Nrn角色Nrnstring

状态码

错误码(Code)错误提示(Message)http status code说明
ProductNotActive400null
MissingParameter400null
EntityNotExist400null

请求示例

https://open.cn-east-1.163yun.com/sam?Action=GetRole&Version=2018-03-22&RoleName=roletest

返回示例

{
	"RoleName": "roletest",
	"Description": "test",
	"Message": "调用成功",
	"RequestId": "0933377e-3085-4b3e-9f1f-68268064cadb",
	"AssumeRolePolicyDocument": "{\"version\": 1, \"statement\": [{\"action\": \"sts:assumeRole\", \"effect\": \"allow\", \"principal\": {\"sam\": [\"ncs:sam::1061934905920847872:root\"]}}]}",
	"CreateTime": "2020-01-20T06:45:33Z",
	"Nrn": "ncs:sam::1061934905920847872:role/roletest",
	"Code": "Success"
}