Class: Stripe::OrderService::UpdateParams::LineItem::ProductData
- Inherits:
-
RequestParams
- Object
- RequestParams
- Stripe::OrderService::UpdateParams::LineItem::ProductData
- Defined in:
- lib/stripe/services/order_service.rb
Defined Under Namespace
Classes: PackageDimensions
Instance Attribute Summary collapse
-
#description ⇒ Object
The product’s description, meant to be displayable to the customer.
-
#id ⇒ Object
A unique identifier for this product.
-
#images ⇒ Object
A list of up to 8 URLs of images for this product, meant to be displayable to the customer.
-
#metadata ⇒ Object
Set of [key-value pairs](stripe.com/docs/api/metadata) that you can attach to an object.
-
#name ⇒ Object
The product’s name, meant to be displayable to the customer.
-
#package_dimensions ⇒ Object
The dimensions of this product for shipping purposes.
-
#shippable ⇒ Object
Whether this product is shipped (i.e., physical goods).
-
#tax_code ⇒ Object
A [tax code](stripe.com/docs/tax/tax-categories) ID.
-
#url ⇒ Object
A URL of a publicly-accessible webpage for this product.
Instance Method Summary collapse
-
#initialize(description: nil, id: nil, images: nil, metadata: nil, name: nil, package_dimensions: nil, shippable: nil, tax_code: nil, url: nil) ⇒ ProductData
constructor
A new instance of ProductData.
Methods inherited from RequestParams
Constructor Details
#initialize(description: nil, id: nil, images: nil, metadata: nil, name: nil, package_dimensions: nil, shippable: nil, tax_code: nil, url: nil) ⇒ ProductData
Returns a new instance of ProductData.
1247 1248 1249 1250 1251 1252 1253 1254 1255 1256 1257 1258 1259 1260 1261 1262 1263 1264 1265 1266 1267 |
# File 'lib/stripe/services/order_service.rb', line 1247 def initialize( description: nil, id: nil, images: nil, metadata: nil, name: nil, package_dimensions: nil, shippable: nil, tax_code: nil, url: nil ) @description = description @id = id @images = images @metadata = @name = name @package_dimensions = package_dimensions @shippable = shippable @tax_code = tax_code @url = url end |
Instance Attribute Details
#description ⇒ Object
The product’s description, meant to be displayable to the customer. Use this field to optionally store a long form explanation of the product being sold for your own rendering purposes.
1227 1228 1229 |
# File 'lib/stripe/services/order_service.rb', line 1227 def description @description end |
#id ⇒ Object
A unique identifier for this product.
‘product_data` automatically creates a Product with this ID. If a Product with the same ID already exists, then `product_data` re-uses it to avoid duplicates. If any of the fields in the existing Product are different from the values in `product_data`, `product_data` updates the existing Product with the new information. So set `product_data` to the same string every time you sell the same product, but don’t re-use the same string for different products.
1231 1232 1233 |
# File 'lib/stripe/services/order_service.rb', line 1231 def id @id end |
#images ⇒ Object
A list of up to 8 URLs of images for this product, meant to be displayable to the customer.
1233 1234 1235 |
# File 'lib/stripe/services/order_service.rb', line 1233 def images @images end |
#metadata ⇒ Object
Set of [key-value pairs](stripe.com/docs/api/metadata) 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`.
1235 1236 1237 |
# File 'lib/stripe/services/order_service.rb', line 1235 def @metadata end |
#name ⇒ Object
The product’s name, meant to be displayable to the customer.
1237 1238 1239 |
# File 'lib/stripe/services/order_service.rb', line 1237 def name @name end |
#package_dimensions ⇒ Object
The dimensions of this product for shipping purposes.
1239 1240 1241 |
# File 'lib/stripe/services/order_service.rb', line 1239 def package_dimensions @package_dimensions end |
#shippable ⇒ Object
Whether this product is shipped (i.e., physical goods).
1241 1242 1243 |
# File 'lib/stripe/services/order_service.rb', line 1241 def shippable @shippable end |
#tax_code ⇒ Object
A [tax code](stripe.com/docs/tax/tax-categories) ID.
1243 1244 1245 |
# File 'lib/stripe/services/order_service.rb', line 1243 def tax_code @tax_code end |
#url ⇒ Object
A URL of a publicly-accessible webpage for this product.
1245 1246 1247 |
# File 'lib/stripe/services/order_service.rb', line 1245 def url @url end |