Class: ApolloDeploySignalSdk::WebhookDeliveryPageResponse

Inherits:
Object
  • Object
show all
Defined in:
lib/apollo_deploy_signal_sdk/types.rb

Overview

Schema type: WebhookDeliveryPageResponse

Instance Attribute Summary collapse

Class Method Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(data:, page:) ⇒ WebhookDeliveryPageResponse

Returns a new instance of WebhookDeliveryPageResponse.

Parameters:



3450
3451
3452
3453
# File 'lib/apollo_deploy_signal_sdk/types.rb', line 3450

def initialize(data: , page: )
  @data = data
  @page = page
end

Instance Attribute Details

#dataArray<WebhookDeliveryResponse>

Returns:



3445
3446
3447
# File 'lib/apollo_deploy_signal_sdk/types.rb', line 3445

def data
  @data
end

#pagePageInfo

Returns:



3447
3448
3449
# File 'lib/apollo_deploy_signal_sdk/types.rb', line 3447

def page
  @page
end

Class Method Details

.from_json(attributes) ⇒ WebhookDeliveryPageResponse

Create an instance from a parsed JSON hash.

Parameters:

  • attributes (Hash)

Returns:



3466
3467
3468
3469
3470
3471
3472
3473
# File 'lib/apollo_deploy_signal_sdk/types.rb', line 3466

def self.from_json(attributes)
  return nil unless attributes.is_a?(Hash)

  new(
    data: attributes.key?("data") ? attributes["data"] : attributes[:data],
    page: attributes.key?("page") ? attributes["page"] : attributes[:page],
  )
end

Instance Method Details

#to_hHash

Returns a hash representation of this object.

Returns:

  • (Hash)

    a hash representation of this object



3456
3457
3458
3459
3460
3461
# File 'lib/apollo_deploy_signal_sdk/types.rb', line 3456

def to_h
  {
    data: @data,
    page: @page,
  }.compact
end