| 1 | # Generated by tools/generate.pl from Twilio's OpenAPI specs. Do not edit this file. | ||||||||||||||||||||
| 2 | package Twilio::Rest::Api::V2010::Account; | ||||||||||||||||||||
| 3 | |||||||||||||||||||||
| 4 | 12 | ▶ | use 5.016; | ||||||||||||||||||
|
Subroutine
BEGIN: called CC=1 SCAR=0.0
| |||||||||||||||||||||
| 5 | 12 | ▶ | use warnings; | ||||||||||||||||||
|
Subroutine
BEGIN: called CC=1 SCAR=0.0
| |||||||||||||||||||||
| 6 | |||||||||||||||||||||
| 7 | 12 | our $VERSION = '2.001'; | |||||||||||||||||||
| 8 | |||||||||||||||||||||
| 9 | package Twilio::Rest::Api::V2010::AccountList; | ||||||||||||||||||||
| 10 | |||||||||||||||||||||
| 11 | 12 | ▶ | use parent 'Twilio::ListResource'; | ||||||||||||||||||
|
Subroutine
BEGIN: called CC=1 SCAR=0.0
| |||||||||||||||||||||
| 12 | |||||||||||||||||||||
| 13 | 12 | ▶ | use Twilio::Serialize; | ||||||||||||||||||
|
Subroutine
BEGIN: called CC=1 SCAR=0.0
| |||||||||||||||||||||
| 14 | |||||||||||||||||||||
| 15 | 203 | ▶ | sub new { | ||||||||||||||||||
|
Subroutine
new: called CC=1 SCAR=0.0
| |||||||||||||||||||||
| 16 | 203 | my ($class, $version) = @_; | |||||||||||||||||||
| 17 | 203 | my $self = $class->SUPER::new($version); | |||||||||||||||||||
| 18 | 203 | $self->{solution} = {}; | |||||||||||||||||||
| 19 | 203 | $self->{uri} = '/Accounts.json'; | |||||||||||||||||||
| 20 | 203 | return $self; | |||||||||||||||||||
| 21 | } | ||||||||||||||||||||
| 22 | |||||||||||||||||||||
| 23 | 1 | ▶ | sub create { | ||||||||||||||||||
|
Subroutine
create: called CC=2 SCAR=7.0
| |||||||||||||||||||||
| 24 | 1 | my ($self, $options) = @_; | |||||||||||||||||||
| 25 | 1 | ▶ | $options //= {}; | ||||||||||||||||||
|
Condition50%1/2
$options //= {}
MC/DC0%0/1
$options //= {}
$options
Truth table50%1/2
A
A= $options
| |||||||||||||||||||||
| 26 | |||||||||||||||||||||
| 27 | 1 | my $data = { FriendlyName => $options->{friendly_name}, }; | |||||||||||||||||||
| 28 | |||||||||||||||||||||
| 29 | my $response = | ||||||||||||||||||||
| 30 | 1 | $self->{version}->handle_request('POST', $self->{uri}, 'create', { data => $data }); | |||||||||||||||||||
| 31 | 1 | return Twilio::Rest::Api::V2010::AccountInstance->new($self->{version}, $response->get_content); | |||||||||||||||||||
| 32 | } | ||||||||||||||||||||
| 33 | |||||||||||||||||||||
| 34 | 1 | ▶ | sub read { | ||||||||||||||||||
|
Subroutine
read: called CC=1 SCAR=0.0
| |||||||||||||||||||||
| 35 | 1 | my ($self, @arguments) = @_; | |||||||||||||||||||
| 36 | 1 | return $self->read_records(@arguments); | |||||||||||||||||||
| 37 | } | ||||||||||||||||||||
| 38 | |||||||||||||||||||||
| 39 | 0 | ▶ | sub stream { | ||||||||||||||||||
|
Subroutine
stream: not called CC=1 SCAR=6.9
| |||||||||||||||||||||
| 40 | 0 | my ($self, @arguments) = @_; | |||||||||||||||||||
| 41 | 0 | return $self->stream_records(@arguments); | |||||||||||||||||||
| 42 | } | ||||||||||||||||||||
| 43 | |||||||||||||||||||||
| 44 | 2 | ▶ | sub page { | ||||||||||||||||||
|
Subroutine
page: called CC=2 SCAR=7.0
| |||||||||||||||||||||
| 45 | 2 | my ($self, $options, $page_size, $page_token, $page_number) = @_; | |||||||||||||||||||
| 46 | 2 | ▶ | $options //= {}; | ||||||||||||||||||
|
Condition50%1/2
$options //= {}
MC/DC0%0/1
$options //= {}
$options
Truth table50%1/2
A
A= $options
| |||||||||||||||||||||
| 47 | |||||||||||||||||||||
| 48 | my $params = { | ||||||||||||||||||||
| 49 | FriendlyName => $options->{friendly_name}, | ||||||||||||||||||||
| 50 | Status => $options->{status}, | ||||||||||||||||||||
| 51 | 2 | PageToken => $page_token, | |||||||||||||||||||
| 52 | Page => $page_number, | ||||||||||||||||||||
| 53 | PageSize => $page_size, | ||||||||||||||||||||
| 54 | }; | ||||||||||||||||||||
| 55 | |||||||||||||||||||||
| 56 | 2 | my $response = $self->{version}->page('GET', $self->{uri}, { params => $params }); | |||||||||||||||||||
| 57 | 2 | return $self->_build_page($response); | |||||||||||||||||||
| 58 | } | ||||||||||||||||||||
| 59 | |||||||||||||||||||||
| 60 | 0 | ▶ | sub get_page { | ||||||||||||||||||
|
Subroutine
get_page: not called CC=1 SCAR=6.9
| |||||||||||||||||||||
| 61 | 0 | my ($self, $target_url) = @_; | |||||||||||||||||||
| 62 | 0 | my $client = $self->{version}->get_domain->get_client; | |||||||||||||||||||
| 63 | 0 | return $self->_build_page($client->request('GET', $target_url)); | |||||||||||||||||||
| 64 | } | ||||||||||||||||||||
| 65 | |||||||||||||||||||||
| 66 | 2 | ▶ | sub _build_page { | ||||||||||||||||||
|
Subroutine
_build_page: called CC=1 SCAR=0.0
| |||||||||||||||||||||
| 67 | 2 | my ($self, $response) = @_; | |||||||||||||||||||
| 68 | 2 | return Twilio::Rest::Api::V2010::AccountPage->new($self->{version}, $response, $self->{solution}); | |||||||||||||||||||
| 69 | } | ||||||||||||||||||||
| 70 | |||||||||||||||||||||
| 71 | 200 | ▶ | sub get_context { | ||||||||||||||||||
|
Subroutine
get_context: called CC=1 SCAR=0.0
| |||||||||||||||||||||
| 72 | 200 | my ($self, $sid) = @_; | |||||||||||||||||||
| 73 | 200 | return Twilio::Rest::Api::V2010::AccountContext->new($self->{version}, $sid); | |||||||||||||||||||
| 74 | } | ||||||||||||||||||||
| 75 | |||||||||||||||||||||
| 76 | package Twilio::Rest::Api::V2010::AccountPage; | ||||||||||||||||||||
| 77 | |||||||||||||||||||||
| 78 | 12 | ▶ | use parent 'Twilio::Page'; | ||||||||||||||||||
|
Subroutine
BEGIN: called CC=1 SCAR=0.0
| |||||||||||||||||||||
| 79 | |||||||||||||||||||||
| 80 | 2 | ▶ | sub records_key { return 'accounts' } | ||||||||||||||||||
|
Subroutine
records_key: called CC=1 SCAR=0.0
| |||||||||||||||||||||
| 81 | |||||||||||||||||||||
| 82 | 2 | ▶ | sub build_instance { | ||||||||||||||||||
|
Subroutine
build_instance: called CC=1 SCAR=0.0
| |||||||||||||||||||||
| 83 | 2 | my ($self, $payload) = @_; | |||||||||||||||||||
| 84 | 2 | return Twilio::Rest::Api::V2010::AccountInstance->new($self->{version}, $payload); | |||||||||||||||||||
| 85 | } | ||||||||||||||||||||
| 86 | |||||||||||||||||||||
| 87 | package Twilio::Rest::Api::V2010::AccountContext; | ||||||||||||||||||||
| 88 | |||||||||||||||||||||
| 89 | 12 | ▶ | use parent 'Twilio::InstanceContext'; | ||||||||||||||||||
|
Subroutine
BEGIN: called CC=1 SCAR=0.0
| |||||||||||||||||||||
| 90 | |||||||||||||||||||||
| 91 | 12 | ▶ | use Twilio::Serialize; | ||||||||||||||||||
|
Subroutine
BEGIN: called CC=1 SCAR=0.0
| |||||||||||||||||||||
| 92 | |||||||||||||||||||||
| 93 | 315 | ▶ | sub new { | ||||||||||||||||||
|
Subroutine
new: called CC=1 SCAR=0.0
| |||||||||||||||||||||
| 94 | 315 | my ($class, $version, $sid) = @_; | |||||||||||||||||||
| 95 | 315 | my $self = $class->SUPER::new($version); | |||||||||||||||||||
| 96 | 315 | $self->{solution} = { sid => $sid }; | |||||||||||||||||||
| 97 | 315 | $self->{uri} = join q{}, '/Accounts/', Twilio::Serialize::path_segment($sid), '.json'; | |||||||||||||||||||
| 98 | 314 | return $self; | |||||||||||||||||||
| 99 | } | ||||||||||||||||||||
| 100 | |||||||||||||||||||||
| 101 | 5 | ▶ | sub fetch { | ||||||||||||||||||
|
Subroutine
fetch: called CC=1 SCAR=0.0
| |||||||||||||||||||||
| 102 | 5 | my ($self) = @_; | |||||||||||||||||||
| 103 | |||||||||||||||||||||
| 104 | 5 | my $response = $self->{version}->handle_request('GET', $self->{uri}, 'fetch'); | |||||||||||||||||||
| 105 | 4 | return $self->_build_instance($response); | |||||||||||||||||||
| 106 | } | ||||||||||||||||||||
| 107 | |||||||||||||||||||||
| 108 | 2 | ▶ | sub update { | ||||||||||||||||||
|
Subroutine
update: called CC=2 SCAR=7.0
| |||||||||||||||||||||
| 109 | 2 | my ($self, $options) = @_; | |||||||||||||||||||
| 110 | 2 | ▶ | $options //= {}; | ||||||||||||||||||
|
Condition50%1/2
$options //= {}
MC/DC0%0/1
$options //= {}
$options
Truth table50%1/2
A
A= $options
| |||||||||||||||||||||
| 111 | |||||||||||||||||||||
| 112 | my $data = { | ||||||||||||||||||||
| 113 | FriendlyName => $options->{friendly_name}, | ||||||||||||||||||||
| 114 | Status => $options->{status}, | ||||||||||||||||||||
| 115 | 2 | }; | |||||||||||||||||||
| 116 | |||||||||||||||||||||
| 117 | my $response = | ||||||||||||||||||||
| 118 | 2 | $self->{version}->handle_request('POST', $self->{uri}, 'update', { data => $data }); | |||||||||||||||||||
| 119 | 2 | return $self->_build_instance($response); | |||||||||||||||||||
| 120 | } | ||||||||||||||||||||
| 121 | |||||||||||||||||||||
| 122 | 6 | ▶ | sub _build_instance { | ||||||||||||||||||
|
Subroutine
_build_instance: called CC=1 SCAR=0.0
| |||||||||||||||||||||
| 123 | 6 | my ($self, $response) = @_; | |||||||||||||||||||
| 124 | return Twilio::Rest::Api::V2010::AccountInstance->new($self->{version}, $response->get_content, | ||||||||||||||||||||
| 125 | 6 | $self->{solution}{sid}); | |||||||||||||||||||
| 126 | } | ||||||||||||||||||||
| 127 | |||||||||||||||||||||
| 128 | 6 | ▶ | sub addresses { | ||||||||||||||||||
|
Subroutine
addresses: called CC=2 SCAR=6.9
| |||||||||||||||||||||
| 129 | 6 | my ($self, $sid) = @_; | |||||||||||||||||||
| 130 | 6 | require Twilio::Rest::Api::V2010::Account::Address; | |||||||||||||||||||
| 131 | my $list = | ||||||||||||||||||||
| 132 | 6 | Twilio::Rest::Api::V2010::Account::AddressList->new($self->{version}, $self->{solution}{sid}); | |||||||||||||||||||
| 133 | 6 | ▶ | return defined $sid ? $list->get_context($sid) : $list; | ||||||||||||||||||
|
Branch: 1 branch
| |||||||||||||||||||||
| 134 | } | ||||||||||||||||||||
| 135 | |||||||||||||||||||||
| 136 | 5 | ▶ | sub applications { | ||||||||||||||||||
|
Subroutine
applications: called CC=2 SCAR=6.9
| |||||||||||||||||||||
| 137 | 5 | my ($self, $sid) = @_; | |||||||||||||||||||
| 138 | 5 | require Twilio::Rest::Api::V2010::Account::Application; | |||||||||||||||||||
| 139 | my $list = Twilio::Rest::Api::V2010::Account::ApplicationList->new($self->{version}, | ||||||||||||||||||||
| 140 | 5 | $self->{solution}{sid}); | |||||||||||||||||||
| 141 | 5 | ▶ | return defined $sid ? $list->get_context($sid) : $list; | ||||||||||||||||||
|
Branch: 1 branch
| |||||||||||||||||||||
| 142 | } | ||||||||||||||||||||
| 143 | |||||||||||||||||||||
| 144 | 2 | ▶ | sub authorized_connect_apps { | ||||||||||||||||||
|
Subroutine
authorized_connect_apps: called CC=2 SCAR=6.9
| |||||||||||||||||||||
| 145 | 2 | my ($self, $connect_app_sid) = @_; | |||||||||||||||||||
| 146 | 2 | require Twilio::Rest::Api::V2010::Account::AuthorizedConnectApp; | |||||||||||||||||||
| 147 | my $list = Twilio::Rest::Api::V2010::Account::AuthorizedConnectAppList->new($self->{version}, | ||||||||||||||||||||
| 148 | 2 | $self->{solution}{sid}); | |||||||||||||||||||
| 149 | 2 | ▶ | return defined $connect_app_sid ? $list->get_context($connect_app_sid) : $list; | ||||||||||||||||||
|
Branch: 1 branch
| |||||||||||||||||||||
| 150 | } | ||||||||||||||||||||
| 151 | |||||||||||||||||||||
| 152 | 10 | ▶ | sub available_phone_numbers { | ||||||||||||||||||
|
Subroutine
available_phone_numbers: called CC=2 SCAR=6.9
| |||||||||||||||||||||
| 153 | 10 | my ($self, $country_code) = @_; | |||||||||||||||||||
| 154 | 10 | require Twilio::Rest::Api::V2010::Account::AvailablePhoneNumberCountry; | |||||||||||||||||||
| 155 | my $list = | ||||||||||||||||||||
| 156 | Twilio::Rest::Api::V2010::Account::AvailablePhoneNumberCountryList->new($self->{version}, | ||||||||||||||||||||
| 157 | 10 | $self->{solution}{sid}); | |||||||||||||||||||
| 158 | 10 | ▶ | return defined $country_code ? $list->get_context($country_code) : $list; | ||||||||||||||||||
|
Branch: 1 branch
| |||||||||||||||||||||
| 159 | } | ||||||||||||||||||||
| 160 | |||||||||||||||||||||
| 161 | 2 | ▶ | sub balance { | ||||||||||||||||||
|
Subroutine
balance: called CC=1 SCAR=0.0
| |||||||||||||||||||||
| 162 | 2 | my ($self) = @_; | |||||||||||||||||||
| 163 | 2 | require Twilio::Rest::Api::V2010::Account::Balance; | |||||||||||||||||||
| 164 | return Twilio::Rest::Api::V2010::Account::BalanceList->new($self->{version}, | ||||||||||||||||||||
| 165 | 2 | $self->{solution}{sid}); | |||||||||||||||||||
| 166 | } | ||||||||||||||||||||
| 167 | |||||||||||||||||||||
| 168 | 40 | ▶ | sub calls { | ||||||||||||||||||
|
Subroutine
calls: called CC=2 SCAR=6.9
| |||||||||||||||||||||
| 169 | 40 | my ($self, $sid) = @_; | |||||||||||||||||||
| 170 | 40 | require Twilio::Rest::Api::V2010::Account::Call; | |||||||||||||||||||
| 171 | my $list = | ||||||||||||||||||||
| 172 | 40 | Twilio::Rest::Api::V2010::Account::CallList->new($self->{version}, $self->{solution}{sid}); | |||||||||||||||||||
| 173 | 40 | ▶ | return defined $sid ? $list->get_context($sid) : $list; | ||||||||||||||||||
|
Branch: 1 branch
| |||||||||||||||||||||
| 174 | } | ||||||||||||||||||||
| 175 | |||||||||||||||||||||
| 176 | 13 | ▶ | sub conferences { | ||||||||||||||||||
|
Subroutine
conferences: called CC=2 SCAR=6.9
| |||||||||||||||||||||
| 177 | 13 | my ($self, $sid) = @_; | |||||||||||||||||||
| 178 | 13 | require Twilio::Rest::Api::V2010::Account::Conference; | |||||||||||||||||||
| 179 | my $list = Twilio::Rest::Api::V2010::Account::ConferenceList->new($self->{version}, | ||||||||||||||||||||
| 180 | 13 | $self->{solution}{sid}); | |||||||||||||||||||
| 181 | 13 | ▶ | return defined $sid ? $list->get_context($sid) : $list; | ||||||||||||||||||
|
Branch: 1 branch
| |||||||||||||||||||||
| 182 | } | ||||||||||||||||||||
| 183 | |||||||||||||||||||||
| 184 | 4 | ▶ | sub connect_apps { | ||||||||||||||||||
|
Subroutine
connect_apps: called CC=2 SCAR=6.9
| |||||||||||||||||||||
| 185 | 4 | my ($self, $sid) = @_; | |||||||||||||||||||
| 186 | 4 | require Twilio::Rest::Api::V2010::Account::ConnectApp; | |||||||||||||||||||
| 187 | my $list = Twilio::Rest::Api::V2010::Account::ConnectAppList->new($self->{version}, | ||||||||||||||||||||
| 188 | 4 | $self->{solution}{sid}); | |||||||||||||||||||
| 189 | 4 | ▶ | return defined $sid ? $list->get_context($sid) : $list; | ||||||||||||||||||
|
Branch: 1 branch
| |||||||||||||||||||||
| 190 | } | ||||||||||||||||||||
| 191 | |||||||||||||||||||||
| 192 | 19 | ▶ | sub incoming_phone_numbers { | ||||||||||||||||||
|
Subroutine
incoming_phone_numbers: called CC=2 SCAR=6.9
| |||||||||||||||||||||
| 193 | 19 | my ($self, $sid) = @_; | |||||||||||||||||||
| 194 | 19 | require Twilio::Rest::Api::V2010::Account::IncomingPhoneNumber; | |||||||||||||||||||
| 195 | my $list = Twilio::Rest::Api::V2010::Account::IncomingPhoneNumberList->new($self->{version}, | ||||||||||||||||||||
| 196 | 19 | $self->{solution}{sid}); | |||||||||||||||||||
| 197 | 19 | ▶ | return defined $sid ? $list->get_context($sid) : $list; | ||||||||||||||||||
|
Branch: 1 branch
| |||||||||||||||||||||
| 198 | } | ||||||||||||||||||||
| 199 | |||||||||||||||||||||
| 200 | 6 | ▶ | sub keys { | ||||||||||||||||||
|
Subroutine
keys: called CC=2 SCAR=6.9
| |||||||||||||||||||||
| 201 | 6 | my ($self, $sid) = @_; | |||||||||||||||||||
| 202 | 6 | require Twilio::Rest::Api::V2010::Account::Key; | |||||||||||||||||||
| 203 | my $list = | ||||||||||||||||||||
| 204 | 6 | Twilio::Rest::Api::V2010::Account::KeyList->new($self->{version}, $self->{solution}{sid}); | |||||||||||||||||||
| 205 | 6 | ▶ | return defined $sid ? $list->get_context($sid) : $list; | ||||||||||||||||||
|
Branch: 1 branch
| |||||||||||||||||||||
| 206 | } | ||||||||||||||||||||
| 207 | |||||||||||||||||||||
| 208 | 86 | ▶ | sub messages { | ||||||||||||||||||
|
Subroutine
messages: called CC=2 SCAR=6.9
| |||||||||||||||||||||
| 209 | 86 | my ($self, $sid) = @_; | |||||||||||||||||||
| 210 | 86 | require Twilio::Rest::Api::V2010::Account::Message; | |||||||||||||||||||
| 211 | my $list = | ||||||||||||||||||||
| 212 | 86 | Twilio::Rest::Api::V2010::Account::MessageList->new($self->{version}, $self->{solution}{sid}); | |||||||||||||||||||
| 213 | 86 | ▶ | return defined $sid ? $list->get_context($sid) : $list; | ||||||||||||||||||
|
Branch: 1 branch
| |||||||||||||||||||||
| 214 | } | ||||||||||||||||||||
| 215 | |||||||||||||||||||||
| 216 | 3 | ▶ | sub new_keys { | ||||||||||||||||||
|
Subroutine
new_keys: called CC=1 SCAR=0.0
| |||||||||||||||||||||
| 217 | 3 | my ($self) = @_; | |||||||||||||||||||
| 218 | 3 | require Twilio::Rest::Api::V2010::Account::NewKey; | |||||||||||||||||||
| 219 | return Twilio::Rest::Api::V2010::Account::NewKeyList->new($self->{version}, | ||||||||||||||||||||
| 220 | 3 | $self->{solution}{sid}); | |||||||||||||||||||
| 221 | } | ||||||||||||||||||||
| 222 | |||||||||||||||||||||
| 223 | 1 | ▶ | sub new_signing_keys { | ||||||||||||||||||
|
Subroutine
new_signing_keys: called CC=1 SCAR=0.0
| |||||||||||||||||||||
| 224 | 1 | my ($self) = @_; | |||||||||||||||||||
| 225 | 1 | require Twilio::Rest::Api::V2010::Account::NewSigningKey; | |||||||||||||||||||
| 226 | return Twilio::Rest::Api::V2010::Account::NewSigningKeyList->new($self->{version}, | ||||||||||||||||||||
| 227 | 1 | $self->{solution}{sid}); | |||||||||||||||||||
| 228 | } | ||||||||||||||||||||
| 229 | |||||||||||||||||||||
| 230 | 4 | ▶ | sub notifications { | ||||||||||||||||||
|
Subroutine
notifications: called CC=2 SCAR=6.9
| |||||||||||||||||||||
| 231 | 4 | my ($self, $sid) = @_; | |||||||||||||||||||
| 232 | 4 | require Twilio::Rest::Api::V2010::Account::Notification; | |||||||||||||||||||
| 233 | my $list = Twilio::Rest::Api::V2010::Account::NotificationList->new($self->{version}, | ||||||||||||||||||||
| 234 | 4 | $self->{solution}{sid}); | |||||||||||||||||||
| 235 | 4 | ▶ | return defined $sid ? $list->get_context($sid) : $list; | ||||||||||||||||||
|
Branch: 1 branch
| |||||||||||||||||||||
| 236 | } | ||||||||||||||||||||
| 237 | |||||||||||||||||||||
| 238 | 4 | ▶ | sub outgoing_caller_ids { | ||||||||||||||||||
|
Subroutine
outgoing_caller_ids: called CC=2 SCAR=6.9
| |||||||||||||||||||||
| 239 | 4 | my ($self, $sid) = @_; | |||||||||||||||||||
| 240 | 4 | require Twilio::Rest::Api::V2010::Account::OutgoingCallerId; | |||||||||||||||||||
| 241 | my $list = Twilio::Rest::Api::V2010::Account::OutgoingCallerIdList->new($self->{version}, | ||||||||||||||||||||
| 242 | 4 | $self->{solution}{sid}); | |||||||||||||||||||
| 243 | 4 | ▶ | return defined $sid ? $list->get_context($sid) : $list; | ||||||||||||||||||
|
Branch: 1 branch
| |||||||||||||||||||||
| 244 | } | ||||||||||||||||||||
| 245 | |||||||||||||||||||||
| 246 | 8 | ▶ | sub queues { | ||||||||||||||||||
|
Subroutine
queues: called CC=2 SCAR=6.9
| |||||||||||||||||||||
| 247 | 8 | my ($self, $sid) = @_; | |||||||||||||||||||
| 248 | 8 | require Twilio::Rest::Api::V2010::Account::Queue; | |||||||||||||||||||
| 249 | my $list = | ||||||||||||||||||||
| 250 | 8 | Twilio::Rest::Api::V2010::Account::QueueList->new($self->{version}, $self->{solution}{sid}); | |||||||||||||||||||
| 251 | 8 | ▶ | return defined $sid ? $list->get_context($sid) : $list; | ||||||||||||||||||
|
Branch: 1 branch
| |||||||||||||||||||||
| 252 | } | ||||||||||||||||||||
| 253 | |||||||||||||||||||||
| 254 | 18 | ▶ | sub recordings { | ||||||||||||||||||
|
Subroutine
recordings: called CC=2 SCAR=6.9
| |||||||||||||||||||||
| 255 | 18 | my ($self, $sid) = @_; | |||||||||||||||||||
| 256 | 18 | require Twilio::Rest::Api::V2010::Account::Recording; | |||||||||||||||||||
| 257 | my $list = | ||||||||||||||||||||
| 258 | 18 | Twilio::Rest::Api::V2010::Account::RecordingList->new($self->{version}, $self->{solution}{sid}); | |||||||||||||||||||
| 259 | 18 | ▶ | return defined $sid ? $list->get_context($sid) : $list; | ||||||||||||||||||
|
Branch: 1 branch
| |||||||||||||||||||||
| 260 | } | ||||||||||||||||||||
| 261 | |||||||||||||||||||||
| 262 | 3 | ▶ | sub short_codes { | ||||||||||||||||||
|
Subroutine
short_codes: called CC=2 SCAR=6.9
| |||||||||||||||||||||
| 263 | 3 | my ($self, $sid) = @_; | |||||||||||||||||||
| 264 | 3 | require Twilio::Rest::Api::V2010::Account::ShortCode; | |||||||||||||||||||
| 265 | my $list = | ||||||||||||||||||||
| 266 | 3 | Twilio::Rest::Api::V2010::Account::ShortCodeList->new($self->{version}, $self->{solution}{sid}); | |||||||||||||||||||
| 267 | 3 | ▶ | return defined $sid ? $list->get_context($sid) : $list; | ||||||||||||||||||
|
Branch: 1 branch
| |||||||||||||||||||||
| 268 | } | ||||||||||||||||||||
| 269 | |||||||||||||||||||||
| 270 | 4 | ▶ | sub signing_keys { | ||||||||||||||||||
|
Subroutine
signing_keys: called CC=2 SCAR=6.9
| |||||||||||||||||||||
| 271 | 4 | my ($self, $sid) = @_; | |||||||||||||||||||
| 272 | 4 | require Twilio::Rest::Api::V2010::Account::SigningKey; | |||||||||||||||||||
| 273 | my $list = Twilio::Rest::Api::V2010::Account::SigningKeyList->new($self->{version}, | ||||||||||||||||||||
| 274 | 4 | $self->{solution}{sid}); | |||||||||||||||||||
| 275 | 4 | ▶ | return defined $sid ? $list->get_context($sid) : $list; | ||||||||||||||||||
|
Branch: 1 branch
| |||||||||||||||||||||
| 276 | } | ||||||||||||||||||||
| 277 | |||||||||||||||||||||
| 278 | 46 | ▶ | sub sip { | ||||||||||||||||||
|
Subroutine
sip: called CC=1 SCAR=0.0
| |||||||||||||||||||||
| 279 | 46 | my ($self) = @_; | |||||||||||||||||||
| 280 | 46 | require Twilio::Rest::Api::V2010::Account::Sip; | |||||||||||||||||||
| 281 | 46 | return Twilio::Rest::Api::V2010::Account::SipList->new($self->{version}, $self->{solution}{sid}); | |||||||||||||||||||
| 282 | } | ||||||||||||||||||||
| 283 | |||||||||||||||||||||
| 284 | 1 | ▶ | sub tokens { | ||||||||||||||||||
|
Subroutine
tokens: called CC=1 SCAR=0.0
| |||||||||||||||||||||
| 285 | 1 | my ($self) = @_; | |||||||||||||||||||
| 286 | 1 | require Twilio::Rest::Api::V2010::Account::Token; | |||||||||||||||||||
| 287 | return Twilio::Rest::Api::V2010::Account::TokenList->new($self->{version}, | ||||||||||||||||||||
| 288 | 1 | $self->{solution}{sid}); | |||||||||||||||||||
| 289 | } | ||||||||||||||||||||
| 290 | |||||||||||||||||||||
| 291 | 3 | ▶ | sub transcriptions { | ||||||||||||||||||
|
Subroutine
transcriptions: called CC=2 SCAR=6.9
| |||||||||||||||||||||
| 292 | 3 | my ($self, $sid) = @_; | |||||||||||||||||||
| 293 | 3 | require Twilio::Rest::Api::V2010::Account::Transcription; | |||||||||||||||||||
| 294 | my $list = Twilio::Rest::Api::V2010::Account::TranscriptionList->new($self->{version}, | ||||||||||||||||||||
| 295 | 3 | $self->{solution}{sid}); | |||||||||||||||||||
| 296 | 3 | ▶ | return defined $sid ? $list->get_context($sid) : $list; | ||||||||||||||||||
|
Branch: 1 branch
| |||||||||||||||||||||
| 297 | } | ||||||||||||||||||||
| 298 | |||||||||||||||||||||
| 299 | 18 | ▶ | sub usage { | ||||||||||||||||||
|
Subroutine
usage: called CC=1 SCAR=0.0
| |||||||||||||||||||||
| 300 | 18 | my ($self) = @_; | |||||||||||||||||||
| 301 | 18 | require Twilio::Rest::Api::V2010::Account::Usage; | |||||||||||||||||||
| 302 | return Twilio::Rest::Api::V2010::Account::UsageList->new($self->{version}, | ||||||||||||||||||||
| 303 | 18 | $self->{solution}{sid}); | |||||||||||||||||||
| 304 | } | ||||||||||||||||||||
| 305 | |||||||||||||||||||||
| 306 | 2 | ▶ | sub validation_requests { | ||||||||||||||||||
|
Subroutine
validation_requests: called CC=1 SCAR=0.0
| |||||||||||||||||||||
| 307 | 2 | my ($self) = @_; | |||||||||||||||||||
| 308 | 2 | require Twilio::Rest::Api::V2010::Account::ValidationRequest; | |||||||||||||||||||
| 309 | return Twilio::Rest::Api::V2010::Account::ValidationRequestList->new($self->{version}, | ||||||||||||||||||||
| 310 | 2 | $self->{solution}{sid}); | |||||||||||||||||||
| 311 | } | ||||||||||||||||||||
| 312 | |||||||||||||||||||||
| 313 | package Twilio::Rest::Api::V2010::AccountInstance; | ||||||||||||||||||||
| 314 | |||||||||||||||||||||
| 315 | 12 | ▶ | use parent 'Twilio::InstanceResource'; | ||||||||||||||||||
|
Subroutine
BEGIN: called CC=1 SCAR=0.0
| |||||||||||||||||||||
| 316 | |||||||||||||||||||||
| 317 | 12 | ▶ | use Twilio::Deserialize; | ||||||||||||||||||
|
Subroutine
BEGIN: called CC=1 SCAR=0.0
| |||||||||||||||||||||
| 318 | |||||||||||||||||||||
| 319 | 9 | ▶ | sub new { | ||||||||||||||||||
|
Subroutine
new: called CC=2 SCAR=7.0
| |||||||||||||||||||||
| 320 | 9 | my ($class, $version, $payload, $sid) = @_; | |||||||||||||||||||
| 321 | 9 | my $self = $class->SUPER::new($version, $payload); | |||||||||||||||||||
| 322 | 9 | ▶ | $self->{solution} = { sid => $sid // $self->{properties}{sid} }; | ||||||||||||||||||
|
Condition66%2/3
$sid // $self->{"properties"}{"sid"}
MC/DC0%0/2
$sid // $self->{"properties"}{"sid"}
$sid
$self->{"properties"}{"sid"}
Truth table66%2/3
A // B
A= $sidB= $self->{"properties"}{"sid"}
| |||||||||||||||||||||
| 323 | 9 | return $self; | |||||||||||||||||||
| 324 | } | ||||||||||||||||||||
| 325 | |||||||||||||||||||||
| 326 | 0 | ▶ | sub fetch { | ||||||||||||||||||
|
Subroutine
fetch: not called CC=1 SCAR=6.9
| |||||||||||||||||||||
| 327 | 0 | my ($self, @arguments) = @_; | |||||||||||||||||||
| 328 | 0 | return $self->_context->fetch(@arguments); | |||||||||||||||||||
| 329 | } | ||||||||||||||||||||
| 330 | |||||||||||||||||||||
| 331 | 0 | ▶ | sub update { | ||||||||||||||||||
|
Subroutine
update: not called CC=1 SCAR=6.9
| |||||||||||||||||||||
| 332 | 0 | my ($self, @arguments) = @_; | |||||||||||||||||||
| 333 | 0 | return $self->_context->update(@arguments); | |||||||||||||||||||
| 334 | } | ||||||||||||||||||||
| 335 | |||||||||||||||||||||
| 336 | 0 | ▶ | sub addresses { | ||||||||||||||||||
|
Subroutine
addresses: not called CC=1 SCAR=6.9
| |||||||||||||||||||||
| 337 | 0 | my ($self, @arguments) = @_; | |||||||||||||||||||
| 338 | 0 | return $self->_context->addresses(@arguments); | |||||||||||||||||||
| 339 | } | ||||||||||||||||||||
| 340 | |||||||||||||||||||||
| 341 | 0 | ▶ | sub applications { | ||||||||||||||||||
|
Subroutine
applications: not called CC=1 SCAR=6.9
| |||||||||||||||||||||
| 342 | 0 | my ($self, @arguments) = @_; | |||||||||||||||||||
| 343 | 0 | return $self->_context->applications(@arguments); | |||||||||||||||||||
| 344 | } | ||||||||||||||||||||
| 345 | |||||||||||||||||||||
| 346 | 0 | ▶ | sub authorized_connect_apps { | ||||||||||||||||||
|
Subroutine
authorized_connect_apps: not called CC=1 SCAR=6.9
| |||||||||||||||||||||
| 347 | 0 | my ($self, @arguments) = @_; | |||||||||||||||||||
| 348 | 0 | return $self->_context->authorized_connect_apps(@arguments); | |||||||||||||||||||
| 349 | } | ||||||||||||||||||||
| 350 | |||||||||||||||||||||
| 351 | 0 | ▶ | sub available_phone_numbers { | ||||||||||||||||||
|
Subroutine
available_phone_numbers: not called CC=1 SCAR=6.9
| |||||||||||||||||||||
| 352 | 0 | my ($self, @arguments) = @_; | |||||||||||||||||||
| 353 | 0 | return $self->_context->available_phone_numbers(@arguments); | |||||||||||||||||||
| 354 | } | ||||||||||||||||||||
| 355 | |||||||||||||||||||||
| 356 | 0 | ▶ | sub balance { | ||||||||||||||||||
|
Subroutine
balance: not called CC=1 SCAR=6.9
| |||||||||||||||||||||
| 357 | 0 | my ($self, @arguments) = @_; | |||||||||||||||||||
| 358 | 0 | return $self->_context->balance(@arguments); | |||||||||||||||||||
| 359 | } | ||||||||||||||||||||
| 360 | |||||||||||||||||||||
| 361 | 0 | ▶ | sub calls { | ||||||||||||||||||
|
Subroutine
calls: not called CC=1 SCAR=6.9
| |||||||||||||||||||||
| 362 | 0 | my ($self, @arguments) = @_; | |||||||||||||||||||
| 363 | 0 | return $self->_context->calls(@arguments); | |||||||||||||||||||
| 364 | } | ||||||||||||||||||||
| 365 | |||||||||||||||||||||
| 366 | 0 | ▶ | sub conferences { | ||||||||||||||||||
|
Subroutine
conferences: not called CC=1 SCAR=6.9
| |||||||||||||||||||||
| 367 | 0 | my ($self, @arguments) = @_; | |||||||||||||||||||
| 368 | 0 | return $self->_context->conferences(@arguments); | |||||||||||||||||||
| 369 | } | ||||||||||||||||||||
| 370 | |||||||||||||||||||||
| 371 | 0 | ▶ | sub connect_apps { | ||||||||||||||||||
|
Subroutine
connect_apps: not called CC=1 SCAR=6.9
| |||||||||||||||||||||
| 372 | 0 | my ($self, @arguments) = @_; | |||||||||||||||||||
| 373 | 0 | return $self->_context->connect_apps(@arguments); | |||||||||||||||||||
| 374 | } | ||||||||||||||||||||
| 375 | |||||||||||||||||||||
| 376 | 0 | ▶ | sub incoming_phone_numbers { | ||||||||||||||||||
|
Subroutine
incoming_phone_numbers: not called CC=1 SCAR=6.9
| |||||||||||||||||||||
| 377 | 0 | my ($self, @arguments) = @_; | |||||||||||||||||||
| 378 | 0 | return $self->_context->incoming_phone_numbers(@arguments); | |||||||||||||||||||
| 379 | } | ||||||||||||||||||||
| 380 | |||||||||||||||||||||
| 381 | 0 | ▶ | sub keys { | ||||||||||||||||||
|
Subroutine
keys: not called CC=1 SCAR=6.9
| |||||||||||||||||||||
| 382 | 0 | my ($self, @arguments) = @_; | |||||||||||||||||||
| 383 | 0 | return $self->_context->keys(@arguments); | |||||||||||||||||||
| 384 | } | ||||||||||||||||||||
| 385 | |||||||||||||||||||||
| 386 | 1 | ▶ | sub messages { | ||||||||||||||||||
|
Subroutine
messages: called CC=1 SCAR=0.0
| |||||||||||||||||||||
| 387 | 1 | my ($self, @arguments) = @_; | |||||||||||||||||||
| 388 | 1 | return $self->_context->messages(@arguments); | |||||||||||||||||||
| 389 | } | ||||||||||||||||||||
| 390 | |||||||||||||||||||||
| 391 | 0 | ▶ | sub new_keys { | ||||||||||||||||||
|
Subroutine
new_keys: not called CC=1 SCAR=6.9
| |||||||||||||||||||||
| 392 | 0 | my ($self, @arguments) = @_; | |||||||||||||||||||
| 393 | 0 | return $self->_context->new_keys(@arguments); | |||||||||||||||||||
| 394 | } | ||||||||||||||||||||
| 395 | |||||||||||||||||||||
| 396 | 0 | ▶ | sub new_signing_keys { | ||||||||||||||||||
|
Subroutine
new_signing_keys: not called CC=1 SCAR=6.9
| |||||||||||||||||||||
| 397 | 0 | my ($self, @arguments) = @_; | |||||||||||||||||||
| 398 | 0 | return $self->_context->new_signing_keys(@arguments); | |||||||||||||||||||
| 399 | } | ||||||||||||||||||||
| 400 | |||||||||||||||||||||
| 401 | 0 | ▶ | sub notifications { | ||||||||||||||||||
|
Subroutine
notifications: not called CC=1 SCAR=6.9
| |||||||||||||||||||||
| 402 | 0 | my ($self, @arguments) = @_; | |||||||||||||||||||
| 403 | 0 | return $self->_context->notifications(@arguments); | |||||||||||||||||||
| 404 | } | ||||||||||||||||||||
| 405 | |||||||||||||||||||||
| 406 | 0 | ▶ | sub outgoing_caller_ids { | ||||||||||||||||||
|
Subroutine
outgoing_caller_ids: not called CC=1 SCAR=6.9
| |||||||||||||||||||||
| 407 | 0 | my ($self, @arguments) = @_; | |||||||||||||||||||
| 408 | 0 | return $self->_context->outgoing_caller_ids(@arguments); | |||||||||||||||||||
| 409 | } | ||||||||||||||||||||
| 410 | |||||||||||||||||||||
| 411 | 0 | ▶ | sub queues { | ||||||||||||||||||
|
Subroutine
queues: not called CC=1 SCAR=6.9
| |||||||||||||||||||||
| 412 | 0 | my ($self, @arguments) = @_; | |||||||||||||||||||
| 413 | 0 | return $self->_context->queues(@arguments); | |||||||||||||||||||
| 414 | } | ||||||||||||||||||||
| 415 | |||||||||||||||||||||
| 416 | 0 | ▶ | sub recordings { | ||||||||||||||||||
|
Subroutine
recordings: not called CC=1 SCAR=6.9
| |||||||||||||||||||||
| 417 | 0 | my ($self, @arguments) = @_; | |||||||||||||||||||
| 418 | 0 | return $self->_context->recordings(@arguments); | |||||||||||||||||||
| 419 | } | ||||||||||||||||||||
| 420 | |||||||||||||||||||||
| 421 | 0 | ▶ | sub short_codes { | ||||||||||||||||||
|
Subroutine
short_codes: not called CC=1 SCAR=6.9
| |||||||||||||||||||||
| 422 | 0 | my ($self, @arguments) = @_; | |||||||||||||||||||
| 423 | 0 | return $self->_context->short_codes(@arguments); | |||||||||||||||||||
| 424 | } | ||||||||||||||||||||
| 425 | |||||||||||||||||||||
| 426 | 0 | ▶ | sub signing_keys { | ||||||||||||||||||
|
Subroutine
signing_keys: not called CC=1 SCAR=6.9
| |||||||||||||||||||||
| 427 | 0 | my ($self, @arguments) = @_; | |||||||||||||||||||
| 428 | 0 | return $self->_context->signing_keys(@arguments); | |||||||||||||||||||
| 429 | } | ||||||||||||||||||||
| 430 | |||||||||||||||||||||
| 431 | 0 | ▶ | sub sip { | ||||||||||||||||||
|
Subroutine
sip: not called CC=1 SCAR=6.9
| |||||||||||||||||||||
| 432 | 0 | my ($self, @arguments) = @_; | |||||||||||||||||||
| 433 | 0 | return $self->_context->sip(@arguments); | |||||||||||||||||||
| 434 | } | ||||||||||||||||||||
| 435 | |||||||||||||||||||||
| 436 | 0 | ▶ | sub tokens { | ||||||||||||||||||
|
Subroutine
tokens: not called CC=1 SCAR=6.9
| |||||||||||||||||||||
| 437 | 0 | my ($self, @arguments) = @_; | |||||||||||||||||||
| 438 | 0 | return $self->_context->tokens(@arguments); | |||||||||||||||||||
| 439 | } | ||||||||||||||||||||
| 440 | |||||||||||||||||||||
| 441 | 0 | ▶ | sub transcriptions { | ||||||||||||||||||
|
Subroutine
transcriptions: not called CC=1 SCAR=6.9
| |||||||||||||||||||||
| 442 | 0 | my ($self, @arguments) = @_; | |||||||||||||||||||
| 443 | 0 | return $self->_context->transcriptions(@arguments); | |||||||||||||||||||
| 444 | } | ||||||||||||||||||||
| 445 | |||||||||||||||||||||
| 446 | 0 | ▶ | sub usage { | ||||||||||||||||||
|
Subroutine
usage: not called CC=1 SCAR=6.9
| |||||||||||||||||||||
| 447 | 0 | my ($self, @arguments) = @_; | |||||||||||||||||||
| 448 | 0 | return $self->_context->usage(@arguments); | |||||||||||||||||||
| 449 | } | ||||||||||||||||||||
| 450 | |||||||||||||||||||||
| 451 | 0 | ▶ | sub validation_requests { | ||||||||||||||||||
|
Subroutine
validation_requests: not called CC=1 SCAR=6.9
| |||||||||||||||||||||
| 452 | 0 | my ($self, @arguments) = @_; | |||||||||||||||||||
| 453 | 0 | return $self->_context->validation_requests(@arguments); | |||||||||||||||||||
| 454 | } | ||||||||||||||||||||
| 455 | |||||||||||||||||||||
| 456 | 1 | ▶ | sub _context { | ||||||||||||||||||
|
Subroutine
_context: called CC=1 SCAR=0.0
| |||||||||||||||||||||
| 457 | 1 | my ($self) = @_; | |||||||||||||||||||
| 458 | 1 | return Twilio::Rest::Api::V2010::AccountContext->new($self->{version}, $self->{solution}{sid}); | |||||||||||||||||||
| 459 | } | ||||||||||||||||||||
| 460 | |||||||||||||||||||||
| 461 | 4 | ▶ | sub auth_token { return $_[0]{properties}{auth_token} } | ||||||||||||||||||
|
Subroutine
auth_token: called CC=1 SCAR=0.0
| |||||||||||||||||||||
| 462 | 4 | ▶ | sub date_created { return Twilio::Deserialize::date_time($_[0]{properties}{date_created}) } | ||||||||||||||||||
|
Subroutine
date_created: called CC=1 SCAR=0.0
| |||||||||||||||||||||
| 463 | 4 | ▶ | sub date_updated { return Twilio::Deserialize::date_time($_[0]{properties}{date_updated}) } | ||||||||||||||||||
|
Subroutine
date_updated: called CC=1 SCAR=0.0
| |||||||||||||||||||||
| 464 | 6 | ▶ | sub friendly_name { return $_[0]{properties}{friendly_name} } | ||||||||||||||||||
|
Subroutine
friendly_name: called CC=1 SCAR=0.0
| |||||||||||||||||||||
| 465 | 4 | ▶ | sub owner_account_sid { return $_[0]{properties}{owner_account_sid} } | ||||||||||||||||||
|
Subroutine
owner_account_sid: called CC=1 SCAR=0.0
| |||||||||||||||||||||
| 466 | 7 | ▶ | sub sid { return $_[0]{properties}{sid} } | ||||||||||||||||||
|
Subroutine
sid: called CC=1 SCAR=0.0
| |||||||||||||||||||||
| 467 | 4 | ▶ | sub status { return $_[0]{properties}{status} } | ||||||||||||||||||
|
Subroutine
status: called CC=1 SCAR=0.0
| |||||||||||||||||||||
| 468 | 4 | ▶ | sub subresource_uris { return $_[0]{properties}{subresource_uris} } | ||||||||||||||||||
|
Subroutine
subresource_uris: called CC=1 SCAR=0.0
| |||||||||||||||||||||
| 469 | 4 | ▶ | sub type { return $_[0]{properties}{type} } | ||||||||||||||||||
|
Subroutine
type: called CC=1 SCAR=0.0
| |||||||||||||||||||||
| 470 | 4 | ▶ | sub uri { return $_[0]{properties}{uri} } | ||||||||||||||||||
|
Subroutine
uri: called CC=1 SCAR=0.0
| |||||||||||||||||||||
| 471 | |||||||||||||||||||||
| 472 | 12 | 1; | |||||||||||||||||||
| 473 | |||||||||||||||||||||
| 474 | __END__ | ||||||||||||||||||||