Class: Stripe::Treasury::Transaction
- Inherits:
-
APIResource
- Object
- StripeObject
- APIResource
- Stripe::Treasury::Transaction
- Extended by:
- APIOperations::List
- Defined in:
- lib/stripe/resources/treasury/transaction.rb
Overview
Transactions represent changes to a [FinancialAccount’s](stripe.com/docs/api#financial_accounts) balance.
Defined Under Namespace
Classes: BalanceImpact, FlowDetails, StatusTransitions
Constant Summary collapse
- OBJECT_NAME =
"treasury.transaction"
Constants inherited from StripeObject
StripeObject::RESERVED_FIELD_NAMES
Instance Attribute Summary collapse
-
#amount ⇒ Object
readonly
Amount (in cents) transferred.
-
#balance_impact ⇒ Object
readonly
Change to a FinancialAccount’s balance.
-
#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.
-
#entries ⇒ Object
readonly
A list of TransactionEntries that are part of this Transaction.
-
#financial_account ⇒ Object
readonly
The FinancialAccount associated with this object.
-
#flow ⇒ Object
readonly
ID of the flow that created the Transaction.
-
#flow_details ⇒ Object
readonly
Details of the flow that created the Transaction.
-
#flow_type ⇒ Object
readonly
Type of the flow that created the Transaction.
-
#id ⇒ Object
readonly
Unique identifier for the object.
-
#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.
-
#object ⇒ Object
readonly
String representing the object’s type.
-
#status ⇒ Object
readonly
Status of the Transaction.
-
#status_transitions ⇒ Object
readonly
Attribute for field status_transitions.
Attributes inherited from APIResource
Attributes inherited from StripeObject
Class Method Summary collapse
- .field_remappings ⇒ Object
- .inner_class_types ⇒ Object
-
.list(params = {}, opts = {}) ⇒ Object
Retrieves a list of Transaction objects.
- .object_name ⇒ Object
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.
90 91 92 |
# File 'lib/stripe/resources/treasury/transaction.rb', line 90 def amount @amount end |
#balance_impact ⇒ Object (readonly)
Change to a FinancialAccount’s balance
92 93 94 |
# File 'lib/stripe/resources/treasury/transaction.rb', line 92 def balance_impact @balance_impact end |
#created ⇒ Object (readonly)
Time at which the object was created. Measured in seconds since the Unix epoch.
94 95 96 |
# File 'lib/stripe/resources/treasury/transaction.rb', line 94 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).
96 97 98 |
# File 'lib/stripe/resources/treasury/transaction.rb', line 96 def currency @currency end |
#description ⇒ Object (readonly)
An arbitrary string attached to the object. Often useful for displaying to users.
98 99 100 |
# File 'lib/stripe/resources/treasury/transaction.rb', line 98 def description @description end |
#entries ⇒ Object (readonly)
A list of TransactionEntries that are part of this Transaction. This cannot be expanded in any list endpoints.
100 101 102 |
# File 'lib/stripe/resources/treasury/transaction.rb', line 100 def entries @entries end |
#financial_account ⇒ Object (readonly)
The FinancialAccount associated with this object.
102 103 104 |
# File 'lib/stripe/resources/treasury/transaction.rb', line 102 def financial_account @financial_account end |
#flow ⇒ Object (readonly)
ID of the flow that created the Transaction.
104 105 106 |
# File 'lib/stripe/resources/treasury/transaction.rb', line 104 def flow @flow end |
#flow_details ⇒ Object (readonly)
Details of the flow that created the Transaction.
106 107 108 |
# File 'lib/stripe/resources/treasury/transaction.rb', line 106 def flow_details @flow_details end |
#flow_type ⇒ Object (readonly)
Type of the flow that created the Transaction.
108 109 110 |
# File 'lib/stripe/resources/treasury/transaction.rb', line 108 def flow_type @flow_type end |
#id ⇒ Object (readonly)
Unique identifier for the object.
110 111 112 |
# File 'lib/stripe/resources/treasury/transaction.rb', line 110 def id @id 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.
112 113 114 |
# File 'lib/stripe/resources/treasury/transaction.rb', line 112 def livemode @livemode end |
#object ⇒ Object (readonly)
String representing the object’s type. Objects of the same type share the same value.
114 115 116 |
# File 'lib/stripe/resources/treasury/transaction.rb', line 114 def object @object end |
#status ⇒ Object (readonly)
Status of the Transaction.
116 117 118 |
# File 'lib/stripe/resources/treasury/transaction.rb', line 116 def status @status end |
#status_transitions ⇒ Object (readonly)
Attribute for field status_transitions
118 119 120 |
# File 'lib/stripe/resources/treasury/transaction.rb', line 118 def status_transitions @status_transitions end |
Class Method Details
.field_remappings ⇒ Object
138 139 140 |
# File 'lib/stripe/resources/treasury/transaction.rb', line 138 def self.field_remappings @field_remappings = {} end |
.inner_class_types ⇒ Object
130 131 132 133 134 135 136 |
# File 'lib/stripe/resources/treasury/transaction.rb', line 130 def self.inner_class_types @inner_class_types = { balance_impact: BalanceImpact, flow_details: FlowDetails, status_transitions: StatusTransitions, } end |
.list(params = {}, opts = {}) ⇒ Object
Retrieves a list of Transaction objects.
121 122 123 124 125 126 127 128 |
# File 'lib/stripe/resources/treasury/transaction.rb', line 121 def self.list(params = {}, opts = {}) request_stripe_object( method: :get, path: "/v1/treasury/transactions", params: params, opts: opts ) end |
.object_name ⇒ Object
11 12 13 |
# File 'lib/stripe/resources/treasury/transaction.rb', line 11 def self.object_name "treasury.transaction" end |