Class: ModerationAPI::Models::WebhookEvent::QueueItemAction::Data::Object

Inherits:
Internal::Type::BaseModel show all
Defined in:
lib/moderation_api/models/webhook_event.rb

Overview

See Also:

Defined Under Namespace

Classes: Author, Item, Queue

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(level:, manual:) ⇒ Object

Parameters:

  • level (Float)

    Author trust level (-1, 0, 1, 2, 3, or 4)

  • manual (Boolean)

    True if the trust level was set manually by a moderator



# File 'lib/moderation_api/models/webhook_event.rb', line 3378

Instance Attribute Details

#authorModerationAPI::Models::WebhookEvent::QueueItemAction::Data::Object::Author?

The author the action was performed on, if any



3364
# File 'lib/moderation_api/models/webhook_event.rb', line 3364

optional :author, -> { ModerationAPI::WebhookEvent::QueueItemAction::Data::Object::Author }

#created_atTime

ISO 8601 timestamp of when the action was performed

Returns:

  • (Time)


3340
# File 'lib/moderation_api/models/webhook_event.rb', line 3340

required :created_at, Time

#idString

Moderation action ID

Returns:

  • (String)


3334
# File 'lib/moderation_api/models/webhook_event.rb', line 3334

required :id, String

#itemModerationAPI::Models::WebhookEvent::QueueItemAction::Data::Object::Item?

The content item the action was performed on, if any



3370
# File 'lib/moderation_api/models/webhook_event.rb', line 3370

optional :item, -> { ModerationAPI::WebhookEvent::QueueItemAction::Data::Object::Item }

#keyString?

Customer-defined key identifying this action

Returns:

  • (String, nil)


3346
# File 'lib/moderation_api/models/webhook_event.rb', line 3346

required :key, String, nil?: true

#nameString?

Display name of the action

Returns:

  • (String, nil)


3352
# File 'lib/moderation_api/models/webhook_event.rb', line 3352

required :name, String, nil?: true

#queueModerationAPI::Models::WebhookEvent::QueueItemAction::Data::Object::Queue?

The queue the item belongs to, if any



3376
# File 'lib/moderation_api/models/webhook_event.rb', line 3376

optional :queue, -> { ModerationAPI::WebhookEvent::QueueItemAction::Data::Object::Queue }

#valueString?

The value passed to the action when it ran

Returns:

  • (String, nil)


3358
# File 'lib/moderation_api/models/webhook_event.rb', line 3358

required :value, String, nil?: true

Class Method Details

.valuesArray<Symbol>

Returns:

  • (Array<Symbol>)


# File 'lib/moderation_api/models/webhook_event.rb', line 4239