Class: Sendly::WebhookSecretRotation
- Inherits:
-
Object
- Object
- Sendly::WebhookSecretRotation
- Defined in:
- lib/sendly/types.rb
Overview
Result of rotating webhook secret
Instance Attribute Summary collapse
-
#message ⇒ Object
readonly
Returns the value of attribute message.
-
#new_secret ⇒ Object
readonly
Returns the value of attribute new_secret.
-
#old_secret_expires_at ⇒ Object
readonly
Returns the value of attribute old_secret_expires_at.
-
#webhook ⇒ Object
readonly
Returns the value of attribute webhook.
Instance Method Summary collapse
-
#initialize(data) ⇒ WebhookSecretRotation
constructor
A new instance of WebhookSecretRotation.
Constructor Details
#initialize(data) ⇒ WebhookSecretRotation
Returns a new instance of WebhookSecretRotation.
376 377 378 379 380 381 |
# File 'lib/sendly/types.rb', line 376 def initialize(data) @webhook = Webhook.new(data["webhook"]) @new_secret = data["new_secret"] || data["newSecret"] @old_secret_expires_at = parse_time(data["old_secret_expires_at"] || data["oldSecretExpiresAt"]) @message = data["message"] end |
Instance Attribute Details
#message ⇒ Object (readonly)
Returns the value of attribute message.
374 375 376 |
# File 'lib/sendly/types.rb', line 374 def @message end |
#new_secret ⇒ Object (readonly)
Returns the value of attribute new_secret.
374 375 376 |
# File 'lib/sendly/types.rb', line 374 def new_secret @new_secret end |
#old_secret_expires_at ⇒ Object (readonly)
Returns the value of attribute old_secret_expires_at.
374 375 376 |
# File 'lib/sendly/types.rb', line 374 def old_secret_expires_at @old_secret_expires_at end |
#webhook ⇒ Object (readonly)
Returns the value of attribute webhook.
374 375 376 |
# File 'lib/sendly/types.rb', line 374 def webhook @webhook end |