Class: Stripe::Checkout::SessionService::CreateParams::CustomField
- Inherits:
-
RequestParams
- Object
- RequestParams
- Stripe::Checkout::SessionService::CreateParams::CustomField
- Defined in:
- lib/stripe/services/checkout/session_service.rb
Defined Under Namespace
Classes: Dropdown, Label, Numeric, Text
Instance Attribute Summary collapse
-
#dropdown ⇒ Object
Configuration for ‘type=dropdown` fields.
-
#key ⇒ Object
String of your choice that your integration can use to reconcile this field.
-
#label ⇒ Object
The label for the field, displayed to the customer.
-
#numeric ⇒ Object
Configuration for ‘type=numeric` fields.
-
#optional ⇒ Object
Whether the customer is required to complete the field before completing the Checkout Session.
-
#text ⇒ Object
Configuration for ‘type=text` fields.
-
#type ⇒ Object
The type of the field.
Instance Method Summary collapse
-
#initialize(dropdown: nil, key: nil, label: nil, numeric: nil, optional: nil, text: nil, type: nil) ⇒ CustomField
constructor
A new instance of CustomField.
Methods inherited from RequestParams
Constructor Details
#initialize(dropdown: nil, key: nil, label: nil, numeric: nil, optional: nil, text: nil, type: nil) ⇒ CustomField
Returns a new instance of CustomField.
263 264 265 266 267 268 269 270 271 272 273 274 275 276 277 278 279 |
# File 'lib/stripe/services/checkout/session_service.rb', line 263 def initialize( dropdown: nil, key: nil, label: nil, numeric: nil, optional: nil, text: nil, type: nil ) @dropdown = dropdown @key = key @label = label @numeric = numeric @optional = optional @text = text @type = type end |
Instance Attribute Details
#dropdown ⇒ Object
Configuration for ‘type=dropdown` fields.
249 250 251 |
# File 'lib/stripe/services/checkout/session_service.rb', line 249 def dropdown @dropdown end |
#key ⇒ Object
String of your choice that your integration can use to reconcile this field. Must be unique to this field, alphanumeric, and up to 200 characters.
251 252 253 |
# File 'lib/stripe/services/checkout/session_service.rb', line 251 def key @key end |
#label ⇒ Object
The label for the field, displayed to the customer.
253 254 255 |
# File 'lib/stripe/services/checkout/session_service.rb', line 253 def label @label end |
#numeric ⇒ Object
Configuration for ‘type=numeric` fields.
255 256 257 |
# File 'lib/stripe/services/checkout/session_service.rb', line 255 def numeric @numeric end |
#optional ⇒ Object
Whether the customer is required to complete the field before completing the Checkout Session. Defaults to ‘false`.
257 258 259 |
# File 'lib/stripe/services/checkout/session_service.rb', line 257 def optional @optional end |
#text ⇒ Object
Configuration for ‘type=text` fields.
259 260 261 |
# File 'lib/stripe/services/checkout/session_service.rb', line 259 def text @text end |
#type ⇒ Object
The type of the field.
261 262 263 |
# File 'lib/stripe/services/checkout/session_service.rb', line 261 def type @type end |