Format Verification
This request is used to check the format of a mobile number. It is available for free.
URL
POST https://api.smspartner.fr/v1/lookup
Required Parameters
apiKey
phoneNumbers
Mobile numbers to check. Must be in international format (+336xxxxxxxx). For multiple numbers, separate them with commas. Max: 500 numbers/request.
Optional Parameters
_format
json or xml
Requests
<?php
// Prepare data for POST request
$fields = array(
'apiKey'=> 'YOUR API KEY',
'phoneNumbers'=> '+336xxxxxxxx'
);
$curl = curl_init();
curl_setopt($curl, CURLOPT_URL,'https://api.smspartner.fr/v1/lookup');
curl_setopt($curl, CURLOPT_RETURNTRANSFER, true);
curl_setopt($curl, CURLOPT_TIMEOUT, 10);
curl_setopt($curl, CURLOPT_POST, 1);
curl_setopt($curl, CURLOPT_POSTFIELDS,json_encode($fields));
$result = curl_exec($curl);
curl_close($curl);
// Process your response here
echo $result;
?>Response
Errors
Error Codes
1
API key is required
2
Phone number is required
3
Numbers must be separated by commas
10
Invalid API key
200
Everything went fine!
Example of notification of an HLR request
HLR Error Codes
0
NO_ERROR No error.
1
EC_UNKNOWN_SUBSCRIBER The number does not exist or has not been assigned to any active subscriber in the operator's user database.
5
EC_UNIDENTIFIED_SUBSCRIBER Unidentified subscriber.
6
EC_ABSENT_SUBSCRIBER_SM As there was no response, the subscriber was detected as unavailable. This is often due to the handset being turned off or in a low-signal area.
7
EC_UNKNOWN_EQUIPMENT The mobile device was not recognized by the EIR (Equipment Identity Register) during verification at the MAP protocol level on the operator’s infrastructure.
8
EC_ROAMING_NOT_ALLOWED The subscriber is currently roaming in another country or using another operator's infrastructure – delivery is not guaranteed due to the lack of roaming agreements between many different operators.
9
EC_ILLEGAL_SUBSCRIBER Illegal subscriber.
12
EC_ILLEGAL_EQUIPMENT Illegal equipment.
13
EC_CALL_BARRED The subscriber is set to DND (Do Not Disturb) and does not receive any service traffic to their number.
27
EC_ABSENT_SUBSCRIBER The subscriber is offline. This is often due to the handset being turned off.
255
EC_UNKNOWN_ERROR Unknown error.
Last updated