Class InvoiceLineItemUpdateParams.Builder

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

public static class InvoiceLineItemUpdateParams.Builder extends Object
  • Constructor Details

    • Builder

      public Builder()
  • Method Details

    • build

      Finalize and obtain parameter instance from this builder.
    • setAmount

      public InvoiceLineItemUpdateParams.Builder setAmount(Long amount)
      The integer amount in cents (or local equivalent) of the charge to be applied to the upcoming invoice. If you want to apply a credit to the customer's account, pass a negative amount.
    • setDescription

      public InvoiceLineItemUpdateParams.Builder setDescription(String description)
      An arbitrary string which you can attach to the invoice item. The description is displayed in the invoice for easy tracking.
    • setDescription

      public InvoiceLineItemUpdateParams.Builder setDescription(EmptyParam description)
      An arbitrary string which you can attach to the invoice item. The description is displayed in the invoice for easy tracking.
    • setDiscountable

      public InvoiceLineItemUpdateParams.Builder setDiscountable(Boolean discountable)
      Controls whether discounts apply to this line item. Defaults to false for prorations or negative line items, and true for all other line items. Cannot be set to true for prorations.
    • 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 InvoiceLineItemUpdateParams.discounts for the field documentation.
    • addAllDiscount

      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 InvoiceLineItemUpdateParams.discounts for the field documentation.
    • setDiscounts

      public InvoiceLineItemUpdateParams.Builder setDiscounts(EmptyParam discounts)
      The coupons, promotion codes & existing discounts which apply to the line item. Item discounts are applied before invoice discounts. Pass an empty string to remove previously-defined discounts.
    • setDiscounts

      The coupons, promotion codes & existing discounts which apply to the line item. Item discounts are applied before invoice discounts. Pass an empty string to remove previously-defined discounts.
    • addExpand

      public InvoiceLineItemUpdateParams.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 InvoiceLineItemUpdateParams.expand for the field documentation.
    • addAllExpand

      public InvoiceLineItemUpdateParams.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 InvoiceLineItemUpdateParams.expand for the field documentation.
    • putExtraParam

      public InvoiceLineItemUpdateParams.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 InvoiceLineItemUpdateParams.extraParams for the field documentation.
    • putAllExtraParam

      public InvoiceLineItemUpdateParams.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 InvoiceLineItemUpdateParams.extraParams for the field documentation.
    • putMetadata

      public InvoiceLineItemUpdateParams.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 InvoiceLineItemUpdateParams.metadata for the field documentation.
    • putAllMetadata

      public InvoiceLineItemUpdateParams.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 InvoiceLineItemUpdateParams.metadata for the field documentation.
    • setMetadata

      public InvoiceLineItemUpdateParams.Builder setMetadata(EmptyParam metadata)
      Set of key-value pairs that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to metadata. For type=recurring line items, the incoming metadata specified on the request is directly used to set this value, in contrast to type=invoiceitem line items, where any existing metadata on the invoice line is merged with the incoming data.
    • setMetadata

      public InvoiceLineItemUpdateParams.Builder setMetadata(Map<String,String> metadata)
      Set of key-value pairs that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to metadata. For type=recurring line items, the incoming metadata specified on the request is directly used to set this value, in contrast to type=invoiceitem line items, where any existing metadata on the invoice line is merged with the incoming data.
    • setPeriod

      The period associated with this invoice item. When set to different values, the period will be rendered on the invoice. If you have Stripe Revenue Recognition enabled, the period will be used to recognize and defer revenue. See the Revenue Recognition documentation for details.
    • setPrice

      The ID of the price object.
    • setPrice

      The ID of the price object.
    • setPriceData

      Data used to generate a new Price object inline.
    • setQuantity

      public InvoiceLineItemUpdateParams.Builder setQuantity(Long quantity)
      Non-negative integer. The quantity of units for the line item.
    • addTaxAmount

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

      Add all elements to `taxAmounts` list. A list is initialized for the first `add/addAll` call, and subsequent calls adds additional elements to the original list. See InvoiceLineItemUpdateParams.taxAmounts for the field documentation.
    • setTaxAmounts

      public InvoiceLineItemUpdateParams.Builder setTaxAmounts(EmptyParam taxAmounts)
      A list of up to 10 tax amounts for this line item. This can be useful if you calculate taxes on your own or use a third-party to calculate them. You cannot set tax amounts if any line item has tax_rates or if the invoice has default_tax_rates or uses automatic tax. Pass an empty string to remove previously defined tax amounts.
    • setTaxAmounts

      A list of up to 10 tax amounts for this line item. This can be useful if you calculate taxes on your own or use a third-party to calculate them. You cannot set tax amounts if any line item has tax_rates or if the invoice has default_tax_rates or uses automatic tax. Pass an empty string to remove previously defined tax amounts.
    • addTaxRate

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

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

      public InvoiceLineItemUpdateParams.Builder setTaxRates(EmptyParam taxRates)
      The tax rates which apply to the line item. When set, the default_tax_rates on the invoice do not apply to this line item. Pass an empty string to remove previously-defined tax rates.
    • setTaxRates

      public InvoiceLineItemUpdateParams.Builder setTaxRates(List<String> taxRates)
      The tax rates which apply to the line item. When set, the default_tax_rates on the invoice do not apply to this line item. Pass an empty string to remove previously-defined tax rates.