Class: ModerationAPI::Models::WebhookListResponseItem
- Inherits:
-
Internal::Type::BaseModel
- Object
- Internal::Type::BaseModel
- ModerationAPI::Models::WebhookListResponseItem
- Defined in:
- lib/moderation_api/models/webhook_list_response.rb,
sig/moderation_api/models/webhook_list_response.rbs
Defined Under Namespace
Modules: EventType, PayloadVersion
Instance Attribute Summary collapse
-
#created_at ⇒ String
The date the webhook was created.
-
#description ⇒ String?
The webhook's description.
-
#event_types ⇒ Array<Symbol, ModerationAPI::Models::WebhookListResponseItem::EventType>
Event types this webhook subscribes to.
-
#id ⇒ String
The ID of the webhook.
-
#name ⇒ String
The webhook's name.
-
#payload_version ⇒ Symbol, ModerationAPI::Models::WebhookListResponseItem::PayloadVersion
Payload envelope version.
-
#url ⇒ String
The URL we call when a subscribed event occurs.
Class Method Summary collapse
Instance Method Summary collapse
- #initialize ⇒ Object constructor
- #to_hash ⇒ {
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 ⇒ Object
29 |
# File 'sig/moderation_api/models/webhook_list_response.rbs', line 29
def initialize: (
|
Instance Attribute Details
#created_at ⇒ String
The date the webhook was created.
16 |
# File 'lib/moderation_api/models/webhook_list_response.rb', line 16 required :created_at, String, api_name: :createdAt |
#description ⇒ String?
The webhook's description.
52 |
# File 'lib/moderation_api/models/webhook_list_response.rb', line 52 optional :description, String, nil?: true |
#event_types ⇒ Array<Symbol, ModerationAPI::Models::WebhookListResponseItem::EventType>
Event types this webhook subscribes to. Empty for legacy v1 webhooks, which
subscribe via their single deprecated type instead.
23 24 25 |
# File 'lib/moderation_api/models/webhook_list_response.rb', line 23 required :event_types, -> { ModerationAPI::Internal::Type::ArrayOf[enum: ModerationAPI::Models::WebhookListResponseItem::EventType] }, api_name: :eventTypes |
#id ⇒ String
The ID of the webhook.
10 |
# File 'lib/moderation_api/models/webhook_list_response.rb', line 10 required :id, String |
#name ⇒ String
The webhook's name.
31 |
# File 'lib/moderation_api/models/webhook_list_response.rb', line 31 required :name, String |
#payload_version ⇒ Symbol, ModerationAPI::Models::WebhookListResponseItem::PayloadVersion
Payload envelope version. V2 is the Stripe-style envelope; V1 is the legacy flat shape and is read-only via this API.
38 39 40 |
# File 'lib/moderation_api/models/webhook_list_response.rb', line 38 required :payload_version, enum: -> { ModerationAPI::Models::WebhookListResponseItem::PayloadVersion }, api_name: :payloadVersion |
#url ⇒ String
The URL we call when a subscribed event occurs.
46 |
# File 'lib/moderation_api/models/webhook_list_response.rb', line 46 required :url, String |
Class Method Details
.values ⇒ Array<Symbol>
|
|
# File 'lib/moderation_api/models/webhook_list_response.rb', line 87
|
Instance Method Details
#to_hash ⇒ {
39 |
# File 'sig/moderation_api/models/webhook_list_response.rbs', line 39
def to_hash: -> {
|