Class: Stripe::Radar::CustomerEvaluation
- Inherits:
-
APIResource
- Object
- StripeObject
- APIResource
- Stripe::Radar::CustomerEvaluation
- Extended by:
- APIOperations::Create
- Includes:
- APIOperations::Save
- Defined in:
- lib/stripe/resources/radar/customer_evaluation.rb
Overview
Customer Evaluation resource returned by the Radar Customer Evaluations API.
Defined Under Namespace
Constant Summary collapse
- OBJECT_NAME =
"radar.customer_evaluation"
Constants inherited from StripeObject
StripeObject::RESERVED_FIELD_NAMES
Instance Attribute Summary collapse
-
#created_at ⇒ Object
readonly
Time at which the object was created.
-
#customer ⇒ Object
readonly
The ID of the Stripe customer the customer evaluation is associated with.
-
#event_type ⇒ Object
readonly
The type of evaluation event.
-
#events ⇒ Object
readonly
A list of events that have been reported on this customer evaluation.
-
#id ⇒ Object
readonly
Unique identifier for the object.
-
#livemode ⇒ Object
readonly
If the object exists in live mode, the value is ‘true`.
-
#object ⇒ Object
readonly
String representing the object’s type.
-
#signals ⇒ Object
readonly
A hash of signal objects providing Radar’s evaluation for the lifecycle event.
Attributes inherited from APIResource
Attributes inherited from StripeObject
Class Method Summary collapse
-
.create(params = {}, opts = {}) ⇒ Object
Creates a new CustomerEvaluation object.
- .field_remappings ⇒ Object
- .inner_class_types ⇒ Object
- .object_name ⇒ Object
-
.update(customer_evaluation, params = {}, opts = {}) ⇒ Object
Reports an event on a CustomerEvaluation object.
Methods included from APIOperations::Create
Methods included from APIOperations::Save
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
#created_at ⇒ Object (readonly)
Time at which the object was created. Measured in seconds since the Unix epoch.
108 109 110 |
# File 'lib/stripe/resources/radar/customer_evaluation.rb', line 108 def created_at @created_at end |
#customer ⇒ Object (readonly)
The ID of the Stripe customer the customer evaluation is associated with.
110 111 112 |
# File 'lib/stripe/resources/radar/customer_evaluation.rb', line 110 def customer @customer end |
#event_type ⇒ Object (readonly)
The type of evaluation event.
112 113 114 |
# File 'lib/stripe/resources/radar/customer_evaluation.rb', line 112 def event_type @event_type end |
#events ⇒ Object (readonly)
A list of events that have been reported on this customer evaluation.
114 115 116 |
# File 'lib/stripe/resources/radar/customer_evaluation.rb', line 114 def events @events end |
#id ⇒ Object (readonly)
Unique identifier for the object.
116 117 118 |
# File 'lib/stripe/resources/radar/customer_evaluation.rb', line 116 def id @id end |
#livemode ⇒ Object (readonly)
If the object exists in live mode, the value is ‘true`. If the object exists in test mode, the value is `false`.
118 119 120 |
# File 'lib/stripe/resources/radar/customer_evaluation.rb', line 118 def livemode @livemode end |
#object ⇒ Object (readonly)
String representing the object’s type. Objects of the same type share the same value.
120 121 122 |
# File 'lib/stripe/resources/radar/customer_evaluation.rb', line 120 def object @object end |
#signals ⇒ Object (readonly)
A hash of signal objects providing Radar’s evaluation for the lifecycle event.
122 123 124 |
# File 'lib/stripe/resources/radar/customer_evaluation.rb', line 122 def signals @signals end |
Class Method Details
.create(params = {}, opts = {}) ⇒ Object
Creates a new CustomerEvaluation object.
125 126 127 128 129 130 131 132 |
# File 'lib/stripe/resources/radar/customer_evaluation.rb', line 125 def self.create(params = {}, opts = {}) request_stripe_object( method: :post, path: "/v1/radar/customer_evaluations", params: params, opts: opts ) end |
.field_remappings ⇒ Object
148 149 150 |
# File 'lib/stripe/resources/radar/customer_evaluation.rb', line 148 def self.field_remappings @field_remappings = {} end |
.inner_class_types ⇒ Object
144 145 146 |
# File 'lib/stripe/resources/radar/customer_evaluation.rb', line 144 def self.inner_class_types @inner_class_types = { events: Event, signals: Signals } end |
.object_name ⇒ Object
12 13 14 |
# File 'lib/stripe/resources/radar/customer_evaluation.rb', line 12 def self.object_name "radar.customer_evaluation" end |
.update(customer_evaluation, params = {}, opts = {}) ⇒ Object
Reports an event on a CustomerEvaluation object.
135 136 137 138 139 140 141 142 |
# File 'lib/stripe/resources/radar/customer_evaluation.rb', line 135 def self.update(customer_evaluation, params = {}, opts = {}) request_stripe_object( method: :post, path: format("/v1/radar/customer_evaluations/%<customer_evaluation>s/report", { customer_evaluation: CGI.escape(customer_evaluation) }), params: params, opts: opts ) end |