Class: Twilio::REST::Numbers::V1::PortingWebhookConfigurationDeleteContext

Inherits:
InstanceContext
  • Object
show all
Defined in:
lib/twilio-ruby/rest/numbers/v1/porting_webhook_configuration_delete.rb

Instance Method Summary collapse

Constructor Details

#initialize(version, webhook_type) ⇒ PortingWebhookConfigurationDeleteContext

Initialize the PortingWebhookConfigurationDeleteContext

Parameters:

  • version (Version)

    Version that contains the resource

  • webhook_type (WebhookType)

    The of the webhook type of the configuration to be deleted



49
50
51
52
53
54
55
56
57
# File 'lib/twilio-ruby/rest/numbers/v1/porting_webhook_configuration_delete.rb', line 49

def initialize(version, webhook_type)
    super(version)

    # Path Solution
    @solution = { webhook_type: webhook_type,  }
    @uri = "/Porting/Configuration/Webhook/#{@solution[:webhook_type]}"

    
end

Instance Method Details

#deleteBoolean

Delete the PortingWebhookConfigurationDeleteInstance

Returns:

  • (Boolean)

    True if delete succeeds, false otherwise



61
62
63
64
65
# File 'lib/twilio-ruby/rest/numbers/v1/porting_webhook_configuration_delete.rb', line 61

def delete

    
    @version.delete('DELETE', @uri)
end

#inspectObject

Provide a detailed, user friendly representation



77
78
79
80
# File 'lib/twilio-ruby/rest/numbers/v1/porting_webhook_configuration_delete.rb', line 77

def inspect
    context = @solution.map{|k, v| "#{k}: #{v}"}.join(',')
    "#<Twilio.Numbers.V1.PortingWebhookConfigurationDeleteContext #{context}>"
end

#to_sObject

Provide a user friendly representation



70
71
72
73
# File 'lib/twilio-ruby/rest/numbers/v1/porting_webhook_configuration_delete.rb', line 70

def to_s
    context = @solution.map{|k, v| "#{k}: #{v}"}.join(',')
    "#<Twilio.Numbers.V1.PortingWebhookConfigurationDeleteContext #{context}>"
end