declineOrCancelInvitation

abstract suspend fun declineOrCancelInvitation(invitationId: String): RainbowResult<Unit>

Declines or cancels an invitation based on its type.

This API determines whether the specified invitation is received or sent and performs the corresponding action:

  • If the invitation is received, it will be declined.

  • If the invitation is sent, it will be canceled.

Return

A RainbowResult indicating the success or failure of the operation. In case of failure, it will contain error details.

Parameters

invitationId

The unique identifier of the invitation to be processed.