ClaimClaimableBalanceOperation

public class ClaimClaimableBalanceOperation : Operation, @unchecked Sendable

Represents a claim claimable balance operation. Claimable Balances can be used to “split up” a payment into two parts, which allows the sending to only depend on the sending account, and the receipt to only depend on the receiving account. See Stellar developer docs.

  • The claimable balance id to be claimed.

    Declaration

    Swift

    public let balanceId: String
  • Creates a new ClaimClaimableBalanceOperation object.

    Declaration

    Swift

    public init(balanceId: String, sourceAccountId: String? = nil)

    Parameters

    balanceId

    The claimable balance id to be claimed.

    sourceAccountId

    The source account of the operation. Optional. Defaults to the transaction’s source account.

  • Creates a new ClaimClaimableBalanceOperation object from the given ClaimClaimableBalanceOpXDR object.

    Declaration

    Swift

    public init(fromXDR: ClaimClaimableBalanceOpXDR, sourceAccountId: String?) throws

    Parameters

    fromXDR

    the ClaimClaimableBalanceOpXDR object to be used to create a new ClaimClaimableBalanceOperation object.

    sourceAccountId

    (optional) source account Id, must be valid, otherwise it will be ignored.