C# SMS API connect

The C# SMS API uses the OZX sms protocol to send and receive SMS messages through the Ozeki 10 SMS Gateway. Thanks to this protocol it is the best SMS API available in C#.Net. The C# SMS api has a method called connect, that can be used to establish a permanent connection to the SMS gateaway.

c# sms api connect method
Figure 1 - C# SMS API connect method

For the C#/.Net SMS api to connect to the SMS Gateway use

To connect the C#/.Net SMS api to the SMS gateway you need

  • Host: The IP address or the hostname of Ozeki SMS Gateway. Default: 127.0.0.1
  • Port: The OZX port number of the SMS Gateway. Default: 9580
  • Username: You have created this to let the C#/Net sms api connect. Default: testuser
  • Password: You have created this to let the C#/Net sms api connect. Default: testpass

C# sms api connect example:

var Client = new OzxClient();
Client.AutoReconnect = true;
Client.Connect("127.0.0.1",9580,"testuser","testpass");

If you set the AutoReconnect property to true, the C# SMS api will know, that it should automatically reestablish the connection if the link is lost.

More information