Package com.stripe.model
Class TransferReversal
java.lang.Object
com.stripe.model.StripeObject
com.stripe.net.ApiResource
com.stripe.model.TransferReversal
- All Implemented Interfaces:
BalanceTransactionSource
,HasId
,MetadataStore<TransferReversal>
,StripeActiveObject
,StripeObjectInterface
public class TransferReversal
extends ApiResource
implements MetadataStore<TransferReversal>, BalanceTransactionSource
Stripe Connect platforms can reverse transfers made
to a connected account, either entirely or partially, and can also specify whether to refund any
related application fees. Transfer reversals add to the platform's balance and subtract from the
destination account's balance.
Reversing a transfer that was made for a destination charge is allowed only up to the amount of the charge. It is possible to reverse a transfer_group transfer only if the destination account has enough balance to cover the reversal.
Related guide: Reverse transfers
-
Nested Class Summary
Nested classes/interfaces inherited from class com.stripe.net.ApiResource
ApiResource.RequestMethod
-
Field Summary
Fields inherited from class com.stripe.net.ApiResource
CHARSET, GSON, INTERNAL_GSON
Fields inherited from class com.stripe.model.StripeObject
PRETTY_PRINT_GSON
-
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptionprotected boolean
boolean
Amount, in cents (or local equivalent).Get ID of expandablebalanceTransaction
object.Get expandedbalanceTransaction
.Time at which the object was created.Three-letter ISO currency code, in lowercase.Get ID of expandabledestinationPaymentRefund
object.Get expandeddestinationPaymentRefund
.getId()
Unique identifier for the object.Set of key-value pairs that you can attach to an object.String representing the object's type.Get ID of expandablesourceRefund
object.Get expandedsourceRefund
.Get ID of expandabletransfer
object.Get expandedtransfer
.int
hashCode()
void
Amount, in cents (or local equivalent).void
void
setBalanceTransactionObject
(BalanceTransaction expandableObject) void
setCreated
(Long created) Time at which the object was created.void
setCurrency
(String currency) Three-letter ISO currency code, in lowercase.void
void
setDestinationPaymentRefundObject
(Refund expandableObject) void
Unique identifier for the object.void
setMetadata
(Map<String, String> metadata) Set of key-value pairs that you can attach to an object.void
String representing the object's type.void
setResponseGetter
(StripeResponseGetter responseGetter) Method is used by the containing object orStripeResponseGetter
implementations to set theStripeResponseGetter
instance used to make further requests.void
void
setSourceRefundObject
(Refund expandableObject) void
setTransfer
(String id) void
setTransferObject
(Transfer expandableObject) update
(TransferReversalUpdateParams params) Updates the specified reversal by setting the values of the parameters passed.update
(TransferReversalUpdateParams params, RequestOptions options) Updates the specified reversal by setting the values of the parameters passed.Updates the specified reversal by setting the values of the parameters passed.update
(Map<String, Object> params, RequestOptions options) Updates the specified reversal by setting the values of the parameters passed.Methods inherited from class com.stripe.net.ApiResource
checkNullTypedParams, getGlobalResponseGetter, getResponseGetter, setExpandableFieldId, setStripeResponseGetter, urlEncode, urlEncodeId
Methods inherited from class com.stripe.model.StripeObject
deserializeStripeObject, deserializeStripeObject, deserializeStripeObject, equals, getLastResponse, getRawJsonObject, setLastResponse, toJson, toString
Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, wait, wait, wait
Methods inherited from interface com.stripe.model.StripeActiveObject
trySetResponseGetter
Methods inherited from interface com.stripe.model.StripeObjectInterface
getLastResponse, setLastResponse
-
Constructor Details
-
TransferReversal
public TransferReversal()
-
-
Method Details
-
getBalanceTransaction
Get ID of expandablebalanceTransaction
object. -
setBalanceTransaction
-
getBalanceTransactionObject
Get expandedbalanceTransaction
. -
setBalanceTransactionObject
-
getDestinationPaymentRefund
Get ID of expandabledestinationPaymentRefund
object. -
setDestinationPaymentRefund
-
getDestinationPaymentRefundObject
Get expandeddestinationPaymentRefund
. -
setDestinationPaymentRefundObject
-
getSourceRefund
Get ID of expandablesourceRefund
object. -
setSourceRefund
-
getSourceRefundObject
Get expandedsourceRefund
. -
setSourceRefundObject
-
getTransfer
Get ID of expandabletransfer
object. -
setTransfer
-
getTransferObject
Get expandedtransfer
. -
setTransferObject
-
update
Updates the specified reversal by setting the values of the parameters passed. Any parameters not provided will be left unchanged.This request only accepts metadata and description as arguments.
- Specified by:
update
in interfaceMetadataStore<TransferReversal>
- Throws:
StripeException
-
update
public TransferReversal update(Map<String, Object> params, RequestOptions options) throws StripeExceptionUpdates the specified reversal by setting the values of the parameters passed. Any parameters not provided will be left unchanged.This request only accepts metadata and description as arguments.
- Specified by:
update
in interfaceMetadataStore<TransferReversal>
- Throws:
StripeException
-
update
Updates the specified reversal by setting the values of the parameters passed. Any parameters not provided will be left unchanged.This request only accepts metadata and description as arguments.
- Throws:
StripeException
-
update
public TransferReversal update(TransferReversalUpdateParams params, RequestOptions options) throws StripeException Updates the specified reversal by setting the values of the parameters passed. Any parameters not provided will be left unchanged.This request only accepts metadata and description as arguments.
- Throws:
StripeException
-
setResponseGetter
Description copied from interface:StripeActiveObject
Method is used by the containing object orStripeResponseGetter
implementations to set theStripeResponseGetter
instance used to make further requests.- Specified by:
setResponseGetter
in interfaceStripeActiveObject
- Overrides:
setResponseGetter
in classApiResource
- Parameters:
responseGetter
- theStripeResponseGetter
instance to use for making further requests.
-
getAmount
Amount, in cents (or local equivalent). -
getCreated
Time at which the object was created. Measured in seconds since the Unix epoch. -
getCurrency
Three-letter ISO currency code, in lowercase. Must be a supported currency. -
getObject
String representing the object's type. Objects of the same type share the same value.Equal to
transfer_reversal
. -
setAmount
Amount, in cents (or local equivalent). -
setCreated
Time at which the object was created. Measured in seconds since the Unix epoch. -
setCurrency
Three-letter ISO currency code, in lowercase. Must be a supported currency. -
setId
Unique identifier for the object. -
setMetadata
Set of key-value pairs that you can attach to an object. This can be useful for storing additional information about the object in a structured format. -
setObject
String representing the object's type. Objects of the same type share the same value.Equal to
transfer_reversal
. -
equals
-
canEqual
-
hashCode
public int hashCode() -
getId
Unique identifier for the object. -
getMetadata
Set of key-value pairs that you can attach to an object. This can be useful for storing additional information about the object in a structured format.- Specified by:
getMetadata
in interfaceMetadataStore<TransferReversal>
-