Skip to content

Latest commit

 

History

History
154 lines (116 loc) · 5.94 KB

HLRApi.md

File metadata and controls

154 lines (116 loc) · 5.94 KB

IO.Swagger.Api.HLRApi

All URIs are relative to https://api.smsfusion.com.au/

Method HTTP request Description
GetHLR GET /hlr/ HLR number lookup
GetHLRCallback GET /hlr-callback/ HLR number lookup with results going to a callback URL

GetHLR

HLRCallback GetHLR (string key, string num, string cc = null)

HLR number lookup

Perform HLR on number

Example

using System;
using System.Diagnostics;
using IO.Swagger.Api;
using IO.Swagger.Client;
using IO.Swagger.Model;

namespace Example
{
    public class GetHLRExample
    {
        public void main()
        {
            
            // Configure API key authorization: api_key
            Configuration.Default.ApiKey.Add("key", "YOUR_API_KEY");
            // Uncomment below to setup prefix (e.g. Bearer) for API key, if needed
            // Configuration.Default.ApiKeyPrefix.Add("key", "Bearer");

            var apiInstance = new HLRApi();
            var key = key_example;  // string | API Key as generated from the <a href='https://www.smsfusion.com.au/admin/api/'>admin panel</a>
            var num = num_example;  // string | A single phone number or <a href='https://www.smsfusion.com.au/help/msisdn/'>MSDISDN</a>
            var cc = cc_example;  // string | 2 character country code <a href='https://en.wikipedia.org/wiki/ISO_3166-2'>ISO 3166-2</a> for formatting local numbers internationally (optional) 

            try
            {
                // HLR number lookup
                HLRCallback result = apiInstance.GetHLR(key, num, cc);
                Debug.WriteLine(result);
            }
            catch (Exception e)
            {
                Debug.Print("Exception when calling HLRApi.GetHLR: " + e.Message );
            }
        }
    }
}

Parameters

Name Type Description Notes
key string API Key as generated from the <a href='https://www.smsfusion.com.au/admin/api/&#39;&gt;admin panel</a>
num string A single phone number or <a href='https://www.smsfusion.com.au/help/msisdn/&#39;&gt;MSDISDN&lt;/a>
cc string 2 character country code <a href='https://en.wikipedia.org/wiki/ISO_3166-2&#39;&gt;ISO 3166-2</a> for formatting local numbers internationally [optional]

Return type

HLRCallback

Authorization

api_key

HTTP request headers

  • Content-Type: Not defined
  • Accept: application/json

[Back to top] [Back to API list] [Back to Model list] [Back to README]

GetHLRCallback

HLRResult GetHLRCallback (string key, List num, string cb, string cc = null)

HLR number lookup with results going to a callback URL

Perform HLR on number with the result being sent to the callback URL provided

Example

using System;
using System.Diagnostics;
using IO.Swagger.Api;
using IO.Swagger.Client;
using IO.Swagger.Model;

namespace Example
{
    public class GetHLRCallbackExample
    {
        public void main()
        {
            
            // Configure API key authorization: api_key
            Configuration.Default.ApiKey.Add("key", "YOUR_API_KEY");
            // Uncomment below to setup prefix (e.g. Bearer) for API key, if needed
            // Configuration.Default.ApiKeyPrefix.Add("key", "Bearer");

            var apiInstance = new HLRApi();
            var key = key_example;  // string | API Key as generated from the <a href='https://www.smsfusion.com.au/admin/api/'>admin panel</a>
            var num = new List<string>(); // List<string> | Comma separated list of phone numbers or <a href='https://www.smsfusion.com.au/help/msisdn/'>MSDISDN</a>'s
            var cb = cb_example;  // string | HTTP or HTTPS callback URL for each result. The result will be sent as POST with a json object included in <b>result</b>. Timeout for callbacks is set to 30 seconds
            var cc = cc_example;  // string | 2 character country code <a href='https://en.wikipedia.org/wiki/ISO_3166-2'>ISO 3166-2</a> for formatting local numbers internationally (optional) 

            try
            {
                // HLR number lookup with results going to a callback URL
                HLRResult result = apiInstance.GetHLRCallback(key, num, cb, cc);
                Debug.WriteLine(result);
            }
            catch (Exception e)
            {
                Debug.Print("Exception when calling HLRApi.GetHLRCallback: " + e.Message );
            }
        }
    }
}

Parameters

Name Type Description Notes
key string API Key as generated from the <a href='https://www.smsfusion.com.au/admin/api/&#39;&gt;admin panel</a>
num List<string> Comma separated list of phone numbers or <a href='https://www.smsfusion.com.au/help/msisdn/&#39;&gt;MSDISDN&lt;/a&gt;&#39;s
cb string HTTP or HTTPS callback URL for each result. The result will be sent as POST with a json object included in <b>result</b>. Timeout for callbacks is set to 30 seconds
cc string 2 character country code <a href='https://en.wikipedia.org/wiki/ISO_3166-2&#39;&gt;ISO 3166-2</a> for formatting local numbers internationally [optional]

Return type

HLRResult

Authorization

api_key

HTTP request headers

  • Content-Type: Not defined
  • Accept: application/json

[Back to top] [Back to API list] [Back to Model list] [Back to README]