Class: OpenAI::Models::Admin::Organization::Health::HealthAlertRule

Inherits:
Internal::Type::BaseModel show all
Defined in:
lib/openai/models/admin/organization/health/health_alert_rule.rb,
sig/openai/models/admin/organization/health/health_alert_rule.rbs

Overview

See Also:

  • OpenAI::Resources::Admin::Organization::Health::AlertRules#create

Defined Under Namespace

Modules: Condition Classes: Filters, Notifications

Instance Attribute Summary collapse

Attributes inherited from Internal::Type::BaseModel

#last_response

Class Method Summary collapse

Instance Method Summary collapse

Methods inherited from Internal::Type::BaseModel

==, #==, #[], #_request_id, #_set_last_response, coerce, #deconstruct_keys, #deep_to_h, dump, #encode_with, 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, coerce_cached, coerce_with_error, #dump, dump, #inspect, inspect, meta_info, new_coerce_state, resolve_type, 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:, condition:, created_at:, enabled:, filters:, name:, notifications:, organization_id:, updated_at:, version:, object: :"health.alert_rule") ⇒ HealthAlertRule

Returns a new instance of HealthAlertRule.

Parameters:



# File 'lib/openai/models/admin/organization/health/health_alert_rule.rb', line 65

Instance Attribute Details

#condition ⇒ OpenAI::Models::Admin::Organization::Health::HealthAlertRule::Condition::ErrorRate, ...



18
# File 'lib/openai/models/admin/organization/health/health_alert_rule.rb', line 18

required :condition, union: -> { OpenAI::Admin::Organization::Health::HealthAlertRule::Condition }

#created_at ⇒ Integer

Parameters:

  • value (Integer)

Returns:

  • (Integer)


23
# File 'lib/openai/models/admin/organization/health/health_alert_rule.rb', line 23

required :created_at, Integer

#enabled ⇒ Boolean

Parameters:

Returns:



28
# File 'lib/openai/models/admin/organization/health/health_alert_rule.rb', line 28

required :enabled, OpenAI::Internal::Type::Boolean

#filters ⇒ OpenAI::Models::Admin::Organization::Health::HealthAlertRule::Filters

Parameters:

  • value (OpenAI::Admin::Organization::Health::HealthAlertRule::Filters)

Returns:



33
# File 'lib/openai/models/admin/organization/health/health_alert_rule.rb', line 33

required :filters, -> { OpenAI::Admin::Organization::Health::HealthAlertRule::Filters }

#id ⇒ String

Parameters:

  • value (String)

Returns:

  • (String)


13
# File 'lib/openai/models/admin/organization/health/health_alert_rule.rb', line 13

required :id, String

#name ⇒ String

Parameters:

  • value (String)

Returns:

  • (String)


38
# File 'lib/openai/models/admin/organization/health/health_alert_rule.rb', line 38

required :name, String

#notifications ⇒ OpenAI::Models::Admin::Organization::Health::HealthAlertRule::Notifications

Parameters:

  • value (OpenAI::Admin::Organization::Health::HealthAlertRule::Notifications)

Returns:



43
# File 'lib/openai/models/admin/organization/health/health_alert_rule.rb', line 43

required :notifications, -> { OpenAI::Admin::Organization::Health::HealthAlertRule::Notifications }

#object ⇒ Symbol, :"health.alert_rule"

Parameters:

  • value (:"health.alert_rule")

Returns:

  • (Symbol, :"health.alert_rule")


48
# File 'lib/openai/models/admin/organization/health/health_alert_rule.rb', line 48

required :object, const: :"health.alert_rule"

#organization_id ⇒ String

Parameters:

  • value (String)

Returns:

  • (String)


53
# File 'lib/openai/models/admin/organization/health/health_alert_rule.rb', line 53

required :organization_id, String

#updated_at ⇒ Integer

Parameters:

  • value (Integer)

Returns:

  • (Integer)


58
# File 'lib/openai/models/admin/organization/health/health_alert_rule.rb', line 58

required :updated_at, Integer

#version ⇒ Integer

Parameters:

  • value (Integer)

Returns:

  • (Integer)


63
# File 'lib/openai/models/admin/organization/health/health_alert_rule.rb', line 63

required :version, Integer

Class Method Details

.values ⇒ Array<Symbol>

Returns:

  • (Array<Symbol>)


# File 'lib/openai/models/admin/organization/health/health_alert_rule.rb', line 242

Instance Method Details

#to_hash ⇒ { id: String, condition: OpenAI::Models::Admin::Organization::Health::HealthAlertRule::condition, created_at: Integer, enabled: bool, filters: OpenAI::Admin::Organization::Health::HealthAlertRule::Filters, name: String, notifications: OpenAI::Admin::Organization::Health::HealthAlertRule::Notifications, ?object: :"health.alert_rule", organization_id: String, updated_at: Integer, version: Integer }

Returns:

  • ({ id: String, condition: OpenAI::Models::Admin::Organization::Health::HealthAlertRule::condition, created_at: Integer, enabled: bool, filters: OpenAI::Admin::Organization::Health::HealthAlertRule::Filters, name: String, notifications: OpenAI::Admin::Organization::Health::HealthAlertRule::Notifications, ?object: :"health.alert_rule", organization_id: String, updated_at: Integer, version: Integer })


60
61
62
63
64
65
66
67
68
69
70
71
72
# File 'sig/openai/models/admin/organization/health/health_alert_rule.rbs', line 60

def to_hash: -> {
  id: String,
  condition: OpenAI::Models::Admin::Organization::Health::HealthAlertRule::condition,
  created_at: Integer,
  enabled: bool,
  filters: OpenAI::Admin::Organization::Health::HealthAlertRule::Filters,
  name: String,
  notifications: OpenAI::Admin::Organization::Health::HealthAlertRule::Notifications,
  ?object: :"health.alert_rule",
  organization_id: String,
  updated_at: Integer,
  version: Integer
}