lib/twilio-ruby/rest/ip_messaging/v2/credential.rb in twilio-ruby-6.9.1 vs lib/twilio-ruby/rest/ip_messaging/v2/credential.rb in twilio-ruby-6.11.0

- old
+ new

@@ -16,10 +16,11 @@ module Twilio module REST class IpMessaging < IpMessagingBase class V2 < Version class CredentialList < ListResource + ## # Initialize the CredentialList # @param [Version] version Version that contains the resource # @return [CredentialList] CredentialList def initialize(version) @@ -57,10 +58,11 @@ 'Sandbox' => sandbox, 'ApiKey' => api_key, 'Secret' => secret, }) + payload = @version.create('POST', @uri, data: data) CredentialInstance.new( @version, payload, ) @@ -178,18 +180,20 @@ ## # Delete the CredentialInstance # @return [Boolean] True if delete succeeds, false otherwise def delete + @version.delete('DELETE', @uri) end ## # Fetch the CredentialInstance # @return [CredentialInstance] Fetched CredentialInstance def fetch + payload = @version.fetch('GET', @uri) CredentialInstance.new( @version, payload, sid: @solution[:sid], @@ -221,9 +225,10 @@ 'Sandbox' => sandbox, 'ApiKey' => api_key, 'Secret' => secret, }) + payload = @version.update('POST', @uri, data: data) CredentialInstance.new( @version, payload, sid: @solution[:sid],