4

Does anyone know of a SIP client that can open a web page to a configurable URL when someone calls? We have a web-based database, and I'd like to search by phone number whenever we get an incoming call, and have the person on screen before I answer it.

The SIP client program doesn't have to have any other audio or calling features - we all have hardware SIP phones on our desks as well.

rjmunro
  • 1,386

4 Answers4

5

I doubt that you're still looking for an answer to this 6 months later, but here goes:

The Twinkle SIP client supports executing a script when an incoming call is received and I'm sure many others do as well. To get something like this working in Twinkle, you'd write a script like the one below, then go into Edit->User Profile->Scripts and select /path/to/my/script for "Incoming Call".

#!/usr/bin/env python
import os
import re

def get_caller_id(from_hdr):
    clid, uri = from_hdr.split(" <sip")
    clid = re.sub("\"", "", clid)
    # Insert ASCII code for spaces
    if re.search("\s", clid):
        clid = re.sub("\s", "%20", clid)
    return clid


if "SIP_FROM" in os.environ:
    from_hdr = os.environ["SIP_FROM"]
    if re.match("\"[A-Za-z0-9\s]+\"", from_hdr):
        cmd = "firefox "
        url = "http://www.google.com/search?q="
        caller_id = get_caller_id(from_hdr)
        cmd_string = cmd + url + caller_id

        # Launch Browser
        os.system(cmd_string)
rjmunro
  • 1,386
2

I found http://www.phoner.de/index_en.htm does this. Options -> External Application and then run a .bat file with something like:

[InternetShortcut]
URL=http://www.google.com/id=%1
1

Recently I've added options to automatically open URL on incoming call or on accepting incoming call to tSIP (Settings/Contacts, HTTP query, e.g. https://www.yandex.com/search/?text=[number] where "[number]" would be replaced with number from current or last incoming call). Previously it was available only as manual action and personally I would prefer it that way. All function keys are configurable (BLF/speed dial/DTMF/etc., similar to desk phones). After configuring "HTTP query" button, global shortcut (e.g. Ctrl + Browser Forward key combination that most likely would be unused) can be assigned to it making it relatively effortless to open page if softphone sits it tray (action for shortcut = "button #", ID = button ID as visible when editing button).

I don't know how call queue works with your PABX (sequential or all-at-once ringing), but opening pages automatically may result with lots of pages opened unnecessary (or be very disturbing if agents are making notes after the call) and I think in many cases agents may know that particular call should be left to be answered by their peers.

TMSZ
  • 231
0

Nowadays you should use WebRTC from web.

This can be easily done with the siplml5 or JsSIP open source WebRTC clients.

Or if you wish a ready to use solution you might try the mizu webphone which has a setting for this, so you just have to enter your URL to be called on incoming calls.