All Products
Search
Document Center

Resource Management:RejectResourceShareInvitation

Last Updated:Aug 28, 2026

Rejects a resource sharing invitation.

Operation description

The following example shows how to reject the resource sharing invitation i-yyTWbkjHArYh**** in the cn-hangzhou region.

Try it now

Try this API in OpenAPI Explorer, no manual signing needed. Successful calls auto-generate SDK code matching your parameters. Download it with built-in credential security for local usage.

Test

RAM authorization

No authorization for this operation. If you encounter issues with this operation, contact technical support.

Request parameters

Parameter

Type

Required

Description

Example

ResourceShareInvitationId

string

Yes

The ID of the resource sharing invitation.

You can call the ListResourceShareInvitations operation to obtain the ID of a resource sharing invitation.

i-yyTWbkjHArYh****

For more information about common request parameters, see Common parameters.

Response elements

Element

Type

Description

Example

object

RequestId

string

The request ID.

E446D6DE-BFC8-5F37-A494-33D7B118147D

ResourceShareInvitation

object

The information about the resource sharing invitation.

ResourceShareInvitationId

string

The invitation ID.

i-yyTWbkjHArYh****

ResourceShareId

string

The resource share ID.

rs-JoA1Ayjm****

ResourceShareName

string

The resource share name.

example

SenderAccountId

string

The Alibaba Cloud account ID of the inviter.

151266687691****

ReceiverAccountId

string

The Alibaba Cloud account ID of the invitee.

134254031178****

CreateTime

string

The time when the invitation was created, in UTC.

2022-09-02T07:07:30.809Z

Status

string

The status of the invitation. Valid values:

  • Pending: The invitation is waiting for confirmation.

  • Accepted: The invitation is accepted.

  • Cancelled: The invitation is canceled.

  • Rejected: The invitation is rejected.

  • Expired: The invitation has expired.

Rejected

Examples

Success response

JSON format

{
  "RequestId": "E446D6DE-BFC8-5F37-A494-33D7B118147D",
  "ResourceShareInvitation": {
    "ResourceShareInvitationId": "i-yyTWbkjHArYh****",
    "ResourceShareId": "rs-JoA1Ayjm****",
    "ResourceShareName": "example",
    "SenderAccountId": "151266687691****",
    "ReceiverAccountId": "134254031178****",
    "CreateTime": "2022-09-02T07:07:30.809Z",
    "Status": "Rejected"
  }
}

Error codes

HTTP status code

Error code

Error message

Description

400 InvalidParameter.ResourceShareInvitationId The ResourceShareInvitationId is invalid.
400 MissingParameter.ResourceShareInvitationId You must specify ResourceShareInvitationId.
409 InvitationStatus.Expired The resource share invitation status is expired.
409 EntityNotExists.ResourceShareInvitation The resource share invitation does not exist in the current account.
409 InvitationStatus.AlreadyRejected The resource share invitation status is rejected.
409 InvitationStatus.AlreadyAccepted The resource share invitation status is alredy accepted.

See Error Codes for a complete list.

Release notes

See Release Notes for a complete list.