About SMSLib
Introduction
SMSLib is a Java library which allows you to send/receive SMS messages via a compatible GSM modem or GSM phone. SMSLib also supports some bulk sms operators (for outbound messaging only).
SMSLib has been converted to a .NET assembly using the IKVM Tools. Read more here.
SMSLib is distributed under the terms of the Apache v2 license.
Features
SMSLib is currently on its 3rd version.
SMSLib v3 retains the old functionality:
- Supports GSM phones and GSM modems connected via serial port interfaces or IP interfaces.
- Works with PDU/TEXT protocols.
- Supports Inbound & Outbound simple text messages.
- Works with 7bit, 8bit and UCS2 (Unicode) message encodings.
- Supports Inbound & Outbound big (multipart) messages.
- Flash messaging.
- Outbound messages with port information / addressing.
- Outbound WAP PUSH SI messages.
- Status (Delivery) Report messages.
- Basic GSM information available: Modem, Manufacturer, S/W revision, Signal level, etc.
- Supports a few bulk operators, using http/https protocols.
- Support the SMPP protocol.
Furthermore, SMSLib v3 offers the following new functionality:
Multiple Gateways
SMSLib v3 has introduced the concept of the Gateway, which is an interface to a device or service that can send and/or receive SMS messages. A gateway could be a GSM modem or a supported bulk sms provider. SMSLib can handle multiple gateways at the same time.
Sending Priorities
SMSLib offers unlimited per-message priorities which can be used for sending messages. When possible, SMSLib priorities are mapped directly to the gateway(s) functionality, otherwise they get simulated.
Synchronous / Asynchronous Receiving
SMSLib gives you two options for receiving messages:
- Synchronously: you take responsibility and periodically call the read() methods.
- Asynchronously: wait for SMSLib to call you upon message receipt.
Synchronous / Asynchronous Sending
SMSLib gives you two options for sending messages:
- Synchronously: when you call SMSLib to send a message, your thread blocks until the message gets sent or fails.
- Asynchronously: when you call SMSLib to send a message, your thread does not block and SMSLib returns immediately. SMSLib queues your message(s) and sends them in the background. You may choose to get notified about the fate of your messages.
Callbacks
SMSLib gives you the option of defining callback methods which it will call when certain events occur:
- Inbound voice calls: SMSLib can be set to call you upon reception of a voice call. Please note that the voice call will be automatically and unconditionally dropped and you will get notified about the number of the calling party.
- Inbound messages: Each time a message is received, SMSLib can be set to call your specified method.
- Outbound messages: When you asynchronously send messages, SMSLib can be set to call your specified method with the message sent (updated with status, etc).
- Gateway status changes: SMSLib can notify you each time a gateway changes its status.
- Queue sending operation: SMSLib can notify you everytime it's ready to send a message via the background queues.
See this page for more information.
Custom Sender ID
SMSLib supports custom Sender ID. This feature is not supported on GSM modems - you have to use one of the supported bulk sms operators.
Encrypted Messages
SMSLib can send/receive encrypted messages. The current encryption engine uses the JDK AES strong key (128bit) implementation. Encrypted messages are send as binary messages. SMSLib provides an automatic way of assigning encryption keys to specific numbers, so the whole send/receive procedure is more or less automatic.
See this page for more information.