Skip to content

Instantly share code, notes, and snippets.

@ioleksiy
Created June 4, 2014 09:29
Show Gist options
  • Save ioleksiy/490c668126034f509329 to your computer and use it in GitHub Desktop.
Save ioleksiy/490c668126034f509329 to your computer and use it in GitHub Desktop.
Using ePochta SMS Gateway
using System;
using Rest4Net.ePochta;
using Rest4Net.ePochta.Responses;
namespace ConsoleApplication1
{
class Program
{
// Provide yours here
private const string PublicKey = "public-key";
private const string PrivateKey = "private-key";
static void Main()
{
// Creating a disposable API accessor
using (var epochta = new ePochtaProvider(PublicKey, PrivateKey))
{
// Sending sms
var result = epochta.SendSms("+12223334455", new MessageInfo("Text of sms", "Sender Title"));
// Informational
Console.WriteLine("Created campaign id: {0}", result.Id);
Console.WriteLine("Total price for campaign: {0}", result.Price);
Console.WriteLine("Currency for the price: {0}", result.PriceCurrency);
}
}
}
}
@ioleksiy
Copy link
Author

ioleksiy commented Jun 4, 2014

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment