REST API: 録音

A Recording instance resource represents an individually recorded call. Recordings can be generated via one of the following methods :

  1. <Record> in TwiML
  2. <Dial record> in TwiML
  3. <Conference record> in TwiML
  4. Record=true in Outbound REST API
  5. Enabling recording on elastic SIP Trunk in Console

これらの録音はTwilioに保存されます。レコーディングリストリソースはアカウント毎に割り当てられます。

Call インスタンス リソースのサブリソースとして、Recordings リスト リソースも用意されています。 このリソースは個々の通話を対象としているため、元の通話から録音へと直接たどることができます。

Recording インスタンス リソース

このリソースはある特定の個人の録音を表します。

リソース URI

/2010-04-01/Accounts/{AccountSid}/Recordings/{RecordingSid}

Because these URLs are useful to many external applications, they are public and do not require HTTP Basic Auth to access. This allows you to easily embed the URL in a web application without revealing your Twilio API credentials. The URLs are fairly long and difficult to guess, so the contents of the recordings should be fairly private unless you distribute the URL. For added security, you can enforce HTTP basic auth to access media using your AccountSid and Authentication token via the voice settings page in the console.

リソースのプロパティ

Recording リソースには、次のプロパティがあります。

プロパティ 説明
Sid このリソースを一意に識別する 34 文字の文字列です。
DateCreated このリソースが生成された日付です。 RFC 2822 フォーマットを使用します。
DateUpdated このリソースが最後に更新された日付です。 RFC 2822 フォーマットを使用します。
AccountSid この録音に関連する アカウント のユニーク ID です。
CallSid 録音に関連づけられた通話の一意な識別子です。 これは常に、2つの呼により構成される通話の親コールを参照します。
Duration この録音の長さ (秒) です。
Price この録音を作成するたびにかかるコストです。例: -0.00250
PriceUnit Price プロパティで使用される通貨です。例: USD
ApiVersion 録音時に使用された API のバージョンです。
Uri URIリソース、右に関連する https://api.twilio.com
Status 録音のステータス。 取りうる値は processing および completed です。
ソース この録音を作成した通話のタイプです。取りうる値は、RecordVerbDialVerbConferenceOutboundAPITrunking です。
チャンネル The number of channels in the final recording file as an integer. Possible values are 1, 2. Separating a two leg call into two separate channels of the recording file is supported in Dial and Outbound Rest API record options.

HTTP GET

いくつかの表現の中から 1 つを返します。

デフォルト: WAV

拡張子なし、または「.wav」の場合は、MIME-Type が「audio/x-wav」のバイナリ WAV 音声ファイルを返します。 たとえば、次のようになります。

GET /2010-04-01/Accounts/ACda6f1.../Recordings/RE557ce644e5ab84fa21cc21112e22c485
デフォルト以外: MP3

URI に「.mp3」をつけると、MIME-Type が「audio/mpeg」 のバイナリ MP3 音声ファイルを返します。 たとえば、次のようになります。

GET /2010-04-01/Accounts/ACda6f1.../Recordings/RE557ce644e5ab84fa21cc21112e22c485.mp3
デフォルト以外: XML

URI に「.xml」をつけると、通常の XML 表現を返します。 たとえば、次のようになります。

$ curl -G https://api.twilio.com/2010-04-01/Accounts/ACXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX/Recordings/RE557ce644e5ab84fa21cc21112e22c485 \
-u "ACXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX:your_auth_token"
<TwilioResponse>
  <Recording>
    <Sid>RE557ce644e5ab84fa21cc21112e22c485</Sid>
    <AccountSid>ACXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX</AccountSid>
    <CallSid>CA8dfedb55c129dd4d6bd1f59af9d11080</CallSid>
    <Duration>53</Duration>
    <DateCreated>Tue, 18 Oct 2016 21:55:38 +0000</DateCreated>
    <ApiVersion>2010-04-01</ApiVersion>
    <DateUpdated>Tue, 18 Oct 2016 21:56:34 +0000</DateUpdated>
    <Status>completed</Status>
    <Source>DialVerb</Source>
    <Channels>2</Channels>
    <Price>-0.00250</Price>
    <PriceUnit>USD</PriceUnit>
    <Uri>/2010-04-01/Accounts/ACXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX/Recordings/RE557ce644e5ab84fa21cc21112e22c485.xml</Uri>
  </Recording>
</TwilioResponse>
Get Recording in XML Format
代替手段 : JSON

URI に「.JSON」をつけると、JSON 表現を返します。 たとえば、次のようになります。

$ curl -G https://api.twilio.com/2010-04-01/Accounts/ACXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX/Recordings/RE557ce644e5ab84fa21cc21112e22c485.json
{
    "account_sid": "ACXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX",
    "api_version": "2010-04-01",
    "call_sid": "CA8dfedb55c129dd4d6bd1f59af9d11080",
    "channels": 2,
    "date_created": "Tue, 18 Oct 2016 21:55:38 +0000",
    "date_updated": "Tue, 18 Oct 2016 21:56:34 +0000",
    "duration": "53",
    "price": "-0.00250",
    "price_unit": "USD",
    "sid": "RE557ce644e5ab84fa21cc21112e22c485",
    "source": "DialVerb",
    "status": "completed",
    "uri": "/2010-04-01/Accounts/ACXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX/Recordings/RE557ce644e5ab84fa21cc21112e22c485.json"
}
Get Recording in JSON Format

HTTP POST

サポートしません。

HTTP PUT

サポートしません。

HTTP DELETE

Deletes a recording from your account. Once the recording is deleted, you will no longer be billed for storage of those minutes.

削除に成功すると、ボディーのない HTTP 204 (No Content) レスポンスを返します。 たとえば、次のようになります。

録音の削除
  • C#
  • curl
  • Java
  • Node.js
  • PHP
  • Python
  • Ruby
SDKバージョン:
  • 4.x
  • 5.x
レスポンス形式:
  • JSON
  • xml
SDKバージョン:
  • 6.x
  • 7.x
SDKバージョン:
  • 2.x
  • 3.x
SDKバージョン:
  • 4.x
  • 5.x
SDKバージョン:
  • 5.x
  • 6.x
SDKバージョン:
  • 4.x
  • 5.x
// Download the twilio-csharp library from twilio.com/docs/libraries/csharp
using System;
using Twilio;
using Twilio.Rest.Api.V2010.Account;

class Example
{
    static void Main(string[] args)
    {
        // Find your Account Sid and Auth Token at twilio.com/console
        const string accountSid = "ACXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX";
        const string authToken = "your_auth_token";
        TwilioClient.Init(accountSid, authToken);

        RecordingResource.Delete("RE557ce644e5ab84fa21cc21112e22c485");
    }
}
<?php
// Get the PHP helper library from twilio.com/docs/php/install
require_once '/path/to/vendor/autoload.php'; // Loads the library
use Twilio\Rest\Client;

// Your Account Sid and Auth Token from twilio.com/user/account
$sid = "ACXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX";
$token = "your_auth_token";
$client = new Client($sid, $token);

$client->recordings("RE557ce644e5ab84fa21cc21112e22c485")->delete();
# Download the Python helper library from twilio.com/docs/python/install
from twilio.rest import TwilioRestClient

# Your Account Sid and Auth Token from twilio.com/user/account
account_sid = "ACXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX"
auth_token  = "your_auth_token"
client = TwilioRestClient(account_sid, auth_token)

client.recordings.delete("RE557ce644e5ab84fa21cc21112e22c485")
require 'rubygems' # not necessary with ruby 1.9 but included for completeness
require 'twilio-ruby'

# put your own credentials here
account_sid = 'ACXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX'
auth_token = 'your_auth_token'

# set up a client to talk to the Twilio REST API
@client = Twilio::REST::Client.new(account_sid, auth_token)

@recording = @client.account
                    .recordings('RE557ce644e5ab84fa21cc21112e22c485').fetch

@recording.delete
$ curl -XDELETE https://api.twilio.com/2010-04-01/Accounts/ACXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX/Recordings/RE557ce644e5ab84fa21cc21112e22c485.json \
    -u 'ACXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX:your_auth_token'
$ curl -XDELETE https://api.twilio.com/2010-04-01/Accounts/ACXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX/Recordings/RE557ce644e5ab84fa21cc21112e22c485 \
    -u 'ACXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX:your_auth_token'
// Install the Java helper library from twilio.com/docs/java/install
import com.twilio.sdk.TwilioRestClient;
import com.twilio.sdk.TwilioRestException;
import com.twilio.sdk.resource.instance.Recording;

public class Example { 

  // Find your Account Sid and Token at twilio.com/user/account
  public static final String ACCOUNT_SID = "ACXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX";
  public static final String AUTH_TOKEN = "your_auth_token";

  public static void main(String[] args) throws TwilioRestException {
    TwilioRestClient client = new TwilioRestClient(ACCOUNT_SID, AUTH_TOKEN);

    // Get an object from its sid. If you do not have a sid,
    // check out the list resource examples on this page
    Recording recording = client.getAccount().getRecording("RE557ce644e5ab84fa21cc21112e22c485");
    
    recording.delete();
    
  }
}
# Download the Python helper library from twilio.com/docs/python/install
from twilio.rest import Client

# Your Account Sid and Auth Token from twilio.com/user/account
account_sid = "ACXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX"
auth_token = "your_auth_token"
client = Client(account_sid, auth_token)

client.recordings("RE557ce644e5ab84fa21cc21112e22c485") \
      .delete()
// Download the Node helper library from twilio.com/docs/node/install
// These consts are your accountSid and authToken from https://www.twilio.com/console
const accountSid = 'ACXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX';
const authToken = 'your_auth_token';
const client = require('twilio')(accountSid, authToken);

const recordingSid = 'RE557ce644e5ab84fa21cc21112e22c485';

client.recordings(recordingSid)
  .remove()
  .then(() => console.log(`Sid ${recordingSid} deleted successfully.`))
  .catch((err) => {
    console.log(err.status);
    throw err;
  });
// Download the twilio-csharp library from twilio.com/docs/csharp/install
using System;
using Twilio;
class Example 
{
  static void Main(string[] args) 
  {
    // Find your Account Sid and Auth Token at twilio.com/user/account
    string AccountSid = "ACXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX";
    string AuthToken = "your_auth_token";
    var twilio = new TwilioRestClient(AccountSid, AuthToken);

    twilio.DeleteRecording("RE557ce644e5ab84fa21cc21112e22c485");
  }
}
<?php
// Get the PHP helper library from twilio.com/docs/php/install
require_once('/path/to/twilio-php/Services/Twilio.php'); // Loads the library

// Your Account Sid and Auth Token from twilio.com/user/account
$sid = "ACXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX"; 
$token = "your_auth_token"; 
$client = new Services_Twilio($sid, $token);

$client->account->recordings->delete("RE557ce644e5ab84fa21cc21112e22c485");
# Get twilio-ruby from twilio.com/docs/ruby/install
require 'rubygems'          # This line not needed for ruby > 1.8
require 'twilio-ruby'

# Get your Account Sid and Auth Token from twilio.com/user/account
account_sid = 'ACXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX'
auth_token = 'your_auth_token'
@client = Twilio::REST::Client.new account_sid, auth_token

@recording = @client.account.recordings.get("RE557ce644e5ab84fa21cc21112e22c485")
@recording.delete
// Install the Java helper library from twilio.com/docs/java/install
import com.twilio.Twilio;
import com.twilio.rest.api.v2010.account.Recording;

public class Example {
  /// Find your Account Sid and Token at twilio.com/user/account
  public static final String ACCOUNT_SID = "ACXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX";
  public static final String AUTH_TOKEN = "your_auth_token";

  public static void main(String[] args) {
    Twilio.init(ACCOUNT_SID, AUTH_TOKEN);

    // Get an object from its sid. If you do not have a sid,
    // check out the list resource examples on this page
    Recording.deleter("RE557ce644e5ab84fa21cc21112e22c485").delete();
  }
}
// Download the Node helper library from twilio.com/docs/node/install
// These vars are your accountSid and authToken from twilio.com/user/account
var accountSid = 'ACXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX';
var authToken = "your_auth_token";
var client = require('twilio')(accountSid, authToken);

client.recordings("RE557ce644e5ab84fa21cc21112e22c485").delete(function(err, data) {
    if (err) {
        console.log(err.status);
        throw err.message;
    } else {
        console.log("Sid RE557ce644e5ab84fa21cc21112e22c485 deleted successfully.");
    }
});
録音の削除

Recording インスタンス サブリソース

それぞれの Recording インスタンス リソースには、この録音から生成されたトランスクリプションがある場合、これらのトランスクリプションのセットを表現する Transcriptions サブリソースがあります。

Transcriptions リスト サブリソース
/2010-04-01/Accounts/{YourAccountSid}/Recordings/{RecordingSid}/Transcriptions

{RecordingSid} で識別される録音の、トランスクリプションのセットを返します。 プロパティとレスポンスのフォーマットについては、 Transcription リソースのドキュメント を参照してください。

Recordings リスト リソース

リソース URI

/2010-04-01/Accounts/{AccountSid}/Recordings
/2010-04-01/Accounts/{AccountSid}/Calls/{CallSid}/Recordings

注 : ) 上記の記載にあるレコーディングインスタンスと違い、レコーディングのリストあなたのアカウントクレデンシャルによって守られています。レコーディングリストリソースにアクセスするためにはHTTPベーシック認証を使用する必要があります。

HTTP GET

Returns a list of Recording resource representations, each representing a recording generated during the course of a call. The list includes paging information.

リスト フィルター

次の GET クエリ パラメーターを使って、返却されるリストに制限を加えます。 パラメーターの大文字と小文字は区別されます。

パラメーター 説明
CallSid この sid で指定した通話中に生成された録音のみを返します。
DateCreated この日に生成された録音のみを返します。 YYYY-MM-DD 形式で表記します。 また、不等号も指定できます。たとえば、DateCreated<=YYYY-MM-DD とすると、この日の午前 0 時以前に生成された録音を返し、DateCreated>=YYYY-MM-DD とすると、この日の午前 0 時以降に生成された録音を返します。
例 1
Get all Recordings for an Account
  • C#
  • curl
  • Java
  • Node.js
  • PHP
  • Python
  • Ruby
SDKバージョン:
  • 4.x
  • 5.x
レスポンス形式:
  • JSON
  • xml
SDKバージョン:
  • 6.x
  • 7.x
SDKバージョン:
  • 2.x
  • 3.x
SDKバージョン:
  • 4.x
  • 5.x
SDKバージョン:
  • 5.x
  • 6.x
SDKバージョン:
  • 4.x
  • 5.x
// Download the twilio-csharp library from twilio.com/docs/libraries/csharp
using System;
using Twilio;
using Twilio.Rest.Api.V2010.Account;

class Example
{
    static void Main(string[] args)
    {
        // Find your Account Sid and Auth Token at twilio.com/console
        const string accountSid = "ACXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX";
        const string authToken = "your_auth_token";
        TwilioClient.Init(accountSid, authToken);

        var recordings = RecordingResource.Read();

        foreach (var recording in recordings)
        {
            Console.WriteLine(recording.Duration);
        }
    }
}
<?php
// Get the PHP helper library from twilio.com/docs/php/install
require_once '/path/to/vendor/autoload.php'; // Loads the library
use Twilio\Rest\Client;

// Your Account Sid and Auth Token from twilio.com/user/account
$sid = "ACXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX";
$token = "your_auth_token";
$client = new Client($sid, $token);

// Loop over the list of recordings and echo a property for each one
foreach ($client->recordings->read() as $recording) {
    echo $recording->duration;
}
# Download the Python helper library from twilio.com/docs/python/install
from twilio.rest import TwilioRestClient

# Your Account Sid and Auth Token from twilio.com/user/account
account_sid = "ACXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX"
auth_token  = "your_auth_token"
client = TwilioRestClient(account_sid, auth_token)

# A list of recording objects with the properties described above
recordings = client.recordings.list()
require 'rubygems' # not necessary with ruby 1.9 but included for completeness
require 'twilio-ruby'

# put your own credentials here
account_sid = 'ACXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX'
auth_token = 'your_auth_token'

# set up a client to talk to the Twilio REST API
@client = Twilio::REST::Client.new(account_sid, auth_token)

# Loop over recordings and print out a property for each one
@client.account.recordings.list.each do |recording|
  puts recording.duration
end
$ curl -G https://api.twilio.com/2010-04-01/Accounts/ACXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX/Recordings.json \
    -u 'ACXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX:your_auth_token'
$ curl -G https://api.twilio.com/2010-04-01/Accounts/ACXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX/Recordings \
    -u 'ACXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX:your_auth_token'
// Install the Java helper library from twilio.com/docs/java/install
import com.twilio.sdk.TwilioRestClient;
import com.twilio.sdk.TwilioRestException;
import com.twilio.sdk.resource.instance.Recording;
import com.twilio.sdk.resource.list.RecordingList;

public class Example { 

  // Find your Account Sid and Token at twilio.com/user/account
  public static final String ACCOUNT_SID = "ACXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX";
  public static final String AUTH_TOKEN = "your_auth_token";

  public static void main(String[] args) throws TwilioRestException {
    TwilioRestClient client = new TwilioRestClient(ACCOUNT_SID, AUTH_TOKEN);

    
    
    RecordingList recordings = client.getAccount().getRecordings();
    
    // Loop over recordings and print out a property for each one.
    for (Recording recording : recordings) {
      System.out.println(recording.getDuration());
    }
    
  }
}
# Download the Python helper library from twilio.com/docs/python/install
from twilio.rest import Client

# Your Account Sid and Auth Token from twilio.com/user/account
account_sid = "ACXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX"
auth_token = "your_auth_token"
client = Client(account_sid, auth_token)

# A list of recording objects with the properties described above
for recording in client.recordings.list():
    print(recording.duration)
// Download the Node helper library from twilio.com/docs/node/install
// These consts are your accountSid and authToken from https://www.twilio.com/console
const accountSid = 'ACXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX';
const authToken = 'your_auth_token';
const client = require('twilio')(accountSid, authToken);

client.recordings
  .each((recording) => console.log(recording.duration));
// Download the twilio-csharp library from twilio.com/docs/csharp/install
using System;
using Twilio;
class Example 
{
  static void Main(string[] args) 
  {
    // Find your Account Sid and Auth Token at twilio.com/user/account
    string AccountSid = "ACXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX";
    string AuthToken = "your_auth_token";
    var twilio = new TwilioRestClient(AccountSid, AuthToken);

    var recordings = twilio.ListRecordings(null, null, null, null);
    
    foreach (var recording in recordings.Recordings)
    {
      Console.WriteLine(recording.Duration);
    }
  }
}
<?php
// Get the PHP helper library from twilio.com/docs/php/install
require_once('/path/to/twilio-php/Services/Twilio.php'); // Loads the library

// Your Account Sid and Auth Token from twilio.com/user/account
$sid = "ACXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX"; 
$token = "your_auth_token"; 
$client = new Services_Twilio($sid, $token);

// Loop over the list of recordings and echo a property for each one
foreach ($client->account->recordings as $recording) {
    echo $recording->duration;
}
# Get twilio-ruby from twilio.com/docs/ruby/install
require 'rubygems'          # This line not needed for ruby > 1.8
require 'twilio-ruby'

# Get your Account Sid and Auth Token from twilio.com/user/account
account_sid = 'ACXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX'
auth_token = 'your_auth_token'
@client = Twilio::REST::Client.new account_sid, auth_token


# Loop over recordings and print out a property for each one
@client.account.recordings.list.each do |recording|
  puts recording.duration
end
// Install the Java helper library from twilio.com/docs/java/install
import com.twilio.Twilio;
import com.twilio.base.ResourceSet;
import com.twilio.rest.api.v2010.account.Recording;

public class Example {
  /// Find your Account Sid and Token at twilio.com/user/account
  public static final String ACCOUNT_SID = "ACXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX";
  public static final String AUTH_TOKEN = "your_auth_token";

  public static void main(String[] args) {
    Twilio.init(ACCOUNT_SID, AUTH_TOKEN);

    ResourceSet<Recording> recordings = Recording.reader().read();

    // Loop over recordings and print out a property for each one.
    for (Recording recording : recordings) {
      System.out.println(recording.getDuration());
    }
  }
}
// Download the Node helper library from twilio.com/docs/node/install
// These vars are your accountSid and authToken from twilio.com/user/account
var accountSid = 'ACXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX';
var authToken = "your_auth_token";
var client = require('twilio')(accountSid, authToken);

client.recordings.list(function(err, data) {
    data.recordings.forEach(function(recording) {
        console.log(recording.Duration);
    });
});
出力を表示
  • JSON
  • XML
{
	"page": 0,
	"page_size": 50,
	"uri": "/2010-04-01/Accounts/ACXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX/Recordings.json"
	"first_page_uri": "/2010-04-01/Accounts/ACXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX/Recordings.json?Page=0&PageSize=50",
	"previous_page_uri": null,
	"next_page_uri": "/2010-04-01/Accounts/ACXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX/Recordings.json?Page=1&PageSize=50",
	"recordings": [
		{
			"account_sid": "ACXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX",
			"api_version": "2010-04-01",
			"call_sid": "CA8dfedb55c129dd4d6bd1f59af9d11080",
			"channels": 2,
			"date_created": "Tue, 18 Oct 2016 21:55:38 +0000",
			"date_updated": "Tue, 18 Oct 2016 21:56:34 +0000",
			"duration": "53",
			"price": "-0.00250",
			"price_unit": "USD",
			"sid": "RE557ce644e5ab84fa21cc21112e22c485",
			"source": "DialVerb",
			"status": "completed",
			"uri": "/2010-04-01/Accounts/ACXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX/Recordings/RE557ce644e5ab84fa21cc21112e22c485.json"
		},
		...
	]
}
<TwilioResponse>
	<Recordings page="0" pagesize="50" uri="/2010-04-01/Accounts/ACXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX/Recordings?Page=0&amp;PageSize=50" firstpageuri="/2010-04-01/Accounts/ACXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX/Recordings?Page=0&amp;PageSize=50" previouspageuri="" nextpageuri="/2010-04-01/Accounts/ACXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX/Recordings?Page=1&amp;PageSize=50">
		<Recording>
			<Sid>RE557ce644e5ab84fa21cc21112e22c485</Sid>
			<AccountSid>ACXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX</AccountSid>
			<CallSid>CA8dfedb55c129dd4d6bd1f59af9d11080</CallSid>
			<Duration>53</Duration>
			<DateCreated>Tue, 18 Oct 2016 21:55:38 +0000</DateCreated>
			<ApiVersion>2010-04-01</ApiVersion>
			<DateUpdated>Tue, 18 Oct 2016 21:56:34 +0000</DateUpdated>
			<Status>completed</Status>
			<Source>DialVerb</Source>
			<Channels>2</Channels>
			<Price>-0.00250</Price>
			<PriceUnit>USD</PriceUnit>
			<Uri>/2010-04-01/Accounts/ACXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX/Recordings/RE557ce644e5ab84fa21cc21112e22c485</Uri>
		</Recording>
		...
	</Recordings>
</TwilioResponse>
Get all Recordings for an Account
レスポンス形式:
  • JSON
  • xml
$ curl -G https://api.twilio.com/2010-04-01/Accounts/ACXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX/Calls/CA8dfedb55c129dd4d6bd1f59af9d11080/Recordings.json \
    -u 'ACXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX:your_auth_token
$ curl -G https://api.twilio.com/2010-04-01/Accounts/ACXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX/Calls/CA8dfedb55c129dd4d6bd1f59af9d11080/Recordings \
    -u 'ACXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX:your_auth_token'
出力を表示
  • JSON
  • XML
{
	"page": 0,
	"page_size": 50,
	"uri": "/2010-04-01/Accounts/ACXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX/Calls/CA8dfedb55c129dd4d6bd1f59af9d11080/Recordings.json?Page=0&PageSize=50",
	"first_page_uri": "/2010-04-01/Accounts/ACXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX/Calls/CA8dfedb55c129dd4d6bd1f59af9d11080/Recordings.json?Page=0&PageSize=50",
	"previous_page_uri": null,
	"next_page_uri": "/2010-04-01/Accounts/ACXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX/Calls/CA8dfedb55c129dd4d6bd1f59af9d11080/Recordings.json?Page=1&PageSize=50",
	"recordings": [
		{
			"account_sid": "ACXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX",
			"api_version": "2010-04-01",
			"call_sid": "CA8dfedb55c129dd4d6bd1f59af9d11080",
			"channels": 2,
			"date_created": "Tue, 18 Oct 2016 21:55:38 +0000",
			"date_updated": "Tue, 18 Oct 2016 21:56:34 +0000",
			"duration": "53",
			"price": "-0.00250",
			"price_unit": "USD",
			"sid": "RE557ce644e5ab84fa21cc21112e22c485",
			"source": "DialVerb",
			"status": "completed",
			"uri": "/2010-04-01/Accounts/ACXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX/Recordings/RE557ce644e5ab84fa21cc21112e22c485.json"
		}
	]
}
<TwilioResponse>
	<Recordings page="0" pagesize="50" uri="/2010-04-01/Accounts/ACXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX/Calls/CA8dfedb55c129dd4d6bd1f59af9d11080/Recordings?Page=0&amp;PageSize=50" firstpageuri="/2010-04-01/Accounts/ACXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX/Calls/CA8dfedb55c129dd4d6bd1f59af9d11080/Recordings?Page=0&amp;PageSize=50" previouspageuri="" nextpageuri="/2010-04-01/Accounts/ACXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX/Calls/CA8dfedb55c129dd4d6bd1f59af9d11080/Recordings?Page=1&amp;PageSize=50">
		<Recording>
		  <Sid>RE557ce644e5ab84fa21cc21112e22c485</Sid>
		  <AccountSid>ACXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX</AccountSid>
		  <CallSid>CA8dfedb55c129dd4d6bd1f59af9d11080</CallSid>
		  <Duration>53</Duration>
		  <DateCreated>Tue, 18 Oct 2016 21:55:38 +0000</DateCreated>
		  <ApiVersion>2010-04-01</ApiVersion>
		  <DateUpdated>Tue, 18 Oct 2016 21:56:34 +0000</DateUpdated>
		  <Status>completed</Status>
		  <Source>DialVerb</Source>
		  <Channels>2</Channels>
		  <Price>-0.00250</Price>
		  <PriceUnit>USD</PriceUnit>
		  <Uri>/2010-04-01/Accounts/ACXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX/Recordings/RE557ce644e5ab84fa21cc21112e22c485</Uri>
		</Recording>
	</Recordings>
</TwilioResponse>
Get all Recordings for a given Call
例 3

Only return recordings generated on Oct 18, 2016.

完全一致による録音のフィルタリング
  • C#
  • curl
  • Java
  • Node.js
  • PHP
  • Python
  • Ruby
SDKバージョン:
  • 4.x
  • 5.x
レスポンス形式:
  • JSON
  • xml
SDKバージョン:
  • 6.x
  • 7.x
SDKバージョン:
  • 2.x
  • 3.x
SDKバージョン:
  • 4.x
  • 5.x
SDKバージョン:
  • 5.x
  • 6.x
SDKバージョン:
  • 4.x
  • 5.x
// Download the twilio-csharp library from twilio.com/docs/libraries/csharp
using System;
using Twilio;
using Twilio.Rest.Api.V2010.Account;

class Example
{
    static void Main(string[] args)
    {
        // Find your Account Sid and Auth Token at twilio.com/console
        const string accountSid = "ACXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX";
        const string authToken = "your_auth_token";
        TwilioClient.Init(accountSid, authToken);

        var recordings = RecordingResource.Read(dateCreated: new DateTime(2016, 10, 18));

        foreach (var recording in recordings)
        {
            Console.WriteLine(recording.CallSid);
        }
    }
}
<?php
// Get the PHP helper library from twilio.com/docs/php/install
require_once '/path/to/vendor/autoload.php'; // Loads the library
use Twilio\Rest\Client;

// Your Account Sid and Auth Token from twilio.com/user/account
$sid = "ACXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX";
$token = "your_auth_token";
$client = new Client($sid, $token);

$recordings = $client->recordings->read(
    array("dateCreated" => "2016-10-18")
);
// Loop over the list of recordings and echo a property for each one
foreach ($recordings as $recording) {
    echo $recording->callSid;
}
# Download the Python helper library from twilio.com/docs/python/install
from twilio.rest import TwilioRestClient

# Your Account Sid and Auth Token from twilio.com/user/account
account_sid = "ACXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX"
auth_token  = "your_auth_token"
client = TwilioRestClient(account_sid, auth_token)

# A list of recording objects with the properties described above
recordings = client.recordings.list(date_created="2016-10-18")
require 'rubygems' # not necessary with ruby 1.9 but included for completeness
require 'twilio-ruby'

# put your own credentials here
account_sid = 'ACXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX'
auth_token = 'your_auth_token'

# set up a client to talk to the Twilio REST API
@client = Twilio::REST::Client.new(account_sid, auth_token)

# Loop over recordings and print out a property for each one
@client.account.recordings.list(
  date_created: Time.new('2009-07-06')
).each do |recording|
  puts recording.call_sid
end
$ curl -G https://api.twilio.com/2010-04-01/Accounts/ACXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX/Recordings.json \
    -d "DateCreated=2016-10-18" \
    -u 'ACXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX:your_auth_token'
$ curl -G https://api.twilio.com/2010-04-01/Accounts/ACXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX/Recordings \
    -d "DateCreated=2016-10-18" \
    -u 'ACXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX:your_auth_token'
// Install the Java helper library from twilio.com/docs/java/install
import com.twilio.sdk.TwilioRestClient;
import com.twilio.sdk.TwilioRestException;
import com.twilio.sdk.resource.instance.Recording;
import com.twilio.sdk.resource.list.RecordingList;
import java.util.HashMap;
import java.util.Map;

public class Example { 

  // Find your Account Sid and Token at twilio.com/user/account
  public static final String ACCOUNT_SID = "ACXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX";
  public static final String AUTH_TOKEN = "your_auth_token";

  public static void main(String[] args) throws TwilioRestException {
    TwilioRestClient client = new TwilioRestClient(ACCOUNT_SID, AUTH_TOKEN);

    // Build a filter for the RecordingList
    Map<String, String> params = new HashMap<String, String>();
    
    params.put("DateCreated", "2016-10-18");
    
    RecordingList recordings = client.getAccount().getRecordings(params);
    
    // Loop over recordings and print out a property for each one.
    for (Recording recording : recordings) {
      System.out.println(recording.getCallSid());
    }
    
  }
}
# Download the Python helper library from twilio.com/docs/python/install
from twilio.rest import Client
from datetime import date

# Your Account Sid and Auth Token from twilio.com/user/account
account_sid = "ACXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX"
auth_token = "your_auth_token"
client = Client(account_sid, auth_token)

# A list of recording objects with the properties described above
recordings = client.recordings \
                   .list(date_created=date(2016, 10, 18))

for recording in recordings:
    print(recording.call_sid)
// Download the Node helper library from twilio.com/docs/node/install
// These consts are your accountSid and authToken from https://www.twilio.com/console
const accountSid = 'ACXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX';
const authToken = 'your_auth_token';
const client = require('twilio')(accountSid, authToken);

client.recordings.each({dateCreated: '2016-10-18'},
                       (recording) => console.log(recording.callSid));
// Download the twilio-csharp library from twilio.com/docs/csharp/install
using System;
using Twilio;
class Example 
{
  static void Main(string[] args) 
  {
    // Find your Account Sid and Auth Token at twilio.com/user/account
    string AccountSid = "ACXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX";
    string AuthToken = "your_auth_token";
    var twilio = new TwilioRestClient(AccountSid, AuthToken);

    var recordings = twilio.ListRecordings(null, new DateTime(2016, 10, 18), null, null);
    
    foreach (var recording in recordings.Recordings)
    {
      Console.WriteLine(recording.CallSid);
    }
  }
}
<?php
// Get the PHP helper library from twilio.com/docs/php/install
require_once('/path/to/twilio-php/Services/Twilio.php'); // Loads the library

// Your Account Sid and Auth Token from twilio.com/user/account
$sid = "ACXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX"; 
$token = "your_auth_token"; 
$client = new Services_Twilio($sid, $token);

// Loop over the list of recordings and echo a property for each one
foreach ($client->account->recordings->getIterator(0, 50, array(
        "DateCreated" => "2016-10-18"
    )) as $recording
) {
    echo $recording->call_sid;
}
# Get twilio-ruby from twilio.com/docs/ruby/install
require 'rubygems'          # This line not needed for ruby > 1.8
require 'twilio-ruby'

# Get your Account Sid and Auth Token from twilio.com/user/account
account_sid = 'ACXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX'
auth_token = 'your_auth_token'
@client = Twilio::REST::Client.new account_sid, auth_token


# Loop over recordings and print out a property for each one
@client.account.recordings.list({
  :date_created => "2016-10-18"}).each do |recording|
  puts recording.call_sid
end
// Install the Java helper library from twilio.com/docs/java/install
import org.joda.time.DateTime;

import com.twilio.Twilio;
import com.twilio.base.ResourceSet;
import com.twilio.rest.api.v2010.account.Recording;

public class Example {
  /// Find your Account Sid and Token at twilio.com/user/account
  public static final String ACCOUNT_SID = "ACXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX";
  public static final String AUTH_TOKEN = "your_auth_token";

  public static void main(String[] args) {
    Twilio.init(ACCOUNT_SID, AUTH_TOKEN);

    ResourceSet<Recording> recordings = Recording.reader()
        .setDateCreated(DateTime.parse("2016-10-18"))
        .read();

    // Loop over recordings and print out a property for each one.
    for (Recording recording : recordings) {
      System.out.println(recording.getDuration());
    }
  }
}
// Download the Node helper library from twilio.com/docs/node/install
// These vars are your accountSid and authToken from twilio.com/user/account
var accountSid = 'ACXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX';
var authToken = "your_auth_token";
var client = require('twilio')(accountSid, authToken);

client.recordings.list({ dateCreated: "2016-10-18" }, function(err, data) {
    data.recordings.forEach(function(recording) {
        console.log(recording.CallSid);
    });
});
出力を表示
  • JSON
  • XML
{
	"page": 0,
	"page_size": 50,
	"uri": "/2010-04-01/Accounts/ACXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX/Recordings.json?DateCreated=2016-10-18&Page=0&PageSize=50",
	"first_page_uri": "/2010-04-01/Accounts/ACXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX/Recordings.json?Page=0&PageSize=50",
	"previous_page_uri": null,
	"next_page_uri": "/2010-04-01/Accounts/ACXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX/Recordings.json?Page=1&PageSize=50",
	"recordings": [
		{
			"account_sid": "ACXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX",
			"api_version": "2010-04-01",
			"call_sid": "CA8dfedb55c129dd4d6bd1f59af9d11080",
			"channels": 2,
			"date_created": "Tue, 18 Oct 2016 21:55:38 +0000",
			"date_updated": "Tue, 18 Oct 2016 21:56:34 +0000",
			"price": "-0.00250",
			"price_unit": "USD",
			"duration": "53",
			"sid": "RE557ce644e5ab84fa21cc21112e22c485",
			"source": "DialVerb",
			"status": "completed",
			"uri": "/2010-04-01/Accounts/ACXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX/Recordings/RE557ce644e5ab84fa21cc21112e22c485.json"
		},
		...
	]
}
<TwilioResponse>
	<Recordings page="0" pagesize="50" uri="/2010-04-01/Accounts/ACXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX/Recordings?DateCreated=2016-10-18&Page=0&amp;PageSize=50" firstpageuri="/2010-04-01/Accounts/ACXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX/Recordings?Page=0&amp;PageSize=50" previouspageuri="" nextpageuri="/2010-04-01/Accounts/ACXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX/Recordings?Page=1&amp;PageSize=50">
		<Recording>
		  <Sid>RE557ce644e5ab84fa21cc21112e22c485</Sid>
		  <AccountSid>ACXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX</AccountSid>
		  <CallSid>CA8dfedb55c129dd4d6bd1f59af9d11080</CallSid>
		  <Duration>53</Duration>
		  <DateCreated>Tue, 18 Oct 2016 21:55:38 +0000</DateCreated>
		  <ApiVersion>2010-04-01</ApiVersion>
		  <DateUpdated>Tue, 18 Oct 2016 21:56:34 +0000</DateUpdated>
		  <Status>completed</Status>
		  <Source>DialVerb</Source>
		  <Channels>2</Channels>
		  <Price>-0.00250</Price>
		  <PriceUnit>USD</PriceUnit>
		  <Uri>/2010-04-01/Accounts/ACXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX/Recordings/RE557ce644e5ab84fa21cc21112e22c485</Uri>
		</Recording>
		...
	</Recordings>
</TwilioResponse>
完全一致による録音のフィルタリング
例 4

Only return recordings generated between midnight Oct 12, 2016 and midnight Oct 15, 2016.

範囲一致による録音のフィルタリング
  • C#
  • curl
  • Java
  • Node.js
  • PHP
  • Python
  • Ruby
SDKバージョン:
  • 4.x
  • 5.x
レスポンス形式:
  • JSON
  • xml
SDKバージョン:
  • 6.x
  • 7.x
SDKバージョン:
  • 2.x
  • 3.x
SDKバージョン:
  • 4.x
  • 5.x
SDKバージョン:
  • 5.x
  • 6.x
SDKバージョン:
  • 4.x
  • 5.x
// Download the twilio-csharp library from twilio.com/docs/libraries/csharp
using System;
using Twilio;
using Twilio.Rest.Api.V2010.Account;

class Example
{
    static void Main(string[] args)
    {
        // Find your Account Sid and Auth Token at twilio.com/console
        const string accountSid = "ACXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX";
        const string authToken = "your_auth_token";
        TwilioClient.Init(accountSid, authToken);

        var recordings = RecordingResource.Read();

        foreach (var recording in recordings)
        {
            Console.WriteLine(recording.Duration);
        }
    }
}
<?php
// Get the PHP helper library from twilio.com/docs/php/install
require_once '/path/to/vendor/autoload.php'; // Loads the library
use Twilio\Rest\Client;

// Your Account Sid and Auth Token from twilio.com/user/account
$sid = "ACXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX";
$token = "your_auth_token";
$client = new Client($sid, $token);

$recordings = $client->recordings->read(
    array(
        "datecreatedBefore" => "2016-10-15",
        "datecreatedAfter" => "2016-10-12"
    )
);
// Loop over the list of recordings and echo a property for each one
foreach ($recordings as $recording) {
    echo $recording->callSid;
}
# Download the Python helper library from twilio.com/docs/python/install
from twilio.rest import TwilioRestClient
from datetime import date

# Your Account Sid and Auth Token from twilio.com/user/account
account_sid = "ACXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX"
auth_token  = "your_auth_token"
client = TwilioRestClient(account_sid, auth_token)

# A list of recording objects with the properties described above
recordings = client.recordings.list(before=date(2016, 10, 15),
    after=date(2016, 10, 12))
require 'rubygems' # not necessary with ruby 1.9 but included for completeness
require 'twilio-ruby'

# put your own credentials here
account_sid = 'ACXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX'
auth_token = 'your_auth_token'

# set up a client to talk to the Twilio REST API
@client = Twilio::REST::Client.new(account_sid, auth_token)

# Loop over recordings and print out a property for each one
@client.account.recordings.list(
  date_created_after: Time.new('2009-07-06'),
  date_created_before: Time.new('2009-07-04')
).each do |recording|
  puts recording.duration
end
$ curl -G https://api.twilio.com/2010-04-01/Accounts/ACXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX/Recordings.json \
    -d "DateCreated<=2016-10-15" \
    -d "DateCreated>=2016-10-12" \
    -u 'ACXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX:your_auth_token'
$ curl -G https://api.twilio.com/2010-04-01/Accounts/ACXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX/Recordings \
    -d "DateCreated<=2016-10-15" \
    -d "DateCreated>=2016-10-12" \
    -u 'ACXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX:your_auth_token'
// Install the Java helper library from twilio.com/docs/java/install
import com.twilio.sdk.TwilioRestClient;
import com.twilio.sdk.TwilioRestException;
import com.twilio.sdk.resource.instance.Recording;
import com.twilio.sdk.resource.list.RecordingList;
import java.util.HashMap;
import java.util.Map;

public class Example { 

  // Find your Account Sid and Token at twilio.com/user/account
  public static final String ACCOUNT_SID = "ACXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX";
  public static final String AUTH_TOKEN = "your_auth_token";

  public static void main(String[] args) throws TwilioRestException {
    TwilioRestClient client = new TwilioRestClient(ACCOUNT_SID, AUTH_TOKEN);

    // Build a filter for the RecordingList
    Map<String, String> params = new HashMap<String, String>();
    
    params.put("DateCreated<", "2016-10-15");
    params.put("DateCreated>", "2016-10-12");
    
    RecordingList recordings = client.getAccount().getRecordings(params);
    
    // Loop over recordings and print out a property for each one.
    for (Recording recording : recordings) {
      System.out.println(recording.getDuration());
    }
    
  }
}
# Download the Python helper library from twilio.com/docs/python/install
from twilio.rest import Client
from datetime import date

# Your Account Sid and Auth Token from twilio.com/user/account
account_sid = "ACXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX"
auth_token = "your_auth_token"
client = Client(account_sid, auth_token)

# A list of recording objects with the properties described above
recordings = client.recordings \
                   .list(date_created_before=date(2016, 10, 15),
                         date_created_after=date(2016, 10, 12))

for recording in recordings:
    print(recording.call_sid)
// Download the Node helper library from twilio.com/docs/node/install
// These consts are your accountSid and authToken from https://www.twilio.com/console
const accountSid = 'ACXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX';
const authToken = 'your_auth_token';
const client = require('twilio')(accountSid, authToken);

const filterOpts = {
  dateCreatedBefore: '2016-10-15',
  dateCreatedAfter: '2016-10-12',
};

client.recordings
  .each(filterOpts, (recording) => console.log(recording.duration));
// Download the twilio-csharp library from twilio.com/docs/csharp/install
using System;
using Twilio;
class Example 
{
  static void Main(string[] args) 
  {
    // Find your Account Sid and Auth Token at twilio.com/user/account
    string AccountSid = "ACXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX";
    string AuthToken = "your_auth_token";
    var twilio = new TwilioRestClient(AccountSid, AuthToken);

    var recordings = twilio.ListRecordings(null, null, null, null);
    
    foreach (var recording in recordings.Recordings)
    {
      Console.WriteLine(recording.Duration);
    }
  }
}
<?php
// Get the PHP helper library from twilio.com/docs/php/install
require_once('/path/to/twilio-php/Services/Twilio.php'); // Loads the library

// Your Account Sid and Auth Token from twilio.com/user/account
$sid = "ACXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX"; 
$token = "your_auth_token"; 
$client = new Services_Twilio($sid, $token);

// Loop over the list of recordings and echo a property for each one
foreach ($client->account->recordings->getIterator(0, 50, array(
        "DateCreated<" => "2016-10-15",
    "DateCreated>" => "2016-10-12"
    )) as $recording
) {
    echo $recording->duration;
}
# Get twilio-ruby from twilio.com/docs/ruby/install
require 'rubygems'          # This line not needed for ruby > 1.8
require 'twilio-ruby'

# Get your Account Sid and Auth Token from twilio.com/user/account
account_sid = 'ACXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX'
auth_token = 'your_auth_token'
@client = Twilio::REST::Client.new account_sid, auth_token


# Loop over recordings and print out a property for each one
@client.account.recordings.list({
  :"date_created<" => "2016-10-15",
  :"date_created>" => "2016-10-12"}).each do |recording|
  puts recording.duration
end
// Install the Java helper library from twilio.com/docs/java/install
import org.joda.time.DateTime;

import com.google.common.collect.Range;
import com.twilio.Twilio;
import com.twilio.base.ResourceSet;
import com.twilio.rest.api.v2010.account.Recording;

public class Example {
  /// Find your Account Sid and Token at twilio.com/user/account
  public static final String ACCOUNT_SID = "ACXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX";
  public static final String AUTH_TOKEN = "your_auth_token";

  public static void main(String[] args) {
    Twilio.init(ACCOUNT_SID, AUTH_TOKEN);

    DateTime lower = DateTime.parse("2016-10-12");
    DateTime upper = DateTime.parse("2016-10-15");

    ResourceSet<Recording> recordings = Recording.reader()
        .setDateCreated(Range.closed(lower, upper))
        .read();

    // Loop over recordings and print out a property for each one.
    for (Recording recording : recordings) {
      System.out.println(recording.getDuration());
    }
  }
}
// Download the Node helper library from twilio.com/docs/node/install
// These vars are your accountSid and authToken from twilio.com/user/account
var accountSid = 'ACXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX';
var authToken = "your_auth_token";
var client = require('twilio')(accountSid, authToken);

client.recordings.list({ "dateCreated<": "2016-10-15",
    "dateCreated>": "2016-10-12" }, function(err, data) {
    data.recordings.forEach(function(recording) {
        console.log(recording.Duration);
    });
});
出力を表示
  • JSON
  • XML
{
	"page": 0,
	"page_size": 50,
	"uri": "/2010-04-01/Accounts/ACXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX/Recordings.json?DateCreated%3C=2016-10-12&DateCreated%3E=2016-10-15&Page=0&PageSize=50",
	"first_page_uri": "/2010-04-01/Accounts/ACXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX/Recordings.json?Page=0&PageSize=50",
	"previous_page_uri": null,
	"next_page_uri": "/2010-04-01/Accounts/ACXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX/Recordings.json?Page=1&PageSize=50",
	"recordings": [
		{
			"account_sid": "ACXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX",
			"api_version": "2010-04-01",
			"call_sid": "CA6ae7af4f7ea97f7b30b379de2e329a02",
			"channels": 2,
			"date_created": "Tue, 14 Oct 2016 21:55:38 +0000",
			"date_updated": "Tue, 14 Oct 2016 21:56:34 +0000",
			"price": "-0.00250",
			"price_unit": "USD",
			"duration": "53",
			"sid": "RE20d7f32989e54e22920075f45174f6bb",
			"source": "DialVerb",
			"status": "completed",
			"uri": "/2010-04-01/Accounts/ACXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX/Recordings/RE20d7f32989e54e22920075f45174f6bb.json"
		},
		...
	]
}
<TwilioResponse>
	<Recordings page="0" pagesize="50" uri="/2010-04-01/Accounts/ACXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX/Recordings?DateCreated%3C=2016-10-15&amp;DateCreated%3E=2016-10-12&amp;Page=0&amp;PageSize=50" firstpageuri="/2010-04-01/Accounts/ACXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX/Recordings?Page=0&amp;PageSize=50" previouspageuri="" nextpageuri="/2010-04-01/Accounts/ACXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX/Recordings?Page=1&amp;PageSize=50">
		<Recording>
		  <Sid>RE20d7f32989e54e22920075f45174f6bb</Sid>
		  <AccountSid>ACXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX</AccountSid>
		  <CallSid>CA6ae7af4f7ea97f7b30b379de2e329a02</CallSid>
		  <Duration>53</Duration>
		  <DateCreated>Tue, 14 Oct 2016 21:55:38 +0000</DateCreated>
		  <ApiVersion>2010-04-01</ApiVersion>
		  <DateUpdated>Tue, 14 Oct 2016 21:56:34 +0000</DateUpdated>
		  <Status>completed</Status>
		  <Source>DialVerb</Source>
		  <Channels>2</Channels>
		  <Price>-0.00250</Price>
		  <PriceUnit>USD</PriceUnit>
		  <Uri>/2010-04-01/Accounts/ACXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX/Recordings/RE20d7f32989e54e22920075f45174f6bb</Uri>
		</Recording>
		...
	</Recordings>
</TwilioResponse>
範囲一致による録音のフィルタリング

HTTP POST

サポートしません。

HTTP PUT

サポートしません。

HTTP DELETE

サポートしません。

1 / 1
Loading Code Samples...
形式:
  • XML
$ curl -G https://api.twilio.com/2010-04-01/Accounts/ACXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX/Recordings/RE557ce644e5ab84fa21cc21112e22c485 \
-u "ACXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX:your_auth_token"
<TwilioResponse>
  <Recording>
    <Sid>RE557ce644e5ab84fa21cc21112e22c485</Sid>
    <AccountSid>ACXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX</AccountSid>
    <CallSid>CA8dfedb55c129dd4d6bd1f59af9d11080</CallSid>
    <Duration>53</Duration>
    <DateCreated>Tue, 18 Oct 2016 21:55:38 +0000</DateCreated>
    <ApiVersion>2010-04-01</ApiVersion>
    <DateUpdated>Tue, 18 Oct 2016 21:56:34 +0000</DateUpdated>
    <Status>completed</Status>
    <Source>DialVerb</Source>
    <Channels>2</Channels>
    <Price>-0.00250</Price>
    <PriceUnit>USD</PriceUnit>
    <Uri>/2010-04-01/Accounts/ACXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX/Recordings/RE557ce644e5ab84fa21cc21112e22c485.xml</Uri>
  </Recording>
</TwilioResponse>
形式:
  • JSON
$ curl -G https://api.twilio.com/2010-04-01/Accounts/ACXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX/Recordings/RE557ce644e5ab84fa21cc21112e22c485.json
{
    "account_sid": "ACXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX",
    "api_version": "2010-04-01",
    "call_sid": "CA8dfedb55c129dd4d6bd1f59af9d11080",
    "channels": 2,
    "date_created": "Tue, 18 Oct 2016 21:55:38 +0000",
    "date_updated": "Tue, 18 Oct 2016 21:56:34 +0000",
    "duration": "53",
    "price": "-0.00250",
    "price_unit": "USD",
    "sid": "RE557ce644e5ab84fa21cc21112e22c485",
    "source": "DialVerb",
    "status": "completed",
    "uri": "/2010-04-01/Accounts/ACXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX/Recordings/RE557ce644e5ab84fa21cc21112e22c485.json"
}
SDKバージョン:
  • 4.x
  • 5.x
レスポンス形式:
  • JSON
  • xml
SDKバージョン:
  • 6.x
  • 7.x
SDKバージョン:
  • 2.x
  • 3.x
SDKバージョン:
  • 4.x
  • 5.x
SDKバージョン:
  • 5.x
  • 6.x
SDKバージョン:
  • 4.x
  • 5.x
// Download the twilio-csharp library from twilio.com/docs/libraries/csharp
using System;
using Twilio;
using Twilio.Rest.Api.V2010.Account;

class Example
{
    static void Main(string[] args)
    {
        // Find your Account Sid and Auth Token at twilio.com/console
        const string accountSid = "ACXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX";
        const string authToken = "your_auth_token";
        TwilioClient.Init(accountSid, authToken);

        RecordingResource.Delete("RE557ce644e5ab84fa21cc21112e22c485");
    }
}
<?php
// Get the PHP helper library from twilio.com/docs/php/install
require_once '/path/to/vendor/autoload.php'; // Loads the library
use Twilio\Rest\Client;

// Your Account Sid and Auth Token from twilio.com/user/account
$sid = "ACXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX";
$token = "your_auth_token";
$client = new Client($sid, $token);

$client->recordings("RE557ce644e5ab84fa21cc21112e22c485")->delete();
# Download the Python helper library from twilio.com/docs/python/install
from twilio.rest import TwilioRestClient

# Your Account Sid and Auth Token from twilio.com/user/account
account_sid = "ACXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX"
auth_token  = "your_auth_token"
client = TwilioRestClient(account_sid, auth_token)

client.recordings.delete("RE557ce644e5ab84fa21cc21112e22c485")
require 'rubygems' # not necessary with ruby 1.9 but included for completeness
require 'twilio-ruby'

# put your own credentials here
account_sid = 'ACXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX'
auth_token = 'your_auth_token'

# set up a client to talk to the Twilio REST API
@client = Twilio::REST::Client.new(account_sid, auth_token)

@recording = @client.account
                    .recordings('RE557ce644e5ab84fa21cc21112e22c485').fetch

@recording.delete
$ curl -XDELETE https://api.twilio.com/2010-04-01/Accounts/ACXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX/Recordings/RE557ce644e5ab84fa21cc21112e22c485.json \
    -u 'ACXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX:your_auth_token'
$ curl -XDELETE https://api.twilio.com/2010-04-01/Accounts/ACXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX/Recordings/RE557ce644e5ab84fa21cc21112e22c485 \
    -u 'ACXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX:your_auth_token'
// Install the Java helper library from twilio.com/docs/java/install
import com.twilio.sdk.TwilioRestClient;
import com.twilio.sdk.TwilioRestException;
import com.twilio.sdk.resource.instance.Recording;

public class Example { 

  // Find your Account Sid and Token at twilio.com/user/account
  public static final String ACCOUNT_SID = "ACXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX";
  public static final String AUTH_TOKEN = "your_auth_token";

  public static void main(String[] args) throws TwilioRestException {
    TwilioRestClient client = new TwilioRestClient(ACCOUNT_SID, AUTH_TOKEN);

    // Get an object from its sid. If you do not have a sid,
    // check out the list resource examples on this page
    Recording recording = client.getAccount().getRecording("RE557ce644e5ab84fa21cc21112e22c485");
    
    recording.delete();
    
  }
}
# Download the Python helper library from twilio.com/docs/python/install
from twilio.rest import Client

# Your Account Sid and Auth Token from twilio.com/user/account
account_sid = "ACXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX"
auth_token = "your_auth_token"
client = Client(account_sid, auth_token)

client.recordings("RE557ce644e5ab84fa21cc21112e22c485") \
      .delete()
// Download the Node helper library from twilio.com/docs/node/install
// These consts are your accountSid and authToken from https://www.twilio.com/console
const accountSid = 'ACXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX';
const authToken = 'your_auth_token';
const client = require('twilio')(accountSid, authToken);

const recordingSid = 'RE557ce644e5ab84fa21cc21112e22c485';

client.recordings(recordingSid)
  .remove()
  .then(() => console.log(`Sid ${recordingSid} deleted successfully.`))
  .catch((err) => {
    console.log(err.status);
    throw err;
  });
// Download the twilio-csharp library from twilio.com/docs/csharp/install
using System;
using Twilio;
class Example 
{
  static void Main(string[] args) 
  {
    // Find your Account Sid and Auth Token at twilio.com/user/account
    string AccountSid = "ACXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX";
    string AuthToken = "your_auth_token";
    var twilio = new TwilioRestClient(AccountSid, AuthToken);

    twilio.DeleteRecording("RE557ce644e5ab84fa21cc21112e22c485");
  }
}
<?php
// Get the PHP helper library from twilio.com/docs/php/install
require_once('/path/to/twilio-php/Services/Twilio.php'); // Loads the library

// Your Account Sid and Auth Token from twilio.com/user/account
$sid = "ACXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX"; 
$token = "your_auth_token"; 
$client = new Services_Twilio($sid, $token);

$client->account->recordings->delete("RE557ce644e5ab84fa21cc21112e22c485");
# Get twilio-ruby from twilio.com/docs/ruby/install
require 'rubygems'          # This line not needed for ruby > 1.8
require 'twilio-ruby'

# Get your Account Sid and Auth Token from twilio.com/user/account
account_sid = 'ACXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX'
auth_token = 'your_auth_token'
@client = Twilio::REST::Client.new account_sid, auth_token

@recording = @client.account.recordings.get("RE557ce644e5ab84fa21cc21112e22c485")
@recording.delete
// Install the Java helper library from twilio.com/docs/java/install
import com.twilio.Twilio;
import com.twilio.rest.api.v2010.account.Recording;

public class Example {
  /// Find your Account Sid and Token at twilio.com/user/account
  public static final String ACCOUNT_SID = "ACXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX";
  public static final String AUTH_TOKEN = "your_auth_token";

  public static void main(String[] args) {
    Twilio.init(ACCOUNT_SID, AUTH_TOKEN);

    // Get an object from its sid. If you do not have a sid,
    // check out the list resource examples on this page
    Recording.deleter("RE557ce644e5ab84fa21cc21112e22c485").delete();
  }
}
// Download the Node helper library from twilio.com/docs/node/install
// These vars are your accountSid and authToken from twilio.com/user/account
var accountSid = 'ACXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX';
var authToken = "your_auth_token";
var client = require('twilio')(accountSid, authToken);

