2012年10月19日 (金)

Microsip Api Better Hot! -

Instead of firing a command and hoping for the best, a wrapper can read the Window Title of MicroSIP. MicroSIP updates its title bar with status (e.g., "Ringing", "Connected", "Hangup"). Your wrapper can parse this text and expose it via an API endpoint.

# To dial a number via the API MicroSIP.exe "callto:+1234567890" microsip api better

hwnd = win32gui.FindWindow(None, "MicroSIP") if hwnd: win32gui.SendMessage(hwnd, win32con.WM_COMMAND, 40007, 0) # Answer Instead of firing a command and hoping for