Class: Inttegro::Order::DiscountLineItem

Inherits:
T::Struct
  • Object
show all
Defined in:
lib/inttegro/order/discount_line_item.rb

Overview

Typed representation of the discount line item object in the Inttegro API.

This generated model is immutable. Construct it with .new, or decode a string-keyed API payload with .from_hash. #serialize produces a string-keyed hash using the original wire field names and serialized enum values.

Instance Attribute Summary collapse

Instance Attribute Details

#discount ⇒ Inttegro::Order::Discount (readonly)

Value of the discount field in the Inttegro API payload.

Required in the API payload. Wire name: discount.



31
32
33
34
# File 'lib/inttegro/order/discount_line_item.rb', line 31

class DiscountLineItem < T::Struct
  const :type, Inttegro::Order::DiscountLineItemType
  const :discount, Inttegro::Order::Discount
end

#type ⇒ Inttegro::Order::DiscountLineItemType (readonly)

Value of the type field in the Inttegro API payload.

Required in the API payload. Wire name: type.



31
32
33
34
# File 'lib/inttegro/order/discount_line_item.rb', line 31

class DiscountLineItem < T::Struct
  const :type, Inttegro::Order::DiscountLineItemType
  const :discount, Inttegro::Order::Discount
end