Class: Inttegro::Price::FixedParams

Inherits:
T::Struct
  • Object
show all
Defined in:
lib/inttegro/price/fixed_params.rb

Overview

Typed representation of the fixed params 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

#about ⇒ String? (readonly)

Longer description of this price

Optional in the API payload; omitted values default to nil. Wire name: about.

Returns:

  • (String, nil)


49
50
51
52
53
54
55
# File 'lib/inttegro/price/fixed_params.rb', line 49

class FixedParams < T::Struct
  const :product_id, T.nilable(String), default: nil
  const :label, T.nilable(String), default: nil
  const :about, T.nilable(String), default: nil
  const :type, Inttegro::Price::FixedParamsType
  const :fixed_amount, Inttegro::Money::AmountParams
end

#fixed_amount ⇒ Inttegro::Money::AmountParams (readonly)

Value of the fixed_amount field in the Inttegro API payload.

Required in the API payload. Wire name: fixed_amount.



49
50
51
52
53
54
55
# File 'lib/inttegro/price/fixed_params.rb', line 49

class FixedParams < T::Struct
  const :product_id, T.nilable(String), default: nil
  const :label, T.nilable(String), default: nil
  const :about, T.nilable(String), default: nil
  const :type, Inttegro::Price::FixedParamsType
  const :fixed_amount, Inttegro::Money::AmountParams
end

#label ⇒ String? (readonly)

Short label for this price

Optional in the API payload; omitted values default to nil. Wire name: label.

Returns:

  • (String, nil)


49
50
51
52
53
54
55
# File 'lib/inttegro/price/fixed_params.rb', line 49

class FixedParams < T::Struct
  const :product_id, T.nilable(String), default: nil
  const :label, T.nilable(String), default: nil
  const :about, T.nilable(String), default: nil
  const :type, Inttegro::Price::FixedParamsType
  const :fixed_amount, Inttegro::Money::AmountParams
end

#product_id ⇒ String? (readonly)

Product ID to associate this price with.

Optional in the API payload; omitted values default to nil. Wire name: product_id.

Returns:

  • (String, nil)


49
50
51
52
53
54
55
# File 'lib/inttegro/price/fixed_params.rb', line 49

class FixedParams < T::Struct
  const :product_id, T.nilable(String), default: nil
  const :label, T.nilable(String), default: nil
  const :about, T.nilable(String), default: nil
  const :type, Inttegro::Price::FixedParamsType
  const :fixed_amount, Inttegro::Money::AmountParams
end

#type ⇒ Inttegro::Price::FixedParamsType (readonly)

Value of the type field in the Inttegro API payload.

Required in the API payload. Wire name: type.



49
50
51
52
53
54
55
# File 'lib/inttegro/price/fixed_params.rb', line 49

class FixedParams < T::Struct
  const :product_id, T.nilable(String), default: nil
  const :label, T.nilable(String), default: nil
  const :about, T.nilable(String), default: nil
  const :type, Inttegro::Price::FixedParamsType
  const :fixed_amount, Inttegro::Money::AmountParams
end