class Restcomm::REST::Recording

Public Class Methods

new(path, client, params={}) click to toggle source
Calls superclass method Restcomm::REST::InstanceResource::new
   # File lib/restcomm-ruby/rest/recordings.rb
 6 def initialize(path, client, params={})
 7   path.sub! /\/Calls\/CA[^\/]+/, ''
 8   super path, client, params
 9   resource :transcriptions
10   # grab a reference to the client's connection object for streaming
11   @connection = @client.instance_variable_get :@connection
12 end

Public Instance Methods

mp3() click to toggle source

Return the mp3 URL for this recording.

   # File lib/restcomm-ruby/rest/recordings.rb
26 def mp3
27   "https://#{@connection.address}#{@path}.mp3"
28 end
mp3!(&block) click to toggle source
   # File lib/restcomm-ruby/rest/recordings.rb
30 def mp3!(&block)
31   @connection.request_get "#{@path}.mp3", &block
32 end
wav() click to toggle source

Return the wav URL for this recording.

   # File lib/restcomm-ruby/rest/recordings.rb
16 def wav
17   "https://#{@connection.address}#{@path}.wav"
18 end
wav!(&block) click to toggle source
   # File lib/restcomm-ruby/rest/recordings.rb
20 def wav!(&block)
21   @connection.request_get @path, &block
22 end