« Twilio/Rest/Insights/V1/CallSummaries.pm
↑ Summary
Twilio/Rest/Api/V2010/Account/IncomingPhoneNumber/Mobile.pm »
| 1 | # Generated by tools/generate.pl from Twilio's OpenAPI specs. Do not edit this file. | ||||||||||||||||||||
| 2 | package Twilio::Rest::Numbers::V1::PortingPortIn; | ||||||||||||||||||||
| 3 | |||||||||||||||||||||
| 4 | 2 | ▶ | use 5.016; | ||||||||||||||||||
|
Subroutine
BEGIN: called CC=1 SCAR=0.0
| |||||||||||||||||||||
| 5 | 2 | ▶ | use warnings; | ||||||||||||||||||
|
Subroutine
BEGIN: called CC=1 SCAR=0.0
| |||||||||||||||||||||
| 6 | |||||||||||||||||||||
| 7 | 2 | our $VERSION = '2.001'; | |||||||||||||||||||
| 8 | |||||||||||||||||||||
| 9 | package Twilio::Rest::Numbers::V1::PortingPortInList; | ||||||||||||||||||||
| 10 | |||||||||||||||||||||
| 11 | 2 | ▶ | use parent 'Twilio::ListResource'; | ||||||||||||||||||
|
Subroutine
BEGIN: called CC=1 SCAR=0.0
| |||||||||||||||||||||
| 12 | |||||||||||||||||||||
| 13 | 2 | ▶ | use Twilio::Serialize; | ||||||||||||||||||
|
Subroutine
BEGIN: called CC=1 SCAR=0.0
| |||||||||||||||||||||
| 14 | |||||||||||||||||||||
| 15 | 3 | ▶ | sub new { | ||||||||||||||||||
|
Subroutine
new: called CC=1 SCAR=0.0
| |||||||||||||||||||||
| 16 | 3 | my ($class, $version) = @_; | |||||||||||||||||||
| 17 | 3 | my $self = $class->SUPER::new($version); | |||||||||||||||||||
| 18 | 3 | $self->{solution} = {}; | |||||||||||||||||||
| 19 | 3 | $self->{uri} = '/Porting/PortIn'; | |||||||||||||||||||
| 20 | 3 | return $self; | |||||||||||||||||||
| 21 | } | ||||||||||||||||||||
| 22 | |||||||||||||||||||||
| 23 | 1 | ▶ | sub create { | ||||||||||||||||||
|
Subroutine
create: called CC=1 SCAR=0.0
| |||||||||||||||||||||
| 24 | 1 | my ($self, $body) = @_; | |||||||||||||||||||
| 25 | |||||||||||||||||||||
| 26 | 1 | my $data = Twilio::Serialize::json_body($body, { 'target_port_in_date' => 'iso8601_date' }); | |||||||||||||||||||
| 27 | |||||||||||||||||||||
| 28 | my $response = $self->{version}->handle_request( | ||||||||||||||||||||
| 29 | 'POST', | ||||||||||||||||||||
| 30 | $self->{uri}, | ||||||||||||||||||||
| 31 | 1 | 'create', | |||||||||||||||||||
| 32 | { | ||||||||||||||||||||
| 33 | data => $data, | ||||||||||||||||||||
| 34 | headers => { 'Content-Type' => 'application/json', } | ||||||||||||||||||||
| 35 | } | ||||||||||||||||||||
| 36 | ); | ||||||||||||||||||||
| 37 | return Twilio::Rest::Numbers::V1::PortingPortInInstance->new($self->{version}, | ||||||||||||||||||||
| 38 | 1 | $response->get_content); | |||||||||||||||||||
| 39 | } | ||||||||||||||||||||
| 40 | |||||||||||||||||||||
| 41 | 2 | ▶ | sub get_context { | ||||||||||||||||||
|
Subroutine
get_context: called CC=1 SCAR=0.0
| |||||||||||||||||||||
| 42 | 2 | my ($self, $port_in_request_sid) = @_; | |||||||||||||||||||
| 43 | return Twilio::Rest::Numbers::V1::PortingPortInContext->new($self->{version}, | ||||||||||||||||||||
| 44 | 2 | $port_in_request_sid); | |||||||||||||||||||
| 45 | } | ||||||||||||||||||||
| 46 | |||||||||||||||||||||
| 47 | package Twilio::Rest::Numbers::V1::PortingPortInContext; | ||||||||||||||||||||
| 48 | |||||||||||||||||||||
| 49 | 2 | ▶ | use parent 'Twilio::InstanceContext'; | ||||||||||||||||||
|
Subroutine
BEGIN: called CC=1 SCAR=0.0
| |||||||||||||||||||||
| 50 | |||||||||||||||||||||
| 51 | 2 | ▶ | use Twilio::Serialize; | ||||||||||||||||||
|
Subroutine
BEGIN: called CC=1 SCAR=0.0
| |||||||||||||||||||||
| 52 | |||||||||||||||||||||
| 53 | 2 | ▶ | sub new { | ||||||||||||||||||
|
Subroutine
new: called CC=1 SCAR=0.0
| |||||||||||||||||||||
| 54 | 2 | my ($class, $version, $port_in_request_sid) = @_; | |||||||||||||||||||
| 55 | 2 | my $self = $class->SUPER::new($version); | |||||||||||||||||||
| 56 | 2 | $self->{solution} = { port_in_request_sid => $port_in_request_sid }; | |||||||||||||||||||
| 57 | 2 | $self->{uri} = join q{}, '/Porting/PortIn/', | |||||||||||||||||||
| 58 | Twilio::Serialize::path_segment($port_in_request_sid); | ||||||||||||||||||||
| 59 | 2 | return $self; | |||||||||||||||||||
| 60 | } | ||||||||||||||||||||
| 61 | |||||||||||||||||||||
| 62 | 1 | ▶ | sub delete { | ||||||||||||||||||
|
Subroutine
delete: called CC=1 SCAR=0.0
| |||||||||||||||||||||
| 63 | 1 | my ($self) = @_; | |||||||||||||||||||
| 64 | 1 | $self->{version}->handle_request('DELETE', $self->{uri}, 'delete'); | |||||||||||||||||||
| 65 | 1 | return 1; | |||||||||||||||||||
| 66 | } | ||||||||||||||||||||
| 67 | |||||||||||||||||||||
| 68 | 1 | ▶ | sub fetch { | ||||||||||||||||||
|
Subroutine
fetch: called CC=1 SCAR=0.0
| |||||||||||||||||||||
| 69 | 1 | my ($self) = @_; | |||||||||||||||||||
| 70 | |||||||||||||||||||||
| 71 | 1 | my $response = $self->{version}->handle_request('GET', $self->{uri}, 'fetch'); | |||||||||||||||||||
| 72 | 1 | return $self->_build_instance($response); | |||||||||||||||||||
| 73 | } | ||||||||||||||||||||
| 74 | |||||||||||||||||||||
| 75 | 1 | ▶ | sub _build_instance { | ||||||||||||||||||
|
Subroutine
_build_instance: called CC=1 SCAR=0.0
| |||||||||||||||||||||
| 76 | 1 | my ($self, $response) = @_; | |||||||||||||||||||
| 77 | return Twilio::Rest::Numbers::V1::PortingPortInInstance->new($self->{version}, | ||||||||||||||||||||
| 78 | 1 | $response->get_content, $self->{solution}{port_in_request_sid}); | |||||||||||||||||||
| 79 | } | ||||||||||||||||||||
| 80 | |||||||||||||||||||||
| 81 | package Twilio::Rest::Numbers::V1::PortingPortInInstance; | ||||||||||||||||||||
| 82 | |||||||||||||||||||||
| 83 | 2 | ▶ | use parent 'Twilio::InstanceResource'; | ||||||||||||||||||
|
Subroutine
BEGIN: called CC=1 SCAR=0.0
| |||||||||||||||||||||
| 84 | |||||||||||||||||||||
| 85 | 2 | ▶ | use Twilio::Deserialize; | ||||||||||||||||||
|
Subroutine
BEGIN: called CC=1 SCAR=0.0
| |||||||||||||||||||||
| 86 | |||||||||||||||||||||
| 87 | 2 | ▶ | sub new { | ||||||||||||||||||
|
Subroutine
new: called CC=2 SCAR=7.0
| |||||||||||||||||||||
| 88 | 2 | my ($class, $version, $payload, $port_in_request_sid) = @_; | |||||||||||||||||||
| 89 | 2 | my $self = $class->SUPER::new($version, $payload); | |||||||||||||||||||
| 90 | $self->{solution} = | ||||||||||||||||||||
| 91 | 2 | ▶ | { port_in_request_sid => $port_in_request_sid // $self->{properties}{port_in_request_sid} }; | ||||||||||||||||||
|
Condition66%2/3
$port_in_request_sid // $self->{"properties"}{"port_in_request_sid"}
MC/DC0%0/2
$port_in_request_sid // $self->{"properties"}{"port_in_request_sid"}
$port_in_request_sid
$self->{"properties"}{"port_in_request_sid"}
Truth table66%2/3
A // B
A= $port_in_request_sidB= $self->{"properties"}{"port_in_request_sid"}
| |||||||||||||||||||||
| 92 | 2 | return $self; | |||||||||||||||||||
| 93 | } | ||||||||||||||||||||
| 94 | |||||||||||||||||||||
| 95 | 0 | ▶ | sub delete { | ||||||||||||||||||
|
Subroutine
delete: not called CC=1 SCAR=6.9
| |||||||||||||||||||||
| 96 | 0 | my ($self, @arguments) = @_; | |||||||||||||||||||
| 97 | 0 | return $self->_context->delete(@arguments); | |||||||||||||||||||
| 98 | } | ||||||||||||||||||||
| 99 | |||||||||||||||||||||
| 100 | 0 | ▶ | sub fetch { | ||||||||||||||||||
|
Subroutine
fetch: not called CC=1 SCAR=6.9
| |||||||||||||||||||||
| 101 | 0 | my ($self, @arguments) = @_; | |||||||||||||||||||
| 102 | 0 | return $self->_context->fetch(@arguments); | |||||||||||||||||||
| 103 | } | ||||||||||||||||||||
| 104 | |||||||||||||||||||||
| 105 | 0 | ▶ | sub _context { | ||||||||||||||||||
|
Subroutine
_context: not called CC=1 SCAR=6.9
| |||||||||||||||||||||
| 106 | 0 | my ($self) = @_; | |||||||||||||||||||
| 107 | return Twilio::Rest::Numbers::V1::PortingPortInContext->new($self->{version}, | ||||||||||||||||||||
| 108 | 0 | $self->{solution}{port_in_request_sid}); | |||||||||||||||||||
| 109 | } | ||||||||||||||||||||
| 110 | |||||||||||||||||||||
| 111 | 2 | ▶ | sub account_sid { return $_[0]{properties}{account_sid} } | ||||||||||||||||||
|
Subroutine
account_sid: called CC=1 SCAR=0.0
| |||||||||||||||||||||
| 112 | 2 | ▶ | sub auto_cancel_approval_numbers { return $_[0]{properties}{auto_cancel_approval_numbers} } | ||||||||||||||||||
|
Subroutine
auto_cancel_approval_numbers: called CC=1 SCAR=0.0
| |||||||||||||||||||||
| 113 | 2 | ▶ | sub bundle_sid { return $_[0]{properties}{bundle_sid} } | ||||||||||||||||||
|
Subroutine
bundle_sid: called CC=1 SCAR=0.0
| |||||||||||||||||||||
| 114 | 2 | ▶ | sub date_created { return Twilio::Deserialize::date_time($_[0]{properties}{date_created}) } | ||||||||||||||||||
|
Subroutine
date_created: called CC=1 SCAR=0.0
| |||||||||||||||||||||
| 115 | 2 | ▶ | sub documents { return $_[0]{properties}{documents} } | ||||||||||||||||||
|
Subroutine
documents: called CC=1 SCAR=0.0
| |||||||||||||||||||||
| 116 | 2 | ▶ | sub losing_carrier_information { return $_[0]{properties}{losing_carrier_information} } | ||||||||||||||||||
|
Subroutine
losing_carrier_information: called CC=1 SCAR=0.0
| |||||||||||||||||||||
| 117 | 2 | ▶ | sub notification_emails { return $_[0]{properties}{notification_emails} } | ||||||||||||||||||
|
Subroutine
notification_emails: called CC=1 SCAR=0.0
| |||||||||||||||||||||
| 118 | 2 | ▶ | sub order_cancellation_reason { return $_[0]{properties}{order_cancellation_reason} } | ||||||||||||||||||
|
Subroutine
order_cancellation_reason: called CC=1 SCAR=0.0
| |||||||||||||||||||||
| 119 | 2 | ▶ | sub phone_numbers { return $_[0]{properties}{phone_numbers} } | ||||||||||||||||||
|
Subroutine
phone_numbers: called CC=1 SCAR=0.0
| |||||||||||||||||||||
| 120 | 2 | ▶ | sub port_in_request_sid { return $_[0]{properties}{port_in_request_sid} } | ||||||||||||||||||
|
Subroutine
port_in_request_sid: called CC=1 SCAR=0.0
| |||||||||||||||||||||
| 121 | 2 | ▶ | sub port_in_request_status { return $_[0]{properties}{port_in_request_status} } | ||||||||||||||||||
|
Subroutine
port_in_request_status: called CC=1 SCAR=0.0
| |||||||||||||||||||||
| 122 | 2 | ▶ | sub portability_advance_carrier { return $_[0]{properties}{portability_advance_carrier} } | ||||||||||||||||||
|
Subroutine
portability_advance_carrier: called CC=1 SCAR=0.0
| |||||||||||||||||||||
| 123 | 2 | ▶ | sub signature_request_url { return $_[0]{properties}{signature_request_url} } | ||||||||||||||||||
|
Subroutine
signature_request_url: called CC=1 SCAR=0.0
| |||||||||||||||||||||
| 124 | 2 | ▶ | sub support_ticket_id { return $_[0]{properties}{support_ticket_id} } | ||||||||||||||||||
|
Subroutine
support_ticket_id: called CC=1 SCAR=0.0
| |||||||||||||||||||||
| 125 | |||||||||||||||||||||
| 126 | 2 | ▶ | sub target_port_in_date { | ||||||||||||||||||
|
Subroutine
target_port_in_date: called CC=1 SCAR=0.0
| |||||||||||||||||||||
| 127 | 2 | return Twilio::Deserialize::date_time($_[0]{properties}{target_port_in_date}); | |||||||||||||||||||
| 128 | } | ||||||||||||||||||||
| 129 | 2 | ▶ | sub target_port_in_time_range_end { return $_[0]{properties}{target_port_in_time_range_end} } | ||||||||||||||||||
|
Subroutine
target_port_in_time_range_end: called CC=1 SCAR=0.0
| |||||||||||||||||||||
| 130 | 2 | ▶ | sub target_port_in_time_range_start { return $_[0]{properties}{target_port_in_time_range_start} } | ||||||||||||||||||
|
Subroutine
target_port_in_time_range_start: called CC=1 SCAR=0.0
| |||||||||||||||||||||
| 131 | 2 | ▶ | sub url { return $_[0]{properties}{url} } | ||||||||||||||||||
|
Subroutine
url: called CC=1 SCAR=0.0
| |||||||||||||||||||||
| 132 | |||||||||||||||||||||
| 133 | 2 | 1; | |||||||||||||||||||
| 134 | |||||||||||||||||||||
| 135 | __END__ | ||||||||||||||||||||