Class QuoteCreateParams.Builder

java.lang.Object
com.stripe.param.QuoteCreateParams.Builder
Enclosing class:
QuoteCreateParams

public static class QuoteCreateParams.Builder extends Object
  • Constructor Details

    • Builder

      public Builder()
  • Method Details

    • build

      public QuoteCreateParams build()
      Finalize and obtain parameter instance from this builder.
    • setApplicationFeeAmount

      public QuoteCreateParams.Builder setApplicationFeeAmount(Long applicationFeeAmount)
      The amount of the application fee (if any) that will be requested to be applied to the payment and transferred to the application owner's Stripe account. There cannot be any line items with recurring prices when using this field.
    • setApplicationFeeAmount

      public QuoteCreateParams.Builder setApplicationFeeAmount(EmptyParam applicationFeeAmount)
      The amount of the application fee (if any) that will be requested to be applied to the payment and transferred to the application owner's Stripe account. There cannot be any line items with recurring prices when using this field.
    • setApplicationFeePercent

      public QuoteCreateParams.Builder setApplicationFeePercent(BigDecimal applicationFeePercent)
      A non-negative decimal between 0 and 100, with at most two decimal places. This represents the percentage of the subscription invoice total that will be transferred to the application owner's Stripe account. There must be at least 1 line item with a recurring price to use this field.
    • setApplicationFeePercent

      public QuoteCreateParams.Builder setApplicationFeePercent(EmptyParam applicationFeePercent)
      A non-negative decimal between 0 and 100, with at most two decimal places. This represents the percentage of the subscription invoice total that will be transferred to the application owner's Stripe account. There must be at least 1 line item with a recurring price to use this field.
    • setAutomaticTax

      public QuoteCreateParams.Builder setAutomaticTax(QuoteCreateParams.AutomaticTax automaticTax)
      Settings for automatic tax lookup for this quote and resulting invoices and subscriptions.
    • setCollectionMethod

      public QuoteCreateParams.Builder setCollectionMethod(QuoteCreateParams.CollectionMethod collectionMethod)
      Either charge_automatically, or send_invoice. When charging automatically, Stripe will attempt to pay invoices at the end of the subscription cycle or at invoice finalization using the default payment method attached to the subscription or customer. When sending an invoice, Stripe will email your customer an invoice with payment instructions and mark the subscription as active. Defaults to charge_automatically.
    • setCustomer

      public QuoteCreateParams.Builder setCustomer(String customer)
      The customer for which this quote belongs to. A customer is required before finalizing the quote. Once specified, it cannot be changed.
    • addDefaultTaxRate

      public QuoteCreateParams.Builder addDefaultTaxRate(String element)
      Add an element to `defaultTaxRates` list. A list is initialized for the first `add/addAll` call, and subsequent calls adds additional elements to the original list. See QuoteCreateParams.defaultTaxRates for the field documentation.
    • addAllDefaultTaxRate

      public QuoteCreateParams.Builder addAllDefaultTaxRate(List<String> elements)
      Add all elements to `defaultTaxRates` list. A list is initialized for the first `add/addAll` call, and subsequent calls adds additional elements to the original list. See QuoteCreateParams.defaultTaxRates for the field documentation.
    • setDefaultTaxRates

      public QuoteCreateParams.Builder setDefaultTaxRates(EmptyParam defaultTaxRates)
      The tax rates that will apply to any line item that does not have tax_rates set.
    • setDefaultTaxRates

      public QuoteCreateParams.Builder setDefaultTaxRates(List<String> defaultTaxRates)
      The tax rates that will apply to any line item that does not have tax_rates set.
    • setDescription

      public QuoteCreateParams.Builder setDescription(String description)
      A description that will be displayed on the quote PDF. If no value is passed, the default description configured in your quote template settings will be used.
    • setDescription

      public QuoteCreateParams.Builder setDescription(EmptyParam description)
      A description that will be displayed on the quote PDF. If no value is passed, the default description configured in your quote template settings will be used.
    • addDiscount

      Add an element to `discounts` list. A list is initialized for the first `add/addAll` call, and subsequent calls adds additional elements to the original list. See QuoteCreateParams.discounts for the field documentation.
    • addAllDiscount

      public QuoteCreateParams.Builder addAllDiscount(List<QuoteCreateParams.Discount> elements)
      Add all elements to `discounts` list. A list is initialized for the first `add/addAll` call, and subsequent calls adds additional elements to the original list. See QuoteCreateParams.discounts for the field documentation.
    • setDiscounts

      public QuoteCreateParams.Builder setDiscounts(EmptyParam discounts)
      The discounts applied to the quote. You can only set up to one discount.
    • setDiscounts

      public QuoteCreateParams.Builder setDiscounts(List<QuoteCreateParams.Discount> discounts)
      The discounts applied to the quote. You can only set up to one discount.
    • addExpand

      public QuoteCreateParams.Builder addExpand(String element)
      Add an element to `expand` list. A list is initialized for the first `add/addAll` call, and subsequent calls adds additional elements to the original list. See QuoteCreateParams.expand for the field documentation.
    • addAllExpand

      public QuoteCreateParams.Builder addAllExpand(List<String> elements)
      Add all elements to `expand` list. A list is initialized for the first `add/addAll` call, and subsequent calls adds additional elements to the original list. See QuoteCreateParams.expand for the field documentation.
    • setExpiresAt

      public QuoteCreateParams.Builder setExpiresAt(Long expiresAt)
      A future timestamp on which the quote will be canceled if in open or draft status. Measured in seconds since the Unix epoch. If no value is passed, the default expiration date configured in your quote template settings will be used.
    • putExtraParam

      public QuoteCreateParams.Builder putExtraParam(String key, Object value)
      Add a key/value pair to `extraParams` map. A map is initialized for the first `put/putAll` call, and subsequent calls add additional key/value pairs to the original map. See QuoteCreateParams.extraParams for the field documentation.
    • putAllExtraParam

      public QuoteCreateParams.Builder putAllExtraParam(Map<String,Object> map)
      Add all map key/value pairs to `extraParams` map. A map is initialized for the first `put/putAll` call, and subsequent calls add additional key/value pairs to the original map. See QuoteCreateParams.extraParams for the field documentation.
    • setFooter

      public QuoteCreateParams.Builder setFooter(String footer)
      A footer that will be displayed on the quote PDF. If no value is passed, the default footer configured in your quote template settings will be used.
    • setFooter

      public QuoteCreateParams.Builder setFooter(EmptyParam footer)
      A footer that will be displayed on the quote PDF. If no value is passed, the default footer configured in your quote template settings will be used.
    • setFromQuote

      public QuoteCreateParams.Builder setFromQuote(QuoteCreateParams.FromQuote fromQuote)
      Clone an existing quote. The new quote will be created in status=draft. When using this parameter, you cannot specify any other parameters except for expires_at.
    • setHeader

      public QuoteCreateParams.Builder setHeader(String header)
      A header that will be displayed on the quote PDF. If no value is passed, the default header configured in your quote template settings will be used.
    • setHeader

      public QuoteCreateParams.Builder setHeader(EmptyParam header)
      A header that will be displayed on the quote PDF. If no value is passed, the default header configured in your quote template settings will be used.
    • setInvoiceSettings

      public QuoteCreateParams.Builder setInvoiceSettings(QuoteCreateParams.InvoiceSettings invoiceSettings)
      All invoices will be billed using the specified settings.
    • addLineItem

      Add an element to `lineItems` list. A list is initialized for the first `add/addAll` call, and subsequent calls adds additional elements to the original list. See QuoteCreateParams.lineItems for the field documentation.
    • addAllLineItem

      public QuoteCreateParams.Builder addAllLineItem(List<QuoteCreateParams.LineItem> elements)
      Add all elements to `lineItems` list. A list is initialized for the first `add/addAll` call, and subsequent calls adds additional elements to the original list. See QuoteCreateParams.lineItems for the field documentation.
    • putMetadata

      public QuoteCreateParams.Builder putMetadata(String key, String value)
      Add a key/value pair to `metadata` map. A map is initialized for the first `put/putAll` call, and subsequent calls add additional key/value pairs to the original map. See QuoteCreateParams.metadata for the field documentation.
    • putAllMetadata

      public QuoteCreateParams.Builder putAllMetadata(Map<String,String> map)
      Add all map key/value pairs to `metadata` map. A map is initialized for the first `put/putAll` call, and subsequent calls add additional key/value pairs to the original map. See QuoteCreateParams.metadata for the field documentation.
    • setOnBehalfOf

      public QuoteCreateParams.Builder setOnBehalfOf(String onBehalfOf)
      The account on behalf of which to charge.
    • setOnBehalfOf

      public QuoteCreateParams.Builder setOnBehalfOf(EmptyParam onBehalfOf)
      The account on behalf of which to charge.
    • setSubscriptionData

      public QuoteCreateParams.Builder setSubscriptionData(QuoteCreateParams.SubscriptionData subscriptionData)
      When creating a subscription or subscription schedule, the specified configuration data will be used. There must be at least one line item with a recurring price for a subscription or subscription schedule to be created. A subscription schedule is created if subscription_data[effective_date] is present and in the future, otherwise a subscription is created.
    • setTestClock

      public QuoteCreateParams.Builder setTestClock(String testClock)
      ID of the test clock to attach to the quote.
    • setTransferData

      public QuoteCreateParams.Builder setTransferData(QuoteCreateParams.TransferData transferData)
      The data with which to automatically create a Transfer for each of the invoices.
    • setTransferData

      public QuoteCreateParams.Builder setTransferData(EmptyParam transferData)
      The data with which to automatically create a Transfer for each of the invoices.