client.recordings("RE557ce644e5ab84fa21cc21112e22c485").delete(function(err, data) {
    if (err) {
        console.log(err.status);
        throw err.message;
    } else {
        console.log("Sid RE557ce644e5ab84fa21cc21112e22c485 deleted successfully.");
    }
});
SDKバージョン:
  • 4.x
  • 5.x
レスポンス形式:
  • JSON
  • xml
SDKバージョン:
  • 6.x
  • 7.x
SDKバージョン:
  • 2.x
  • 3.x
SDKバージョン:
  • 4.x
  • 5.x
SDKバージョン:
  • 5.x
  • 6.x
SDKバージョン:
  • 4.x
  • 5.x
形式:
  • JSON
  • XML
// Download the twilio-csharp library from twilio.com/docs/libraries/csharp
using System;
using Twilio;
using Twilio.Rest.Api.V2010.Account;

class Example
{
    static void Main(string[] args)
    {
        // Find your Account Sid and Auth Token at twilio.com/console
        const string accountSid = "ACXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX";
        const string authToken = "your_auth_token";
        TwilioClient.Init(accountSid, authToken);

        var recordings = RecordingResource.Read();

        foreach (var recording in recordings)
        {
            Console.WriteLine(recording.Duration);
        }
    }
}
<?php
// Get the PHP helper library from twilio.com/docs/php/install
require_once '/path/to/vendor/autoload.php'; // Loads the library
use Twilio\Rest\Client;

// Your Account Sid and Auth Token from twilio.com/user/account
$sid = "ACXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX";
$token = "your_auth_token";
$client = new Client($sid, $token);

// Loop over the list of recordings and echo a property for each one
foreach ($client->recordings->read() as $recording) {
    echo $recording->duration;
}
# Download the Python helper library from twilio.com/docs/python/install
from twilio.rest import TwilioRestClient

# Your Account Sid and Auth Token from twilio.com/user/account
account_sid = "ACXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX"
auth_token  = "your_auth_token"
client = TwilioRestClient(account_sid, auth_token)

# A list of recording objects with the properties described above
recordings = client.recordings.list()
require 'rubygems' # not necessary with ruby 1.9 but included for completeness
require 'twilio-ruby'

# put your own credentials here
account_sid = 'ACXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX'
auth_token = 'your_auth_token'

# set up a client to talk to the Twilio REST API
@client = Twilio::REST::Client.new(account_sid, auth_token)

# Loop over recordings and print out a property for each one
@client.account.recordings.list.each do |recording|
  puts recording.duration
end
$ curl -G https://api.twilio.com/2010-04-01/Accounts/ACXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX/Recordings.json \
    -u 'ACXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX:your_auth_token'
$ curl -G https://api.twilio.com/2010-04-01/Accounts/ACXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX/Recordings \
    -u 'ACXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX:your_auth_token'
// Install the Java helper library from twilio.com/docs/java/install
import com.twilio.sdk.TwilioRestClient;
import com.twilio.sdk.TwilioRestException;
import com.twilio.sdk.resource.instance.Recording;
import com.twilio.sdk.resource.list.RecordingList;

public class Example { 

  // Find your Account Sid and Token at twilio.com/user/account
  public static final String ACCOUNT_SID = "ACXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX";
  public static final String AUTH_TOKEN = "your_auth_token";

  public static void main(String[] args) throws TwilioRestException {
    TwilioRestClient client = new TwilioRestClient(ACCOUNT_SID, AUTH_TOKEN);

    
    
    RecordingList recordings = client.getAccount().getRecordings();
    
    // Loop over recordings and print out a property for each one.
    for (Recording recording : recordings) {
      System.out.println(recording.getDuration());
    }
    
  }
}
# Download the Python helper library from twilio.com/docs/python/install
from twilio.rest import Client

# Your Account Sid and Auth Token from twilio.com/user/account
account_sid = "ACXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX"
auth_token = "your_auth_token"
client = Client(account_sid, auth_token)

# A list of recording objects with the properties described above
for recording in client.recordings.list():
    print(recording.duration)
// Download the Node helper library from twilio.com/docs/node/install
// These consts are your accountSid and authToken from https://www.twilio.com/console
const accountSid = 'ACXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX';
const authToken = 'your_auth_token';
const client = require('twilio')(accountSid, authToken);

client.recordings
  .each((recording) => console.log(recording.duration));
// Download the twilio-csharp library from twilio.com/docs/csharp/install
using System;
using Twilio;
class Example 
{
  static void Main(string[] args) 
  {
    // Find your Account Sid and Auth Token at twilio.com/user/account
    string AccountSid = "ACXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX";
    string AuthToken = "your_auth_token";
    var twilio = new TwilioRestClient(AccountSid, AuthToken);

    var recordings = twilio.ListRecordings(null, null, null, null);
    
    foreach (var recording in recordings.Recordings)
    {
      Console.WriteLine(recording.Duration);
    }
  }
}
<?php
// Get the PHP helper library from twilio.com/docs/php/install
require_once('/path/to/twilio-php/Services/Twilio.php'); // Loads the library

// Your Account Sid and Auth Token from twilio.com/user/account
$sid = "ACXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX"; 
$token = "your_auth_token"; 
$client = new Services_Twilio($sid, $token);

// Loop over the list of recordings and echo a property for each one
foreach ($client->account->recordings as $recording) {
    echo $recording->duration;
}
# Get twilio-ruby from twilio.com/docs/ruby/install
require 'rubygems'          # This line not needed for ruby > 1.8
require 'twilio-ruby'

# Get your Account Sid and Auth Token from twilio.com/user/account
account_sid = 'ACXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX'
auth_token = 'your_auth_token'
@client = Twilio::REST::Client.new account_sid, auth_token


# Loop over recordings and print out a property for each one
@client.account.recordings.list.each do |recording|
  puts recording.duration
end
// Install the Java helper library from twilio.com/docs/java/install
import com.twilio.Twilio;
import com.twilio.base.ResourceSet;
import com.twilio.rest.api.v2010.account.Recording;

public class Example {
  /// Find your Account Sid and Token at twilio.com/user/account
  public static final String ACCOUNT_SID = "ACXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX";
  public static final String AUTH_TOKEN = "your_auth_token";

  public static void main(String[] args) {
    Twilio.init(ACCOUNT_SID, AUTH_TOKEN);

    ResourceSet<Recording> recordings = Recording.reader().read();

    // Loop over recordings and print out a property for each one.
    for (Recording recording : recordings) {
      System.out.println(recording.getDuration());
    }
  }
}
// Download the Node helper library from twilio.com/docs/node/install
// These vars are your accountSid and authToken from twilio.com/user/account
var accountSid = 'ACXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX';
var authToken = "your_auth_token";
var client = require('twilio')(accountSid, authToken);

client.recordings.list(function(err, data) {
    data.recordings.forEach(function(recording) {
        console.log(recording.Duration);
    });
});
{
	"page": 0,
	"page_size": 50,
	"uri": "/2010-04-01/Accounts/ACXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX/Recordings.json"
	"first_page_uri": "/2010-04-01/Accounts/ACXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX/Recordings.json?Page=0&PageSize=50",
	"previous_page_uri": null,
	"next_page_uri": "/2010-04-01/Accounts/ACXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX/Recordings.json?Page=1&PageSize=50",
	"recordings": [
		{
			"account_sid": "ACXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX",
			"api_version": "2010-04-01",
			"call_sid": "CA8dfedb55c129dd4d6bd1f59af9d11080",
			"channels": 2,
			"date_created": "Tue, 18 Oct 2016 21:55:38 +0000",
			"date_updated": "Tue, 18 Oct 2016 21:56:34 +0000",
			"duration": "53",
			"price": "-0.00250",
			"price_unit": "USD",
			"sid": "RE557ce644e5ab84fa21cc21112e22c485",
			"source": "DialVerb",
			"status": "completed",
			"uri": "/2010-04-01/Accounts/ACXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX/Recordings/RE557ce644e5ab84fa21cc21112e22c485.json"
		},
		...
	]
}
<TwilioResponse>
	<Recordings page="0" pagesize="50" uri="/2010-04-01/Accounts/ACXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX/Recordings?Page=0&amp;PageSize=50" firstpageuri="/2010-04-01/Accounts/ACXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX/Recordings?Page=0&amp;PageSize=50" previouspageuri="" nextpageuri="/2010-04-01/Accounts/ACXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX/Recordings?Page=1&amp;PageSize=50">
		<Recording>
			<Sid>RE557ce644e5ab84fa21cc21112e22c485</Sid>
			<AccountSid>ACXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX</AccountSid>
			<CallSid>CA8dfedb55c129dd4d6bd1f59af9d11080</CallSid>
			<Duration>53</Duration>
			<DateCreated>Tue, 18 Oct 2016 21:55:38 +0000</DateCreated>
			<ApiVersion>2010-04-01</ApiVersion>
			<DateUpdated>Tue, 18 Oct 2016 21:56:34 +0000</DateUpdated>
			<Status>completed</Status>
			<Source>DialVerb</Source>
			<Channels>2</Channels>
			<Price>-0.00250</Price>
			<PriceUnit>USD</PriceUnit>
			<Uri>/2010-04-01/Accounts/ACXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX/Recordings/RE557ce644e5ab84fa21cc21112e22c485</Uri>
		</Recording>
		...
	</Recordings>
</TwilioResponse>
レスポンス形式:
  • JSON
  • xml
形式:
  • JSON
  • XML
$ curl -G https://api.twilio.com/2010-04-01/Accounts/ACXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX/Calls/CA8dfedb55c129dd4d6bd1f59af9d11080/Recordings.json \
    -u 'ACXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX:your_auth_token
