Skip to contentSkip to navigationSkip to topbar
On this page

Call Forwarding


Lookup's Call Forwarding package allows you to get the unconditional call forwarding status of a mobile phone number.

Call Forwarding Lookups are billed per Lookup, even if data may not be available. Currently, requesting Call Forwarding Lookups for unsupported carriers will return null values, but will not be billed.

To make a Call Forwarding request, add call_forwarding to the optional query parameter Fields when making a standard Lookup request.

1
curl -X GET "https://lookups.twilio.com/v2/PhoneNumbers/{PhoneNumber}?Fields=call_forwarding" \ -u
2
$TWILIO_ACCOUNT_SID:$TWILIO_AUTH_TOKEN

Coverage and Limitations: Only numbers owned by major carriers in the United Kingdom are supported.

Release Stage and Access: Private Beta, please submit this form(link takes you to an external page) to contact sales. Requires carrier approvals.


Response properties

response-properties page anchor

The following additional properties are returned for a Call Forwarding request.

PropertyDescription
CallForwardingStatusA Boolean value indicating unconditional call forwarding is currently enabled for the requested mobile phone number (true) or is not (false).
ErrorCodeThe error code, if any, associated with your request.
Call Forwarding LookupLink to code sample: Call Forwarding Lookup
1
// Download the helper library from https://www.twilio.com/docs/node/install
2
const twilio = require("twilio"); // Or, for ESM: import twilio from "twilio";
3
4
// Find your Account SID and Auth Token at twilio.com/console
5
// and set the environment variables. See http://twil.io/secure
6
const accountSid = process.env.TWILIO_ACCOUNT_SID;
7
const authToken = process.env.TWILIO_AUTH_TOKEN;
8
const client = twilio(accountSid, authToken);
9
10
async function fetchPhoneNumber() {
11
const phoneNumber = await client.lookups.v2
12
.phoneNumbers("+447772000001")
13
.fetch({ fields: "call_forwarding" });
14
15
console.log(phoneNumber.callForwarding);
16
}
17
18
fetchPhoneNumber();

Output

1
{
2
"calling_country_code": "44",
3
"country_code": "GB",
4
"phone_number": "+447772000001",
5
"national_format": "07772 000001",
6
"valid": true,
7
"validation_errors": null,
8
"caller_name": null,
9
"sim_swap": null,
10
"call_forwarding": {
11
"call_forwarding_status": true,
12
"error_code": null
13
},
14
"line_status": null,
15
"line_type_intelligence": null,
16
"identity_match": null,
17
"reassigned_number": null,
18
"sms_pumping_risk": null,
19
"phone_number_quality_score": null,
20
"pre_fill": null,
21
"url": "https://lookups.twilio.com/v2/PhoneNumbers/+447772000001"
22
}