Sha256: a60073b489e3272976c34a91e30d03b51fe12014e2c744902b1b34d80ba49ff7

Contents?: true

Size: 633 Bytes

Versions: 42

Compression:

Stored size: 633 Bytes

Contents

module Twilio
  module REST
    class Calls < ListResource
      def initialize(path, client)
        super
        resource :feedback_summary
      end

      def make(from, to, url)
        create from: from, to: to, url: url
      end
    end

    class Call < InstanceResource
      def initialize(path, client, params={})
        super path, client, params
        resource :recordings, :notifications, :feedback
      end

      def redirect_to(url)
        update url: url
      end

      def cancel
        update status: 'canceled'
      end

      def hangup
        update status: 'completed'
      end
    end
  end
end

Version data entries

42 entries across 42 versions & 1 rubygems

Version Path
twilio-ruby-4.13.0 lib/twilio-ruby/rest/calls.rb
twilio-ruby-4.12.1 lib/twilio-ruby/rest/calls.rb
twilio-ruby-4.11.1 lib/twilio-ruby/rest/calls.rb
twilio-ruby-4.11.0 lib/twilio-ruby/rest/calls.rb
twilio-ruby-4.10.0.edge lib/twilio-ruby/rest/calls.rb
twilio-ruby-4.10.0 lib/twilio-ruby/rest/calls.rb
twilio-ruby-4.9.1 lib/twilio-ruby/rest/calls.rb
twilio-ruby-4.9.1.edge lib/twilio-ruby/rest/calls.rb
twilio-ruby-4.9.0 lib/twilio-ruby/rest/calls.rb
twilio-ruby-4.9.0.edge lib/twilio-ruby/rest/calls.rb
twilio-ruby-4.8.0 lib/twilio-ruby/rest/calls.rb
twilio-ruby-4.7.0 lib/twilio-ruby/rest/calls.rb
twilio-ruby-4.8.3.edge lib/twilio-ruby/rest/calls.rb
twilio-ruby-4.8.2.edge lib/twilio-ruby/rest/calls.rb
twilio-ruby-4.8.1.edge lib/twilio-ruby/rest/calls.rb
twilio-ruby-4.8.0.edge lib/twilio-ruby/rest/calls.rb
twilio-ruby-4.6.2 lib/twilio-ruby/rest/calls.rb
twilio-ruby-4.6.1 lib/twilio-ruby/rest/calls.rb
twilio-ruby-4.6.0 lib/twilio-ruby/rest/calls.rb
twilio-ruby-4.7.0.edge lib/twilio-ruby/rest/calls.rb