Class SkuCreateParams.Builder

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

public static class SkuCreateParams.Builder extends Object
  • Constructor Details

    • Builder

      public Builder()
  • Method Details

    • build

      public SkuCreateParams build()
      Finalize and obtain parameter instance from this builder.
    • setActive

      public SkuCreateParams.Builder setActive(Boolean active)
      Whether the SKU is available for purchase. Default to true.
    • putAttribute

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

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

      public SkuCreateParams.Builder setCurrency(String currency)
      Three-letter ISO currency code, in lowercase. Must be a supported currency.
    • addExpand

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

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

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

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

      public SkuCreateParams.Builder setId(String id)
      The identifier for the SKU. Must be unique. If not provided, an identifier will be randomly generated.
    • setImage

      public SkuCreateParams.Builder setImage(String image)
      The URL of an image for this SKU, meant to be displayable to the customer.
    • setInventory

      public SkuCreateParams.Builder setInventory(SkuCreateParams.Inventory inventory)
      Description of the SKU's inventory.
    • putMetadata

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

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

      public SkuCreateParams.Builder setPackageDimensions(SkuCreateParams.PackageDimensions packageDimensions)
      The dimensions of this SKU for shipping purposes.
    • setPrice

      public SkuCreateParams.Builder setPrice(Long price)
      The cost of the item as a nonnegative integer in the smallest currency unit (that is, 100 cents to charge $1.00, or 100 to charge ¥100, Japanese Yen being a zero-decimal currency).
    • setProduct

      public SkuCreateParams.Builder setProduct(String product)
      The ID of the product this SKU is associated with. Must be a product with type good.