调试
您可以在API Explorer中调试该接口,支持自动认证鉴权。API Explorer可以自动生成SDK代码示例,并提供SDK代码示例调试功能。
授权信息
账号具备所有API的调用权限,如果使用账号下的IAM用户调用当前API,该IAM用户需具备调用API所需的权限。
- 如果使用角色与策略授权,具体权限要求请参见权限和授权项。
- 如果使用身份策略授权,需具备如下身份策略权限。
| 授权项 | 访问级别 | 资源类型(*为必须) | 条件键 | 别名 | 依赖的授权项 |
| ram:resourceShareInvitations:accept | Write | resourceShareInvitation * | - | - | - |
| - | ram:ShareOwnerAccountId |
URI
POST /v1/resource-share-invitations/{resource_share_invitation_id}/accept
表1 路径参数 | 参数 | 是否必选 | 参数类型 | 描述 |
| resource_share_invitation_id | 是 | String | 资源共享邀请的ID。 |
响应参数
状态码:200
表4 ResourceShareInvitation | 参数 | 参数类型 | 描述 |
| receiver_account_id | String | 接收资源共享邀请的账号ID。 |
| resource_share_id | String | 资源共享实例的ID。 |
| resource_share_name | String | 资源共享实例的名称。 |
| resource_share_invitation_id | String | 资源共享邀请的ID。 |
| sender_account_id | String | 发送资源共享邀请的账号ID。 |
| status | String | 资源共享邀请的当前状态。 |
| created_at | String | 创建邀请的时间。 |
| updated_at | String | 最后一次更新邀请的时间。 |
请求示例
接受来自其他账号的资源共享邀请。
POST /v1/resource-share-invitations/{resource_share_invitation_id}/accept 响应示例
状态码:200
请求成功。
{
"resource_share_invitation" : {
"receiver_account_id" : "string",
"resource_share_id" : "string",
"resource_share_name" : "string",
"resource_share_invitation_id" : "string",
"sender_account_id" : "string",
"status" : "string",
"created_at" : "2022-08-22T12:28:26.631Z",
"updated_at" : "2022-08-22T12:28:26.631Z"
}
}