Asterisk-Java

The Asterisk-Java package consists of a set of Java classes that allow you to easily build Java applications that interact with an Asterisk PBX Server.

Asterisk-Java supports most features of the following Asterisk interfaces:

Please start with the tutorials, the frequently asked questions, or the API reference.

License

Asterisk-Java is provided under the terms of the Apache License, Version 2.0.

Status

We plan to release Asterisk-Java 1.0.0 shortly after Asterisk 1.6. It will be available at the distribution site where you can also find the previous releases.

Asterisk-Java 1.0.0 will further enhance the new stateful higher level API with operations like "get list of currently active calls" or "place call" with objects like "Channel" or "Agent" that are transparently updated as the state of the corresponding object within the Asterisk server changes. You can have a look at org.asteriskjava.live that represents its current state.

Download

Official releases and release candidates are available from the our distribution site.

The snapshot distribution site hosts the latest snapshot releases.

Please feel free to provide any feedback or ask for support via the Asterisk-Java users mailing list.

The latest development version of Asterisk-Java is always available via SVN:

  svn co http://svn.reucon.net/repos/asterisk-java/trunk asterisk-java

Requirements

Asterisk-Java is compatible with Asterisk 1.0, 1.2 and 1.4. The upcoming 1.0.0 release will add full support for Asterisk 1.6.

At runtime Asterisk-Java requires a Java Runtime Environment (JRE) of at least version 1.6 (Java SE 6).

Of course you also need a working Asterisk server. When using the Manager API be sure that it has been enabled (see Asterisk config manager.conf).

For logging Asterisk-Java will use log4j when available. If you do not include log4j in your Classpath Asterisk-Java will use java.util.logging.

If you choose to compile Asterisk-Java on your own you need a Java Developer Kit (JDK) of at least version 1.6 (Java SE 6). To run the unit tests you need JUnit and EasyMock in addition.

Related Projects

Asterisk Desktop Manager, or ADM for short, brings the power of Asterisk to the user's desktop. It is written in Java, uses the Eclipse SWT library for its GUI and Asterisk-Java to provide Asterisk connectivity.
Available under the GNU General Public License (GPL).

Asterisk-IM is a plugin for the Wildfire XMPP (Jabber) server. It provides integrated presence between your IM client and phone, notification of incoming calls by IM and originate calls from the IM client - and of course it is based on Asterisk-Java.
Available under the GNU General Public License (GPL).

AsterFax provides an SMTP Fax gateway for the transmission of faxes using Asterisk and is based on Asterisk-Java.
Available under a modified GNU General Public License (Organizations with more than one fax lines must purchase a commercial licence).

Asterisk-JTAPI is a JTAPI implementation for the Asterisk software PBX system. JTAPI is a provider independent programming interface for Java to build applications for computer telephony or to add support for it. JTAPI covers a wide range of usage scenarios starting from controlling a single telephone to a whole PBX system for example in call-centers.
Asterisk-JTAPI builds on top of two other projects: Asterisk-Java, which provides a Java interface to the Asterisk Manager API, and GJTAPI, which provides a general framework for JTAPI interfaces.
Available under Apache License.

Asterisk .NET is a full port of Asterisk-Java to .NET. It supports both the Manager API and FastAGI. The latest version is available from SourceForge.
Available under Apache License.

Asterisk-Java for Mono/.NET is a port of Asterisk-Java to C# for Mono, Microsoft's .NET Framework and anything else that implements the basic portions of the framework. It currently only supports the Manager API and is based on a pre-0.1 snapshot of Asterisk-Java.
Available under Apache License.

Mobicents is a VoIP Middleware based on the JAIN SLEE standard. It includes an Asterisk RA that is based on Asterisk-Java.
Available under Lesser GNU General Public License (LGPL)

Jast Agi is another toolkit for writing Java applications that connect to Asterisk using the FastAGI protocol. The lastest version introduces a statemachine approach to handle AGI requests and uses java.nio to process all requests in one Thread.
Available under Apache License.

OrderlyCalls supports writing Java based AGI Scripts using FastAGI. Support for the Manager API was recently added.
Available under a modified Lesser GNU General Public License (It is prohibited to use it for automating 'cold-calling' and you need prior written permission to provide or augment call queuing).

JAsterisk is a set of JNI classes providing direct access to Asterisk PBX functionality from Java. It is not a socket-level interface to Asterisk (like Asterisk-Java) but a true Java-Asterisk integration at the Thread level.
Available under GNU General Public License.

Sponsors

Thanks to our sponsors:

Contact

You can reach me at stefan.reuter at reucon dot com.