NAME
Net::API::Stripe::Order::Item - A Stripe Order Item Object
SYNOPSIS
my $item = $stripe->order_item({
amount => 2000,
currency => 'jpy',
description => 'Onsite support service',
parent => $order_object,
# hours
quantity => 200,
type => 'sku',
});
See documentation in Net::API::Stripe for example to make api calls to Stripe to create those objects.
VERSION
v0.100.0
DESCRIPTION
A representation of the constituent items of any given order. Can be used to represent SKUs, shipping costs, or taxes owed on the order.
CONSTRUCTOR
- new( %ARG )
-
Creates a new Net::API::Stripe::Order::Item object. It may also take an hash like arguments, that also are method of the same name.
METHODS
- object string, value is "order_item"
-
String representing the object’s type. Objects of the same type share the same value.
- amount integer
-
A positive integer in the smallest currency unit (that is, 100 cents for $1.00, or 1 for ¥1, Japanese Yen being a zero-decimal currency) representing the total amount for the line item.
- currency currency
-
Three-letter ISO currency code, in lowercase. Must be a supported currency.
- description string
-
Description of the line item, meant to be displayable to the user (e.g., "Express shipping").
- parent string (expandable) discount or sku
-
The ID of the associated object for this line item. Expandable if not null (e.g., expandable to a SKU).
When expanded, this is a Net::API::Stripe::Order object.
- quantity positive integer
-
A positive integer representing the number of instances of parent that are included in this order item. Applicable/present only if type is sku.
- type string
-
The type of line item. One of sku, tax, shipping, or discount.
API SAMPLE
{
"object": "order_item",
"amount": 1500,
"currency": "jpy",
"description": "T-shirt",
"parent": "sk_fake123456789",
"quantity": null,
"type": "sku"
}
HISTORY
v0.1
Initial version
AUTHOR
Jacques Deguest <jack@deguest.jp>
SEE ALSO
Stripe API documentation:
https://stripe.com/docs/api/order_items
COPYRIGHT & LICENSE
Copyright (c) 2019-2020 DEGUEST Pte. Ltd.
You can use, copy, modify and redistribute this package and associated files under the same terms as Perl itself.