Esempio n. 1
0
        private static void Main(string[] args)
        {
            const string clientId = "hqikydyh";
            const string clientSecret = "kakdxpvd";


            try {
                var host = new ApiHost(new BasicAuth(clientId, clientSecret));
                var messageApi = new MessagingApi(host);
                MessageResponse msg = messageApi.SendQuickMessage("Arsene", "+233247063817", "Hello Big Bro!", true);
                Console.WriteLine(msg.Status);                
            }
            catch (Exception e) {
                if (e.GetType() == typeof (HttpRequestException)) {
                    var ex = e as HttpRequestException;
                    if (ex != null && ex.HttpResponse != null) {
                        Console.WriteLine("Error Status Code " + ex.HttpResponse.Status);
                    }
                }
                throw;
            }

            Console.ReadKey();
        }
Esempio n. 2
0
 /// <summary>
 ///     Constructor
 /// </summary>
 /// <param name="host"></param>
 public AccountApi(ApiHost host) : base(host) {}
Esempio n. 3
0
 /// <summary>
 ///     Constructor
 /// </summary>
 /// <param name="host"></param>
 public SupportApi(ApiHost host) : base(host) {}
Esempio n. 4
0
 public MessagingApi(ApiHost host) : base(host)
 {
 }
Esempio n. 5
0
 /// <summary>
 /// </summary>
 /// <param name="host"></param>
 public ContactApi(ApiHost host) : base(host) {}
Esempio n. 6
0
 public SupportApi(ApiHost host) : base(host)
 {
 }
Esempio n. 7
0
 public ContentApi(ApiHost host) : base(host)
 {
 }
Esempio n. 8
0
 public ContactApi(ApiHost host) : base(host)
 {
 }
Esempio n. 9
0
 /// <summary>
 ///     Default constructor. Use this constructor whenever this class is going to be referenced.
 /// </summary>
 /// <param name="host"><see cref="ApiHost" /> The Api Host object.</param>
 public ContentApi(ApiHost host) : base(host) {}
Esempio n. 10
0
 public AccountApi(ApiHost host) : base(host)
 {
 }
Esempio n. 11
0
 /// <summary>
 /// </summary>
 /// <param name="host"></param>
 public MessagingApi(ApiHost host) : base(host) {}