HLR Lookup Documentation

The HLR Lookup Developer Hub

Welcome to the HLR Lookup help pages. Here you'll find all the information you need to get started with our API or batch upload services.
Search the docs for explanations on the results you'll receive and a breakdown of all the possible parameters available.

HLR Lookup request over API

The following pages will help you to get started with using our API to check your numbers.

We recommend you submit all requests to HLR Lookup API over HTTPS.

This is so it allows the traffic to be encrypted and privacy to be ensured.

HLR Lookup's API is based on GET standards, enabling you to use your browser for accessing URLs. Use any HTTP client in any programming language to interact with our API.

Base URL: https://www.hlrlookup.com/api/hlr/
Method: GET

Required Parameters

apikey - Your API key, obtained from account settings.

password - Your Account Password, created when you signed up for an account.

msisdn - The number you wish check.

If you wish to send multiple requests at once you can append multiple MSISDNs separated by a comma
(e.g. "447777123456,4477777123999"). This is limited to a maximum of 80 MSISDNs per request.

Note

Replace $key, $password and $msisdn with your own details

Examples:

function hlr_check($key,$password,$msisdn)
{    
    $curl = curl_init("https://www.hlrlookup.com/api/hlr/?apikey=$key&password=$password&msisdn=$msisdn");
    curl_setopt($curl, CURLOPT_HEADER,0);
    curl_setopt($curl, CURLOPT_POST, 0);
    curl_setopt($curl, CURLOPT_RETURNTRANSFER, 1);
 
    $response = curl_exec($curl);
    curl_close($curl);
    return $response;
}
static size_t hlr_result(char *ptr, size_t size, size_t nmemb, void *userdata)
{
	printf( "HLR Result: %s\n" ptr );
 
	return size*nmemb;
}
 
CURLcode hlr_check( char* szKey, char* szPassword, char* szMSISDN )
{
	char szURL[1024];
	sprintf( szURL, "https://www.hlrlookup.com/api/hlr/?apikey=%s&password=%smsisdn=%s", szKey, szPassword, szMSISDN );
 
	CURL* pCurl = curl_easy_init();
 
	curl_easy_setopt( pCurl, CURLOPT_URL, szURL );
	curl_easy_setopt( pCurl, CURLOPT_FOLLOWLOCATION, 1L );
	curl_easy_setopt( pCurl, CURLOPT_WRITEFUNCTION, &hlr_result );
	curl_easy_setopt( pCurl, CURLOPT_HEADER, 0 );
	curl_easy_setopt( pCurl, CURLOPT_POST, 0L );
 
	CURLcode res = curl_easy_perform( pCurl );
	curl_easy_cleanup(pCurl);
	return res;
}
void hlr_check( string key, string password, string msisdn )
{
	WebRequest webRequest = WebRequest.Create("https://www.hlrlookup.com/api/hlr/?apikey="+key+"&password="+password+"&msisdn="+msisdn);
	webRequest.Method = "GET";
 
	WebResponse webResp = webRequest.GetResponse();
}