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.
1268 1269 1270 1271 1272 1273 1274 1275 1276 1277 1278 1279 1280 1281 1282 1283 1284 1285 1286 1287 1288 |
# File 'lib/stripe/services/order_service.rb', line 1268 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.
1248 1249 1250 |
# File 'lib/stripe/services/order_service.rb', line 1248 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.
1252 1253 1254 |
# File 'lib/stripe/services/order_service.rb', line 1252 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.
1254 1255 1256 |
# File 'lib/stripe/services/order_service.rb', line 1254 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`.
1256 1257 1258 |
# File 'lib/stripe/services/order_service.rb', line 1256 def @metadata end |
#name ⇒ Object
The product’s name, meant to be displayable to the customer.
1258 1259 1260 |
# File 'lib/stripe/services/order_service.rb', line 1258 def name @name end |
#package_dimensions ⇒ Object
The dimensions of this product for shipping purposes.
1260 1261 1262 |
# File 'lib/stripe/services/order_service.rb', line 1260 def package_dimensions @package_dimensions end |
#shippable ⇒ Object
Whether this product is shipped (i.e., physical goods).
1262 1263 1264 |
# File 'lib/stripe/services/order_service.rb', line 1262 def shippable @shippable end |
#tax_code ⇒ Object
A [tax code](stripe.com/docs/tax/tax-categories) ID.
1264 1265 1266 |
# File 'lib/stripe/services/order_service.rb', line 1264 def tax_code @tax_code end |
#url ⇒ Object
A URL of a publicly-accessible webpage for this product.
1266 1267 1268 |
# File 'lib/stripe/services/order_service.rb', line 1266 def url @url end |