Class: Revox::Models::CampaignUpdateParams::CallRetryConfig

Inherits:
Internal::Type::BaseModel show all
Defined in:
lib/revox/models/campaign_update_params.rb,
sig/revox/models/campaign_update_params.rbs

Defined Under Namespace

Modules: AllowedDay Classes: CallingWindow

Instance Attribute Summary collapse

Class Method 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:, assistant_id: nil, call_retry_config: nil, contacts: nil, from_phone_number: nil, max_concurrent_calls: nil, name: nil, scheduled_at: nil, type: nil, request_options: {}) ⇒ Object

Some parameter documentations has been truncated, see Revox::Models::CampaignUpdateParams for more details.

Parameters:

  • id (String)
  • assistant_id (String) (defaults to: nil)

    The ID of the assistant to use (draft only)

  • call_retry_config (Revox::Models::CampaignUpdateParams::CallRetryConfig, nil) (defaults to: nil)

    Configuration for call retry behavior including time windows, delays, and max it

  • contacts (Array<Revox::Models::CampaignUpdateParams::Contact>) (defaults to: nil)

    Replace contact list (draft only)

  • from_phone_number (String, nil) (defaults to: nil)

    The phone number to use for outbound calls (draft only)

  • max_concurrent_calls (Float, nil) (defaults to: nil)

    Maximum concurrent calls (draft only)

  • name (String) (defaults to: nil)

    Campaign display name

  • scheduled_at (Time, Object, nil) (defaults to: nil)

    Scheduled start time (draft only)

  • type (Symbol, Revox::Models::CampaignUpdateParams::Type) (defaults to: nil)

    Campaign type (draft only)

  • request_options (Revox::RequestOptions, Hash{Symbol=>Object}) (defaults to: {})


88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
# File 'lib/revox/models/campaign_update_params.rb', line 88

class CallRetryConfig < Revox::Internal::Type::BaseModel
  # @!attribute allowed_days
  #   Days of the week when calls are allowed, in the recipient's timezone. Default:
  #   Monday through Friday.
  #
  #   @return [Array<Symbol, Revox::Models::CampaignUpdateParams::CallRetryConfig::AllowedDay>]
  required :allowed_days,
           -> { Revox::Internal::Type::ArrayOf[enum: Revox::CampaignUpdateParams::CallRetryConfig::AllowedDay] }

  # @!attribute call_twice_in_a_row
  #   If true and max_retry_attempts >= 2, attempt #2 fires immediately (skipping
  #   retry_delay_seconds) when attempt #1 didn't reach a human.
  #   Calling-window/allowed-days checks still apply. Only affects the 1→2 transition.
  #   Default: false.
  #
  #   @return [Boolean]
  required :call_twice_in_a_row, Revox::Internal::Type::Boolean

  # @!attribute calling_windows
  #
  #   @return [Array<Revox::Models::CampaignUpdateParams::CallRetryConfig::CallingWindow>]
  required :calling_windows,
           -> { Revox::Internal::Type::ArrayOf[Revox::CampaignUpdateParams::CallRetryConfig::CallingWindow] }

  # @!attribute max_retry_attempts
  #   Maximum number of call retry attempts. Default: 3.
  #
  #   @return [Integer]
  required :max_retry_attempts, Integer

  # @!attribute timezone
  #   Optional IANA timezone identifier to override the automatic timezone detection
  #   from phone number. If not provided, timezone is determined from the recipient's
  #   phone number country code. Examples: 'America/New_York', 'Europe/Paris'.
  #
  #   @return [String, nil]
  optional :timezone, String, nil?: true

  # @!method initialize(allowed_days:, call_twice_in_a_row:, calling_windows:, max_retry_attempts:, timezone: nil)
  #   Some parameter documentations has been truncated, see
  #   {Revox::Models::CampaignUpdateParams::CallRetryConfig} for more details.
  #
  #   Configuration for call retry behavior including time windows, delays, and max
  #   iterations. If not provided, defaults will be used.
  #
  #   @param allowed_days [Array<Symbol, Revox::Models::CampaignUpdateParams::CallRetryConfig::AllowedDay>] Days of the week when calls are allowed, in the recipient's timezone. Default: M
  #
  #   @param call_twice_in_a_row [Boolean] If true and max_retry_attempts >= 2, attempt #2 fires immediately (skipping retr
  #
  #   @param calling_windows [Array<Revox::Models::CampaignUpdateParams::CallRetryConfig::CallingWindow>]
  #
  #   @param max_retry_attempts [Integer] Maximum number of call retry attempts. Default: 3.
  #
  #   @param timezone [String, nil] Optional IANA timezone identifier to override the automatic timezone detection f

  module AllowedDay
    extend Revox::Internal::Type::Enum

    MONDAY = :monday
    TUESDAY = :tuesday
    WEDNESDAY = :wednesday
    THURSDAY = :thursday
    FRIDAY = :friday
    SATURDAY = :saturday
    SUNDAY = :sunday

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

  class CallingWindow < Revox::Internal::Type::BaseModel
    # @!attribute calling_window_end_time
    #   End time for the calling window in the recipient's timezone (or
    #   timezone_override if provided). Format: 'HH:mm' (24-hour) or 'H:mma' (12-hour).
    #   Examples: '17:00', '6pm'. Default: '18:00'.
    #
    #   @return [String]
    required :calling_window_end_time, String

    # @!attribute calling_window_start_time
    #   Start time for the calling window in the recipient's timezone (or
    #   timezone_override if provided). Format: 'HH:mm' (24-hour) or 'H:mma' (12-hour).
    #   Examples: '09:00', '10am'. Default: '10:00'.
    #
    #   @return [String]
    required :calling_window_start_time, String

    # @!attribute retry_delay_seconds
    #   Delay between retry attempts in seconds. Default: 7200 (2 hours).
    #
    #   @return [Integer]
    required :retry_delay_seconds, Integer

    # @!method initialize(calling_window_end_time:, calling_window_start_time:, retry_delay_seconds:)
    #   Some parameter documentations has been truncated, see
    #   {Revox::Models::CampaignUpdateParams::CallRetryConfig::CallingWindow} for more
    #   details.
    #
    #   @param calling_window_end_time [String] End time for the calling window in the recipient's timezone (or timezone_overrid
    #
    #   @param calling_window_start_time [String] Start time for the calling window in the recipient's timezone (or timezone_overr
    #
    #   @param retry_delay_seconds [Integer] Delay between retry attempts in seconds. Default: 7200 (2 hours).
  end
