Class: Stripe::Treasury::ReceivedCredit
- Inherits:
-
APIResource
- Object
- StripeObject
- APIResource
- Stripe::Treasury::ReceivedCredit
- Extended by:
- APIOperations::List
- Defined in:
- lib/stripe/resources/treasury/received_credit.rb
Overview
ReceivedCredits represent funds sent to a [FinancialAccount](stripe.com/docs/api#financial_accounts) (for example, via ACH or wire). These money movements are not initiated from the FinancialAccount.
Defined Under Namespace
Classes: CreateParams, InitiatingPaymentMethodDetails, LinkedFlows, ListParams, NetworkDetails, ReversalDetails, TestHelpers
Constant Summary collapse
- OBJECT_NAME =
"treasury.received_credit"
Constants inherited from StripeObject
StripeObject::RESERVED_FIELD_NAMES
Instance Attribute Summary collapse
-
#amount ⇒ Object
readonly
Amount (in cents) transferred.
-
#created ⇒ Object
readonly
Time at which the object was created.
-
#currency ⇒ Object
readonly
Three-letter [ISO currency code](www.iso.org/iso-4217-currency-codes.html), in lowercase.
-
#description ⇒ Object
readonly
An arbitrary string attached to the object.
-
#failure_code ⇒ Object
readonly
Reason for the failure.
-
#financial_account ⇒ Object
readonly
The FinancialAccount that received the funds.
-
#hosted_regulatory_receipt_url ⇒ Object
readonly
A [hosted transaction receipt](stripe.com/docs/treasury/moving-money/regulatory-receipts) URL that is provided when money movement is considered regulated under Stripe’s money transmission licenses.
-
#id ⇒ Object
readonly
Unique identifier for the object.
-
#initiating_payment_method_details ⇒ Object
readonly
Attribute for field initiating_payment_method_details.
-
#linked_flows ⇒ Object
readonly
Attribute for field linked_flows.
-
#livemode ⇒ Object
readonly
Has the value ‘true` if the object exists in live mode or the value `false` if the object exists in test mode.
-
#network ⇒ Object
readonly
The rails used to send the funds.
-
#network_details ⇒ Object
readonly
Details specific to the money movement rails.
-
#object ⇒ Object
readonly
String representing the object’s type.
-
#reversal_details ⇒ Object
readonly
Details describing when a ReceivedCredit may be reversed.
-
#status ⇒ Object
readonly
Status of the ReceivedCredit.
-
#transaction ⇒ Object
readonly
The Transaction associated with this object.
Attributes inherited from APIResource
Attributes inherited from StripeObject
Class Method Summary collapse
- .field_remappings ⇒ Object
- .inner_class_types ⇒ Object
-
.list(params = {}, opts = {}) ⇒ Object
Returns a list of ReceivedCredits.
- .object_name ⇒ Object
Instance Method Summary collapse
Methods included from APIOperations::List
Methods inherited from APIResource
class_name, custom_method, #refresh, #request_stripe_object, resource_url, #resource_url, retrieve, save_nested_resource
Methods included from APIOperations::Request
Methods inherited from StripeObject
#==, #[], #[]=, #_get_inner_class_type, additive_object_param, additive_object_param?, #as_json, construct_from, #deleted?, #dirty!, #each, #eql?, #hash, #initialize, #inspect, #keys, #marshal_dump, #marshal_load, protected_fields, #serialize_params, #to_hash, #to_json, #to_s, #update_attributes, #values
Constructor Details
This class inherits a constructor from Stripe::StripeObject
Dynamic Method Handling
This class handles dynamic methods through the method_missing method in the class Stripe::StripeObject
Instance Attribute Details
#amount ⇒ Object (readonly)
Amount (in cents) transferred.
339 340 341 |
# File 'lib/stripe/resources/treasury/received_credit.rb', line 339 def amount @amount end |
#created ⇒ Object (readonly)
Time at which the object was created. Measured in seconds since the Unix epoch.
341 342 343 |
# File 'lib/stripe/resources/treasury/received_credit.rb', line 341 def created @created end |
#currency ⇒ Object (readonly)
Three-letter [ISO currency code](www.iso.org/iso-4217-currency-codes.html), in lowercase. Must be a [supported currency](stripe.com/docs/currencies).
343 344 345 |
# File 'lib/stripe/resources/treasury/received_credit.rb', line 343 def currency @currency end |
#description ⇒ Object (readonly)
An arbitrary string attached to the object. Often useful for displaying to users.
345 346 347 |
# File 'lib/stripe/resources/treasury/received_credit.rb', line 345 def description @description end |
#failure_code ⇒ Object (readonly)
Reason for the failure. A ReceivedCredit might fail because the receiving FinancialAccount is closed or frozen.
347 348 349 |
# File 'lib/stripe/resources/treasury/received_credit.rb', line 347 def failure_code @failure_code end |
#financial_account ⇒ Object (readonly)
The FinancialAccount that received the funds.
349 350 351 |
# File 'lib/stripe/resources/treasury/received_credit.rb', line 349 def financial_account @financial_account end |
#hosted_regulatory_receipt_url ⇒ Object (readonly)
A [hosted transaction receipt](stripe.com/docs/treasury/moving-money/regulatory-receipts) URL that is provided when money movement is considered regulated under Stripe’s money transmission licenses.
351 352 353 |
# File 'lib/stripe/resources/treasury/received_credit.rb', line 351 def hosted_regulatory_receipt_url @hosted_regulatory_receipt_url end |
#id ⇒ Object (readonly)
Unique identifier for the object.
353 354 355 |
# File 'lib/stripe/resources/treasury/received_credit.rb', line 353 def id @id end |
#initiating_payment_method_details ⇒ Object (readonly)
Attribute for field initiating_payment_method_details
355 356 357 |
# File 'lib/stripe/resources/treasury/received_credit.rb', line 355 def initiating_payment_method_details @initiating_payment_method_details end |
#linked_flows ⇒ Object (readonly)
Attribute for field linked_flows
357 358 359 |
# File 'lib/stripe/resources/treasury/received_credit.rb', line 357 def linked_flows @linked_flows end |
#livemode ⇒ Object (readonly)
Has the value ‘true` if the object exists in live mode or the value `false` if the object exists in test mode.
359 360 361 |
# File 'lib/stripe/resources/treasury/received_credit.rb', line 359 def livemode @livemode end |
#network ⇒ Object (readonly)
The rails used to send the funds.
361 362 363 |
# File 'lib/stripe/resources/treasury/received_credit.rb', line 361 def network @network end |
#network_details ⇒ Object (readonly)
Details specific to the money movement rails.
363 364 365 |
# File 'lib/stripe/resources/treasury/received_credit.rb', line 363 def network_details @network_details end |
#object ⇒ Object (readonly)
String representing the object’s type. Objects of the same type share the same value.
365 366 367 |
# File 'lib/stripe/resources/treasury/received_credit.rb', line 365 def object @object end |
#reversal_details ⇒ Object (readonly)
Details describing when a ReceivedCredit may be reversed.
367 368 369 |
# File 'lib/stripe/resources/treasury/received_credit.rb', line 367 def reversal_details @reversal_details end |
#status ⇒ Object (readonly)
Status of the ReceivedCredit. ReceivedCredits are created either ‘succeeded` (approved) or `failed` (declined). If a ReceivedCredit is declined, the failure reason can be found in the `failure_code` field.
369 370 371 |
# File 'lib/stripe/resources/treasury/received_credit.rb', line 369 def status @status end |
#transaction ⇒ Object (readonly)
The Transaction associated with this object.
371 372 373 |
# File 'lib/stripe/resources/treasury/received_credit.rb', line 371 def transaction @transaction end |
Class Method Details
.field_remappings ⇒ Object
413 414 415 |
# File 'lib/stripe/resources/treasury/received_credit.rb', line 413 def self.field_remappings @field_remappings = {} end |
.inner_class_types ⇒ Object
404 405 406 407 408 409 410 411 |
# File 'lib/stripe/resources/treasury/received_credit.rb', line 404 def self.inner_class_types @inner_class_types = { initiating_payment_method_details: InitiatingPaymentMethodDetails, linked_flows: LinkedFlows, network_details: NetworkDetails, reversal_details: ReversalDetails, } end |
.list(params = {}, opts = {}) ⇒ Object
Returns a list of ReceivedCredits.
374 375 376 377 378 379 380 381 |
# File 'lib/stripe/resources/treasury/received_credit.rb', line 374 def self.list(params = {}, opts = {}) request_stripe_object( method: :get, path: "/v1/treasury/received_credits", params: params, opts: opts ) end |
.object_name ⇒ Object
11 12 13 |
# File 'lib/stripe/resources/treasury/received_credit.rb', line 11 def self.object_name "treasury.received_credit" end |
Instance Method Details
#test_helpers ⇒ Object
383 384 385 |
# File 'lib/stripe/resources/treasury/received_credit.rb', line 383 def test_helpers TestHelpers.new(self) end |