Methods

Objects

Phone Numbers (DID)

Dynamically buy and assign phone numbers.

Get phone numbers from all around the world!

Summary

    API init

    require 'vendor/autoload.php'; // Composer
    
    $api = new \CALLR\API\Client;
    $api->setAuth(new \CALLR\API\Authentication\LoginPasswordAuth('login', 'password'));
    
    var callr = require('callr');
    var api = new callr.api(callr.loginPasswordAuth('login', 'password'));
    
    require 'callr'
    api = CALLR::Api.new('login', 'password')
    
    import callr
    api = callr.Api("login", "password")
    
            

    List your currently assign DIDs

    Method

    Objects

    • DID
    $result = $api->call('apps.get_dids', [false]);
    
    api.call('apps.get_dids', false).success(function(result) {
        //
    });
    
    result = api.call('apps.get_dids', false)
    result = api.call('apps.get_dids', False)
            

    List available countries with DID availability

    Method

    Objects

    • DID.Country
    $result = $api->call('did/areacode.countries');
    
    api.call('did/areacode.countries').success(function(result) {
        //
    });
    
    result = api.call('did/areacode.countries')
    result = api.call('did/areacode.countries')
            

    Get area codes available for a specific country and DID type

    Method

    Objects

    • DID.AreaCode
    $result = $api->call('did/areacode.get_list', ['US', null]);
    
    api.call('did/areacode.get_list', 'US', null).success(function(result) {
        //
    });
    
    result = api.call('did/areacode.get_list', 'US', nil)
    result = api.call('did/areacode.get_list', 'US', None)
            

    Get DID types available for a specific country

    Method

    Objects

    • DID.Type
    $result = $api->call('did/areacode.types', ['US']);
    
    api.call('did/areacode.types', 'US').success(function(result) {
        //
    });
    
    result = api.call('did/areacode.types', 'US')
    result = api.call('did/areacode.types', 'US')
            

    Buy a DID (after a reserve)

    Method

    Objects

    • DID.Store.BuyStatus
    $result = $api->call('did/store.buy_order', ['OrderToken']);
    
    api.call('did/store.buy_order', 'OrderToken').success(function(result) {
        //
    });
    
    result = api.call('did/store.buy_order', 'OrderToken')
    result = api.call('did/store.buy_order', 'OrderToken')
            

    Cancel your order (after a reserve)

    $result = $api->call('did/store.cancel_order', ['OrderToken']);
    
    api.call('did/store.cancel_order', 'OrderToken').success(function(result) {
        //
    });
    
    result = api.call('did/store.cancel_order', 'OrderToken')
    result = api.call('did/store.cancel_order', 'OrderToken')
            

    Cancel a DID subscription

    $result = $api->call('did/store.cancel_subscription', ['DID ID']);
    
    api.call('did/store.cancel_subscription', 'DID ID').success(function(result) {
        //
    });
    
    result = api.call('did/store.cancel_subscription', 'DID ID')
    result = api.call('did/store.cancel_subscription', 'DID ID')
            

    View your store quota status

    Method

    Objects

    • DID.Store.QuotaStatus
    $result = $api->call('did/store.get_quota_status');
    
    api.call('did/store.get_quota_status').success(function(result) {
        //
    });
    
    result = api.call('did/store.get_quota_status')
    result = api.call('did/store.get_quota_status')
            

    Get a quote without reserving a DID

    Method

    Objects

    • DID.Store.Quote
    $result = $api->call('did/store.get_quote', [0, 'GOLD', 1]);
    
    api.call('did/store.get_quote', 0, 'GOLD', 1).success(function(result) {
        //
    });
    
    result = api.call('did/store.get_quote', 0, 'GOLD', 1)
    result = api.call('did/store.get_quote', 0, 'GOLD', 1)
            

    Reserve a DID

    Method

    Objects

    • DID.Store.Reservation
    $result = $api->call('did/store.reserve', [0, 'GOLD', 1, 'RANDOM']);
    
    api.call('did/store.reserve', 0, 'GOLD', 1, 'RANDOM').success(function(result) {
        //
    });
    
    result = api.call('did/store.reserve', 0, 'GOLD', 1, 'RANDOM')
    result = api.call('did/store.reserve', 0, 'GOLD', 1, 'RANDOM')
            

    View your order

    Method

    Objects

    • DID.Store.Reservation
    $result = $api->call('did/store.view_order', ['OrderToken']);
    
    api.call('did/store.view_order', 'OrderToken').success(function(result) {
        //
    });
    
    result = api.call('did/store.view_order', 'OrderToken')
    result = api.call('did/store.view_order', 'OrderToken')