end

Instance Attribute Details

#allowed_daysArray<Symbol, Revox::Models::CampaignUpdateParams::CallRetryConfig::AllowedDay>

Days of the week when calls are allowed, in the recipient's timezone. Default: Monday through Friday.

Parameters:

  • value (::Array[Revox::Models::CampaignUpdateParams::CallRetryConfig::allowed_day])

Returns:



94
95
# File 'lib/revox/models/campaign_update_params.rb', line 94

required :allowed_days,
-> { Revox::Internal::Type::ArrayOf[enum: Revox::CampaignUpdateParams::CallRetryConfig::AllowedDay] }

#call_twice_in_a_rowBoolean

If true and max_retry_attempts >= 2, attempt #2 fires immediately (skipping retry_delay_seconds) when attempt #1 didn't reach a human. Calling-window/allowed-days checks still apply. Only affects the 1→2 transition. Default: false.

Parameters:

  • value (Boolean)

Returns:

  • (Boolean)


104
# File 'lib/revox/models/campaign_update_params.rb', line 104

required :call_twice_in_a_row, Revox::Internal::Type::Boolean

#calling_windowsArray<Revox::Models::CampaignUpdateParams::CallRetryConfig::CallingWindow>

Parameters:

  • value (::Array[Revox::CampaignUpdateParams::CallRetryConfig::CallingWindow])

Returns:



109
110
# File 'lib/revox/models/campaign_update_params.rb', line 109

required :calling_windows,
-> { Revox::Internal::Type::ArrayOf[Revox::CampaignUpdateParams::CallRetryConfig::CallingWindow] }

#max_retry_attemptsInteger

Maximum number of call retry attempts. Default: 3.

Parameters:

  • value (Integer)

Returns:

  • (Integer)


116
# File 'lib/revox/models/campaign_update_params.rb', line 116

required :max_retry_attempts, Integer

#timezoneString?

Optional IANA timezone identifier to override the automatic timezone detection from phone number. If not provided, timezone is determined from the recipient's phone number country code. Examples: 'America/New_York', 'Europe/Paris'.

Parameters:

  • value (String, nil)

Returns:

  • (String, nil)


124
# File 'lib/revox/models/campaign_update_params.rb', line 124

optional :timezone, String, nil?: true

Class Method Details

.valuesArray<Symbol>

Returns:

  • (Array<Symbol>)


# File 'lib/revox/models/campaign_update_params.rb', line 154

Instance Method Details

#to_hash{

Returns:

  • ({)


105
# File 'sig/revox/models/campaign_update_params.rbs', line 105

def to_hash: -> {