$ curl -G https://api.twilio.com/2010-04-01/Accounts/ACXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX/Calls/CA8dfedb55c129dd4d6bd1f59af9d11080/Recordings \
    -u 'ACXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX:your_auth_token'
{
	"page": 0,
	"page_size": 50,
	"uri": "/2010-04-01/Accounts/ACXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX/Calls/CA8dfedb55c129dd4d6bd1f59af9d11080/Recordings.json?Page=0&PageSize=50",
	"first_page_uri": "/2010-04-01/Accounts/ACXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX/Calls/CA8dfedb55c129dd4d6bd1f59af9d11080/Recordings.json?Page=0&PageSize=50",
	"previous_page_uri": null,
	"next_page_uri": "/2010-04-01/Accounts/ACXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX/Calls/CA8dfedb55c129dd4d6bd1f59af9d11080/Recordings.json?Page=1&PageSize=50",
	"recordings": [
		{
			"account_sid": "ACXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX",
			"api_version": "2010-04-01",
			"call_sid": "CA8dfedb55c129dd4d6bd1f59af9d11080",
			"channels": 2,
			"date_created": "Tue, 18 Oct 2016 21:55:38 +0000",
			"date_updated": "Tue, 18 Oct 2016 21:56:34 +0000",
			"duration": "53",
			"price": "-0.00250",
			"price_unit": "USD",
			"sid": "RE557ce644e5ab84fa21cc21112e22c485",
			"source": "DialVerb",
			"status": "completed",
			"uri": "/2010-04-01/Accounts/ACXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX/Recordings/RE557ce644e5ab84fa21cc21112e22c485.json"
		}
	]
}
<TwilioResponse>
	<Recordings page="0" pagesize="50" uri="/2010-04-01/Accounts/ACXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX/Calls/CA8dfedb55c129dd4d6bd1f59af9d11080/Recordings?Page=0&amp;PageSize=50" firstpageuri="/2010-04-01/Accounts/ACXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX/Calls/CA8dfedb55c129dd4d6bd1f59af9d11080/Recordings?Page=0&amp;PageSize=50" previouspageuri="" nextpageuri="/2010-04-01/Accounts/ACXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX/Calls/CA8dfedb55c129dd4d6bd1f59af9d11080/Recordings?Page=1&amp;PageSize=50">
		<Recording>
		  <Sid>RE557ce644e5ab84fa21cc21112e22c485</Sid>
		  <AccountSid>ACXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX</AccountSid>
		  <CallSid>CA8dfedb55c129dd4d6bd1f59af9d11080</CallSid>
		  <Duration>53</Duration>
		  <DateCreated>Tue, 18 Oct 2016 21:55:38 +0000</DateCreated>
		  <ApiVersion>2010-04-01</ApiVersion>
		  <DateUpdated>Tue, 18 Oct 2016 21:56:34 +0000</DateUpdated>
		  <Status>completed</Status>
		  <Source>DialVerb</Source>
		  <Channels>2</Channels>
		  <Price>-0.00250</Price>
		  <PriceUnit>USD</PriceUnit>
		  <Uri>/2010-04-01/Accounts/ACXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX/Recordings/RE557ce644e5ab84fa21cc21112e22c485</Uri>
		</Recording>
	</Recordings>
</TwilioResponse>
SDKバージョン:
  • 4.x
  • 5.x
レスポンス形式:
  • JSON
  • xml
SDKバージョン:
  • 6.x
  • 7.x
SDKバージョン:
  • 2.x
  • 3.x
SDKバージョン:
  • 4.x
  • 5.x
SDKバージョン:
  • 5.x
  • 6.x
SDKバージョン:
  • 4.x
  • 5.x
形式:
  • JSON
  • XML
// Download the twilio-csharp library from twilio.com/docs/libraries/csharp
using System;
using Twilio;
using Twilio.Rest.Api.V2010.Account;

class Example
{
    static void Main(string[] args)
    {
        // Find your Account Sid and Auth Token at twilio.com/console
        const string accountSid = "ACXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX";
        const string authToken = "your_auth_token";
        TwilioClient.Init(accountSid, authToken);

        var recordings = RecordingResource.Read(dateCreated: new DateTime(2016, 10, 18));

        foreach (var recording in recordings)
        {
            Console.WriteLine(recording.CallSid);
        }
    }
}
<?php
// Get the PHP helper library from twilio.com/docs/php/install
require_once '/path/to/vendor/autoload.php'; // Loads the library
use Twilio\Rest\Client;

// Your Account Sid and Auth Token from twilio.com/user/account
$sid = "ACXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX";
$token = "your_auth_token";
$client = new Client($sid, $token);

$recordings = $client->recordings->read(
    array("dateCreated" => "2016-10-18")
);
// Loop over the list of recordings and echo a property for each one
foreach ($recordings as $recording) {
    echo $recording->callSid;
}
# Download the Python helper library from twilio.com/docs/python/install
from twilio.rest import TwilioRestClient

# Your Account Sid and Auth Token from twilio.com/user/account
account_sid = "ACXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX"
auth_token  = "your_auth_token"
client = TwilioRestClient(account_sid, auth_token)

# A list of recording objects with the properties described above
recordings = client.recordings.list(date_created="2016-10-18")
require 'rubygems' # not necessary with ruby 1.9 but included for completeness
require 'twilio-ruby'

# put your own credentials here
account_sid = 'ACXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX'
auth_token = 'your_auth_token'

# set up a client to talk to the Twilio REST API
@client = Twilio::REST::Client.new(account_sid, auth_token)

# Loop over recordings and print out a property for each one
@client.account.recordings.list(
  date_created: Time.new('2009-07-06')
).each do |recording|
  puts recording.call_sid
end
$ curl -G https://api.twilio.com/2010-04-01/Accounts/ACXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX/Recordings.json \
    -d "DateCreated=2016-10-18" \
    -u 'ACXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX:your_auth_token'
$ curl -G https://api.twilio.com/2010-04-01/Accounts/ACXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX/Recordings \
    -d "DateCreated=2016-10-18" \
    -u 'ACXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX:your_auth_token'
// Install the Java helper library from twilio.com/docs/java/install
import com.twilio.sdk.TwilioRestClient;
import com.twilio.sdk.TwilioRestException;
import com.twilio.sdk.resource.instance.Recording;
import com.twilio.sdk.resource.list.RecordingList;
import java.util.HashMap;
import java.util.Map;

public class Example { 

  // Find your Account Sid and Token at twilio.com/user/account
  public static final String ACCOUNT_SID = "ACXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX";
  public static final String AUTH_TOKEN = "your_auth_token";

  public static void main(String[] args) throws TwilioRestException {
    TwilioRestClient client = new TwilioRestClient(ACCOUNT_SID, AUTH_TOKEN);

    // Build a filter for the RecordingList
    Map<String, String> params = new HashMap<String, String>();
    
    params.put("DateCreated", "2016-10-18");
    
    RecordingList recordings = client.getAccount().getRecordings(params);
    
    // Loop over recordings and print out a property for each one.
    for (Recording recording : recordings) {
      System.out.println(recording.getCallSid());
    }
    
  }
}
# Download the Python helper library from twilio.com/docs/python/install
from twilio.rest import Client
from datetime import date

# Your Account Sid and Auth Token from twilio.com/user/account
account_sid = "ACXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX"
auth_token = "your_auth_token"
client = Client(account_sid, auth_token)

# A list of recording objects with the properties described above
recordings = client.recordings \
                   .list(date_created=date(2016, 10, 18))

for recording in recordings:
    print(recording.call_sid)
// Download the Node helper library from twilio.com/docs/node/install
// These consts are your accountSid and authToken from https://www.twilio.com/console
const accountSid = 'ACXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX';
const authToken = 'your_auth_token';
const client = require('twilio')(accountSid, authToken);

client.recordings.each({dateCreated: '2016-10-18'},
                       (recording) => console.log(recording.callSid));
// Download the twilio-csharp library from twilio.com/docs/csharp/install
using System;
using Twilio;
class Example 
{
  static void Main(string[] args) 
  {
    // Find your Account Sid and Auth Token at twilio.com/user/account
    string AccountSid = "ACXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX";
    string AuthToken = "your_auth_token";
    var twilio = new TwilioRestClient(AccountSid, AuthToken);

    var recordings = twilio.ListRecordings(null, new DateTime(2016, 10, 18), null, null);
    
    foreach (var recording in recordings.Recordings)
    {
      Console.WriteLine(recording.CallSid);
    }
  }
}
<?php
// Get the PHP helper library from twilio.com/docs/php/install
require_once('/path/to/twilio-php/Services/Twilio.php'); // Loads the library

// Your Account Sid and Auth Token from twilio.com/user/account
$sid = "ACXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX"; 
$token = "your_auth_token"; 
$client = new Services_Twilio($sid, $token);

// Loop over the list of recordings and echo a property for each one
foreach ($client->account->recordings->getIterator(0, 50, array(
        "DateCreated" => "2016-10-18"
    )) as $recording
) {
    echo $recording->call_sid;
}
# Get twilio-ruby from twilio.com/docs/ruby/install
require 'rubygems'          # This line not needed for ruby > 1.8
require 'twilio-ruby'

# Get your Account Sid and Auth Token from twilio.com/user/account
account_sid = 'ACXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX'
auth_token = 'your_auth_token'
@client = Twilio::REST::Client.new account_sid, auth_token


# Loop over recordings and print out a property for each one
@client.account.recordings.list({
  :date_created => "2016-10-18"}).each do |recording|
  puts recording.call_sid
end
// Install the Java helper library from twilio.com/docs/java/install
import org.joda.time.DateTime;

import com.twilio.Twilio;
import com.twilio.base.ResourceSet;
import com.twilio.rest.api.v2010.account.Recording;

public class Example {
  /// Find your Account Sid and Token at twilio.com/user/account
  public static final String ACCOUNT_SID = "ACXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX";
  public static final String AUTH_TOKEN = "your_auth_token";

  public static void main(String[] args) {
    Twilio.init(ACCOUNT_SID, AUTH_TOKEN);

    ResourceSet<Recording> recordings = Recording.reader()
        .setDateCreated(DateTime.parse("2016-10-18"))
        .read();

    // Loop over recordings and print out a property for each one.
    for (Recording recording : recordings) {
      System.out.println(recording.getDuration());
    }
  }
}
// Download the Node helper library from twilio.com/docs/node/install
// These vars are your accountSid and authToken from twilio.com/user/account
var accountSid = 'ACXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX';
var authToken = "your_auth_token";
var client = require('twilio')(accountSid, authToken);

client.recordings.list({ dateCreated: "2016-10-18" }, function(err, data) {
    data.recordings.forEach(function(recording) {
        console.log(recording.CallSid);
    });
});
{
	"page": 0,
	"page_size": 50,
	"uri": "/2010-04-01/Accounts/ACXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX/Recordings.json?DateCreated=2016-10-18&Page=0&PageSize=50",
	"first_page_uri": "/2010-04-01/Accounts/ACXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX/Recordings.json?Page=0&PageSize=50",
	"previous_page_uri": null,
	"next_page_uri": "/2010-04-01/Accounts/ACXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX/Recordings.json?Page=1&PageSize=50",
	"recordings": [
		{
			"account_sid": "ACXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX",
			"api_version": "2010-04-01",
			"call_sid": "CA8dfedb55c129dd4d6bd1f59af9d11080",
			"channels": 2,
			"date_created": "Tue, 18 Oct 2016 21:55:38 +0000",
			"date_updated": "Tue, 18 Oct 2016 21:56:34 +0000",
			"price": "-0.00250",
			"price_unit": "USD",
			"duration": "53",
			"sid": "RE557ce644e5ab84fa21cc21112e22c485",
			"source": "DialVerb",
			"status": "completed",
			"uri": "/2010-04-01/Accounts/ACXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX/Recordings/RE557ce644e5ab84fa21cc21112e22c485.json"
		},
		...
	]
}
<TwilioResponse>
	<Recordings page="0" pagesize="50" uri="/2010-04-01/Accounts/ACXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX/Recordings?DateCreated=2016-10-18&Page=0&amp;PageSize=50" firstpageuri="/2010-04-01/Accounts/ACXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX/Recordings?Page=0&amp;PageSize=50" previouspageuri="" nextpageuri="/2010-04-01/Accounts/ACXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX/Recordings?Page=1&amp;PageSize=50">
		<Recording>
		  <Sid>RE557ce644e5ab84fa21cc21112e22c485</Sid>
		  <AccountSid>ACXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX</AccountSid>
		  <CallSid>CA8dfedb55c129dd4d6bd1f59af9d11080</CallSid>
		  <Duration>53</Duration>
		  <DateCreated>Tue, 18 Oct 2016 21:55:38 +0000</DateCreated>
		  <ApiVersion>2010-04-01</ApiVersion>
		  <DateUpdated>Tue, 18 Oct 2016 21:56:34 +0000</DateUpdated>
		  <Status>completed</Status>
		  <Source>DialVerb</Source>
		  <Channels>2</Channels>
		  <Price>-0.00250</Price>
		  <PriceUnit>USD</PriceUnit>
		  <Uri>/2010-04-01/Accounts/ACXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX/Recordings/RE557ce644e5ab84fa21cc21112e22c485</Uri>
		</Recording>
		...
	</Recordings>
