Class: Recurly::Requests::LineItemCreate
- Inherits:
-
Recurly::Request
- Object
- Recurly::Request
- Recurly::Requests::LineItemCreate
- Defined in:
- lib/recurly/requests/line_item_create.rb
Instance Attribute Summary collapse
-
#accounting_code ⇒ String
Accounting Code for the
LineItem. -
#credit_reason_code ⇒ String
The reason the credit was given when line item is ‘type=credit`.
-
#currency ⇒ String
3-letter ISO 4217 currency code.
-
#description ⇒ String
Description that appears on the invoice.
-
#end_date ⇒ DateTime
If this date is provided, it indicates the end of a time range.
-
#item_code ⇒ String
Unique code to identify an item, when the Catalog feature is enabled.
-
#item_id ⇒ String
Available when the Catalog feature is enabled.
-
#product_code ⇒ String
Optional field to track a product code or SKU for the line item.
-
#quantity ⇒ Integer
This number will be multiplied by the unit amount to compute the subtotal before any discounts or taxes.
-
#revenue_schedule_type ⇒ String
Revenue schedule type.
-
#start_date ⇒ DateTime
If an end date is present, this is value indicates the beginning of a billing time range.
-
#tax_code ⇒ String
Optional field used by Avalara, Vertex, and Recurly’s EU VAT tax feature to determine taxation rules.
-
#tax_exempt ⇒ Boolean
trueexempts tax on charges,falseapplies tax on charges. -
#type ⇒ String
Line item type.
-
#unit_amount ⇒ Float
A positive or negative amount with ‘type=charge` will result in a positive
unit_amount.
Attributes inherited from Recurly::Request
Method Summary
Methods inherited from Recurly::Request
Methods included from Schema::SchemaFactory
Methods included from Schema::RequestCaster
Methods included from Schema::ResourceCaster
Methods included from Schema::SchemaValidator
#get_did_you_mean, #validate!, #validate_attribute!
Instance Attribute Details
#accounting_code ⇒ String
Returns Accounting Code for the LineItem. If item_code/item_id is part of the request then accounting_code must be absent.
11 |
# File 'lib/recurly/requests/line_item_create.rb', line 11 define_attribute :accounting_code, String |
#credit_reason_code ⇒ String
Returns The reason the credit was given when line item is ‘type=credit`. When the Credit Invoices feature is enabled, the value can be set and will default to general. When the Credit Invoices feature is not enabled, the value will always be null.
15 |
# File 'lib/recurly/requests/line_item_create.rb', line 15 define_attribute :credit_reason_code, String |
#currency ⇒ String
Returns 3-letter ISO 4217 currency code. If item_code/item_id is part of the request then currency is optional, if the site has a single default currency. currency is required if item_code/item_id is present, and there are multiple currencies defined on the site. If item_code/item_id is not present currency is required.
19 |
# File 'lib/recurly/requests/line_item_create.rb', line 19 define_attribute :currency, String |
#description ⇒ String
Returns Description that appears on the invoice. If item_code/item_id is part of the request then description must be absent.
23 |
# File 'lib/recurly/requests/line_item_create.rb', line 23 define_attribute :description, String |
#end_date ⇒ DateTime
Returns If this date is provided, it indicates the end of a time range.
27 |
# File 'lib/recurly/requests/line_item_create.rb', line 27 define_attribute :end_date, DateTime |
#item_code ⇒ String
Returns Unique code to identify an item, when the Catalog feature is enabled.
31 |
# File 'lib/recurly/requests/line_item_create.rb', line 31 define_attribute :item_code, String |
#item_id ⇒ String
Returns Available when the Catalog feature is enabled.
35 |
# File 'lib/recurly/requests/line_item_create.rb', line 35 define_attribute :item_id, String |
#product_code ⇒ String
Returns Optional field to track a product code or SKU for the line item. This can be used to later reporting on product purchases. For Vertex tax calculations, this field will be used as the Vertex product field. If item_code/item_id is part of the request then product_code must be absent.
39 |
# File 'lib/recurly/requests/line_item_create.rb', line 39 define_attribute :product_code, String |
#quantity ⇒ Integer
Returns This number will be multiplied by the unit amount to compute the subtotal before any discounts or taxes.
43 |
# File 'lib/recurly/requests/line_item_create.rb', line 43 define_attribute :quantity, Integer |
#revenue_schedule_type ⇒ String
Returns Revenue schedule type.
47 |
# File 'lib/recurly/requests/line_item_create.rb', line 47 define_attribute :revenue_schedule_type, String |
#start_date ⇒ DateTime
Returns If an end date is present, this is value indicates the beginning of a billing time range. If no end date is present it indicates billing for a specific date. Defaults to the current date-time.
51 |
# File 'lib/recurly/requests/line_item_create.rb', line 51 define_attribute :start_date, DateTime |
#tax_code ⇒ String
Returns Optional field used by Avalara, Vertex, and Recurly’s EU VAT tax feature to determine taxation rules. If you have your own AvaTax or Vertex account configured, use their tax codes to assign specific tax rules. If you are using Recurly’s EU VAT feature, you can use values of unknown, physical, or digital.
55 |
# File 'lib/recurly/requests/line_item_create.rb', line 55 define_attribute :tax_code, String |
#tax_exempt ⇒ Boolean
Returns true exempts tax on charges, false applies tax on charges. If not defined, then defaults to the Plan and Site settings. This attribute does not work for credits (negative line items). Credits are always applied post-tax. Pre-tax discounts should use the Coupons feature.
59 |
# File 'lib/recurly/requests/line_item_create.rb', line 59 define_attribute :tax_exempt, :Boolean |
#type ⇒ String
Returns Line item type. If item_code/item_id is present then type should not be present. If item_code/item_id is not present then type is required.
63 |
# File 'lib/recurly/requests/line_item_create.rb', line 63 define_attribute :type, String |
#unit_amount ⇒ Float
Returns A positive or negative amount with ‘type=charge` will result in a positive unit_amount. A positive or negative amount with `type=credit` will result in a negative unit_amount. If item_code/item_id is present, unit_amount can be passed in, to override the Item’s unit_amount. If item_code/item_id is not present then unit_amount is required.
67 |
# File 'lib/recurly/requests/line_item_create.rb', line 67 define_attribute :unit_amount, Float |