Class Charge
- All Implemented Interfaces:
BalanceTransactionSource,HasId,MetadataStore<Charge>,StripeObjectInterface
Charge object. You can retrieve and
refund individual charges as well as list all charges. Charges are identified by a unique, random
ID.
Related guide: Accept a payment with the Charges API.
-
Nested Class Summary
Nested ClassesModifier and TypeClassDescriptionstatic classstatic classstatic classstatic classstatic classstatic classThe predicate to evaluate the payment against.static classOptions to configure Radar.static classNested classes/interfaces inherited from class com.stripe.net.ApiResource
ApiResource.RequestMethod -
Field Summary
Fields inherited from class com.stripe.net.ApiResource
CHARSET, GSONFields inherited from class com.stripe.model.StripeObject
PRETTY_PRINT_GSON -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionprotected booleancapture()Capture the payment of an existing, uncaptured, charge.capture(RequestOptions options) Capture the payment of an existing, uncaptured, charge.capture(ChargeCaptureParams params) Capture the payment of an existing, uncaptured, charge.capture(ChargeCaptureParams params, RequestOptions options) Capture the payment of an existing, uncaptured, charge.Capture the payment of an existing, uncaptured, charge.capture(Map<String, Object> params, RequestOptions options) Capture the payment of an existing, uncaptured, charge.static Chargecreate(ChargeCreateParams params) To charge a credit card or other payment source, you create aChargeobject.static Chargecreate(ChargeCreateParams params, RequestOptions options) To charge a credit card or other payment source, you create aChargeobject.static ChargeTo charge a credit card or other payment source, you create aChargeobject.static Chargecreate(Map<String, Object> params, RequestOptions options) To charge a credit card or other payment source, you create aChargeobject.booleanAmount intended to be collected by this payment.Amount in %s captured (can be less than the amount attribute on the charge if a partial capture was made).Amount in %s refunded (can be less than the amount attribute on the charge if a partial refund was issued).Get ID of expandableapplicationobject.Get ID of expandableapplicationFeeobject.The amount of the application fee (if any) requested for the charge.Get expandedapplicationFee.Get expandedapplication.Authorization code on the charge.Get ID of expandablebalanceTransactionobject.Get expandedbalanceTransaction.The full statement descriptor that is passed to card networks, and that is displayed on your customers' credit card and bank statements.If the charge was created without capturing, this Boolean represents whether it is still uncaptured or has since been captured.Time at which the object was created.Three-letter ISO currency code, in lowercase.Get ID of expandablecustomerobject.Get expandedcustomer.An arbitrary string attached to the object.Get ID of expandabledestinationobject.Get expandeddestination.Get ID of expandabledisputeobject.Whether the charge has been disputed.Get expandeddispute.Get ID of expandablefailureBalanceTransactionobject.Get expandedfailureBalanceTransaction.Error code explaining reason for charge failure if available (see the errors section for a list of codes).Message to user further explaining reason for charge failure if available.Information on fraud assessments for the charge.getId()Unique identifier for the object.Get ID of expandableinvoiceobject.Get expandedinvoice.Has the valuetrueif the object exists in live mode or the valuefalseif the object exists in test mode.Set of key-value pairs that you can attach to an object.String representing the object's type.Get ID of expandableonBehalfOfobject.Get expandedonBehalfOf.Details about whether the payment was accepted, and why.getPaid()trueif the charge succeeded, or was successfully authorized for later capture.Get ID of expandablepaymentIntentobject.Get expandedpaymentIntent.ID of the payment method used in this charge.Details about the payment method at the time of the transaction.Options to configure Radar.This is the email address that the receipt for this charge was sent to.This is the transaction number that appears on email receipts sent for this charge.This is the URL to view the receipt for this charge.Whether the charge has been fully refunded.A list of refunds that have been applied to the charge.Get ID of expandablereviewobject.Get expandedreview.Shipping information for the charge.This is a legacy field that will be removed in the future.Get ID of expandablesourceTransferobject.Get expandedsourceTransfer.For card charges, usestatement_descriptor_suffixinstead.Provides information about the charge that customers see on their statements.The status of the payment is eithersucceeded,pending, orfailed.Get ID of expandabletransferobject.An optional dictionary including the account to automatically transfer to as part of a destination charge.A string that identifies this transaction as part of a group.Get expandedtransfer.inthashCode()static ChargeCollectionlist(ChargeListParams params) Returns a list of charges you’ve previously created.static ChargeCollectionlist(ChargeListParams params, RequestOptions options) Returns a list of charges you’ve previously created.static ChargeCollectionReturns a list of charges you’ve previously created.static ChargeCollectionlist(Map<String, Object> params, RequestOptions options) Returns a list of charges you’ve previously created.static ChargeRetrieves the details of a charge that has previously been created.static Chargeretrieve(String charge, RequestOptions options) Retrieves the details of a charge that has previously been created.static Chargeretrieve(String charge, ChargeRetrieveParams params, RequestOptions options) Retrieves the details of a charge that has previously been created.static ChargeRetrieves the details of a charge that has previously been created.static ChargeSearchResultsearch(ChargeSearchParams params) Search for charges you’ve previously created using Stripe’s Search Query Language.static ChargeSearchResultsearch(ChargeSearchParams params, RequestOptions options) Search for charges you’ve previously created using Stripe’s Search Query Language.static ChargeSearchResultSearch for charges you’ve previously created using Stripe’s Search Query Language.static ChargeSearchResultsearch(Map<String, Object> params, RequestOptions options) Search for charges you’ve previously created using Stripe’s Search Query Language.voidsetAlternateStatementDescriptors(Charge.AlternateStatementDescriptors alternateStatementDescriptors) voidAmount intended to be collected by this payment.voidsetAmountCaptured(Long amountCaptured) Amount in %s captured (can be less than the amount attribute on the charge if a partial capture was made).voidsetAmountRefunded(Long amountRefunded) Amount in %s refunded (can be less than the amount attribute on the charge if a partial refund was issued).voidsetApplication(String id) voidvoidsetApplicationFeeAmount(Long applicationFeeAmount) The amount of the application fee (if any) requested for the charge.voidsetApplicationFeeObject(ApplicationFee expandableObject) voidsetApplicationObject(Application expandableObject) voidsetAuthorizationCode(String authorizationCode) Authorization code on the charge.voidvoidsetBalanceTransactionObject(BalanceTransaction expandableObject) voidsetBillingDetails(Charge.BillingDetails billingDetails) voidsetCalculatedStatementDescriptor(String calculatedStatementDescriptor) The full statement descriptor that is passed to card networks, and that is displayed on your customers' credit card and bank statements.voidsetCaptured(Boolean captured) If the charge was created without capturing, this Boolean represents whether it is still uncaptured or has since been captured.voidsetCreated(Long created) Time at which the object was created.voidsetCurrency(String currency) Three-letter ISO currency code, in lowercase.voidsetCustomer(String id) voidsetCustomerObject(Customer expandableObject) voidsetDescription(String description) An arbitrary string attached to the object.voidsetDestination(String id) voidsetDestinationObject(Account expandableObject) voidsetDispute(String id) voidsetDisputed(Boolean disputed) Whether the charge has been disputed.voidsetDisputeObject(Dispute expandableObject) voidvoidsetFailureBalanceTransactionObject(BalanceTransaction expandableObject) voidsetFailureCode(String failureCode) Error code explaining reason for charge failure if available (see the errors section for a list of codes).voidsetFailureMessage(String failureMessage) Message to user further explaining reason for charge failure if available.voidsetFraudDetails(Charge.FraudDetails fraudDetails) Information on fraud assessments for the charge.voidUnique identifier for the object.voidsetInvoice(String id) voidsetInvoiceObject(Invoice expandableObject) voidsetLevel3(Charge.Level3 level3) voidsetLivemode(Boolean livemode) Has the valuetrueif the object exists in live mode or the valuefalseif the object exists in test mode.voidsetMetadata(Map<String, String> metadata) Set of key-value pairs that you can attach to an object.voidString representing the object's type.voidsetOnBehalfOf(String id) voidsetOnBehalfOfObject(Account expandableObject) voidsetOutcome(Charge.Outcome outcome) Details about whether the payment was accepted, and why.voidtrueif the charge succeeded, or was successfully authorized for later capture.voidvoidsetPaymentIntentObject(PaymentIntent expandableObject) voidsetPaymentMethod(String paymentMethod) ID of the payment method used in this charge.voidsetPaymentMethodDetails(Charge.PaymentMethodDetails paymentMethodDetails) Details about the payment method at the time of the transaction.voidsetRadarOptions(Charge.RadarOptions radarOptions) Options to configure Radar.voidsetReceiptEmail(String receiptEmail) This is the email address that the receipt for this charge was sent to.voidsetReceiptNumber(String receiptNumber) This is the transaction number that appears on email receipts sent for this charge.voidsetReceiptUrl(String receiptUrl) This is the URL to view the receipt for this charge.voidsetRefunded(Boolean refunded) Whether the charge has been fully refunded.voidsetRefunds(RefundCollection refunds) A list of refunds that have been applied to the charge.voidvoidsetReviewObject(Review expandableObject) voidsetShipping(ShippingDetails shipping) Shipping information for the charge.voidsetSource(PaymentSource source) This is a legacy field that will be removed in the future.voidvoidsetSourceTransferObject(Transfer expandableObject) voidsetStatementDescriptor(String statementDescriptor) For card charges, usestatement_descriptor_suffixinstead.voidsetStatementDescriptorSuffix(String statementDescriptorSuffix) Provides information about the charge that customers see on their statements.voidThe status of the payment is eithersucceeded,pending, orfailed.voidsetTransfer(String id) voidsetTransferData(Charge.TransferData transferData) An optional dictionary including the account to automatically transfer to as part of a destination charge.voidsetTransferGroup(String transferGroup) A string that identifies this transaction as part of a group.voidsetTransferObject(Transfer expandableObject) update(ChargeUpdateParams params) Updates the specified charge by setting the values of the parameters passed.update(ChargeUpdateParams params, RequestOptions options) Updates the specified charge by setting the values of the parameters passed.Updates the specified charge by setting the values of the parameters passed.update(Map<String, Object> params, RequestOptions options) Updates the specified charge 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, urlEncodeIdMethods inherited from class com.stripe.model.StripeObject
equals, getLastResponse, getRawJsonObject, setLastResponse, toJson, toStringMethods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, wait, wait, waitMethods inherited from interface com.stripe.model.StripeObjectInterface
getLastResponse, setLastResponse
-
Constructor Details
-
Charge
public Charge()
-
-
Method Details
-
getApplication
Get ID of expandableapplicationobject. -
setApplication
-
getApplicationObject
Get expandedapplication. -
setApplicationObject
-
getApplicationFee
Get ID of expandableapplicationFeeobject. -
setApplicationFee
-
getApplicationFeeObject
Get expandedapplicationFee. -
setApplicationFeeObject
-
getBalanceTransaction
Get ID of expandablebalanceTransactionobject. -
setBalanceTransaction
-
getBalanceTransactionObject
Get expandedbalanceTransaction. -
setBalanceTransactionObject
-
getCustomer
Get ID of expandablecustomerobject. -
setCustomer
-
getCustomerObject
Get expandedcustomer. -
setCustomerObject
-
getDestination
Get ID of expandabledestinationobject. -
setDestination
-
getDestinationObject
Get expandeddestination. -
setDestinationObject
-
getDispute
Get ID of expandabledisputeobject. -
setDispute
-
getDisputeObject
Get expandeddispute. -
setDisputeObject
-
getFailureBalanceTransaction
Get ID of expandablefailureBalanceTransactionobject. -
setFailureBalanceTransaction
-
getFailureBalanceTransactionObject
Get expandedfailureBalanceTransaction. -
setFailureBalanceTransactionObject
-
getInvoice
Get ID of expandableinvoiceobject. -
setInvoice
-
getInvoiceObject
Get expandedinvoice. -
setInvoiceObject
-
getOnBehalfOf
Get ID of expandableonBehalfOfobject. -
setOnBehalfOf
-
getOnBehalfOfObject
Get expandedonBehalfOf. -
setOnBehalfOfObject
-
getPaymentIntent
Get ID of expandablepaymentIntentobject. -
setPaymentIntent
-
getPaymentIntentObject
Get expandedpaymentIntent. -
setPaymentIntentObject
-
getReview
Get ID of expandablereviewobject. -
setReview
-
getReviewObject
Get expandedreview. -
setReviewObject
-
getSourceTransfer
Get ID of expandablesourceTransferobject. -
setSourceTransfer
-
getSourceTransferObject
Get expandedsourceTransfer. -
setSourceTransferObject
-
getTransfer
Get ID of expandabletransferobject. -
setTransfer
-
getTransferObject
Get expandedtransfer. -
setTransferObject
-
capture
Capture the payment of an existing, uncaptured, charge. This is the second half of the two-step payment flow, where first you created a charge with the capture option set to false.Uncaptured payments expire a set number of days after they are created (7 by default). If they are not captured by that point in time, they will be marked as refunded and will no longer be capturable.
- Throws:
StripeException
-
capture
Capture the payment of an existing, uncaptured, charge. This is the second half of the two-step payment flow, where first you created a charge with the capture option set to false.Uncaptured payments expire a set number of days after they are created (7 by default). If they are not captured by that point in time, they will be marked as refunded and will no longer be capturable.
- Throws:
StripeException
-
capture
Capture the payment of an existing, uncaptured, charge. This is the second half of the two-step payment flow, where first you created a charge with the capture option set to false.Uncaptured payments expire a set number of days after they are created (7 by default). If they are not captured by that point in time, they will be marked as refunded and will no longer be capturable.
- Throws:
StripeException
-
capture
Capture the payment of an existing, uncaptured, charge. This is the second half of the two-step payment flow, where first you created a charge with the capture option set to false.Uncaptured payments expire a set number of days after they are created (7 by default). If they are not captured by that point in time, they will be marked as refunded and will no longer be capturable.
- Throws:
StripeException
-
capture
Capture the payment of an existing, uncaptured, charge. This is the second half of the two-step payment flow, where first you created a charge with the capture option set to false.Uncaptured payments expire a set number of days after they are created (7 by default). If they are not captured by that point in time, they will be marked as refunded and will no longer be capturable.
- Throws:
StripeException
-
capture
Capture the payment of an existing, uncaptured, charge. This is the second half of the two-step payment flow, where first you created a charge with the capture option set to false.Uncaptured payments expire a set number of days after they are created (7 by default). If they are not captured by that point in time, they will be marked as refunded and will no longer be capturable.
- Throws:
StripeException
-
create
To charge a credit card or other payment source, you create aChargeobject. If your API key is in test mode, the supplied payment source (e.g., card) won’t actually be charged, although everything else will occur as if in live mode. (Stripe assumes that the charge would have completed successfully).- Throws:
StripeException
-
create
public static Charge create(Map<String, Object> params, RequestOptions options) throws StripeExceptionTo charge a credit card or other payment source, you create aChargeobject. If your API key is in test mode, the supplied payment source (e.g., card) won’t actually be charged, although everything else will occur as if in live mode. (Stripe assumes that the charge would have completed successfully).- Throws:
StripeException
-
create
To charge a credit card or other payment source, you create aChargeobject. If your API key is in test mode, the supplied payment source (e.g., card) won’t actually be charged, although everything else will occur as if in live mode. (Stripe assumes that the charge would have completed successfully).- Throws:
StripeException
-
create
public static Charge create(ChargeCreateParams params, RequestOptions options) throws StripeException To charge a credit card or other payment source, you create aChargeobject. If your API key is in test mode, the supplied payment source (e.g., card) won’t actually be charged, although everything else will occur as if in live mode. (Stripe assumes that the charge would have completed successfully).- Throws:
StripeException
-
list
Returns a list of charges you’ve previously created. The charges are returned in sorted order, with the most recent charges appearing first.- Throws:
StripeException
-
list
public static ChargeCollection list(Map<String, Object> params, RequestOptions options) throws StripeExceptionReturns a list of charges you’ve previously created. The charges are returned in sorted order, with the most recent charges appearing first.- Throws:
StripeException
-
list
Returns a list of charges you’ve previously created. The charges are returned in sorted order, with the most recent charges appearing first.- Throws:
StripeException
-
list
public static ChargeCollection list(ChargeListParams params, RequestOptions options) throws StripeException Returns a list of charges you’ve previously created. The charges are returned in sorted order, with the most recent charges appearing first.- Throws:
StripeException
-
retrieve
Retrieves the details of a charge that has previously been created. Supply the unique charge ID that was returned from your previous request, and Stripe will return the corresponding charge information. The same information is returned when creating or refunding the charge.- Throws:
StripeException
-
retrieve
Retrieves the details of a charge that has previously been created. Supply the unique charge ID that was returned from your previous request, and Stripe will return the corresponding charge information. The same information is returned when creating or refunding the charge.- Throws:
StripeException
-
retrieve
public static Charge retrieve(String charge, Map<String, Object> params, RequestOptions options) throws StripeExceptionRetrieves the details of a charge that has previously been created. Supply the unique charge ID that was returned from your previous request, and Stripe will return the corresponding charge information. The same information is returned when creating or refunding the charge.- Throws:
StripeException
-
retrieve
public static Charge retrieve(String charge, ChargeRetrieveParams params, RequestOptions options) throws StripeException Retrieves the details of a charge that has previously been created. Supply the unique charge ID that was returned from your previous request, and Stripe will return the corresponding charge information. The same information is returned when creating or refunding the charge.- Throws:
StripeException
-
search
Search for charges you’ve previously created using Stripe’s Search Query Language. Don’t use search in read-after-write flows where strict consistency is necessary. Under normal operating conditions, data is searchable in less than a minute. Occasionally, propagation of new or updated data can be up to an hour behind during outages. Search functionality is not available to merchants in India.- Throws:
StripeException
-
search
public static ChargeSearchResult search(Map<String, Object> params, RequestOptions options) throws StripeExceptionSearch for charges you’ve previously created using Stripe’s Search Query Language. Don’t use search in read-after-write flows where strict consistency is necessary. Under normal operating conditions, data is searchable in less than a minute. Occasionally, propagation of new or updated data can be up to an hour behind during outages. Search functionality is not available to merchants in India.- Throws:
StripeException
-
search
Search for charges you’ve previously created using Stripe’s Search Query Language. Don’t use search in read-after-write flows where strict consistency is necessary. Under normal operating conditions, data is searchable in less than a minute. Occasionally, propagation of new or updated data can be up to an hour behind during outages. Search functionality is not available to merchants in India.- Throws:
StripeException
-
search
public static ChargeSearchResult search(ChargeSearchParams params, RequestOptions options) throws StripeException Search for charges you’ve previously created using Stripe’s Search Query Language. Don’t use search in read-after-write flows where strict consistency is necessary. Under normal operating conditions, data is searchable in less than a minute. Occasionally, propagation of new or updated data can be up to an hour behind during outages. Search functionality is not available to merchants in India.- Throws:
StripeException
-
update
Updates the specified charge by setting the values of the parameters passed. Any parameters not provided will be left unchanged.- Specified by:
updatein interfaceMetadataStore<Charge>- Throws:
StripeException
-
update
Updates the specified charge by setting the values of the parameters passed. Any parameters not provided will be left unchanged.- Specified by:
updatein interfaceMetadataStore<Charge>- Throws:
StripeException
-
update
Updates the specified charge by setting the values of the parameters passed. Any parameters not provided will be left unchanged.- Throws:
StripeException
-
update
Updates the specified charge by setting the values of the parameters passed. Any parameters not provided will be left unchanged.- Throws:
StripeException
-
getAlternateStatementDescriptors
-
getAmount
Amount intended to be collected by this payment. A positive integer representing how much to charge in the smallest currency unit (e.g., 100 cents to charge $1.00 or 100 to charge ¥100, a zero-decimal currency). The minimum amount is $0.50 US or equivalent in charge currency. The amount value supports up to eight digits (e.g., a value of 99999999 for a USD charge of $999,999.99). -
getAmountCaptured
Amount in %s captured (can be less than the amount attribute on the charge if a partial capture was made). -
getAmountRefunded
Amount in %s refunded (can be less than the amount attribute on the charge if a partial refund was issued). -
getApplicationFeeAmount
The amount of the application fee (if any) requested for the charge. See the Connect documentation for details. -
getAuthorizationCode
Authorization code on the charge. -
getBillingDetails
-
getCalculatedStatementDescriptor
The full statement descriptor that is passed to card networks, and that is displayed on your customers' credit card and bank statements. Allows you to see what the statement descriptor looks like after the static and dynamic portions are combined. -
getCaptured
If the charge was created without capturing, this Boolean represents whether it is still uncaptured or has since been captured. -
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. -
getDescription
An arbitrary string attached to the object. Often useful for displaying to users. -
getDisputed
Whether the charge has been disputed. -
getFailureCode
Error code explaining reason for charge failure if available (see the errors section for a list of codes). -
getFailureMessage
Message to user further explaining reason for charge failure if available. -
getFraudDetails
Information on fraud assessments for the charge. -
getLevel3
-
getLivemode
Has the valuetrueif the object exists in live mode or the valuefalseif the object exists in test mode. -
getObject
String representing the object's type. Objects of the same type share the same value.Equal to
charge. -
getOutcome
Details about whether the payment was accepted, and why. See understanding declines for details. -
getPaid
trueif the charge succeeded, or was successfully authorized for later capture. -
getPaymentMethod
ID of the payment method used in this charge. -
getPaymentMethodDetails
Details about the payment method at the time of the transaction. -
getRadarOptions
Options to configure Radar. See Radar Session for more information. -
getReceiptEmail
This is the email address that the receipt for this charge was sent to. -
getReceiptNumber
This is the transaction number that appears on email receipts sent for this charge. This attribute will benulluntil a receipt has been sent. -
getReceiptUrl
This is the URL to view the receipt for this charge. The receipt is kept up-to-date to the latest state of the charge, including any refunds. If the charge is for an Invoice, the receipt will be stylized as an Invoice receipt. -
getRefunded
Whether the charge has been fully refunded. If the charge is only partially refunded, this attribute will still be false. -
getRefunds
A list of refunds that have been applied to the charge. -
getShipping
Shipping information for the charge. -
getSource
This is a legacy field that will be removed in the future. It contains the Source, Card, or BankAccount object used for the charge. For details about the payment method used for this charge, refer topayment_methodorpayment_method_detailsinstead. -
getStatementDescriptor
For card charges, usestatement_descriptor_suffixinstead. Otherwise, you can use this value as the complete description of a charge on your customers’ statements. Must contain at least one letter, maximum 22 characters. -
getStatementDescriptorSuffix
Provides information about the charge that customers see on their statements. Concatenated with the prefix (shortened descriptor) or statement descriptor that’s set on the account to form the complete statement descriptor. Maximum 22 characters for the concatenated descriptor. -
getStatus
The status of the payment is eithersucceeded,pending, orfailed.One of
failed,pending, orsucceeded. -
getTransferData
An optional dictionary including the account to automatically transfer to as part of a destination charge. See the Connect documentation for details. -
getTransferGroup
A string that identifies this transaction as part of a group. See the Connect documentation for details. -
setAlternateStatementDescriptors
public void setAlternateStatementDescriptors(Charge.AlternateStatementDescriptors alternateStatementDescriptors) -
setAmount
Amount intended to be collected by this payment. A positive integer representing how much to charge in the smallest currency unit (e.g., 100 cents to charge $1.00 or 100 to charge ¥100, a zero-decimal currency). The minimum amount is $0.50 US or equivalent in charge currency. The amount value supports up to eight digits (e.g., a value of 99999999 for a USD charge of $999,999.99). -
setAmountCaptured
Amount in %s captured (can be less than the amount attribute on the charge if a partial capture was made). -
setAmountRefunded
Amount in %s refunded (can be less than the amount attribute on the charge if a partial refund was issued). -
setApplicationFeeAmount
The amount of the application fee (if any) requested for the charge. See the Connect documentation for details. -
setAuthorizationCode
Authorization code on the charge. -
setBillingDetails
-
setCalculatedStatementDescriptor
The full statement descriptor that is passed to card networks, and that is displayed on your customers' credit card and bank statements. Allows you to see what the statement descriptor looks like after the static and dynamic portions are combined. -
setCaptured
If the charge was created without capturing, this Boolean represents whether it is still uncaptured or has since been captured. -
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. -
setDescription
An arbitrary string attached to the object. Often useful for displaying to users. -
setDisputed
Whether the charge has been disputed. -
setFailureCode
Error code explaining reason for charge failure if available (see the errors section for a list of codes). -
setFailureMessage
Message to user further explaining reason for charge failure if available. -
setFraudDetails
Information on fraud assessments for the charge. -
setId
Unique identifier for the object. -
setLevel3
-
setLivemode
Has the valuetrueif the object exists in live mode or the valuefalseif the object exists in test mode. -
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
charge. -
setOutcome
Details about whether the payment was accepted, and why. See understanding declines for details. -
setPaid
trueif the charge succeeded, or was successfully authorized for later capture. -
setPaymentMethod
ID of the payment method used in this charge. -
setPaymentMethodDetails
Details about the payment method at the time of the transaction. -
setRadarOptions
Options to configure Radar. See Radar Session for more information. -
setReceiptEmail
This is the email address that the receipt for this charge was sent to. -
setReceiptNumber
This is the transaction number that appears on email receipts sent for this charge. This attribute will benulluntil a receipt has been sent. -
setReceiptUrl
This is the URL to view the receipt for this charge. The receipt is kept up-to-date to the latest state of the charge, including any refunds. If the charge is for an Invoice, the receipt will be stylized as an Invoice receipt. -
setRefunded
Whether the charge has been fully refunded. If the charge is only partially refunded, this attribute will still be false. -
setRefunds
A list of refunds that have been applied to the charge. -
setShipping
Shipping information for the charge. -
setSource
This is a legacy field that will be removed in the future. It contains the Source, Card, or BankAccount object used for the charge. For details about the payment method used for this charge, refer topayment_methodorpayment_method_detailsinstead. -
setStatementDescriptor
For card charges, usestatement_descriptor_suffixinstead. Otherwise, you can use this value as the complete description of a charge on your customers’ statements. Must contain at least one letter, maximum 22 characters. -
setStatementDescriptorSuffix
Provides information about the charge that customers see on their statements. Concatenated with the prefix (shortened descriptor) or statement descriptor that’s set on the account to form the complete statement descriptor. Maximum 22 characters for the concatenated descriptor. -
setStatus
The status of the payment is eithersucceeded,pending, orfailed.One of
failed,pending, orsucceeded. -
setTransferData
An optional dictionary including the account to automatically transfer to as part of a destination charge. See the Connect documentation for details. -
setTransferGroup
A string that identifies this transaction as part of a group. See the Connect documentation for details. -
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:
getMetadatain interfaceMetadataStore<Charge>
-