Class: WhopSDK::Models::InvoiceCreateParams::Body::CreateInvoiceInputWithProductID
- Inherits:
-
Internal::Type::BaseModel
- Object
- Internal::Type::BaseModel
- WhopSDK::Models::InvoiceCreateParams::Body::CreateInvoiceInputWithProductID
- Defined in:
- lib/whop_sdk/models/invoice_create_params.rb
Defined Under Namespace
Classes: BillingAddress, LineItem, Plan
Instance Attribute Summary collapse
-
#automatically_finalizes_at ⇒ Time?
The date and time when the invoice will be automatically finalized.
-
#billing_address ⇒ WhopSDK::Models::InvoiceCreateParams::Body::CreateInvoiceInputWithProductID::BillingAddress?
Inline billing address to create a new mailing address for this invoice.
-
#charge_buyer_fee ⇒ Boolean?
Whether to charge the customer a buyer fee on this invoice.
-
#collection_method ⇒ Symbol, WhopSDK::Models::CollectionMethod
How the invoice should be collected.
-
#company_id ⇒ String
The unique identifier of the company to create this invoice for.
-
#customer_name ⇒ String?
The name of the customer.
-
#due_date ⇒ Time?
The date by which the invoice must be paid.
-
#email_address ⇒ String?
The email address of the customer.
-
#line_items ⇒ Array<WhopSDK::Models::InvoiceCreateParams::Body::CreateInvoiceInputWithProductID::LineItem>?
Optional line items that break down the invoice total.
-
#mailing_address_id ⇒ String?
The unique identifier of an existing mailing address to attach to this invoice.
-
#member_id ⇒ String?
The unique identifier of an existing member to create this invoice for.
-
#payment_method_id ⇒ String?
The unique identifier of the payment method to charge.
-
#payment_token_id ⇒ String?
The payment token ID to use for this invoice.
-
#plan ⇒ WhopSDK::Models::InvoiceCreateParams::Body::CreateInvoiceInputWithProductID::Plan
The plan attributes defining the price, currency, and billing interval for this invoice.
-
#product_id ⇒ String
The unique identifier of an existing product to create this invoice for.
-
#save_as_draft ⇒ Boolean?
When true, creates the invoice as a draft without sending or charging.
-
#subscription_billing_anchor_at ⇒ Time?
The date that defines when the subscription billing cycle should start.
Instance Method Summary collapse
-
#initialize(city: nil, country: nil, line1: nil, line2: nil, name: nil, phone: nil, postal_code: nil, state: nil, tax_id_type: nil, tax_id_value: nil) ⇒ Object
constructor
Inline billing address to create a new mailing address for this invoice.
Methods inherited from Internal::Type::BaseModel
==, #==, #[], coerce, #deconstruct_keys, #deep_to_h, dump, fields, hash, #hash, inherited, inspect, #inspect, known_fields, optional, recursively_to_h, required, #to_h, #to_json, #to_s, to_sorbet_type, #to_yaml
Methods included from Internal::Type::Converter
#coerce, coerce, #dump, dump, #inspect, inspect, meta_info, new_coerce_state, type_info
Methods included from Internal::Util::SorbetRuntimeSupport
#const_missing, #define_sorbet_constant!, #sorbet_constant_defined?, #to_sorbet_type, to_sorbet_type
Constructor Details
#initialize(city: nil, country: nil, line1: nil, line2: nil, name: nil, phone: nil, postal_code: nil, state: nil, tax_id_type: nil, tax_id_value: nil) ⇒ Object
Inline billing address to create a new mailing address for this invoice. Cannot be used together with mailing_address_id.
|
|
# File 'lib/whop_sdk/models/invoice_create_params.rb', line 705
|
Instance Attribute Details
#automatically_finalizes_at ⇒ Time?
The date and time when the invoice will be automatically finalized. For charge_automatically, triggers an automatic charge. For send_invoice, sends the invoice email to the customer at the specified time.
614 |
# File 'lib/whop_sdk/models/invoice_create_params.rb', line 614 optional :automatically_finalizes_at, Time, nil?: true |
#billing_address ⇒ WhopSDK::Models::InvoiceCreateParams::Body::CreateInvoiceInputWithProductID::BillingAddress?
Inline billing address to create a new mailing address for this invoice. Cannot be used together with mailing_address_id.
621 622 623 |
# File 'lib/whop_sdk/models/invoice_create_params.rb', line 621 optional :billing_address, -> { WhopSDK::InvoiceCreateParams::Body::CreateInvoiceInputWithProductID::BillingAddress }, nil?: true |
#charge_buyer_fee ⇒ Boolean?
Whether to charge the customer a buyer fee on this invoice.
629 |
# File 'lib/whop_sdk/models/invoice_create_params.rb', line 629 optional :charge_buyer_fee, WhopSDK::Internal::Type::Boolean, nil?: true |
#collection_method ⇒ Symbol, WhopSDK::Models::CollectionMethod
How the invoice should be collected. Use charge_automatically to charge a stored payment method, or send_invoice to email the customer.
587 |
# File 'lib/whop_sdk/models/invoice_create_params.rb', line 587 required :collection_method, enum: -> { WhopSDK::CollectionMethod } |
#company_id ⇒ String
The unique identifier of the company to create this invoice for.
593 |
# File 'lib/whop_sdk/models/invoice_create_params.rb', line 593 required :company_id, String |
#customer_name ⇒ String?
The name of the customer. Required when creating an invoice for a customer who is not yet a member of the company.
636 |
# File 'lib/whop_sdk/models/invoice_create_params.rb', line 636 optional :customer_name, String, nil?: true |
#due_date ⇒ Time?
The date by which the invoice must be paid. Required unless save_as_draft is true.
643 |
# File 'lib/whop_sdk/models/invoice_create_params.rb', line 643 optional :due_date, Time, nil?: true |
#email_address ⇒ String?
The email address of the customer. Required when creating an invoice for a customer who is not yet a member of the company.
650 |
# File 'lib/whop_sdk/models/invoice_create_params.rb', line 650 optional :email_address, String, nil?: true |
#line_items ⇒ Array<WhopSDK::Models::InvoiceCreateParams::Body::CreateInvoiceInputWithProductID::LineItem>?
Optional line items that break down the invoice total. When provided, the sum of (quantity * unit_price) for all items must equal the plan price.
657 658 659 660 661 |
# File 'lib/whop_sdk/models/invoice_create_params.rb', line 657 optional :line_items, -> { WhopSDK::Internal::Type::ArrayOf[WhopSDK::InvoiceCreateParams::Body::CreateInvoiceInputWithProductID::LineItem] }, nil?: true |
#mailing_address_id ⇒ String?
The unique identifier of an existing mailing address to attach to this invoice. Cannot be used together with billing_address.
668 |
# File 'lib/whop_sdk/models/invoice_create_params.rb', line 668 optional :mailing_address_id, String, nil?: true |
#member_id ⇒ String?
The unique identifier of an existing member to create this invoice for. If not provided, you must supply an email_address and customer_name.
675 |
# File 'lib/whop_sdk/models/invoice_create_params.rb', line 675 optional :member_id, String, nil?: true |
#payment_method_id ⇒ String?
The unique identifier of the payment method to charge. Required when collection_method is charge_automatically.
682 |
# File 'lib/whop_sdk/models/invoice_create_params.rb', line 682 optional :payment_method_id, String, nil?: true |
#payment_token_id ⇒ String?
The payment token ID to use for this invoice. If using charge_automatically, you must provide a payment_token.
689 |
# File 'lib/whop_sdk/models/invoice_create_params.rb', line 689 optional :payment_token_id, String, nil?: true |
#plan ⇒ WhopSDK::Models::InvoiceCreateParams::Body::CreateInvoiceInputWithProductID::Plan
The plan attributes defining the price, currency, and billing interval for this invoice.
600 |
# File 'lib/whop_sdk/models/invoice_create_params.rb', line 600 required :plan, -> { WhopSDK::InvoiceCreateParams::Body::CreateInvoiceInputWithProductID::Plan } |
#product_id ⇒ String
The unique identifier of an existing product to create this invoice for.
606 |
# File 'lib/whop_sdk/models/invoice_create_params.rb', line 606 required :product_id, String |
#save_as_draft ⇒ Boolean?
When true, creates the invoice as a draft without sending or charging. Relaxes customer and due date requirements.
696 |
# File 'lib/whop_sdk/models/invoice_create_params.rb', line 696 optional :save_as_draft, WhopSDK::Internal::Type::Boolean, nil?: true |
#subscription_billing_anchor_at ⇒ Time?
The date that defines when the subscription billing cycle should start. When set on a renewal plan invoice, this anchors all future billing periods to this date.
703 |
# File 'lib/whop_sdk/models/invoice_create_params.rb', line 703 optional :subscription_billing_anchor_at, Time, nil?: true |