CallFire has a new API!
We are proud to announce the launch of our API 2.0! Learn more about our streamlined, transactional and broadcast APIs. This version of the API documentation will remain available for reference only. There will be no new development, only bug fixes. We highly recommend upgrading to our newer and more sophisticated documentation.
Supply list of keywords to see if they are available for purchase. If keyword is available for purchase it will be returned in result. If not available then it will not be returned in result.
Once available keywords are found they can be purchase using CreateNumberOrder
Request Parameters
Parameter | Demo Value | Description | Data Type |
---|---|---|---|
SearchAvailableKeywords | object | ||
Keywords | List[string] |
* indicates choice value, bolded parameters are required
Response Parameters
Parameter | Description | Data Type |
---|---|---|
KeywordQueryResult | List of Keywords returned from query | |
TotalResults | Results count | long |
Keyword | Info on Keyword like status and lease info | |
ShortCode | Deprecated, use Number instead | PhoneNumber |
Number | PhoneNumber | |
Keyword | string | |
Status | [PENDING, ACTIVE, RELEASED, UNAVAILABLE] | NumberStatus |
LeaseInfo | Info about Lease | |
LeaseBegin | Date lease began | date |
LeaseEnd | Date lease ends | date |
AutoRenew | Is lease set to renew each month | boolean |
<?php
/**
* You'll need your login/password pair when you create the SOAP client.
* Don't use the fake login/password provided here; it's just for show and won't work.
*/
$wsdl = "http://callfire.com/api/1.1/wsdl/callfire-service-http-soap12.wsdl";
$client = new SoapClient($wsdl, array(
'soap_version' => SOAP_1_2,
'login' => 'YourLoginId',
'password' => 'YourPassword'));
/**
* SearchAvailableKeywords. If number is available for purchase it will be returned
* in result. If unavailable for purchase it will be missing from result.
*/
//
// Searching these 3 keywords see result only contains the 2 keywords available.
//
$request = new stdclass();
$request->Keywords = array("CHOCOLATE", "CALLFIRE", "VANILLA"); // required
$response = $client->SearchAvailableKeywords($request);
print_r($response);
// Sample $response:
// stdClass Object (
// [TotalResults] => 0
// [Keyword] => Array (
// [0] => stdClass Object (
// [ShortCode] => 67076
// [Keyword] => CHOCOLATE
// )
// [1] => stdClass Object (
// [ShortCode] => 67076
// [Keyword] => VANILLA
// )
// )
// )
?>