Sign in

Welcome.
How can we help?

Alternative answering numbers

Topic: , Updated:

In this example we will learn how use the API to set alternative answering numbers. Normally when you create a source, calls are always sent to the number set in phonenr. However, if you would like to send calls to different call centers depending on business hours or simply send all calls to voicemail after business hours, you can use the alternative answering numbers feature. alt_numbers is a JSON representation of array(array(“phonenr”⇒,”weekdays”⇒,”from_time”⇒,”to_time”⇒,”alt_key”⇒)), and alt_key is generated by Freespee and can be omitted when creating or updating rules.

1. Different call centers

To enable alternative answering numbers on different business hours for a source, update the source with appropriate information:

PUT /sources/219982
alt_numbers=[{"phonenr":"01890510","weekdays":"mon,fri","from_time":"11:30","to_time":"13:00"}]
{
 "sources":[{
  "source_id":"219982",
  "name":"test",
  "email":null,
  "smsnumber":null,
  "media":null,
  "customer_id":"86931",
  "phonenr":"+461890510",
  "destnr":"+4618921814",
  "timestamp":"2012-03-13 23:00:00",
  "expire":null,
  "created":"2012-03-14 20:56:46",
  "modified":"2012-03-15 09:07:14",
  "class":"0",
  "status":"active",
  "vm_greeting_id":"303",
  "campaign_id":null,
  "publisher_id":null,
  "notify_on_missed_call":"0",
  "notify_on_new_voicemail":"0",
  "vm_divert_all":"0",
  "vm_divert_busy":"1",
  "vm_divert_noanswer":"1",
  "alt_numbers":[{
   "phonenr":"+461890520",
   "weekdays":"mon,fri",
   "from_time":"11:30",
   "to_time":"13:00",
   "alt_key":"10"}]
 }]
}

In this example all calls are normally sent to a call center at +461890510. With the use of alternate response numbers, we've now enabled that the call center at +461890520 will receive all calls from 11:30 to 13:00, Monday and Friday.

2. Voicemail after hours

To enable voicemail after business hours, update the source with appropriate information:

PUT /sources/219982
alt_numbers=[{"phonenr":"voicemail","weekdays":"mon,tue,wed,thu,fri","from_time":"17:00","to_time":"24:00"},
{"phonenr":"voicemail","weekdays":"mon,tue,wed,thu,fri","from_time":"00:00","to_time":"07:00"}]
{
 "sources":[{
  "source_id":"219982",
  "name":"test",
  "email":null,
  "smsnumber":null,
  "media":null,
  "customer_id":"86931",
  "phonenr":"+461890510",
  "destnr":"+4618921814",
  "timestamp":"2012-03-13 23:00:00",
  "expire":null,
  "created":"2012-03-14 20:56:46",
  "modified":"2012-03-15 09:29:51",
  "class":"0",
  "status":"active",
  "vm_greeting_id":"303",
  "campaign_id":null,
  "publisher_id":null,
  "notify_on_missed_call":"0",
  "notify_on_new_voicemail":"0",
  "vm_divert_all":"0",
  "vm_divert_busy":"1",
  "vm_divert_noanswer":"1",
  "alt_numbers":[{
   "phonenr":"voicemail",
   "weekdays":"mon,tue,wed,thu,fri",
   "from_time":"17:00",
   "to_time":"24:00",
   "alt_key":"10"
   },{
   "phonenr":"voicemail",
   "weekdays":"mon,tue,wed,thu,fri",
   "from_time":"00:00",
   "to_time":"07:00",
   "alt_key":"20"
   }]
 }]
}

In this example, all calls will be sent to voicemail Mon-Fri, 17:00 to 07:00.

Congratulations! You've now learned how to handle alternative answering numbers using the Freespee API.

Was this article helpful?
0 out of 0 found this helpful

Comments


Not the answer to your question?

Powered by Zendesk