Returns the list of high-risk prefixes for a country.
A prefix is a contiguous number range for a block of E.164 numbers that includes the E.164 assigned country code. For example, a North American Numbering Plan prefix like +1510720
written like +1(510) 720
matches all numbers inclusive from +1(510) 720-0000
to +1(510) 720-9999
.
GET https://voice.twilio.com/v1/DialingPermissions/Countries/{IsoCode}/HighRiskSpecialPrefixes
The ISO 3166-1 country code to identify the country permissions from which high-risk special service number prefixes are fetched
How many resources to return in each list page. The default is 50, and the maximum is 1000.
1
Maximum: 1000
The page token. This is provided by the API.
1// Download the helper library from https://www.twilio.com/docs/node/install2const twilio = require("twilio"); // Or, for ESM: import twilio from "twilio";34// Find your Account SID and Auth Token at twilio.com/console5// and set the environment variables. See http://twil.io/secure6const accountSid = process.env.TWILIO_ACCOUNT_SID;7const authToken = process.env.TWILIO_AUTH_TOKEN;8const client = twilio(accountSid, authToken);910async function listDialingPermissionsHrsPrefixes() {11const highriskSpecialPrefixes = await client.voice.v1.dialingPermissions12.countries("LV")13.highriskSpecialPrefixes.list({ limit: 20 });1415highriskSpecialPrefixes.forEach((h) => console.log(h.prefix));16}1718listDialingPermissionsHrsPrefixes();
1{2"content": [3{4"prefix": "+37181"5},6{7"prefix": "+3719000"8}9],10"meta": {11"first_page_url": "https://voice.twilio.com/v1/DialingPermissions/Countries/LV/HighRiskSpecialPrefixes?PageSize=50&Page=0",12"key": "content",13"next_page_url": null,14"page": 0,15"page_size": 50,16"previous_page_url": null,17"url": "https://voice.twilio.com/v1/DialingPermissions/Countries/LV/HighRiskSpecialPrefixes?PageSize=50&Page=0"18}19}