Package com.stripe.model
Class Transfer
- java.lang.Object
-
- com.stripe.model.StripeObject
-
- com.stripe.net.ApiResource
-
- com.stripe.model.Transfer
-
- All Implemented Interfaces:
BalanceTransactionSource
,HasId
,MetadataStore<Transfer>
,StripeObjectInterface
public class Transfer extends ApiResource implements MetadataStore<Transfer>, BalanceTransactionSource
-
-
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
-
Fields inherited from class com.stripe.model.StripeObject
PRETTY_PRINT_GSON
-
-
Constructor Summary
Constructors Constructor Description Transfer()
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description protected boolean
canEqual(java.lang.Object other)
static Transfer
create(TransferCreateParams params)
To send funds from your Stripe account to a connected account, you create a new transfer object.static Transfer
create(TransferCreateParams params, RequestOptions options)
To send funds from your Stripe account to a connected account, you create a new transfer object.static Transfer
create(java.util.Map<java.lang.String,java.lang.Object> params)
To send funds from your Stripe account to a connected account, you create a new transfer object.static Transfer
create(java.util.Map<java.lang.String,java.lang.Object> params, RequestOptions options)
To send funds from your Stripe account to a connected account, you create a new transfer object.boolean
equals(java.lang.Object o)
java.lang.Long
getAmount()
Amount in %s to be transferred.java.lang.Long
getAmountReversed()
Amount in %s reversed (can be less than the amount attribute on the transfer if a partial reversal was issued).java.lang.String
getBalanceTransaction()
Get ID of expandablebalanceTransaction
object.BalanceTransaction
getBalanceTransactionObject()
Get expandedbalanceTransaction
.java.lang.Long
getCreated()
Time that this record of the transfer was first created.java.lang.String
getCurrency()
Three-letter ISO currency code, in lowercase.java.lang.String
getDescription()
An arbitrary string attached to the object.java.lang.String
getDestination()
Get ID of expandabledestination
object.Account
getDestinationObject()
Get expandeddestination
.java.lang.String
getDestinationPayment()
Get ID of expandabledestinationPayment
object.Charge
getDestinationPaymentObject()
Get expandeddestinationPayment
.java.lang.String
getId()
Unique identifier for the object.java.lang.Boolean
getLivemode()
Has the valuetrue
if the object exists in live mode or the valuefalse
if the object exists in test mode.java.util.Map<java.lang.String,java.lang.String>
getMetadata()
Set of key-value pairs that you can attach to an object.java.lang.String
getObject()
String representing the object's type.TransferReversalCollection
getReversals()
A list of reversals that have been applied to the transfer.java.lang.Boolean
getReversed()
Whether the transfer has been fully reversed.java.lang.String
getSourceTransaction()
Get ID of expandablesourceTransaction
object.Charge
getSourceTransactionObject()
Get expandedsourceTransaction
.java.lang.String
getSourceType()
The source balance this transfer came from.java.lang.String
getTransferGroup()
A string that identifies this transaction as part of a group.int
hashCode()
static TransferCollection
list(TransferListParams params)
Returns a list of existing transfers sent to connected accounts.static TransferCollection
list(TransferListParams params, RequestOptions options)
Returns a list of existing transfers sent to connected accounts.static TransferCollection
list(java.util.Map<java.lang.String,java.lang.Object> params)
Returns a list of existing transfers sent to connected accounts.static TransferCollection
list(java.util.Map<java.lang.String,java.lang.Object> params, RequestOptions options)
Returns a list of existing transfers sent to connected accounts.static Transfer
retrieve(java.lang.String transfer)
Retrieves the details of an existing transfer.static Transfer
retrieve(java.lang.String transfer, RequestOptions options)
Retrieves the details of an existing transfer.static Transfer
retrieve(java.lang.String transfer, TransferRetrieveParams params, RequestOptions options)
Retrieves the details of an existing transfer.static Transfer
retrieve(java.lang.String transfer, java.util.Map<java.lang.String,java.lang.Object> params, RequestOptions options)
Retrieves the details of an existing transfer.void
setAmount(java.lang.Long amount)
Amount in %s to be transferred.void
setAmountReversed(java.lang.Long amountReversed)
Amount in %s reversed (can be less than the amount attribute on the transfer if a partial reversal was issued).void
setBalanceTransaction(java.lang.String id)
void
setBalanceTransactionObject(BalanceTransaction expandableObject)
void
setCreated(java.lang.Long created)
Time that this record of the transfer was first created.void
setCurrency(java.lang.String currency)
Three-letter ISO currency code, in lowercase.void
setDescription(java.lang.String description)
An arbitrary string attached to the object.void
setDestination(java.lang.String id)
void
setDestinationObject(Account expandableObject)
void
setDestinationPayment(java.lang.String id)
void
setDestinationPaymentObject(Charge expandableObject)
void
setId(java.lang.String id)
Unique identifier for the object.void
setLivemode(java.lang.Boolean livemode)
Has the valuetrue
if the object exists in live mode or the valuefalse
if the object exists in test mode.void
setMetadata(java.util.Map<java.lang.String,java.lang.String> metadata)
Set of key-value pairs that you can attach to an object.void
setObject(java.lang.String object)
String representing the object's type.void
setReversals(TransferReversalCollection reversals)
A list of reversals that have been applied to the transfer.void
setReversed(java.lang.Boolean reversed)
Whether the transfer has been fully reversed.void
setSourceTransaction(java.lang.String id)
void
setSourceTransactionObject(Charge expandableObject)
void
setSourceType(java.lang.String sourceType)
The source balance this transfer came from.void
setTransferGroup(java.lang.String transferGroup)
A string that identifies this transaction as part of a group.Transfer
update(TransferUpdateParams params)
Updates the specified transfer by setting the values of the parameters passed.Transfer
update(TransferUpdateParams params, RequestOptions options)
Updates the specified transfer by setting the values of the parameters passed.Transfer
update(java.util.Map<java.lang.String,java.lang.Object> params)
Updates the specified transfer by setting the values of the parameters passed.Transfer
update(java.util.Map<java.lang.String,java.lang.Object> params, RequestOptions options)
Updates the specified transfer by setting the values of the parameters passed.-
Methods inherited from class com.stripe.net.ApiResource
checkNullTypedParams, classUrl, classUrl, instanceUrl, instanceUrl, request, request, requestCollection, requestCollection, requestSearchResult, requestSearchResult, requestStream, requestStream, setExpandableFieldId, setStripeResponseGetter, singleClassUrl, singleClassUrl, subresourceUrl, urlEncode, urlEncodeId
-
Methods inherited from class com.stripe.model.StripeObject
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.StripeObjectInterface
getLastResponse, setLastResponse
-
-
-
-
Method Detail
-
getBalanceTransaction
public java.lang.String getBalanceTransaction()
Get ID of expandablebalanceTransaction
object.
-
setBalanceTransaction
public void setBalanceTransaction(java.lang.String id)
-
getBalanceTransactionObject
public BalanceTransaction getBalanceTransactionObject()
Get expandedbalanceTransaction
.
-
setBalanceTransactionObject
public void setBalanceTransactionObject(BalanceTransaction expandableObject)
-
getDestination
public java.lang.String getDestination()
Get ID of expandabledestination
object.
-
setDestination
public void setDestination(java.lang.String id)
-
getDestinationObject
public Account getDestinationObject()
Get expandeddestination
.
-
setDestinationObject
public void setDestinationObject(Account expandableObject)
-
getDestinationPayment
public java.lang.String getDestinationPayment()
Get ID of expandabledestinationPayment
object.
-
setDestinationPayment
public void setDestinationPayment(java.lang.String id)
-
getDestinationPaymentObject
public Charge getDestinationPaymentObject()
Get expandeddestinationPayment
.
-
setDestinationPaymentObject
public void setDestinationPaymentObject(Charge expandableObject)
-
getSourceTransaction
public java.lang.String getSourceTransaction()
Get ID of expandablesourceTransaction
object.
-
setSourceTransaction
public void setSourceTransaction(java.lang.String id)
-
getSourceTransactionObject
public Charge getSourceTransactionObject()
Get expandedsourceTransaction
.
-
setSourceTransactionObject
public void setSourceTransactionObject(Charge expandableObject)
-
create
public static Transfer create(java.util.Map<java.lang.String,java.lang.Object> params) throws StripeException
To send funds from your Stripe account to a connected account, you create a new transfer object. Your Stripe balance must be able to cover the transfer amount, or you’ll receive an “Insufficient Funds” error.- Throws:
StripeException
-
create
public static Transfer create(java.util.Map<java.lang.String,java.lang.Object> params, RequestOptions options) throws StripeException
To send funds from your Stripe account to a connected account, you create a new transfer object. Your Stripe balance must be able to cover the transfer amount, or you’ll receive an “Insufficient Funds” error.- Throws:
StripeException
-
create
public static Transfer create(TransferCreateParams params) throws StripeException
To send funds from your Stripe account to a connected account, you create a new transfer object. Your Stripe balance must be able to cover the transfer amount, or you’ll receive an “Insufficient Funds” error.- Throws:
StripeException
-
create
public static Transfer create(TransferCreateParams params, RequestOptions options) throws StripeException
To send funds from your Stripe account to a connected account, you create a new transfer object. Your Stripe balance must be able to cover the transfer amount, or you’ll receive an “Insufficient Funds” error.- Throws:
StripeException
-
list
public static TransferCollection list(java.util.Map<java.lang.String,java.lang.Object> params) throws StripeException
Returns a list of existing transfers sent to connected accounts. The transfers are returned in sorted order, with the most recently created transfers appearing first.- Throws:
StripeException
-
list
public static TransferCollection list(java.util.Map<java.lang.String,java.lang.Object> params, RequestOptions options) throws StripeException
Returns a list of existing transfers sent to connected accounts. The transfers are returned in sorted order, with the most recently created transfers appearing first.- Throws:
StripeException
-
list
public static TransferCollection list(TransferListParams params) throws StripeException
Returns a list of existing transfers sent to connected accounts. The transfers are returned in sorted order, with the most recently created transfers appearing first.- Throws:
StripeException
-
list
public static TransferCollection list(TransferListParams params, RequestOptions options) throws StripeException
Returns a list of existing transfers sent to connected accounts. The transfers are returned in sorted order, with the most recently created transfers appearing first.- Throws:
StripeException
-
retrieve
public static Transfer retrieve(java.lang.String transfer) throws StripeException
Retrieves the details of an existing transfer. Supply the unique transfer ID from either a transfer creation request or the transfer list, and Stripe will return the corresponding transfer information.- Throws:
StripeException
-
retrieve
public static Transfer retrieve(java.lang.String transfer, RequestOptions options) throws StripeException
Retrieves the details of an existing transfer. Supply the unique transfer ID from either a transfer creation request or the transfer list, and Stripe will return the corresponding transfer information.- Throws:
StripeException
-
retrieve
public static Transfer retrieve(java.lang.String transfer, java.util.Map<java.lang.String,java.lang.Object> params, RequestOptions options) throws StripeException
Retrieves the details of an existing transfer. Supply the unique transfer ID from either a transfer creation request or the transfer list, and Stripe will return the corresponding transfer information.- Throws:
StripeException
-
retrieve
public static Transfer retrieve(java.lang.String transfer, TransferRetrieveParams params, RequestOptions options) throws StripeException
Retrieves the details of an existing transfer. Supply the unique transfer ID from either a transfer creation request or the transfer list, and Stripe will return the corresponding transfer information.- Throws:
StripeException
-
update
public Transfer update(java.util.Map<java.lang.String,java.lang.Object> params) throws StripeException
Updates the specified transfer by setting the values of the parameters passed. Any parameters not provided will be left unchanged.This request accepts only metadata as an argument.
- Specified by:
update
in interfaceMetadataStore<Transfer>
- Throws:
StripeException
-
update
public Transfer update(java.util.Map<java.lang.String,java.lang.Object> params, RequestOptions options) throws StripeException
Updates the specified transfer by setting the values of the parameters passed. Any parameters not provided will be left unchanged.This request accepts only metadata as an argument.
- Specified by:
update
in interfaceMetadataStore<Transfer>
- Throws:
StripeException
-
update
public Transfer update(TransferUpdateParams params) throws StripeException
Updates the specified transfer by setting the values of the parameters passed. Any parameters not provided will be left unchanged.This request accepts only metadata as an argument.
- Throws:
StripeException
-
update
public Transfer update(TransferUpdateParams params, RequestOptions options) throws StripeException
Updates the specified transfer by setting the values of the parameters passed. Any parameters not provided will be left unchanged.This request accepts only metadata as an argument.
- Throws:
StripeException
-
getAmount
public java.lang.Long getAmount()
Amount in %s to be transferred.
-
getAmountReversed
public java.lang.Long getAmountReversed()
Amount in %s reversed (can be less than the amount attribute on the transfer if a partial reversal was issued).
-
getCreated
public java.lang.Long getCreated()
Time that this record of the transfer was first created.
-
getCurrency
public java.lang.String getCurrency()
Three-letter ISO currency code, in lowercase. Must be a supported currency.
-
getDescription
public java.lang.String getDescription()
An arbitrary string attached to the object. Often useful for displaying to users.
-
getLivemode
public java.lang.Boolean getLivemode()
Has the valuetrue
if the object exists in live mode or the valuefalse
if the object exists in test mode.
-
getObject
public java.lang.String getObject()
String representing the object's type. Objects of the same type share the same value.Equal to
transfer
.
-
getReversals
public TransferReversalCollection getReversals()
A list of reversals that have been applied to the transfer.
-
getReversed
public java.lang.Boolean getReversed()
Whether the transfer has been fully reversed. If the transfer is only partially reversed, this attribute will still be false.
-
getSourceType
public java.lang.String getSourceType()
The source balance this transfer came from. One ofcard
,fpx
, orbank_account
.
-
getTransferGroup
public java.lang.String getTransferGroup()
A string that identifies this transaction as part of a group. See the Connect documentation for details.
-
setAmount
public void setAmount(java.lang.Long amount)
Amount in %s to be transferred.
-
setAmountReversed
public void setAmountReversed(java.lang.Long amountReversed)
Amount in %s reversed (can be less than the amount attribute on the transfer if a partial reversal was issued).
-
setCreated
public void setCreated(java.lang.Long created)
Time that this record of the transfer was first created.
-
setCurrency
public void setCurrency(java.lang.String currency)
Three-letter ISO currency code, in lowercase. Must be a supported currency.
-
setDescription
public void setDescription(java.lang.String description)
An arbitrary string attached to the object. Often useful for displaying to users.
-
setId
public void setId(java.lang.String id)
Unique identifier for the object.
-
setLivemode
public void setLivemode(java.lang.Boolean livemode)
Has the valuetrue
if the object exists in live mode or the valuefalse
if the object exists in test mode.
-
setMetadata
public void setMetadata(java.util.Map<java.lang.String,java.lang.String> metadata)
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
public void setObject(java.lang.String object)
String representing the object's type. Objects of the same type share the same value.Equal to
transfer
.
-
setReversals
public void setReversals(TransferReversalCollection reversals)
A list of reversals that have been applied to the transfer.
-
setReversed
public void setReversed(java.lang.Boolean reversed)
Whether the transfer has been fully reversed. If the transfer is only partially reversed, this attribute will still be false.
-
setSourceType
public void setSourceType(java.lang.String sourceType)
The source balance this transfer came from. One ofcard
,fpx
, orbank_account
.
-
setTransferGroup
public void setTransferGroup(java.lang.String transferGroup)
A string that identifies this transaction as part of a group. See the Connect documentation for details.
-
equals
public boolean equals(java.lang.Object o)
- Overrides:
equals
in classjava.lang.Object
-
canEqual
protected boolean canEqual(java.lang.Object other)
-
hashCode
public int hashCode()
- Overrides:
hashCode
in classjava.lang.Object
-
getId
public java.lang.String getId()
Unique identifier for the object.
-
getMetadata
public java.util.Map<java.lang.String,java.lang.String> 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<Transfer>
-
-