Exception: Dinie::UnknownWebhookEventError

Inherits:
Error
  • Object
show all
Defined in:
lib/dinie/runtime/errors.rb,
sig/dinie/runtime/errors.rbs

Overview

A webhook signature verified, but the payload's type is not in the openapi catalog.

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(event_type) ⇒ UnknownWebhookEventError

Returns a new instance of UnknownWebhookEventError.

Parameters:

  • event_type (String)


140
141
142
143
144
145
# File 'lib/dinie/runtime/errors.rb', line 140

def initialize(event_type)
  @event_type = event_type
  super("Unknown webhook event type: #{event_type.inspect}. It is not in the openapi event " \
        "catalog (generated/events). If Dinie added a new event type, the SDK must be updated " \
        "from the contract before it can deserialize this payload.")
end

Instance Attribute Details

#event_type ⇒ String (readonly)

Returns the unrecognized (but verified) webhook event type.

Returns:

  • (String) —

    the unrecognized (but verified) webhook event type



137
138
139
# File 'lib/dinie/runtime/errors.rb', line 137

def event_type
  @event_type
end