You'd better switch to a software-based system, like Ozeki's PBX. With its SDK you can develop call recorder in C#:
public class Program
{
public void static void Main(string[] args)
{
OpsClient opsClient = new OpsClient();
var result = opsClient.Login("ozekixepbx.ip", "admin", "abc12345");
opsClient.SessionCreated += new EventHandler>(opsClient_SessionCreated);
opsClient.SessionCompleted += new EventHandler>(opsClient_SessionCompleted);
}
static void client_SessionCreated(object sender, Ozeki.VoIP.VoIPEventArgs e)
{
try{
var mp3Recorder = currentCalls.GetOrAdd(session, (s) => new MP3StreamRecorder(string.Format("{0}_{1}_{2}.mp3", session.CallerId, session.Destination, session.SessionID)));
session.ConnectAudioReceiver(CallParty.All, mp3Recorder);
mp3Recorder.StartStreaming();
}catch(Exception ex)
{
Console.WrinteLine(ex.Message);
}
}
static void client_SessionCompleted(object sender, Ozeki.VoIP.VoIPEventArgs e)
{
MP3StreamRecorder recorder;
if(currentCalls.TryGetValue(session, out recorder))
{
recorder.Dispose();
session.DisconnectAudioReceiver(CallParty.All, recorder);
}
}
}
Source:
http://www.ozekiphone.com/voip-part2-c-example-on-recording-voip-calls-call-routing-754.html[
^]