</TwilioResponse>
SDKバージョン:
  • 4.x
  • 5.x
レスポンス形式:
  • JSON
  • xml
SDKバージョン:
  • 6.x
  • 7.x
SDKバージョン:
  • 2.x
  • 3.x
SDKバージョン:
  • 4.x
  • 5.x
SDKバージョン:
  • 5.x
  • 6.x
SDKバージョン:
  • 4.x
  • 5.x
形式:
  • JSON
  • XML
// Download the twilio-csharp library from twilio.com/docs/libraries/csharp
using System;
using Twilio;
using Twilio.Rest.Api.V2010.Account;

class Example
{
    static void Main(string[] args)
    {
        // Find your Account Sid and Auth Token at twilio.com/console
        const string accountSid = "ACXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX";
        const string authToken = "your_auth_token";
        TwilioClient.Init(accountSid, authToken);

        var recordings = RecordingResource.Read();

        foreach (var recording in recordings)
        {
            Console.WriteLine(recording.Duration);
        }
    }
}
<?php
// Get the PHP helper library from twilio.com/docs/php/install
require_once '/path/to/vendor/autoload.php'; // Loads the library
use Twilio\Rest\Client;

// Your Account Sid and Auth Token from twilio.com/user/account
$sid = "ACXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX";
$token = "your_auth_token";
$client = new Client($sid, $token);

$recordings = $client->recordings->read(
    array(
        "datecreatedBefore" => "2016-10-15",
        "datecreatedAfter" => "2016-10-12"
    )
);
// Loop over the list of recordings and echo a property for each one
foreach ($recordings as $recording) {
    echo $recording->callSid;
}
# Download the Python helper library from twilio.com/docs/python/install
from twilio.rest import TwilioRestClient
from datetime import date

# Your Account Sid and Auth Token from twilio.com/user/account
account_sid = "ACXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX"
auth_token  = "your_auth_token"
client = TwilioRestClient(account_sid, auth_token)

# A list of recording objects with the properties described above
recordings = client.recordings.list(before=date(2016, 10, 15),
    after=date(2016, 10, 12))
require 'rubygems' # not necessary with ruby 1.9 but included for completeness
require 'twilio-ruby'

# put your own credentials here
account_sid = 'ACXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX'
auth_token = 'your_auth_token'

# set up a client to talk to the Twilio REST API
@client = Twilio::REST::Client.new(account_sid, auth_token)

# Loop over recordings and print out a property for each one
@client.account.recordings.list(
  date_created_after: Time.new('2009-07-06'),
  date_created_before: Time.new('2009-07-04')
).each do |recording|
  puts recording.duration
end
$ curl -G https://api.twilio.com/2010-04-01/Accounts/ACXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX/Recordings.json \
    -d "DateCreated<=2016-10-15" \
    -d "DateCreated>=2016-10-12" \
    -u 'ACXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX:your_auth_token'
$ curl -G https://api.twilio.com/2010-04-01/Accounts/ACXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX/Recordings \
    -d "DateCreated<=2016-10-15" \
    -d "DateCreated>=2016-10-12" \
    -u 'ACXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX:your_auth_token'
// Install the Java helper library from twilio.com/docs/java/install
import com.twilio.sdk.TwilioRestClient;
import com.twilio.sdk.TwilioRestException;
import com.twilio.sdk.resource.instance.Recording;
import com.twilio.sdk.resource.list.RecordingList;
import java.util.HashMap;
import java.util.Map;

public class Example { 

  // Find your Account Sid and Token at twilio.com/user/account
  public static final String ACCOUNT_SID = "ACXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX";
  public static final String AUTH_TOKEN = "your_auth_token";

  public static void main(String[] args) throws TwilioRestException {
    TwilioRestClient client = new TwilioRestClient(ACCOUNT_SID, AUTH_TOKEN);

    // Build a filter for the RecordingList
    Map<String, String> params = new HashMap<String, String>();
    
    params.put("DateCreated<", "2016-10-15");
    params.put("DateCreated>", "2016-10-12");
    
    RecordingList recordings = client.getAccount().getRecordings(params);
    
    // Loop over recordings and print out a property for each one.
    for (Recording recording : recordings) {
      System.out.println(recording.getDuration());
    }
    
  }
}
# Download the Python helper library from twilio.com/docs/python/install
from twilio.rest import Client
from datetime import date

# Your Account Sid and Auth Token from twilio.com/user/account
account_sid = "ACXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX"
auth_token = "your_auth_token"
client = Client(account_sid, auth_token)

# A list of recording objects with the properties described above
recordings = client.recordings \
                   .list(date_created_before=date(2016, 10, 15),
                         date_created_after=date(2016, 10, 12))

for recording in recordings:
    print(recording.call_sid)
// Download the Node helper library from twilio.com/docs/node/install
// These consts are your accountSid and authToken from https://www.twilio.com/console
const accountSid = 'ACXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX';
const authToken = 'your_auth_token';
const client = require('twilio')(accountSid, authToken);

const filterOpts = {
  dateCreatedBefore: '2016-10-15',
  dateCreatedAfter: '2016-10-12',
};

client.recordings
  .each(filterOpts, (recording) => console.log(recording.duration));
// Download the twilio-csharp library from twilio.com/docs/csharp/install
using System;
using Twilio;
class Example 
{
  static void Main(string[] args) 
  {
    // Find your Account Sid and Auth Token at twilio.com/user/account
    string AccountSid = "ACXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX";
    string AuthToken = "your_auth_token";
    var twilio = new TwilioRestClient(AccountSid, AuthToken);

    var recordings = twilio.ListRecordings(null, null, null, null);
    
    foreach (var recording in recordings.Recordings)
    {
      Console.WriteLine(recording.Duration);
    }
  }
}
<?php
// Get the PHP helper library from twilio.com/docs/php/install
require_once('/path/to/twilio-php/Services/Twilio.php'); // Loads the library

// Your Account Sid and Auth Token from twilio.com/user/account
$sid = "ACXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX"; 
$token = "your_auth_token"; 
$client = new Services_Twilio($sid, $token);

// Loop over the list of recordings and echo a property for each one
foreach ($client->account->recordings->getIterator(0, 50, array(
        "DateCreated<" => "2016-10-15",
    "DateCreated>" => "2016-10-12"
    )) as $recording
) {
    echo $recording->duration;
}
# Get twilio-ruby from twilio.com/docs/ruby/install
require 'rubygems'          # This line not needed for ruby > 1.8
require 'twilio-ruby'

# Get your Account Sid and Auth Token from twilio.com/user/account
account_sid = 'ACXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX'
auth_token = 'your_auth_token'
@client = Twilio::REST::Client.new account_sid, auth_token


# Loop over recordings and print out a property for each one
@client.account.recordings.list({
  :"date_created<" => "2016-10-15",
  :"date_created>" => "2016-10-12"}).each do |recording|
  puts recording.duration
end
// Install the Java helper library from twilio.com/docs/java/install
import org.joda.time.DateTime;

import com.google.common.collect.Range;
import com.twilio.Twilio;
import com.twilio.base.ResourceSet;
import com.twilio.rest.api.v2010.account.Recording;

public class Example {
  /// Find your Account Sid and Token at twilio.com/user/account
  public static final String ACCOUNT_SID = "ACXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX";
  public static final String AUTH_TOKEN = "your_auth_token";

  public static void main(String[] args) {
    Twilio.init(ACCOUNT_SID, AUTH_TOKEN);

    DateTime lower = DateTime.parse("2016-10-12");
    DateTime upper = DateTime.parse("2016-10-15");

    ResourceSet<Recording> recordings = Recording.reader()
        .setDateCreated(Range.closed(lower, upper))
        .read();

    // Loop over recordings and print out a property for each one.
    for (Recording recording : recordings) {
      System.out.println(recording.getDuration());
    }
  }
}
// Download the Node helper library from twilio.com/docs/node/install
// These vars are your accountSid and authToken from twilio.com/user/account
var accountSid = 'ACXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX';
var authToken = "your_auth_token";
var client = require('twilio')(accountSid, authToken);

client.recordings.list({ "dateCreated<": "2016-10-15",
    "dateCreated>": "2016-10-12" }, function(err, data) {
    data.recordings.forEach(function(recording) {
        console.log(recording.Duration);
    });
});
{
	"page": 0,
	"page_size": 50,
	"uri": "/2010-04-01/Accounts/ACXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX/Recordings.json?DateCreated%3C=2016-10-12&DateCreated%3E=2016-10-15&Page=0&PageSize=50",
	"first_page_uri": "/2010-04-01/Accounts/ACXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX/Recordings.json?Page=0&PageSize=50",
	"previous_page_uri": null,
	"next_page_uri": "/2010-04-01/Accounts/ACXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX/Recordings.json?Page=1&PageSize=50",
	"recordings": [
		{
			"account_sid": "ACXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX",
			"api_version": "2010-04-01",
			"call_sid": "CA6ae7af4f7ea97f7b30b379de2e329a02",
			"channels": 2,
			"date_created": "Tue, 14 Oct 2016 21:55:38 +0000",
			"date_updated": "Tue, 14 Oct 2016 21:56:34 +0000",
			"price": "-0.00250",
			"price_unit": "USD",
			"duration": "53",
			"sid": "RE20d7f32989e54e22920075f45174f6bb",
			"source": "DialVerb",
			"status": "completed",
			"uri": "/2010-04-01/Accounts/ACXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX/Recordings/RE20d7f32989e54e22920075f45174f6bb.json"
		},
		...
	]
}
<TwilioResponse>
	<Recordings page="0" pagesize="50" uri="/2010-04-01/Accounts/ACXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX/Recordings?DateCreated%3C=2016-10-15&amp;DateCreated%3E=2016-10-12&amp;Page=0&amp;PageSize=50" firstpageuri="/2010-04-01/Accounts/ACXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX/Recordings?Page=0&amp;PageSize=50" previouspageuri="" nextpageuri="/2010-04-01/Accounts/ACXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX/Recordings?Page=1&amp;PageSize=50">
		<Recording>
		  <Sid>RE20d7f32989e54e22920075f45174f6bb</Sid>
		  <AccountSid>ACXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX</AccountSid>
		  <CallSid>CA6ae7af4f7ea97f7b30b379de2e329a02</CallSid>
		  <Duration>53</Duration>
		  <DateCreated>Tue, 14 Oct 2016 21:55:38 +0000</DateCreated>
		  <ApiVersion>2010-04-01</ApiVersion>
		  <DateUpdated>Tue, 14 Oct 2016 21:56:34 +0000</DateUpdated>
		  <Status>completed</Status>
		  <Source>DialVerb</Source>
		  <Channels>2</Channels>
		  <Price>-0.00250</Price>
		  <PriceUnit>USD</PriceUnit>
		  <Uri>/2010-04-01/Accounts/ACXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX/Recordings/RE20d7f32989e54e22920075f45174f6bb</Uri>
		</Recording>
		...
	</Recordings>
</TwilioResponse>