NAME

Twilio::Rest::Lookups::V2::LookupOverride - The LookupOverride resource

SYNOPSIS

my $client = Twilio::Rest::Client->new($account_sid, $auth_token);

my $lookup_override = $client->lookups->v2->lookup_overrides($phone_number, $field)->create(\%body);
my $lookup_override = $client->lookups->v2->lookup_overrides($phone_number, $field)->fetch;
$client->lookups->v2->lookup_overrides($phone_number, $field)->update(\%body);
$client->lookups->v2->lookup_overrides($phone_number, $field)->delete;

DESCRIPTION

This file holds LookupOverrideList, LookupOverrideContext and LookupOverrideInstance. Methods that make a request throw Twilio::Exceptions::RestException on an error response.

LookupOverrideList

Returned by $client->lookups->v2->lookup_overrides($phone_number). See also Twilio::ListResource.

get_context

my $context = $client->lookups->v2->lookup_overrides($phone_number)->get_context($field);

Returns a LookupOverrideContext, and makes no request.

LookupOverrideContext

Returned by $client->lookups->v2->lookup_overrides($phone_number, $field). It makes no request until one of these methods is called.

create

my $lookup_override = $client->lookups->v2->lookup_overrides($phone_number, $field)->create(\%body);

Create an Override for a specific package and phone number. Returns a LookupOverrideInstance.

%body is sent as JSON. It can be left out. When given, it takes the names Twilio's API documentation uses.

Its fields are:

line_type

The new line type to override the original line type One of mobile, landline, tollFree, fixedVoip, nonFixedVoip, personal, premium, voicemail, sharedCost, uan, pager or unknown.

reason

The reason for the override

fetch

my $lookup_override = $client->lookups->v2->lookup_overrides($phone_number, $field)->fetch;

Retrieve an Override for a specific package and phone number. Returns a LookupOverrideInstance.

update

my $lookup_override = $client->lookups->v2->lookup_overrides($phone_number, $field)->update(\%body);

Update an Override for a specific package and phone number. Returns a LookupOverrideInstance.

%body is sent as JSON. It can be left out. When given, it takes the names Twilio's API documentation uses.

Its fields are:

line_type

The new line type to override the original line type One of mobile, landline, tollFree, fixedVoip, nonFixedVoip, personal, premium, voicemail, sharedCost, uan, pager or unknown.

reason

The reason for the override

delete

$client->lookups->v2->lookup_overrides($phone_number, $field)->delete;

Delete an Override for a specific package and phone number. Returns true.

LookupOverrideInstance

See also Twilio::InstanceResource.

It has create, fetch, update and delete, which work as they do on the context.

Its fields are:

original_line_type

The original line type One of mobile, landline, tollFree, fixedVoip, nonFixedVoip, personal, premium, voicemail, sharedCost, uan, pager or unknown.

overridden_by_account_sid

The Account SID for the user who made the override

overridden_line_type

The new line type after the override One of mobile, landline, tollFree, fixedVoip, nonFixedVoip, personal, premium, voicemail, sharedCost, uan, pager or unknown.

override_reason

The reason for the override

override_timestamp

A Time::Piece object in UTC. See "date_time" in Twilio::Deserialize.

phone_number

The phone number for which the override was created

CONSTRUCTORS

new

Objects here come from the methods above, so there is no need to call new directly.

LICENSE

Copyright (c) 2026 Francisco Zarabozo. Released under the MIT License.