Class: Stigg::Models::V1Beta::Customers::AssignmentUpsertResponse::Data

Inherits:
Internal::Type::BaseModel show all
Defined in:
lib/stigg/models/v1_beta/customers/assignment_upsert_response.rb

Defined Under Namespace

Modules: Cadence

Instance Attribute Summary collapse

Instance Method Summary collapse

Methods inherited from Internal::Type::BaseModel

==, #==, #[], coerce, #deconstruct_keys, #deep_to_h, dump, fields, hash, #hash, inherited, inspect, #inspect, known_fields, optional, recursively_to_h, required, #to_h, #to_json, #to_s, to_sorbet_type, #to_yaml

Methods included from Internal::Type::Converter

#coerce, coerce, #dump, dump, #inspect, inspect, meta_info, new_coerce_state, type_info

Methods included from Internal::Util::SorbetRuntimeSupport

#const_missing, #define_sorbet_constant!, #sorbet_constant_defined?, #to_sorbet_type, to_sorbet_type

Constructor Details

#initialize(id:, cadence:, capability_id:, created_at:, entity_id:, updated_at:, usage_limit:) ⇒ Object

A capability assignment for an entity belonging to a customer. Defines how much of the capability the entity may consume (‘usageLimit`) and how often the counter resets (`cadence`).

Parameters:

  • id (String)

    Synthetic UUID identifier — also the cursor anchor for paginated lists

  • cadence (Symbol, Stigg::Models::V1Beta::Customers::AssignmentUpsertResponse::Data::Cadence)

    Usage-reset cadence. Currently only ‘MONTH` is supported

  • capability_id (String)

    The capability refId this assignment grants

  • created_at (Time)

    Timestamp of when the record was created

  • entity_id (String)

    The entity refId this assignment is attached to

  • updated_at (Time)

    Timestamp of when the record was last updated

  • usage_limit (Float)

    Maximum usage allowed within one cadence window



20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
# File 'lib/stigg/models/v1_beta/customers/assignment_upsert_response.rb', line 20

class Data < Stigg::Internal::Type::BaseModel
  # @!attribute id
  #   Synthetic UUID identifier — also the cursor anchor for paginated lists
  #
  #   @return [String]
  required :id, String

  # @!attribute cadence
  #   Usage-reset cadence. Currently only `MONTH` is supported
  #
  #   @return [Symbol, Stigg::Models::V1Beta::Customers::AssignmentUpsertResponse::Data::Cadence]
  required :cadence, enum: -> { Stigg::Models::V1Beta::Customers::AssignmentUpsertResponse::Data::Cadence }

  # @!attribute capability_id
  #   The capability refId this assignment grants
  #
  #   @return [String]
  required :capability_id, String, api_name: :capabilityId

  # @!attribute created_at
  #   Timestamp of when the record was created
  #
  #   @return [Time]
  required :created_at, Time, api_name: :createdAt

  # @!attribute entity_id
  #   The entity refId this assignment is attached to
  #
  #   @return [String]
  required :entity_id, String, api_name: :entityId

  # @!attribute updated_at
  #   Timestamp of when the record was last updated
  #
  #   @return [Time]
  required :updated_at, Time, api_name: :updatedAt

  # @!attribute usage_limit
  #   Maximum usage allowed within one cadence window
  #
  #   @return [Float]
  required :usage_limit, Float, api_name: :usageLimit

  # @!method initialize(id:, cadence:, capability_id:, created_at:, entity_id:, updated_at:, usage_limit:)
  #   A capability assignment for an entity belonging to a customer. Defines how much
  #   of the capability the entity may consume (`usageLimit`) and how often the
  #   counter resets (`cadence`).
  #
  #   @param id [String] Synthetic UUID identifier — also the cursor anchor for paginated lists
  #
  #   @param cadence [Symbol, Stigg::Models::V1Beta::Customers::AssignmentUpsertResponse::Data::Cadence] Usage-reset cadence. Currently only `MONTH` is supported
  #
  #   @param capability_id [String] The capability refId this assignment grants
  #
  #   @param created_at [Time] Timestamp of when the record was created
  #
  #   @param entity_id [String] The entity refId this assignment is attached to
  #
  #   @param updated_at [Time] Timestamp of when the record was last updated
  #
  #   @param usage_limit [Float] Maximum usage allowed within one cadence window

  # Usage-reset cadence. Currently only `MONTH` is supported
  #
  # @see Stigg::Models::V1Beta::Customers::AssignmentUpsertResponse::Data#cadence
  module Cadence
    extend Stigg::Internal::Type::Enum

    MONTH = :MONTH

    # @!method self.values
    #   @return [Array<Symbol>]
  end
end

Instance Attribute Details

#cadenceSymbol, Stigg::Models::V1Beta::Customers::AssignmentUpsertResponse::Data::Cadence

Usage-reset cadence. Currently only ‘MONTH` is supported



31
# File 'lib/stigg/models/v1_beta/customers/assignment_upsert_response.rb', line 31

required :cadence, enum: -> { Stigg::Models::V1Beta::Customers::AssignmentUpsertResponse::Data::Cadence }

#capability_idString

The capability refId this assignment grants

Returns:

  • (String)


37
# File 'lib/stigg/models/v1_beta/customers/assignment_upsert_response.rb', line 37

required :capability_id, String, api_name: :capabilityId

#created_atTime

Timestamp of when the record was created

Returns:

  • (Time)


43
# File 'lib/stigg/models/v1_beta/customers/assignment_upsert_response.rb', line 43

required :created_at, Time, api_name: :createdAt

#entity_idString

The entity refId this assignment is attached to

Returns:

  • (String)


49
# File 'lib/stigg/models/v1_beta/customers/assignment_upsert_response.rb', line 49

required :entity_id, String, api_name: :entityId

#idString

Synthetic UUID identifier — also the cursor anchor for paginated lists

Returns:

  • (String)


25
# File 'lib/stigg/models/v1_beta/customers/assignment_upsert_response.rb', line 25

required :id, String

#updated_atTime

Timestamp of when the record was last updated

Returns:

  • (Time)


55
# File 'lib/stigg/models/v1_beta/customers/assignment_upsert_response.rb', line 55

required :updated_at, Time, api_name: :updatedAt

#usage_limitFloat

Maximum usage allowed within one cadence window

Returns:

  • (Float)


61
# File 'lib/stigg/models/v1_beta/customers/assignment_upsert_response.rb', line 61

required :usage_limit, Float, api_name: :usageLimit