Class: Pago::V2026_04::Models::CheckoutPublicConfirmed
- Defined in:
- lib/pago/v2026_04/models.rb,
sig/pago/v2026_04/generated.rbs
Overview
Checkout session data retrieved using the client secret after confirmation.
It contains a customer session token to retrieve order information right after the checkout.
Constant Summary collapse
- JSON_KEYS =
{ id: "id", created_at: "created_at", modified_at: "modified_at", custom_field_data: "custom_field_data", payment_processor: "payment_processor", status: "status", client_secret: "client_secret", url: "url", expires_at: "expires_at", success_url: "success_url", return_url: "return_url", embed_origin: "embed_origin", amount: "amount", seats: "seats", min_seats: "min_seats", max_seats: "max_seats", discount_amount: "discount_amount", net_amount: "net_amount", tax_amount: "tax_amount", tax_behavior: "tax_behavior", total_amount: "total_amount", currency: "currency", allow_trial: "allow_trial", active_trial_interval: "active_trial_interval", active_trial_interval_count: "active_trial_interval_count", trial_end: "trial_end", organization_id: "organization_id", product_id: "product_id", product_price_id: "product_price_id", discount_id: "discount_id", allow_discount_codes: "allow_discount_codes", require_billing_address: "require_billing_address", is_discount_applicable: "is_discount_applicable", is_free_product_price: "is_free_product_price", is_payment_required: "is_payment_required", is_payment_setup_required: "is_payment_setup_required", is_payment_form_required: "is_payment_form_required", customer_id: "customer_id", is_business_customer: "is_business_customer", customer_name: "customer_name", customer_email: "customer_email", customer_ip_address: "customer_ip_address", customer_billing_name: "customer_billing_name", customer_billing_address: "customer_billing_address", customer_tax_id: "customer_tax_id", locale: "locale", payment_processor_metadata: "payment_processor_metadata", billing_address_fields: "billing_address_fields", products: "products", product: "product", product_price: "product_price", prices: "prices", discount: "discount", organization: "organization", attached_custom_fields: "attached_custom_fields", customer_session_token: "customer_session_token" }.freeze
- REQUIRED_KEYS =
["id", "created_at", "modified_at", "payment_processor", "status", "client_secret", "url", "expires_at", "success_url", "return_url", "embed_origin", "amount", "discount_amount", "net_amount", "tax_amount", "tax_behavior", "total_amount", "currency", "allow_trial", "active_trial_interval", "active_trial_interval_count", "trial_end", "organization_id", "product_id", "product_price_id", "discount_id", "allow_discount_codes", "require_billing_address", "is_discount_applicable", "is_free_product_price", "is_payment_required", "is_payment_setup_required", "is_payment_form_required", "customer_id", "is_business_customer", "customer_name", "customer_email", "customer_ip_address", "customer_billing_name", "customer_billing_address", "customer_tax_id", "payment_processor_metadata", "billing_address_fields", "products", "product", "product_price", "prices", "discount", "organization", "attached_custom_fields", "customer_session_token"].freeze
Instance Attribute Summary collapse
-
#active_trial_interval ⇒ String?
readonly
Interval unit of the trial period, if any.
-
#active_trial_interval_count ⇒ Integer?
readonly
Number of interval units of the trial period, if any.
-
#allow_discount_codes ⇒ Boolean
readonly
Whether to allow the customer to apply discount codes.
-
#allow_trial ⇒ Boolean?
readonly
Whether to enable the trial period for the checkout session.
-
#amount ⇒ Integer
readonly
Amount in cents, before discounts and taxes.
- #attached_custom_fields ⇒ Array<Models::AttachedCustomField>? readonly
- #billing_address_fields ⇒ Models::CheckoutBillingAddressFields readonly
-
#client_secret ⇒ String
readonly
Client secret used to update and complete the checkout session from the client.
-
#created_at ⇒ String
readonly
Creation timestamp of the object.
-
#currency ⇒ String
readonly
Currency code of the checkout session.
-
#custom_field_data ⇒ Hash{String => String, Integer, Boolean, nil}
readonly
Key-value object storing custom field values.
- #customer_billing_address ⇒ Models::Address? readonly
- #customer_billing_name ⇒ String? readonly
-
#customer_email ⇒ String?
readonly
Email address of the customer.
- #customer_id ⇒ String? readonly
- #customer_ip_address ⇒ String? readonly
-
#customer_name ⇒ String?
readonly
Name of the customer.
- #customer_session_token ⇒ String? readonly
- #customer_tax_id ⇒ String? readonly
- #discount ⇒ Models::CheckoutDiscountFixedOnceForeverDuration, ... readonly
-
#discount_amount ⇒ Integer
readonly
Discount amount in cents.
-
#discount_id ⇒ String?
readonly
ID of the discount applied to the checkout.
-
#embed_origin ⇒ String?
readonly
When checkout is embedded, represents the Origin of the page embedding the checkout.
-
#expires_at ⇒ String
readonly
Expiration date and time of the checkout session.
-
#id ⇒ String
readonly
The ID of the object.
-
#is_business_customer ⇒ Boolean
readonly
Whether the customer is a business or an individual.
-
#is_discount_applicable ⇒ Boolean
readonly
Whether the discount is applicable to the checkout.
-
#is_free_product_price ⇒ Boolean
readonly
Whether the product price is free, regardless of discounts.
-
#is_payment_form_required ⇒ Boolean
readonly
Whether the checkout requires a payment form, whether because of a payment or payment method setup.
-
#is_payment_required ⇒ Boolean
readonly
Whether the checkout requires payment, e.g.
-
#is_payment_setup_required ⇒ Boolean
readonly
Whether the checkout requires setting up a payment method, regardless of the amount, e.g.
- #locale ⇒ String? readonly
-
#max_seats ⇒ Integer?
readonly
Maximum number of seats (works with seat-based pricing only).
-
#min_seats ⇒ Integer?
readonly
Minimum number of seats (works with seat-based pricing only).
-
#modified_at ⇒ String?
readonly
Last modification timestamp of the object.
-
#net_amount ⇒ Integer
readonly
Amount in cents, after discounts but before taxes.
- #organization ⇒ Models::CheckoutOrganization readonly
-
#organization_id ⇒ String
readonly
ID of the organization owning the checkout session.
- #payment_processor ⇒ String readonly
- #payment_processor_metadata ⇒ Hash{String => String} readonly
-
#prices ⇒ Hash{String => Array<Object>}?
readonly
Mapping of product IDs to their list of prices.
-
#product ⇒ Models::CheckoutProduct?
readonly
Product selected to checkout.
-
#product_id ⇒ String?
readonly
ID of the product to checkout.
- #product_price ⇒ Object? readonly deprecated Deprecated.
- #product_price_id ⇒ String? readonly deprecated Deprecated.
-
#products ⇒ Array<Models::CheckoutProduct>
readonly
List of products available to select.
-
#require_billing_address ⇒ Boolean
readonly
Whether to require the customer to fill their full billing address, instead of just the country.
-
#return_url ⇒ String?
readonly
When set, a back button will be shown in the checkout to return to this URL.
-
#seats ⇒ Integer?
readonly
Predefined number of seats (works with seat-based pricing only).
- #status ⇒ String readonly
-
#success_url ⇒ String
readonly
URL where the customer will be redirected after a successful payment.
-
#tax_amount ⇒ Integer?
readonly
Sales tax amount in cents.
-
#tax_behavior ⇒ String?
readonly
Tax behavior of the checkout.
-
#total_amount ⇒ Integer
readonly
Amount in cents, after discounts and taxes.
-
#trial_end ⇒ String?
readonly
End date and time of the trial period, if any.
-
#url ⇒ String
readonly
URL where the customer can access the checkout session.
Class Method Summary collapse
Instance Method Summary collapse
Methods inherited from Model
#==, #[], #field_set?, #hash, #inspect, json_keys, required_json_keys, #to_json, #to_json_hash, wrap_raw
Constructor Details
#initialize(id:, created_at:, modified_at:, custom_field_data: ::Pago::UNSET, payment_processor:, status:, client_secret:, url:, expires_at:, success_url:, return_url:, embed_origin:, amount:, seats: ::Pago::UNSET, min_seats: ::Pago::UNSET, max_seats: ::Pago::UNSET, discount_amount:, net_amount:, tax_amount:, tax_behavior:, total_amount:, currency:, allow_trial:, active_trial_interval:, active_trial_interval_count:, trial_end:, organization_id:, product_id:, product_price_id:, discount_id:, allow_discount_codes:, require_billing_address:, is_discount_applicable:, is_free_product_price:, is_payment_required:, is_payment_setup_required:, is_payment_form_required:, customer_id:, is_business_customer:, customer_name:, customer_email:, customer_ip_address:, customer_billing_name:, customer_billing_address:, customer_tax_id:, locale: ::Pago::UNSET, payment_processor_metadata:, billing_address_fields:, products:, product:, product_price:, prices:, discount:, organization:, attached_custom_fields:, customer_session_token:) ⇒ CheckoutPublicConfirmed
Returns a new instance of CheckoutPublicConfirmed.
12423 12424 12425 12426 12427 12428 12429 12430 12431 12432 12433 12434 12435 12436 12437 12438 12439 12440 12441 12442 12443 12444 12445 12446 12447 12448 12449 12450 12451 12452 12453 12454 12455 12456 12457 12458 12459 12460 12461 12462 12463 12464 12465 12466 12467 12468 12469 12470 12471 12472 12473 12474 12475 12476 12477 12478 12479 12480 12481 12482 12483 12484 12485 12486 12487 12488 12489 12490 12491 12492 12493 12494 12495 12496 12497 12498 12499 12500 12501 12502 12503 12504 12505 12506 12507 12508 12509 12510 12511 12512 12513 12514 12515 12516 12517 12518 12519 12520 12521 12522 12523 12524 12525 12526 12527 12528 12529 12530 12531 12532 12533 12534 12535 12536 12537 12538 |
# File 'lib/pago/v2026_04/models.rb', line 12423 def initialize( id:, created_at:, modified_at:, custom_field_data: ::Pago::UNSET, payment_processor:, status:, client_secret:, url:, expires_at:, success_url:, return_url:, embed_origin:, amount:, seats: ::Pago::UNSET, min_seats: ::Pago::UNSET, max_seats: ::Pago::UNSET, discount_amount:, net_amount:, tax_amount:, tax_behavior:, total_amount:, currency:, allow_trial:, active_trial_interval:, active_trial_interval_count:, trial_end:, organization_id:, product_id:, product_price_id:, discount_id:, allow_discount_codes:, require_billing_address:, is_discount_applicable:, is_free_product_price:, is_payment_required:, is_payment_setup_required:, is_payment_form_required:, customer_id:, is_business_customer:, customer_name:, customer_email:, customer_ip_address:, customer_billing_name:, customer_billing_address:, customer_tax_id:, locale: ::Pago::UNSET, payment_processor_metadata:, billing_address_fields:, products:, product:, product_price:, prices:, discount:, organization:, attached_custom_fields:, customer_session_token: ) super() assign(:id, id) assign(:created_at, created_at) assign(:modified_at, modified_at) assign(:custom_field_data, custom_field_data) assign(:payment_processor, payment_processor) assign(:status, status) assign(:client_secret, client_secret) assign(:url, url) assign(:expires_at, expires_at) assign(:success_url, success_url) assign(:return_url, return_url) assign(:embed_origin, ) assign(:amount, amount) assign(:seats, seats) assign(:min_seats, min_seats) assign(:max_seats, max_seats) assign(:discount_amount, discount_amount) assign(:net_amount, net_amount) assign(:tax_amount, tax_amount) assign(:tax_behavior, tax_behavior) assign(:total_amount, total_amount) assign(:currency, currency) assign(:allow_trial, allow_trial) assign(:active_trial_interval, active_trial_interval) assign(:active_trial_interval_count, active_trial_interval_count) assign(:trial_end, trial_end) assign(:organization_id, organization_id) assign(:product_id, product_id) assign(:product_price_id, product_price_id) assign(:discount_id, discount_id) assign(:allow_discount_codes, allow_discount_codes) assign(:require_billing_address, require_billing_address) assign(:is_discount_applicable, is_discount_applicable) assign(:is_free_product_price, is_free_product_price) assign(:is_payment_required, is_payment_required) assign(:is_payment_setup_required, is_payment_setup_required) assign(:is_payment_form_required, is_payment_form_required) assign(:customer_id, customer_id) assign(:is_business_customer, is_business_customer) assign(:customer_name, customer_name) assign(:customer_email, customer_email) assign(:customer_ip_address, customer_ip_address) assign(:customer_billing_name, customer_billing_name) assign(:customer_billing_address, customer_billing_address) assign(:customer_tax_id, customer_tax_id) assign(:locale, locale) assign(:payment_processor_metadata, ) assign(:billing_address_fields, billing_address_fields) assign(:products, products) assign(:product, product) assign(:product_price, product_price) assign(:prices, prices) assign(:discount, discount) assign(:organization, organization) assign(:attached_custom_fields, attached_custom_fields) assign(:customer_session_token, customer_session_token) end |
Instance Attribute Details
#active_trial_interval ⇒ String? (readonly)
Interval unit of the trial period, if any. This value is either set from the checkout, if trial_interval is set, or from the selected product.
12303 12304 12305 |
# File 'lib/pago/v2026_04/models.rb', line 12303 def active_trial_interval @active_trial_interval end |
#active_trial_interval_count ⇒ Integer? (readonly)
Number of interval units of the trial period, if any. This value is either set from the checkout, if trial_interval_count is set, or from the selected product.
12307 12308 12309 |
# File 'lib/pago/v2026_04/models.rb', line 12307 def active_trial_interval_count @active_trial_interval_count end |
#allow_discount_codes ⇒ Boolean (readonly)
Whether to allow the customer to apply discount codes. If you apply a discount through discount_id, it'll still be applied, but the customer won't be able to change it.
12332 12333 12334 |
# File 'lib/pago/v2026_04/models.rb', line 12332 def allow_discount_codes @allow_discount_codes end |
#allow_trial ⇒ Boolean? (readonly)
Whether to enable the trial period for the checkout session. If false, the trial period will be disabled, even if the selected product has a trial configured.
12299 12300 12301 |
# File 'lib/pago/v2026_04/models.rb', line 12299 def allow_trial @allow_trial end |
#amount ⇒ Integer (readonly)
Amount in cents, before discounts and taxes.
12259 12260 12261 |
# File 'lib/pago/v2026_04/models.rb', line 12259 def amount @amount end |
#attached_custom_fields ⇒ Array<Models::AttachedCustomField>? (readonly)
12418 12419 12420 |
# File 'lib/pago/v2026_04/models.rb', line 12418 def attached_custom_fields @attached_custom_fields end |
#billing_address_fields ⇒ Models::CheckoutBillingAddressFields (readonly)
12392 12393 12394 |
# File 'lib/pago/v2026_04/models.rb', line 12392 def billing_address_fields @billing_address_fields end |
#client_secret ⇒ String (readonly)
Client secret used to update and complete the checkout session from the client.
12235 12236 12237 |
# File 'lib/pago/v2026_04/models.rb', line 12235 def client_secret @client_secret end |
#created_at ⇒ String (readonly)
Creation timestamp of the object.
12217 12218 12219 |
# File 'lib/pago/v2026_04/models.rb', line 12217 def created_at @created_at end |
#currency ⇒ String (readonly)
Currency code of the checkout session.
12295 12296 12297 |
# File 'lib/pago/v2026_04/models.rb', line 12295 def currency @currency end |
#custom_field_data ⇒ Hash{String => String, Integer, Boolean, nil} (readonly)
Key-value object storing custom field values.
12225 12226 12227 |
# File 'lib/pago/v2026_04/models.rb', line 12225 def custom_field_data @custom_field_data end |
#customer_billing_address ⇒ Models::Address? (readonly)
12380 12381 12382 |
# File 'lib/pago/v2026_04/models.rb', line 12380 def customer_billing_address @customer_billing_address end |
#customer_billing_name ⇒ String? (readonly)
12377 12378 12379 |
# File 'lib/pago/v2026_04/models.rb', line 12377 def customer_billing_name @customer_billing_name end |
#customer_email ⇒ String? (readonly)
Email address of the customer.
12371 12372 12373 |
# File 'lib/pago/v2026_04/models.rb', line 12371 def customer_email @customer_email end |
#customer_id ⇒ String? (readonly)
12359 12360 12361 |
# File 'lib/pago/v2026_04/models.rb', line 12359 def customer_id @customer_id end |
#customer_ip_address ⇒ String? (readonly)
12374 12375 12376 |
# File 'lib/pago/v2026_04/models.rb', line 12374 def customer_ip_address @customer_ip_address end |
#customer_name ⇒ String? (readonly)
Name of the customer.
12367 12368 12369 |
# File 'lib/pago/v2026_04/models.rb', line 12367 def customer_name @customer_name end |
#customer_session_token ⇒ String? (readonly)
12421 12422 12423 |
# File 'lib/pago/v2026_04/models.rb', line 12421 def customer_session_token @customer_session_token end |
#customer_tax_id ⇒ String? (readonly)
12383 12384 12385 |
# File 'lib/pago/v2026_04/models.rb', line 12383 def customer_tax_id @customer_tax_id end |
#discount ⇒ Models::CheckoutDiscountFixedOnceForeverDuration, ... (readonly)
12412 12413 12414 |
# File 'lib/pago/v2026_04/models.rb', line 12412 def discount @discount end |
#discount_amount ⇒ Integer (readonly)
Discount amount in cents.
12275 12276 12277 |
# File 'lib/pago/v2026_04/models.rb', line 12275 def discount_amount @discount_amount end |
#discount_id ⇒ String? (readonly)
ID of the discount applied to the checkout.
12328 12329 12330 |
# File 'lib/pago/v2026_04/models.rb', line 12328 def discount_id @discount_id end |
#embed_origin ⇒ String? (readonly)
When checkout is embedded, represents the Origin of the page embedding the checkout. Used as a security measure to send messages only to the embedding page.
12255 12256 12257 |
# File 'lib/pago/v2026_04/models.rb', line 12255 def @embed_origin end |
#expires_at ⇒ String (readonly)
Expiration date and time of the checkout session.
12243 12244 12245 |
# File 'lib/pago/v2026_04/models.rb', line 12243 def expires_at @expires_at end |
#id ⇒ String (readonly)
The ID of the object.
12213 12214 12215 |
# File 'lib/pago/v2026_04/models.rb', line 12213 def id @id end |
#is_business_customer ⇒ Boolean (readonly)
Whether the customer is a business or an individual. If true, the customer will be required to fill their full billing address and billing name.
12363 12364 12365 |
# File 'lib/pago/v2026_04/models.rb', line 12363 def is_business_customer @is_business_customer end |
#is_discount_applicable ⇒ Boolean (readonly)
Whether the discount is applicable to the checkout. Typically, free and custom prices are not discountable.
12340 12341 12342 |
# File 'lib/pago/v2026_04/models.rb', line 12340 def is_discount_applicable @is_discount_applicable end |
#is_free_product_price ⇒ Boolean (readonly)
Whether the product price is free, regardless of discounts.
12344 12345 12346 |
# File 'lib/pago/v2026_04/models.rb', line 12344 def is_free_product_price @is_free_product_price end |
#is_payment_form_required ⇒ Boolean (readonly)
Whether the checkout requires a payment form, whether because of a payment or payment method setup.
12356 12357 12358 |
# File 'lib/pago/v2026_04/models.rb', line 12356 def is_payment_form_required @is_payment_form_required end |
#is_payment_required ⇒ Boolean (readonly)
Whether the checkout requires payment, e.g. in case of free products or discounts that cover the total amount.
12348 12349 12350 |
# File 'lib/pago/v2026_04/models.rb', line 12348 def is_payment_required @is_payment_required end |
#is_payment_setup_required ⇒ Boolean (readonly)
Whether the checkout requires setting up a payment method, regardless of the amount, e.g. subscriptions that have first free cycles.
12352 12353 12354 |
# File 'lib/pago/v2026_04/models.rb', line 12352 def is_payment_setup_required @is_payment_setup_required end |
#locale ⇒ String? (readonly)
12386 12387 12388 |
# File 'lib/pago/v2026_04/models.rb', line 12386 def locale @locale end |
#max_seats ⇒ Integer? (readonly)
Maximum number of seats (works with seat-based pricing only)
12271 12272 12273 |
# File 'lib/pago/v2026_04/models.rb', line 12271 def max_seats @max_seats end |
#min_seats ⇒ Integer? (readonly)
Minimum number of seats (works with seat-based pricing only)
12267 12268 12269 |
# File 'lib/pago/v2026_04/models.rb', line 12267 def min_seats @min_seats end |
#modified_at ⇒ String? (readonly)
Last modification timestamp of the object.
12221 12222 12223 |
# File 'lib/pago/v2026_04/models.rb', line 12221 def modified_at @modified_at end |
#net_amount ⇒ Integer (readonly)
Amount in cents, after discounts but before taxes.
12279 12280 12281 |
# File 'lib/pago/v2026_04/models.rb', line 12279 def net_amount @net_amount end |
#organization ⇒ Models::CheckoutOrganization (readonly)
12415 12416 12417 |
# File 'lib/pago/v2026_04/models.rb', line 12415 def organization @organization end |
#organization_id ⇒ String (readonly)
ID of the organization owning the checkout session.
12315 12316 12317 |
# File 'lib/pago/v2026_04/models.rb', line 12315 def organization_id @organization_id end |
#payment_processor ⇒ String (readonly)
12228 12229 12230 |
# File 'lib/pago/v2026_04/models.rb', line 12228 def payment_processor @payment_processor end |
#payment_processor_metadata ⇒ Hash{String => String} (readonly)
12389 12390 12391 |
# File 'lib/pago/v2026_04/models.rb', line 12389 def @payment_processor_metadata end |
#prices ⇒ Hash{String => Array<Object>}? (readonly)
Mapping of product IDs to their list of prices.
12409 12410 12411 |
# File 'lib/pago/v2026_04/models.rb', line 12409 def prices @prices end |
#product ⇒ Models::CheckoutProduct? (readonly)
Product selected to checkout.
12400 12401 12402 |
# File 'lib/pago/v2026_04/models.rb', line 12400 def product @product end |
#product_id ⇒ String? (readonly)
ID of the product to checkout.
12319 12320 12321 |
# File 'lib/pago/v2026_04/models.rb', line 12319 def product_id @product_id end |
#product_price ⇒ Object? (readonly)
Price of the selected product.
12405 12406 12407 |
# File 'lib/pago/v2026_04/models.rb', line 12405 def product_price @product_price end |
#product_price_id ⇒ String? (readonly)
ID of the product price to checkout.
12324 12325 12326 |
# File 'lib/pago/v2026_04/models.rb', line 12324 def product_price_id @product_price_id end |
#products ⇒ Array<Models::CheckoutProduct> (readonly)
List of products available to select.
12396 12397 12398 |
# File 'lib/pago/v2026_04/models.rb', line 12396 def products @products end |
#require_billing_address ⇒ Boolean (readonly)
Whether to require the customer to fill their full billing address, instead of just the country. Customers in the US will always be required to fill their full address, regardless of this setting. If you preset the billing address, this setting will be automatically set to true.
12336 12337 12338 |
# File 'lib/pago/v2026_04/models.rb', line 12336 def require_billing_address @require_billing_address end |
#return_url ⇒ String? (readonly)
When set, a back button will be shown in the checkout to return to this URL.
12251 12252 12253 |
# File 'lib/pago/v2026_04/models.rb', line 12251 def return_url @return_url end |
#seats ⇒ Integer? (readonly)
Predefined number of seats (works with seat-based pricing only)
12263 12264 12265 |
# File 'lib/pago/v2026_04/models.rb', line 12263 def seats @seats end |
#status ⇒ String (readonly)
12231 12232 12233 |
# File 'lib/pago/v2026_04/models.rb', line 12231 def status @status end |
#success_url ⇒ String (readonly)
URL where the customer will be redirected after a successful payment.
12247 12248 12249 |
# File 'lib/pago/v2026_04/models.rb', line 12247 def success_url @success_url end |
#tax_amount ⇒ Integer? (readonly)
Sales tax amount in cents. If null, it means there is no enough information yet to calculate it.
12283 12284 12285 |
# File 'lib/pago/v2026_04/models.rb', line 12283 def tax_amount @tax_amount end |
#tax_behavior ⇒ String? (readonly)
Tax behavior of the checkout. inclusive means the price includes tax, exclusive means tax is added on top. If null, tax is not yet calculated.
12287 12288 12289 |
# File 'lib/pago/v2026_04/models.rb', line 12287 def tax_behavior @tax_behavior end |
#total_amount ⇒ Integer (readonly)
Amount in cents, after discounts and taxes.
12291 12292 12293 |
# File 'lib/pago/v2026_04/models.rb', line 12291 def total_amount @total_amount end |
#trial_end ⇒ String? (readonly)
End date and time of the trial period, if any.
12311 12312 12313 |
# File 'lib/pago/v2026_04/models.rb', line 12311 def trial_end @trial_end end |
#url ⇒ String (readonly)
URL where the customer can access the checkout session.
12239 12240 12241 |
# File 'lib/pago/v2026_04/models.rb', line 12239 def url @url end |
Class Method Details
.from_json(data) ⇒ CheckoutPublicConfirmed?
12542 12543 12544 12545 12546 12547 12548 12549 12550 12551 12552 12553 12554 12555 12556 12557 12558 12559 12560 12561 12562 12563 12564 12565 12566 12567 12568 12569 12570 12571 12572 12573 12574 12575 12576 12577 12578 12579 12580 12581 12582 12583 12584 12585 12586 12587 12588 12589 12590 12591 12592 12593 12594 12595 12596 12597 12598 12599 12600 12601 12602 12603 12604 12605 12606 12607 12608 |
# File 'lib/pago/v2026_04/models.rb', line 12542 def self.from_json(data) data = ::JSON.parse(data) if data.is_a?(String) data = ::Pago::Serde.object(data) return nil if data.nil? wrap_raw( new( id: (data.key?("id") ? data["id"] : ::Pago::UNSET), created_at: (data.key?("created_at") ? data["created_at"] : ::Pago::UNSET), modified_at: (data.key?("modified_at") ? data["modified_at"] : ::Pago::UNSET), custom_field_data: (data.key?("custom_field_data") ? data["custom_field_data"] : ::Pago::UNSET), payment_processor: (data.key?("payment_processor") ? data["payment_processor"] : ::Pago::UNSET), status: (data.key?("status") ? data["status"] : ::Pago::UNSET), client_secret: (data.key?("client_secret") ? data["client_secret"] : ::Pago::UNSET), url: (data.key?("url") ? data["url"] : ::Pago::UNSET), expires_at: (data.key?("expires_at") ? data["expires_at"] : ::Pago::UNSET), success_url: (data.key?("success_url") ? data["success_url"] : ::Pago::UNSET), return_url: (data.key?("return_url") ? data["return_url"] : ::Pago::UNSET), embed_origin: (data.key?("embed_origin") ? data["embed_origin"] : ::Pago::UNSET), amount: (data.key?("amount") ? data["amount"] : ::Pago::UNSET), seats: (data.key?("seats") ? data["seats"] : ::Pago::UNSET), min_seats: (data.key?("min_seats") ? data["min_seats"] : ::Pago::UNSET), max_seats: (data.key?("max_seats") ? data["max_seats"] : ::Pago::UNSET), discount_amount: (data.key?("discount_amount") ? data["discount_amount"] : ::Pago::UNSET), net_amount: (data.key?("net_amount") ? data["net_amount"] : ::Pago::UNSET), tax_amount: (data.key?("tax_amount") ? data["tax_amount"] : ::Pago::UNSET), tax_behavior: (data.key?("tax_behavior") ? data["tax_behavior"] : ::Pago::UNSET), total_amount: (data.key?("total_amount") ? data["total_amount"] : ::Pago::UNSET), currency: (data.key?("currency") ? data["currency"] : ::Pago::UNSET), allow_trial: (data.key?("allow_trial") ? data["allow_trial"] : ::Pago::UNSET), active_trial_interval: (data.key?("active_trial_interval") ? data["active_trial_interval"] : ::Pago::UNSET), active_trial_interval_count: (data.key?("active_trial_interval_count") ? data["active_trial_interval_count"] : ::Pago::UNSET), trial_end: (data.key?("trial_end") ? data["trial_end"] : ::Pago::UNSET), organization_id: (data.key?("organization_id") ? data["organization_id"] : ::Pago::UNSET), product_id: (data.key?("product_id") ? data["product_id"] : ::Pago::UNSET), product_price_id: (data.key?("product_price_id") ? data["product_price_id"] : ::Pago::UNSET), discount_id: (data.key?("discount_id") ? data["discount_id"] : ::Pago::UNSET), allow_discount_codes: (data.key?("allow_discount_codes") ? data["allow_discount_codes"] : ::Pago::UNSET), require_billing_address: (data.key?("require_billing_address") ? data["require_billing_address"] : ::Pago::UNSET), is_discount_applicable: (data.key?("is_discount_applicable") ? data["is_discount_applicable"] : ::Pago::UNSET), is_free_product_price: (data.key?("is_free_product_price") ? data["is_free_product_price"] : ::Pago::UNSET), is_payment_required: (data.key?("is_payment_required") ? data["is_payment_required"] : ::Pago::UNSET), is_payment_setup_required: (data.key?("is_payment_setup_required") ? data["is_payment_setup_required"] : ::Pago::UNSET), is_payment_form_required: (data.key?("is_payment_form_required") ? data["is_payment_form_required"] : ::Pago::UNSET), customer_id: (data.key?("customer_id") ? data["customer_id"] : ::Pago::UNSET), is_business_customer: (data.key?("is_business_customer") ? data["is_business_customer"] : ::Pago::UNSET), customer_name: (data.key?("customer_name") ? data["customer_name"] : ::Pago::UNSET), customer_email: (data.key?("customer_email") ? data["customer_email"] : ::Pago::UNSET), customer_ip_address: (data.key?("customer_ip_address") ? data["customer_ip_address"] : ::Pago::UNSET), customer_billing_name: (data.key?("customer_billing_name") ? data["customer_billing_name"] : ::Pago::UNSET), customer_billing_address: (data.key?("customer_billing_address") ? Models::Address.from_json(data["customer_billing_address"]) : ::Pago::UNSET), customer_tax_id: (data.key?("customer_tax_id") ? data["customer_tax_id"] : ::Pago::UNSET), locale: (data.key?("locale") ? data["locale"] : ::Pago::UNSET), payment_processor_metadata: (data.key?("payment_processor_metadata") ? data["payment_processor_metadata"] : ::Pago::UNSET), billing_address_fields: (data.key?("billing_address_fields") ? Models::CheckoutBillingAddressFields.from_json(data["billing_address_fields"]) : ::Pago::UNSET), products: (data.key?("products") ? ::Pago::Serde.array(data["products"]) { |item0| Models::CheckoutProduct.from_json(item0) } : ::Pago::UNSET), product: (data.key?("product") ? Models::CheckoutProduct.from_json(data["product"]) : ::Pago::UNSET), product_price: (data.key?("product_price") ? ::Pago::Serde.union(data["product_price"], variants: [Unions::LegacyRecurringProductPrice, Unions::ProductPrice]) : ::Pago::UNSET), prices: (data.key?("prices") ? ::Pago::Serde.map(data["prices"]) { |value0| ::Pago::Serde.array(value0) { |item1| ::Pago::Serde.union(item1, variants: [Unions::LegacyRecurringProductPrice, Unions::ProductPrice]) } } : ::Pago::UNSET), discount: (data.key?("discount") ? ::Pago::Serde.union(data["discount"], variants: [Models::CheckoutDiscountFixedOnceForeverDuration, Models::CheckoutDiscountFixedRepeatDuration, Models::CheckoutDiscountPercentageOnceForeverDuration, Models::CheckoutDiscountPercentageRepeatDuration]) : ::Pago::UNSET), organization: (data.key?("organization") ? Models::CheckoutOrganization.from_json(data["organization"]) : ::Pago::UNSET), attached_custom_fields: (data.key?("attached_custom_fields") ? ::Pago::Serde.array(data["attached_custom_fields"]) { |item0| Models::AttachedCustomField.from_json(item0) } : ::Pago::UNSET), customer_session_token: (data.key?("customer_session_token") ? data["customer_session_token"] : ::Pago::UNSET) ), data ) end |