Modifies the information of a resource share.
Try it now
Test
RAM authorization
Action | Access level | Resource type | Condition key | Dependent action |
resourcesharing:UpdateResourceShare | update | *All Resource
|
| None |
Request parameters
Parameter | Type | Required | Description | Example |
ResourceShareId | string | Yes | The ID of the resource share. | rs-qSkW1HBY**** |
ResourceShareName | string | Yes | The new name for the resource share. The name must be 1 to 50 characters in length. It can contain letters, digits, periods (.), underscores (_), and hyphens (-). | new |
AllowExternalTargets | boolean | No | Specifies whether to share resources with accounts outside your resource directory. Valid values:
| false |
Response elements
Element | Type | Description | Example |
object | The response parameters. | ||
RequestId | string | The request ID. | 2860A3A4-D8C1-4EF4-954E-84A3945E26E5 |
| ResourceShare | object | The information about the resource share. | |
UpdateTime | string | The time when the resource share was updated. | 2020-12-04T08:55:25.382Z |
ResourceShareName | string | The name of the resource share. | new |
ResourceShareOwner | string | The owner of the resource share. | 151266687691**** |
CreateTime | string | The time when the resource share was created. | 2020-12-03T08:02:22.413Z |
ResourceShareId | string | The ID of the resource share. | rs-qSkW1HBY**** |
ResourceShareStatus | string | The status of the resource share. Valid values:
Note The system automatically deletes the records of resource shares in the | Active |
AllowExternalTargets | boolean | Indicates whether resources can be shared with accounts outside your resource directory. Valid values:
| false |
Examples
Success response
JSON format
{
"RequestId": "2860A3A4-D8C1-4EF4-954E-84A3945E26E5",
"ResourceShare": {
"UpdateTime": "2020-12-04T08:55:25.382Z",
"ResourceShareName": "new",
"ResourceShareOwner": "151266687691****",
"CreateTime": "2020-12-03T08:02:22.413Z",
"ResourceShareId": "rs-qSkW1HBY****",
"ResourceShareStatus": "Active",
"AllowExternalTargets": false
}
}Error codes
HTTP status code | Error code | Error message | Description |
400 | MissingParameter.ResourceShareId | You must specify ResourceShareId. | You must specify ResourceShareId. |
400 | InvalidParameter.ResourceShareId | The ResourceShareId is invalid. | The ResourceShareId parameter is invalid. |
400 | MissingParameter.ResourceShareName | You must specify ResourceShareName. | The ResourceShareName parameter is missing. |
400 | InvalidParameter.ResourceShareName | The ResourceShareName is invalid. | The ResourceShareName parameter is invalid. |
400 | InvalidParameter.ResourceShareName.Length | The maximum length of ResourceShareName exceeds 50 characters. | The length of ResourceShareName cannot exceed 50 characters. |
400 | InvalidParameter | The specified parameter is invalid. | The specified parameter is invalid. |
404 | EntityNotExists.ResourceShare | The resource share does not exist in the current account. | The resource share does not exist in the current account. |
409 | OperationNotPermitted | You do not have permission to do this operation. | You are not authorized to perform this operation. |
409 | ResourceShareStatusMismatchAction | The status of the resource share does not allow the specified operation. | The status of the resource share does not allow the specified operation. |
See Error Codes for a complete list.
Release notes
See Release Notes for a complete list.