Documente Academic
Documente Profesional
Documente Cultură
Kolmisoft 2006-2012
1
Contents
Introduction ..................................................................................................................................... 6
Who is this product designed for ...................................................................................................... 6
Supported Business Models ............................................................................................................. 7
How to make first call ..................................................................................................................... 8
Concepts/Definitions ....................................................................................................................... 14
MOR Terminology......................................................................................................................... 14
Billing Concepts ........................................................................................................................... 18
Billing Logic ................................................................................................................................. 19
Call explained .............................................................................................................................. 20
E.164 ................................................................................................................................. 21
Rounding ................................................................................................................................. 21
Multi-Tax system ......................................................................................................................... 21
What is a PIN? ............................................................................................................................. 24
ASR/ACD ................................................................................................................................. 25
Margin and Markup ...................................................................................................................... 25
What are callgroups and pickupgroups ............................................................................................ 26
Balance and Credit ....................................................................................................................... 27
Why amounts are without VAT? ..................................................................................................... 28
Local Calls ................................................................................................................................. 28
Prepaid Logic ............................................................................................................................... 30
Authentication ............................................................................................................................. 32
Fax over VoIP .............................................................................................................................. 34
Configuration from GUI ................................................................................................................... 36
ReCAPTCHA................................................................................................................................. 43
Payments configuration ................................................................................................................ 48
Default device settings ................................................................................................................. 54
Default user ................................................................................................................................ 56
Accountant permissions ................................................................................................................ 57
Logo change ................................................................................................................................ 59
Currencies ................................................................................................................................. 60
Translations ................................................................................................................................ 63
Global date format ....................................................................................................................... 64
Remove Manual link from admin GUI .............................................................................................. 65
Voicemail ................................................................................................................................. 65
Email settings .............................................................................................................................. 70
Number Manipulation ...................................................................................................................... 76
Localization ................................................................................................................................. 76
Provider Rules ............................................................................................................................. 82
DID handling by Localization ......................................................................................................... 85
Users ............................................................................................................................................ 93
User Details ................................................................................................................................ 93
Warning balance .......................................................................................................................... 95
User Blocking .............................................................................................................................. 96
Blocking ................................................................................................................................. 98
Hide Users ................................................................................................................................ 100
Why MOR does not allow to delete users ........................................................................................ 102
How to create User and Device ..................................................................................................... 103
How to change Admin details........................................................................................................ 103
MOR forgot user password ........................................................................................................... 104
Minimum contract billing .............................................................................................................. 106
Tariffs .......................................................................................................................................... 107
Kolmisoft 2006-2012
2
Directions and Destinations .......................................................................................................... 107
Destinations Groups .................................................................................................................... 108
Block some Destination to User .................................................................................................... 109
Day setup ................................................................................................................................ 112
Entering Rates for Wholesale Tariff ................................................................................................ 113
Rate import from CSV.................................................................................................................. 117
Wholesale Tariff .......................................................................................................................... 127
Entering Rates for Retail Tariff ...................................................................................................... 129
Advanced Rates .......................................................................................................................... 131
Custom Rates ............................................................................................................................. 134
Tariff Transformation ................................................................................................................... 135
Make Retail Tariff from Wholesale Tariff explained ........................................................................... 136
Devices ........................................................................................................................................ 138
H323 Device settings ................................................................................................................... 145
Extension lines ........................................................................................................................... 146
Ring several devices at same time ................................................................................................ 146
How to create User and Device ..................................................................................................... 147
Trunks ................................................................................................................................ 147
CLIs (Incoming CallerIDs) ............................................................................................................ 148
ANI/CLI ban system .................................................................................................................... 149
Duplicate call prevention .............................................................................................................. 152
Allow loss calls ........................................................................................................................... 152
Device groups ............................................................................................................................ 153
Call Flow ................................................................................................................................ 154
Which codecs should I choose for devices ...................................................................................... 160
Change Audio/Video Codecs priority .............................................................................................. 163
Authentication ............................................................................................................................ 164
Providers ...................................................................................................................................... 173
Authentication ............................................................................................................................ 175
Failover provider ......................................................................................................................... 178
Terminators ............................................................................................................................... 179
Provider with several IP ............................................................................................................... 179
Provider connection testing .......................................................................................................... 180
H323 Provider settings ................................................................................................................ 181
Provider with ANI ........................................................................................................................ 181
Configure Provider which can make calls ........................................................................................ 183
Configure Provider with dynamic IP ............................................................................................... 183
Simultaneous call limitation .......................................................................................................... 185
NO ANSWER/BUSY interpretation for providers ............................................................................... 188
Call Routing .................................................................................................................................. 209
LCR ................................................................................................................................ 209
LCR Logic ................................................................................................................................ 211
Call Routing by price ................................................................................................................... 213
Call Routing by priority (Manual LCR) ............................................................................................ 214
Call routing per destination basis .................................................................................................. 216
How to route call to specific Destination through specific Provider ..................................................... 219
LCR/Tariff change based on call prefix ........................................................................................... 220
Routing by Percent ...................................................................................................................... 221
Why call was not routed through other provider/trunk? ................................................................... 224
DIDs ............................................................................................................................................ 226
DID Management ........................................................................................................................ 226
Assign DID to Trunk .................................................................................................................... 236
Work flow for DID ....................................................................................................................... 238
Kolmisoft 2006-2012
3
DID Billing ................................................................................................................................ 239
DIDs Usage ................................................................................................................................ 243
Personal DIDs............................................................................................................................. 243
DID with VoxBone using his URI ................................................................................................... 248
Forward DID to External Number .................................................................................................. 249
How to charge DID on a monthly basis .......................................................................................... 249
DID handling by Localization ........................................................................................................ 250
DID Blocking .............................................................................................................................. 251
Dial Plans ................................................................................................................................ 252
Authorization by PIN ................................................................................................................... 253
Authorization by ANI ................................................................................................................... 256
Calling Card Dial Plan .................................................................................................................. 259
Callback Dial Plan ....................................................................................................................... 261
IVR Dial Plan .............................................................................................................................. 263
STATISTICS -> Various –> DIDs .................................................................................................. 263
Accounting .................................................................................................................................... 264
Invoices ................................................................................................................................ 269
Credit notes ............................................................................................................................... 280
Payments ................................................................................................................................ 283
Vouchers ................................................................................................................................ 286
Flat-Rates ................................................................................................................................ 289
Reporting...................................................................................................................................... 290
Active Calls ................................................................................................................................ 290
Last Calls ................................................................................................................................ 295
Users Calls ................................................................................................................................ 297
Users Finances ........................................................................................................................... 298
Loss Making Calls ........................................................................................................................ 298
Providers Statistics...................................................................................................................... 299
Providers Calls ............................................................................................................................ 300
First Activity ............................................................................................................................... 301
Quick Stats ................................................................................................................................ 301
Simultaneous Calls stats .............................................................................................................. 304
Calls by Source ........................................................................................................................... 305
Login Stats ................................................................................................................................ 306
Profit Stats ................................................................................................................................ 307
Country Stats ............................................................................................................................. 307
Google Maps integration .............................................................................................................. 309
Balance in phone ........................................................................................................................ 310
Privacy to hide Destination ends ................................................................................................... 312
Troubleshooting ............................................................................................................................. 314
Action log ................................................................................................................................ 314
User actions ............................................................................................................................... 317
Call Tracing ................................................................................................................................ 317
Integrity Check ........................................................................................................................... 325
Hangupcause Codes .................................................................................................................... 327
Hangupcause Sounds .................................................................................................................. 329
Different code send to User compared to received from Provider ....................................................... 330
Call Info ................................................................................................................................ 331
SIP debug info ............................................................................................................................ 333
Asterisk CLI ............................................................................................................................... 334
MOR's Core version ..................................................................................................................... 336
Lots of calls made by System Admin user ...................................................................................... 336
Maintenance ................................................................................................................................. 337
Kolmisoft 2006-2012
4
Upgrade MOR GUI ....................................................................................................................... 338
Lost MOR GUI admin password ..................................................................................................... 338
Where I can get my serial key from ............................................................................................... 339
Testing ......................................................................................................................................... 339
VoIP Bandwidth Calculator ........................................................................................................... 339
Payment gateways ......................................................................................................................... 340
Other functionality ......................................................................................................................... 351
IVR system ................................................................................................................................ 351
IVR Greeting for DID ................................................................................................................... 359
Voicemail ................................................................................................................................ 361
Dial Local ................................................................................................................................ 366
PBX Function External DID ........................................................................................................... 370
Ring-Groups ............................................................................................................................... 372
Fax2Email ................................................................................................................................ 375
Recordings ................................................................................................................................ 379
PhoneBook ................................................................................................................................ 381
Speed Dials ................................................................................................................................ 383
Backup system ........................................................................................................................... 384
Data import................................................................................................................................ 386
CDR Import ................................................................................................................................ 394
CDR Rerating ............................................................................................................................. 398
Online registration ...................................................................................................................... 400
Online registration customization .................................................................................................. 403
Quick Forwards ........................................................................................................................... 403
Quickforwards rules..................................................................................................................... 406
Transfers with MOR ..................................................................................................................... 408
GUI on Mobile Devices ................................................................................................................. 409
PBX connection to MOR................................................................................................................ 410
MOR API ................................................................................................................................ 421
Cron actions ............................................................................................................................... 426
MOR Addons ................................................................................................................................. 429
Calling Cards Addon .................................................................................................................... 429
Callback Addon ........................................................................................................................... 469
Auto-Dialer Addon....................................................................................................................... 482
Reseller Addon ........................................................................................................................... 488
Reseller Pro Addon ...................................................................................................................... 494
Manual for Resellers .................................................................................................................... 497
SMS Addon ................................................................................................................................ 509
Recordings Addon ....................................................................................................................... 511
Mobile Number Portability Addon .................................................................................................. 516
Payment Gateway Addon ............................................................................................................. 518
Monitorings Addon ...................................................................................................................... 543
Call Shop Addon ......................................................................................................................... 554
Skype Addon .............................................................................................................................. 572
Provider billing addon .................................................................................................................. 583
Tutorials ....................................................................................................................................... 586
Usual configuration sequence ....................................................................................................... 586
How to configure 911 service ....................................................................................................... 591
How to make several connections from one IP ................................................................................ 593
How to forward calls when device is offline ..................................................................................... 597
Kolmisoft 2006-2012
5
Introduction
Kolmisoft VoIP Softswitch with Billing and Routing MOR is an advanced system that enables
alternative telecoms to provide flexible voice services, effectively manage service offerings
and grow their voice businesses due to the systems stability and high traffic scalability.
Kolmisoft System MOR integrates the core AAA functions Authentication, Authorization, and
Accounting with vital functions that facilitate the effective management of all billing/routing-
related processes:
Customers
Services
Finance
Services distribution
Reporting
Traffic partners
User rights
On the business side, Kolmisoft System MOR makes possible the deployment of services with
high-quality and flexibility within any VoIP business model; on the technical side the system
maintains seamless performance at high and rapidly increasing traffic volume. The optimal
combination of functions, the adaptability to every VoIP business model and rate-plan
settings, as well as its stability, make Kolmisoft System MOR the absolute billing/routing and
customer care solution for Voice Over Broadband/ IP businesses worldwide.
Kolmisoft 2006-2012
6
Supported Business Models
Kolmisoft System MOR is adaptable to telephony service providers' business models and
custom requirements for service configuration. Voice-over-IP and Voice-over-Broadband
providers can configure different service types within all of the following basic business
models:
Kolmisoft 2006-2012
7
How to make first call
This small guide will show how to make your first call after
system installation.
Create a tariff
Kolmisoft 2006-2012
8
Enter the name (you will use it to recognize tariff (price list) in variuos system places). Choose
currency in which you will pay for providers/suppliers. Select what type of tariff do you want
and click Create.
In this example tariffs have rates/prices from your Providers. These prices are paid TO
Providers when they terminate calls FROM your system to PSTN. This is self-cost for you, e.g.
you buy calls using these prices, as it is written next to the blue information icon.
Rates
However if you choose other type than Providers you will have to either import rates from
CSV or fill them in manually by clicking Rates -> New rate. The most important fields in
Rates are Prefix and Rates.
Create a provider
Select Technology, from a dropdown list assign Tarrif you have created, select the server and
click Create.
Kolmisoft 2006-2012
9
Create a LCR
Enter the name. From a dropdown list select the order. If you select order of providers by
price the cheapest way to dial a destination will be used. If you select by priority the call will
be routed by a predetermined order. Routing by percent is similar to routing by priority. After
you selected click Create.
You will see that there are no providers assigned to this created LCR.
Click Providers.
Kolmisoft 2006-2012
10
Assign created provider from the dropdown list and click Add.
Please note that Save changes button is only for failover providers, not for providers in
general.
Adding a user
Kolmisoft 2006-2012
11
Assign created LCR and click Create at the bottom of the page.
To add a device go to SETTINGS -> Users and in the users list click the devices icon ( ). In
the opened window click Add new device.
Click Create.
Softphone
To make a real call, you will need a softphone for a quick test.
You can use your own if it supports the SIP or IAX2 protocols.
Kolmisoft 2006-2012
12
For the sake of simplicity, we will show how to configure Idefisk 1.37 , which is very small and
easily configurable.
Use Idefisk configuration manual to configure Idefisk with your <SERVER_IP> and
username/password of test user's device.
NOTE: that User 101 is by default Blocked to insure maximum security to your system.
Unblock it before making a test call.
Dialing
Next, enter a phone number into your softphone and try to dial.
NOTE: enter the number in international (E.164) format. Do not use any international prefixes
- use country code + area code + number.
For example, a Lithuanian number is 37063042439, where 370 is the country code, 6 is the
area code (MOB network), and all the rest is the number itself.
NOTE: USA/Canada numbers should start with 1 (which is the USA/Canada country code).
Call logs
After the call, you can check your call in the system.
Go to: STATISTICS -> Calls -> Last Calls and you will see your call.
It will be already billed.
Kolmisoft 2006-2012
13
Concepts/Definitions
MOR Terminology
1. Accountant [http://wiki.kolmisoft.com/index.php/Accountant_permissions] – a type of user
which has more rights than simple user in MOR, but still not enough to fully manage all
configuration of MOR system. His rights can be adjusted at any time.
2. Action log [http://wiki.kolmisoft.com/index.php/Action_log] – detailed report about user
activity.
3. Addons [http://wiki.kolmisoft.com/index.php/MOR_Addons]– a special feature group for
MOR which adds additional functionality.
4. Admin [http://wiki.kolmisoft.com/index.php/Users] – most powerful user account in MOR
(just like root in UNIX systems).
5. Aggregate [http://wiki.kolmisoft.com/index.php/MOR_Manual#Reporting] – advanced
report on calls.
6. API [http://wiki.kolmisoft.com/index.php/MOR_API] - application programming interface is
an interface implemented by a software program to enable interaction with other software,
similar to the way a user interface facilitates interaction between humans and computers.
7. Asterisk [http://en.wikipedia.org/wiki/Asterisk_(PBX)]- PBX free software, multi platform,
published under license GPL per Spencer Mark of the Digium company.
8. Auto Dialer [http://wiki.kolmisoft.com/index.php/Auto-Dialer_Addon] – this addon allows
to call an array of numbers automatically and when answered plays back a prerecorded
message to the receiving end of the call.
9. Backup [http://wiki.kolmisoft.com/index.php/Backup_system] - a backup or the process of
backing up refers to making copies of data so that these additional copies may be used to
restore the original after a data loss event.
10. Browser title – most top of web browser.
11. Callback [http://wiki.kolmisoft.com/index.php/Callback] – in telecommunications, a
callback (also written as call-back) occurs when the originator of a call is immediately called
back in a second call as a response.
12. Call tracing [http://wiki.kolmisoft.com/index.php/Call_Tracing] – used for checking the
setup of MOR in order to be sure user will be able to dial out to specified destination number.
13. Calling cards [http://wiki.kolmisoft.com/index.php/Calling_Cards_Addon]– an addon to
MOR billing which adds Calling Card functionality.
14. CDR – call data (detail) records are computer records produced by a
telephone exchange containing details of a call that passed through it.
15. Click2Call [http://wiki.kolmisoft.com/index.php/Click2Call] – the technology which virtually
always refers to a means for a web consumer to ask a website operator to call her. In
Kolmisoft 2006-2012
14
other words, "clicktocall" would be more accurately be referred to as "RequestACall,"
as in "Please give me a call (here is my phone number)."
16. Default device [http://wiki.kolmisoft.com/index.php/Default_device_settings] - when you
configure default device's parameters, next time when you try make new device for someone,
the newly device will have ―default device's‖ parameters already.
17. Default user – when you configure default user's parameters, next time when you try to
make new user, he already will have them.
18. Destination – destination helps identify country and city and destination number stands
for final number which will be sent to provider.
19. Devices [http://wiki.kolmisoft.com/index.php/Devices] - represents endpoint which can
generate (originate) or receive (terminate) calls. As example device can represent: VoIP
phone, VoIP softphone, PSTN phone (connected through FXS port), PBX, softswitch, etc.
20. Dial Plan [http://wiki.kolmisoft.com/index.php/Dial_Plans] - a dial plan establishes rules
how to handle some call.
21. DIDS [http://wiki.kolmisoft.com/index.php/MOR_Manual#DIDs] - Direct Inward Dialing is a
feature offered by telephone companies for use with their customers' PBX systems, whereby
the telephone company allocates a range of numbers all connected to their customer's
PBX. As calls are presented to the PBX, the number that the caller dialed is also given, so the
PBX can route the call to the desired person or bureau within the organization.
22. Direct link or Direct URL [http://wiki.kolmisoft.com/index.php/What_is_direct_URL] – a link
to specified place in WEB.
23. Direction [http://wiki.kolmisoft.com/index.php/Directions_and_Destinations] - usually
refers to Countries. Could also be satellite networks. They describe direction where the call
will be routed.
24. Domain – usually meaning of second level domain, for example: example.com (com is first
level and example is second level)
25. Domestic – meaning to describe ―calls inside country‖ or in other words ―local calls‖.
26. FAX [http://wiki.kolmisoft.com/index.php/Fax2Email] - a fax (short for facsimile) is a
document sent over a telephone line. FAX implementation in VOIP is very bad and currently it
is still not possible to send/receive fax in VOIP at 100% succession rate.
27. Firewall – is a part of a computer system or network that is designed to block
unauthorized access while permitting authorized communications. Poorly configured firewall
is very often the cause to failed calls.
28. Frontpage text – first page in MOR GUI displayed for successfully logged in user or admin.
29. Graph – function which generates visual data sets.
30. HGC [http://wiki.kolmisoft.com/index.php/Hangupcause_Codes] – substitution for
―hangup cause code‖, those codes used to identify status of all made calls through MOR.
31. Integrity check [http://wiki.kolmisoft.com/index.php/Integrity_Check] – a place with
various properties of billing system which tells where potential problems could exists.
32. Invoice [http://wiki.kolmisoft.com/index.php/Invoices] - a document issued from a vendor
for payment, detailing the goods or services the vendor has provided to the buyer, the
Kolmisoft 2006-2012
15
cost(s), and any VAT due. The document may be called a 'Sales Invoice', from the point of
view of the vendor, or a 'Purchase Invoice' by the buyer.
33. IVR [http://wiki.kolmisoft.com/index.php/IVR_system] - Interactive Voice Response (IVR) is
a technology that allows a computer to detect voice and dualtone multi-frequency signaling
(DTMF) keypad inputs. Most often usage of IVR in VOIP is for Virtual menus.
34. Last Calls [http://wiki.kolmisoft.com/index.php/Last_Calls] – place in MOR GUI where you
can see detailed list of last billed calls.
35. LCR [http://wiki.kolmisoft.com/index.php/LCR] – stands for Least Cost Routing is the
process of selecting the path of outbound communications traffic based on cost (cheapest
price), order (always route calls to A, but if A fails, then route to B, if B fails, route to C etc.) or
percent (used for load balancing, for example: send 50% of call to provider A and rest 50% to
B).
36. Localization [http://wiki.kolmisoft.com/index.php/Localization] – technology used by MOR
which transforms received number to E.164 format number.
37. LOGO [http://wiki.kolmisoft.com/index.php/Logo_change] – your company's logo.
38. MOR [http://www.kolmisoft.com/billing-and-routing/mor-voip-billing-features] –
softswitch with billing and routing made by Kolmisoft Ltd.39. Number digits - how many
decimal digits will see all system users. You can change this setting in Settings.
40. Originate - initialize call.
41. PBX [http://en.wikipedia.org/wiki/Private_branch_exchange] - small version of the phone
company's larger central switching office. A PBX is a private telephone switch. It is connected
to groups of lines from one or more central offices and to all of the telephones at the location
served by the PBX.
42. PhoneBook [http://wiki.kolmisoft.com/index.php/PhoneBook] – place containing an
alphabetical list of telephone numbers.
43. Prefix - refers to the first digits of a telephone number. These digits are a way to identify
the area that the phone number is located in.
44. Profit [http://en.wikipedia.org/wiki/Profit_(accounting)] - amount expressed as a value that
is left over from sales once all expenses have been deducted.
45. Provider [http://wiki.kolmisoft.com/index.php/MOR_Manual#Providers] – meaning for
VOIP provider. Usually company sells voice traffic.
46. Rate [http://wiki.kolmisoft.com/index.php/Tariffs] – a price for destination.
47. ReCAPTHA [http://www.google.com/recaptcha] – a mechanism which helps to protect
websites from automatic registrations.
48. Recording [http://wiki.kolmisoft.com/index.php/Recordings] – voice file where you can
hear conversation of your customer and remote end (where he called).
49. Registration [http://wiki.kolmisoft.com/index.php/Online_registration] – place in MOR
where new users could register themselves without help from MOR admin.
50. Rerating [http://wiki.kolmisoft.com/index.php/CDR_Rerating] – recalculation of the call's
price which is already recorded.
Kolmisoft 2006-2012
16
51. Reseller Addon [http://wiki.kolmisoft.com/index.php/Reseller_Addon] – this addon
incorporates basic reseller functionality support into MOR system which adds opportunity
MOR system owner have reseller support.
52. Retail tariff [http://wiki.kolmisoft.com/index.php/Advanced_Rates] – with retail tariff there
is possibility get more control of how call will be billed, let say make first 15 seconds of call
free.
53. Router [http://en.wikipedia.org/wiki/Router] - a device that forwards data packets from
one local area network (LAN) or wide area network (WAN) to another. Poorly configured
device also leads to voice and traffic problems.
54. Service - product which can be sold to the client. That can be various types of services. For
example: monthly fee, line rent, phone rent, internet plan.
55. Site – your MOR website.
56. SMS Addon [http://wiki.kolmisoft.com/index.php/SMS_Addon] – this addon adds SMS
sending option through and from MOR.
57. SSH [http://en.wikipedia.org/wiki/Secure_Shell] – secure shell for completely controlling
server from remote location.
58. Subscription - users can subscribe for some services. When they do so – they get
Subscription for some service.
59. Supplier [http://wiki.kolmisoft.com/index.php/Providers] – see meaning of Provider.
60. Terminate – end call in specified end.
61. Terminator [http://wiki.kolmisoft.com/index.php/Providers] – a final destination point
where call be terminated.
62. Trunk [http://wiki.kolmisoft.com/index.php/Trunks] - other server/PBX which can be
connected to the MOR system.
63. User [http://wiki.kolmisoft.com/index.php/Users] – your customer.
64. Voicemail [http://wiki.kolmisoft.com/index.php/Voicemail] - Voicemail (or voice mail,
voicemail, vmail or VMS, sometimes called message bank is a centralized system of
managing telephone messages for a large group of people. The term is also used more
broadly, to denote any system of conveying voice message, including the answering machine.
65. VOIP [http://en.wikipedia.org/wiki/VOIP] - general term for a family of
transmission technologies for delivery of voice communications over IP networks such
as the Internet or other packet-switched networks.
66. Voucher [http://wiki.kolmisoft.com/index.php/Vouchers] – this function allows to enter
voucher number over phone and top up user's balance.
67. Web callback [http://wiki.kolmisoft.com/index.php/WEB_Callback] - technology where a
person can enter his or her telephone number in a form on a web site.
68. Wholesale tariff [http://wiki.kolmisoft.com/index.php/Wholesale_Tariff] – in wholesale
tariff you can set price for each prefix, while in retail you cannot, but retail has its own
advantages.
69. ZAP/Zaptel series of drivers for telephony hardware devices (later renamed to DAHDI).
Kolmisoft 2006-2012
17
Billing Concepts
This section deals with the billing system. It breaks down the actual call-flow from user to
Provider(s).
The billing system is quite complex and there are a lot of concepts to grasp.
There are a number of main categories of billing in MOR. The most important are:
Providers
Least Cost Route (LCR)
Directions
Destinations
Rates
Tariffs
Users
Devices
Providers - In the old PSTN world, these were called Trunks. They are your routes to the
outside world (out of your VoIP network). Providers can be of several types: Zap, SIP, IAX2,
and H323. The type determines which technology is used to connect to the Provider.
Least Cost Route (LCR) - LCR describes how calls may go through several Providers and the
order in which they go. The order can be determined by the call route's price, quality or
manual priority.
Directions - This term refers to countries, or perhaps to satellite networks. It simply describes
the direction in which the call is routed.
Destinations - Destinations are the specific steps that make up the course of the call. Let's
say we are dialing number 37068547771. From this number, MOR knows that the Direction is
Lithuania, and the Destination is the mobile network Bite. Destinations are determined by
Prefix, and each destination has a unique Prefix. The Prefix in this example is 370685.
Rates - These are the prices for the Destinations. They have many properties, which
determine they way they are calculated.
Tariffs - These are groups of Rates. Sometimes they are called Price Lists.
Kolmisoft 2006-2012
18
Users - This term refers to the actual user of the system – the client who dials out or receives
calls. ―User‖ may represent a single person or a whole company, but it is main unit in the
system. Most of the settings are associated with Users.
Devices - Each user can have many devices. A device represents the end-point to which voice
traffic should be sent. For example, a device might be a:
VoIP phone
VoIP softphone
PSTN phone (connected through FXS port).
Billing Logic
In order to use MOR successfully for dialing out and billing, some rules must be followed.
This example provides only a basic illustration of how the billing system works. The whole
process in MOR is much more complex.
Kolmisoft 2006-2012
19
Call explained
Duration - the time from when the caller enters the number until the end of the call.
Billsec - the time from when the callee answers until the end of the call.
Kolmisoft 2006-2012
20
E.164
What is an E.164 format number? In short, it's a number without an international prefix that
starts with the country code. For further details, check Wikipedia
[http://en.wikipedia.org/wiki/E.164].
Every destination inside MOR should be in the E.164 format. That is one of the most
important rules of MOR. If the destination is not in the E.164 format, it can't be billed
correctly.
All DIDs in MOR should also be in this format. Do not include international prefixes for DIDs.
Enter them in E.164 format.
In Australia, for instance, the local number 08 6311 3000 would be converted under E.164 to
61863113000. More information on how MOR works with E.164 can be found at Number
Manipulation.
Rounding
Rounding in MOR GUI is done only when showing the final result.
Values are not rounded in the database. Why not? For example: 0.027 + 0.027 = 0.054.
Rounded, this comes to 0.05. But if you are rounding each step, then you get: 0.03 + 0.03 =
0.06. This figure is not so accurate as 0.05.
Multi-Tax system
All prices and rates in MOR are without TAXES. That's a rule. Each user has a TAX percent. The
user is charged by this TAX percent when he makes payments or views his rates.
The Multi-Tax system provides for several taxes in the final reports for users.
Kolmisoft 2006-2012
21
Compound Tax and Simple Tax
Let's say we have taxes T1, T2, T3 and T4. And some amount without tax, X.
When Compound tax is checked, multiple taxes are calculated in following way:
SUBTOTAL 3.99
TAX1: 18%
TAX2: 15%
in digits:
(SUBTOTAL + TAX1) = 3.99 + 18% = 3.99 + 3.99 / 100 * 18 = 3.99 * 1.18 = 4.7082
(SUBTOTAL + TAX1) + TAX2 = 4.7082 + 15% = 4.7082 + 4.7082 / 100 * 15 = 4.7082 +
0.70623 = 4.7082 * 1.15 = 5.41443
Amount with Compound tax = 5.41443
in digits:
SUBTOTAL + (TAX1 + TAX2) = 3.99 + (18% + 15%) = 3.99 + 33% = 3.99 + 3.99 / 100 * 33 =
3.99 + 1.3167 = 3.99 * 1.33 = 5.3067
Amount with Simple tax = 5.3067
Kolmisoft 2006-2012
22
Example for Canada
As an example we can take Canada, which has GST and PST taxes that should be shown on
invoices, reports, and so on:
Kolmisoft 2006-2012
23
If you change taxes, you can assign this to all Users/Calling Cards by pressing the buttons
below:
What is a PIN?
Description
Calling Cards
An example of how a PIN is used in Calling Cards can be found here: Calling Card logic.
Kolmisoft 2006-2012
24
ASR/ACD
ASR - Answer-Seizure Ratio
The Answer-Seizure Ratio (ASR) is calculated by dividing the number of successfully answered
calls by the total number of calls attempted, which are known as "seizures". Since busy signals
and other rejections by the called number count as call failures, the calculated ASR value can
vary depending on user behavior. (http://www.voip-info.org/wiki/view/ASR)
The Average Call Duration (ACD) is calculated by taking the sum of billable seconds (billsec)
of answered calls and dividing it by the number of these answered calls.
In other words:
Margin = PROFIT's part in the SELL price, or the part profit makes up in the sell price.
Markup = the increase from the BUY price to the SELL price, or how much the SELL
price has increased from the BUY price, in percent.
Kolmisoft 2006-2012
25
What are callgroups and pickupgroups
Letting someone else answer a call
In the mgcp, SIP, IAX, and Asterisk Skinny Channels and in the zapata channels, you can
define call and pickup groups for phones. Note that call pickup typically only works WITHIN a
technology, e.g. from a SIP phone to a SIP phone, and not ACROSS technologies, e.g. from a
SIP phone to an IAX phone.
callgroup=1
pickupgroup=1-9,13
A common misconception
Callgroups are not intended to call a group of phones. All a callgroup entry does is help
define who is permitted to perform a pick-up for particular calls.
Call pick-up is the function that allows a user to pick up his phone, enter a predefined
number, and take a call from another phone that is currently ringing. It is useful in situations
when somebody has called your colleague and you do not want to jump up from your desk
and run to his desk in order to answer his phone. Instead you pick up your own phone, enter
the predefined number, and take the call on your own phone.
Kolmisoft 2006-2012
26
Balance and Credit
Description
There are two fields that describe the money situation for the user: balance and credit.
These fields act differently and have a slightly different meaning for postpaid and prepaid
users.
Postpaid users
< 0 – the user owes you money for your services. He will get an invoice at the end of
the month, and when he pays that invoice, his balance will increase.
> 0 – the user has overpaid you (you owe the user).
== 0 – nobody owes anything to anyone (this is usual when the user is new or has just
paid his invoice and has not yet made further calls or used other services).
> 0 – the user can make calls and use other services until he reaches credit, e.g. if his
credit = 10 USD, he can make calls (and use other services) to a total amount of 10
USD. His balance starts at 0 and goes down to -10 USD. When the balance reaches -10
USD, the user will not be able to make any more calls.
== ∞ - the user can make unlimited calls and use any service without restriction. All
the charges will be included in the invoice.
Kolmisoft 2006-2012
27
Prepaid users
The balance for prepaid users should ALWAYS be more than zero. Otherwise, the prepaid
user will be unable to dial-out.
Note: balance and credit are set for users, not devices. For example, if a user has several
devices and his balance/credit does not allow him to make any more calls, he will be unable
to use any of his devices.
Local Calls
Description
A Local Call is a call made when a device which is connected directly to the system dials the
extension of another device connected directly to the system.
Kolmisoft 2006-2012
28
Billing
MOR does not serve local calls when users are using extensions, so no reports are available to
see such calls.
If one user dials another user using DID, then it is possible to see reports about such calls.
The same applies to billing local calls. If one extension dials another using DID, then it is
possible to bill such a call.
Use Extension (of another Local Device) to dial another Local Device. Extension can be found
in this Device's Edit window.
It is also visible on softphone or VoIP phone screen usually (if this Device is registered to the
Asterisk server).
See also
Sip poke noanswer: Peer 'XXX' is now UNREACHABLE!
Kolmisoft 2006-2012
29
Prepaid Logic
Explanation
In /etc/asterisk/mor.conf value, frozen_time describes the maximum time for calls by prepaid
users.
When a user makes a call, his balance is frozen by the amount which is necessary to make the
maximum length of the call (frozen_time).
If the user talks for less time, his part of the balance is unfrozen and the correct amount is
deducted.
If the user talks for a time which is equal to frozen_time, then his call ends automatically after
the frozen_time minutes are up.
Example
/etc/asterisk/mor.conf frozen_time = 3
When the user makes a second call to Lithuania MOB (the first call is in progress):
MOR freezes the remaining 2 EUR from the user's unfrozen balance.
Now the user has 8 EUR frozen balance and 0 left as unfrozen.
The call limit for this call is 10 min (2 EUR / 0.2 EUR/min).
Kolmisoft 2006-2012
30
When the user makes a third call to Lithuania MOB (the first and second calls are in progress):
The call is dropped because there is no free balance to cover the call.
When the user hangs up his first call, let's say after 12 minutes:
If the user hangs up his second call, say with a length of 9 minutes and there is no fourth call,
we have this situation:
If the user talks for 10 minutes in the second call, this call is automatically ended by the
system.
This logic prevents any loss to the system owner. It applies stricter rules, but this pays off in
the long run.
Special case
When only one simultaneous call is allowed for the device and/or user (Call Limit = 1), then
frozen_balance is not used.
Example #1: If User/Device is limited to only one call at a time, he can use all his remaining
balance for the call (if the user is prepaid).
NOTE: Two hours is the hardcoded call limit for all calls. Even if the balance allows longer
calls than two hours, the call will still be limited to two hours.
If the user has Call Limit not 1, but his one device (D1) has Call Limit == 1 and another device
(D2) Call Limit not 1, then device D1 will be able to make 1 simm. call two hours in duration,
Kolmisoft 2006-2012
31
and ONLY if the balance is sufficient to cover for frozen_time. Device D2 calls will be limited
to frozen_time.
Calling Card calls are always limited to one call - that is, a calling card can make only one call
(for whole available balance) at a time.
Questions
Q. What would happen if a user has a balance lower than the cost of a "maximum duration"
call?
A. The user will be allowed to talk only for the time that is covered by his balance. Example:
maximum duration = 2 hours. If a user has enough balance for one hour, his call will be
limited to one hour. After one hour, his call will end (the system will terminate it) and you will
not take any loss.
See also
Hangupcause Codes
MOR authorize: Balance too low for more simultaneous calls!
Authentication
There are two types of authentication in MOR: IP authentication, and using login and
password.
IP authentication means accepting calls from a given IP automatically, without requesting any
additional login data.
To use login and password authentication, the sender needs to register his phone or pbx to
MOR before sending calls, otherwise MOR will reject them.
Note: IP and login/password authentication cannot work together for the same device
or provider.
Kolmisoft 2006-2012
32
IP Authentication
This example shows how to configure device to use IP Authentication. Important parts are
marked in RED:
Kolmisoft 2006-2012
33
Fax over VoIP
Fax over VoIP is not reliable and does not work most of the time.
The T38 protocol is supposed to work reliable over VoIP, but the problems with this protocol
are following:
See also
Send Receive Fax over T38
Fax is not received
I have a problem with Fax
Configuration
mor.conf
This file is in /etc/asterisk/ and describes some values for the app_mor.so application, which
is the main MOR core working in the Asterisk environment.
hostname, dbname, user, password, port, sock – All these values describe
connections to the database.
Kolmisoft 2006-2012
34
min_frozen – Minimum credit left to allow simultaneous calls. If the user's balance is
lower, he will not be able to make simultaneous calls (default 10); Not used starting
from MOR 0.7.
frozen_time – How much balance to be frozen in terms of minutes if the user is
prepaid (default 30). If the user makes several simultaneous calls and is prepaid, we
need to "freeze― some amount to be safe. A more detailed explanation is in Prepaid
Logic.
show_notice, show_warning, show_error – Sets debug level for the app_mor.so
application in Asterisk CLI.
zap_change – Change ZAP into something else in Asterisk to permit the use of some
custom-made channels based on Zaptel.
server_id – Unique number for server identification.
active_calls – Tells app_mor.so to update info to DB related to calls currently on the
system.
dial_out_settings – Global settings for Dial() command in Asterisk (rTt or similar).
serial – Serial key for activating app_mor.so.
use_lcr_partials - Should MOR be able to use LCR by destinations? Default 1.
global_call_timeout - Global timeout for calls in seconds, default 7200 seconds (2h).
check_banned_clis - Should MOR check for banned CLIs? Default 1, Enables/Disables
ANI/CLI ban system (available from MOR 8).
use_flat_rates - Should MOR use Flat-Rates, default 1.
use_speed_dials - Should Speed Dials be enabled.
server_ip - external server IP, default 127.0.0.1 (Used in P-Asserted-Identity).
play_hgc_audio - Should we play audio with error message when call fails? (default 0
if not set).
o If it is equal to 1, then sound files will be played for error codes 200 and higher
o If it is equal to 2, then sound files will be played for ALL error codes (sound files
for these error codes are not included into MOR) (This option is available
starting from MOR 10.)
In order to activate changes made to this file, you need to restart Asterisk or reload
app_mor.so
Reload app_mor.so
Kolmisoft 2006-2012
35
See also
You can find this menu in SETTINGS –> Setup –> Settings
Global
Kolmisoft 2006-2012
36
Registration
See also
Default user
Invoices
Settings
Details
Address format – changes field positioning in the invoice for the address.
Address line 1-4 – address info.
Bank details line 1-5 – bank details info.
Invoice balance line - line for balance (e.g. "Your current balance is")
Invoice to pay Line
End title – a title for the end of your invoice.
Additional
Show additional details on separate page - enables additional custom page at the
end of the invoice.
Additional details - the information to be displayed in a custom page at the end of
the invoice.
WEB Callback
Kolmisoft 2006-2012
38
Emails
Sending enabled – if this is checked, you will be able to use Mass Mailing and the
system will send emails upon user registration.
SMTP server – hostname of the server.
Port - port of SMTP server.
Login – username to your SMTP server.
Password – password to your SMTP server.
Batch size – value for Mass Mailing, oe how many emails to send at once.
From - email address to put into From: field in email.
Test email sending - save settings and press this to test email sending. Do not forget
to save settings first!
P.S. Remember to set admin's e-mail in admin's personal settings. Without this
test email sending will not work!
See also
Mass Emails
Email variables
Various
Days for DID to close - how long to keep DID closed before making it free.
Agreement number length - number length in digits.
Change Zap - Sometimes this is used to change "Zap" to something else in GUI, e.g.
to "PSTN", mainly because not everybody knows what Zap stands for. PSTN is more
common.
Device PIN length - length for automatically generated PIN codes for devices.
Device range MIN - from which extension automatic extension assigning starts.
Device range MAX - till which extension automatic extension assigning goes.
o For example, from this interval: [Device range MIN, Device range MAX] MOR will
select extensions for newly created Devices.
Kolmisoft 2006-2012
39
User wholesale tariff enabled - enables user wholesale tariffs.
Allow devices to check balance over HTTP
Allow devices to check rate over HTTP
Play IVR for unauthenticated call
Banned CLIs default IVR - default IVR to route banned numbers.
Do not allow duplicate device user names
Do not allow users to change their email addresses
Allow short passwords in devices
Do not allow prepaid user balance drop below zero
Logout link - a user will be redirected to this link after pressing "Logout"
Change ANSWER to FAILED if HGC not equal to 16 for Users - changes the
Hangupcause for users in call reports from Answered to Failed if Hangupcause is not
16.
Tax
Google Maps
Fullscreen - should we show Google Maps in full-screen (for example, remove the
menu from the template)?
Reload Time - how often to refresh in seconds
Width - width for the GMaps window in pixels
Height - height for the GMaps window in pixels
Key - GMaps key.
o Instructions on how to get it here.
o More about Google Maps integration.
Kolmisoft 2006-2012
40
Backups
API
See also
MOR API
Functionality
FAX
Kolmisoft 2006-2012
41
CSV
CSV Column Separator - how columns are separated in imported/exported CSV files.
CSV Decimal Separator - how decimal parts in numbers are separated in
imported/exported CSV files.
Archive CSV file when size reaches - if CSV file reaches a certain size, the system will
archive it to save time to download it (0 means to archive always)
Active Calls
How many maximum Active Calls to show in GUI - how many Active Calls to show
in GUI
Active Calls refresh interval - Active Calls refresh interval in seconds
Show Active Calls for Users - tick if you want to allow users to see Active Calls
Show Servers in Active Calls
Tariffs/Rates
Show rates for users - tick if you want to allow users to see rates
Show rates without Tax - tick if you want to see rates without TAX
Show Advanced Rates for users - tick if you want to allow users to see Advanced
Rates
Privacy
Kolmisoft 2006-2012
42
Visual
Items per page - the number of items to display per one page
Default date format - System default time format
Number digits - how many digits to display after a comma
Hide Quick Stats - hide Quick stats from start page
Hide device passwords for users - do not display device passwords for users
Hide HELP banner - hide HELP banner in GUI
Hide "I want to" help links
Hide "Manual" link - hides "Manual" link
Show logo on first page - unselect to hide logo on the start page
Show Full Source (CallerID Name and Number)
Hide payment options for postpaid users
Show advanced Device settings
Hide non-completed payments for user - hides non-completed payments (the ones
which are started in MOR, but are not completed in a payment gateway website)
Show only main page - this is a very advanced feature for those who want to hide
default MOR menu tree on the left so that they could build their own menu using
advanced techniques without modifying MOR GUI sources.
Hide Recordings for all users - hides recordings for all system users from menu and
device settings.
Show only main page - this is a very advanced feature for those who want to hide
default MOR menu tree on the left so that they could build their own menu using
advanced techniques without modifying MOR GUI sources.
Hide Recordings for all users - hides recordings for all system users from menu and
device settings.
ReCAPTCHA
Kolmisoft 2006-2012
43
can read distorted text as well as humans can, so bots cannot navigate sites protected by
CAPTCHAs.
Implementation in MOR
Kolmisoft 2006-2012
44
Here enter your domain name, or your IP if you do not have a domain - for example:
http://22.33.44.55 (put your IP here! Do not leave support.kolmisoft.com or 22.33.44.55 <-
these are just examples!)
Kolmisoft 2006-2012
45
Copy-paste these keys into MOR configuration:
Kolmisoft 2006-2012
46
Now, on the registration page, the user should enter valid words to complete registration.
Kolmisoft 2006-2012
47
Payments configuration
Vouchers
Kolmisoft 2006-2012
48
PayPal
Kolmisoft 2006-2012
49
WebMoney
Kolmisoft 2006-2012
50
LinkPoint
Enabled – yes or no
Test – testing mode
Allow HTTP requests – yes or no
LinkPoint StoreID – enter LinkPoint StoreID
LinkPoint Currency – select currency
Default Amount - amount to show for customer when he tries to enter payment. User can
change this amount.
Min. Amount - the minimum amount a user can send you.
Kolmisoft 2006-2012
51
Cyberplat
Kolmisoft 2006-2012
52
Ouroboros
Kolmisoft 2006-2012
53
Default device settings
About
This means that if you enter some special settings here and later go on to create a new device
for a user, the device will have these settings preset.
Kolmisoft 2006-2012
54
Default values of Default Device
Kolmisoft 2006-2012
55
Default user
What is Default User settings?
These are the default settings which are applied to all new users.
Default user settings can be found in SETTING -> Setup -> Settings -> Default User
For more details about available options in default user settings please refer to user details.
Kolmisoft 2006-2012
56
Accountant permissions
Description
It is possible to allow them to make some changes to the system by changing their
permissions.
Accountant Groups
Kolmisoft 2006-2012
57
Create permissions:
Kolmisoft 2006-2012
58
Create Accountants and assign them to an Acc. Group.
Logo change
What is a LOGO?
LOGO (shortcut of "logotype") is a picture that represents your company. For more
information see logotype.
Kolmisoft 2006-2012
59
How to change a LOGO?
You can do this by clicking Choose file, navigating to the file in your operating system and
pressing Upload logo.
See also
Custom Reseller Login page LOGO
Currencies
SETTINGS -> Setup -> Settings -> Currencies
Default Currency
It is necessary to decide in which currency the software will operate and set such currency as
the default before starting to work with the software.
That means that all operations inside MOR will be done in this default currency.
Kolmisoft 2006-2012
60
You can fin a video which demonstrates how to change the default currency here
[http://wiki.kolmisoft.com/index.php/Currencies]
Currencies window
The first one is the default and the most important currency.
Exchange rate is equal to Default Currency DIVIDED BY some other currency, e.g. EUR
Exchange rate when Default Currency is USD is equal (in 2009-03-24) 0.7351, e.g.
USD/EUR.
Last Update is for informational purposes.
Active? - shows if this Currency is used in GUI (to create Tariffs, Payments, view Stats,
etc).
Update? - if checked, this currency (its exchange rate) will be updated from
finances.yahoo.com at midnight.
Yahoo - update this currency (its exchange rate) from finances.yahoo.com right now.
Edit - this option is accessible when Update? is OFF. You can then enter Exchange
Rate manually for this currency.
Update currencies from web - updates all currencies marked as to be updated from
the web.
Add/Remove Currency
You can add own currency - just make sure it is not in the list already.
To add a currency, fill data at the bottom of the Currencies table and click the Add icon.
For a newly added currency, you will need to set the Exchange Rate manually. Updating from
Yahoo is not possible.
A manually added currency can be deleted, that is, removed from MOR.
Kolmisoft 2006-2012
61
Default supported currencies
These currencies are in MOR by default and can be updated automatically from
finances.yahoo.com.
USD United States dollar FJD Fiji Dollar NZD New Zealand Dollar
EUR Euro FIM Finnish Markka NIO Nicaraguan Cordoba
XAF Cameroon CFA Franc BEAC FRF French Franc NGN Nigerian Naira
ALL Albanian Lek GMD Gambia Dalasi NOK Norwegian Krone
DZD Algerian Dinar DEM German Mark OMR Oman Rial
ARS Argentinian Peso GHC Ghanaian Cedi PKR Pakistani Rupee
AWG Aruban Florin GIP Gibraltar Pound PGK Papua New Guinea Kina
AUD Australian Dollar GRD Greek Drachma PEN Peruvian Sol
ATS Austrian Schilling GTQ Guatemala Quetzal PHP Philippines Peso
BHD Bahraini Dinar GNF Guinea Franc PLN Polish Zloty
BDT Bangladesh Taka GYD Guyana Dollar PTE Portuguese Escudo
BBD Barbados Dollar HTG Haitian Gourde QAR Qatari Rial
BEF Belgian Franc HNL Honduras Lempira CNY Renminbi Yuan
BZD Belize Dollar HKD Hong Kong Dollar ROL Romanian Leu
BMD Bermuda Dollar HUF Hungarian Forint RUB Russian Ruble
BTN Bhutan Ngultrum ISK Iceland Krona SBD Solomon Islands Dollar
BOB Bolivian Boliviano INR Indian Rupee STD Sao Tome & Principe
BWP Botswana Pula IDR Indonesian Rupiah Dobra
BRL Brazilian Real IEP Irish Punt SAR Saudi Arabian Riyal
GBP British Pound ILS Israeli Shekel SCR Seychelles Rupee
BND Brunei Dollar ITL Italian Lira SLL Sierra Leone Leone
BGN Bulgarian Lev JMD Jamaican Dollar SGD Singapore Dollar
KHR Cambodian Riel JPY Japanese Yen SKK Slovak Koruna
CAD Canadian Dollar JOD Jordanian Dinar SIT Slovenian Tolar
CVE Cape Verde Escudo KES Kenyan Shilling ZAR South African Rand
KYD Cayman Islands Dollar KWD Kuwaiti Dinar KRW South Korean Won
BCEAO CFA Franc LAK Laos Kip ESP Spanish Peseta
XOF CFA Franc LVL Latvian Lats LKR Sri Lanka Rupee
BEAC CFA Franc LBP Lebanese Pound SHP St. Helena Pound
XPF CFP Franc LSL Lesotho Loti SDD Sudanese Dinar
CLP Chilean Peso LTL Lithuanian Litas SRG Surinam Guilder
COP Colombian Peso MGF Malagasy Franc SZL Swaziland Lilangeni
KMF Comoros Franc MWK Malawi Kwacha SEK Swedish Krona
CRC Costa Rican Colon MYR Malaysian Ringgit CHF Swiss Franc
HRK Croatian Kuna MVR Maldives Rufiyan SYP Syria Pound
CUP Cuban Peso MTL Maltese Pound TWD Taiwan New Dollar
CYP Cypriot Pound MRO Mauritania Ouguiya TZS Tanzanian Shilling
CZK Czech Koruna MUR Mauritius Rupee THB Thai Baht
DKK Danish Krone MXN Mexican Peso TOP Tonga Isl Paanga
DJF Djibouti Franc MNT Mongolian Tugrik TTD Trinidad Dollar
DOP Dominican Peso MAD Moroccan Dirham TND Tunisian Dinar
NLG Dutch Guilder MZM Mozambique Metical TRL Turkish Lira
XCD East Caribbean Dollar MMK Myanmar Kyat UGX Ugandan Shilling
EGP Egyptian Pound NAD Namibian Dollar UAH Ukraine Hryvnia
SVC El Salvador Colon NPR Nepal Rupee AED United Arab Emirates
EEK Estonian Kroon ANG Netherlands Antilles Dirham
ETB Ethiopian Birr Guilder VUV Vanuatu Vatu
Kolmisoft 2006-2012
62
VEB Venezuelan Bolivar WST Western Samoa Tala ZWD Zimbabwean Dollar
VND Vietnam Dong ZMK Zambia Kwacha
Translations
If you want to change the translation of the MOR GUI, you can click on the selected flag in
the upper right corner of the window.
In order to manage Translations of the MOR, you should go to SETTINGS –> Setup –>
Settings -> Translations.
Here you will see a window with all the available translations.
In the first column, you can Drag & Drop a translation to its new place. This column is
dedicated to managing the order of translations.
The second column is for activating/deactivating translations. Simply click on the desired
translation to activate/deactivate it. When disabled, it is grayed out.
If you want to see changes instantly, click the icon at the bottom. The page will be reloaded
and you will not need to logout/login to see the changed translation order in the upper right
corner of your window, where translations are represented as flags.
The first translation is the DEFAULT translation. If you want to change the default translation,
Drag&Drop the other translation to the very top of the translations list.
The default translation is the translation that is active when the user comes to the page for
the first time.
You can find a video which shows you how to change the default translation here
[http://wiki.kolmisoft.com/index.php/Translations]
See also
MOR GUI Translation
Change flag for translation
Kolmisoft 2006-2012
63
Global date format
Global date format can be easily changed in SETTINGS -> Setup -> Settings -> Visual.
To change the date format select it from Default Date Format drop-down menu.
P.S. Don't forget to save settings by pressing the Save changes button
See also
GUI configuration
More info about date formats on Wikipedia
Kolmisoft 2006-2012
64
Remove Manual link from admin GUI
What is a Manual link in MOR?
Manual link opens a MOR MANUAL in Kolmisoft wiki page. This link can be found on the
right bottom:
Voicemail
Description
Voicemail (or voice mail, voice-mail, vmail or VMS, sometimes called messagebank) is a
centralized system of managing telephone messages for a large group of people. The term is
Kolmisoft 2006-2012
65
also used more broadly, to denote any system of conveying voice messages, including the
answering machine. [http://en.wikipedia.org/wiki/Voicemail]
Voicemail is automatically sent to a user's email if the email address is specified in the device
details.
Configuration
This section can be found in SETTINGS –> Billing –> DIDs –> PBX Functions –> VoiceMail:
Kolmisoft 2006-2012
66
VoiceMail Extension (local) - describes which local extensions a local user can dial to
retrieve his voicemail (the system will ask him to enter his voicemail password, which
can be set in the device's details).
If you want to setup VoiceMail (VM) on a different server, then the following settings are
important:
VoiceMail Server active - turns VM server on/off. When on, all VM requests will go to
distant VM server; when off, VM will be handled locally on Asterisk.
VoiceMail Server connection/device - describes connection to VM server.
VoiceMail Retrieve Extension (local) - which extension to dial on a distant VM server
to retrieve voicemail for an extension.
Example:
Let's say we have our server on IP 23.45.67.89 connected with SIP to our Asterisk.
We create a separate user/device (vm_device) to describe this connection. Device's
type is SIP, IP = 23.45.67.89; set other settings also (codecs/etc).
VoiceMail Retrieve Extension (local) = 999.
Kolmisoft 2006-2012
67
First action is when VM is recorded
So now when the VM server is ON and the user with device 201 gets a VM, the call is
redirected like this:
Dial(SIP/vm_device/201)
This means that the server on 23.45.67.89 will receive a call to extension 201. The server
SHOULD BE configured so that it will process VM correctly when it receives such a call.
When user wants to retrieve his VM on a distant machine he dials VoiceMail Extension
(local).
Dial(SIP/vm_device/999#201)
Again, the distant server should know how to process such a request.
[incoming]
# to retrieve VM
exten => _999#.,1,VoiceMailMain(${EXTEN:4})
exten => _999#.,2,Hangup
# to record VM
exten => _X.,1,VoiceMail(${EXTEN})
exten => _X.,2,Hangup
Kolmisoft 2006-2012
68
FROM string
To change the Voicemail email sending FROM field, edit the /etc/asterisk/voicemail.conf file
line:
to:
serveremail
This setting can be used to identify the source of a voicemail notification message.
;serveremail=asterisk
to:
OR:
;serveremail=asterisk@linux-support.net
to
Kolmisoft 2006-2012
69
MWI - Message Waiting Indication
See also
Email settings
Please check Configuration from GUI for information how to setup email sending.
Emails
What are Emails?
This function is used to send emails to your clients. It can be used to send commercials, notes
about service unavailability or anything else – maybe Christmas greetings!
Kolmisoft 2006-2012
70
Where I can find Emails?
Here you see emails which are templates for emails about various system messages. The 'test'
email is created for demo purposes for mass-mailing.
Kolmisoft 2006-2012
71
Next is how to Edit email. Creating email and editing it are very similar processes. Here is
how to edit:
The Name and Subject fields are simple. The most important field is Message text. Here you
enter message for the user. Also, you can use the following variables here:
<%= server_ip %> - Server IP where your users should register their SIP/IAX2 devices.
<%= device_type %> - Used on user registration - shows the device type the user has
selected.
<%= device_username %> - Used on user registration - shows the device's username.
<%= device_password %> - Used on user registration - shows device's password.
<%= login_url %> - GUI login url.
<%= login_username %> - User's username to login to GUI.
<%= login_password %> - User's password to login to GUI.
<%= username %> - same as login_username.
<%= first_name %> - First name of the user.
<%= last_name %> - Last name of the user.
<%= full_name %> - First name and last name of the user.
Click on Change to save any of these variables.
Full list of MOR supported email variables can be found in Email variables page.
Kolmisoft 2006-2012
72
In the main window (SETTINGS –> Setup –> Emails), you can press on icon to select to
which recipients to send this email:
Additional Notes
Email variables
Every email
<%= server_ip %> - server IP where your users should register their SIP/IAX2 devices.
<%= device_type %> - shows the user's primary device type. (The device is set as the
primary device after user registration).
<%= device_username %> - shows the user's primary device username. (The device
is set as the primary device after user registration).
<%= device_password %> - shows the user's primary device password. (The device is
set as the primary device after user registration).
<%= login_url %> - GUI login url.
<%= login_username %> - user's username to login to GUI.
<%= username %> - same as login_username.
<%= first_name %> - first name of the user.
<%= last_name %> - last name of the user.
<%= full_name %> - first name and last name of the user.
<%= balance %> - user's balance.
<%= nice_balance %> - formated user's balance.
Kolmisoft 2006-2012
73
<%= warning_email_balance %> - amount below which user should be warned with
email.
<%= nice_warning_email_balance %> - formated amount below which user should
be warned with email.
<%= currency %> - default system currency's short name (USD).
<%= user_email %> - user's email address.
<%= company_email %> - company email address.
<%= email %> - company email address.
<%= company %> - company title.
<%= primary_device_pin %> - PIN of user's default device. The fault device is created
the moment the user registers, so this variable can be used universally.
After registration
Kolmisoft 2006-2012
74
Example
This template:
Hello, <%=full_name%>
Your balance in MOR has fallen below <%= nice_warning_email_balance %> <%=
currency %> and now is <%= nice_balance %> <%= currency %>.
Please login to <%= login_url %> and replenish it.
Yours sincerely,
KOLMISOFT
Your balance in MOR has fallen below 10.00 USD and now is 5.67 USD.
Please login to http://your_site/billing and replenish it.
Yours sincerely,
KOLMISOFT
Illegal usage
You will get an error when you try to use non-existent variables.
Also, you cannot use something like this: <%= "www.kolmisoft.com" %>
See also
Email Configuration
Mass Emails
Kolmisoft 2006-2012
75
Number Manipulation
Localization
Description
Localization transforms received number to E.164 format number.
The main idea of localization is: No matter how the user dials the number (destination),
when localized it should be in E.164 format.
Localization has nothing in common with numbers you send to providers. It operates with
numbers received from the caller.
Depends on the location of the user (or his device), it is often important to allow users to dial
differently formatted numbers to reach a destination. For this purpose, each device has a field
Location, which describes the physical location of the device and provides rules for how th3
device can dial a destination. In other words each device IS in (or belongs to) some Location
where specific dialing rules apply.
By default, a device has the location Global. Global rules apply to ALL devices. If a user
belongs to some other location and his dialed destination has some rule for his destination,
then global rules are not activated – they have a lower priority in location rules.
You can access Localization settings in SETTINGS –> Billing –> Functions –> Localization.
At first there is only the Global location. You can't delete this location. It's the default for all
devices.
Kolmisoft 2006-2012
76
You can add a new Location by entering this Location's name in the field at the bottom of the
table:
and clicking :
Kolmisoft 2006-2012
77
Tariff - which Tariff to apply when this rule is applied. It is used in special cases, for
example here. Leave this empty in most cases.
LCR - which LCR to apply when this rule is applied. It is used in special cases, example
here. Leave this empty in most cases.
When you have entered all the necessary values (Cut or Add can be left empty), click .
For example:
Rules can be enabled or disabled by clicking the icon or in the Enabled? column.
Kolmisoft 2006-2012
78
click on in the Devices column to access Devices in Global Location:
Here all Devices with a selected location are listed. Choose other locations for the selected
Device and click on icon to activate this change. The device will be assigned to the selected
Location.
NOTE: It's possible to change a device's Location in the Device settings (SETTINGS –> Users
–> Devices).
Now our device belongs to Location "Lithuania Vilnius". And if we dial a mobile number in the
Lithuanian format, for example 863042438, MOR cuts 86 (leaving 3042438) and adds 3706.
The result is: 37063042438, which is E.164 compatible and can be billed correctly by MOR.
NOTE: make sure that after localization your number is always E.164 compatible. Call Tracing
can help you do this.
Kolmisoft 2006-2012
79
Special cases
With rule Cut: *# it is possible to cut everything till # (# included) in the dialed destination:
For example:
This function can be used in fancy MNP (Mobile Number Portability) schemes and perhaps
elsewhere.
NOTE: The Add value still can be used to add any value after Cut is used on the Destination.
Reseller localizations
Starting from MOR 10 reseller is not using admin's global localization rules. Instead now he
can copy the rules and modify them according to his needs. All new created resellers have
those global rules copied automatically from admin.
IMPORTANT: Fields "Change User Tariff to this Tariff" and "Change User LCR to this LCR" will
not be copied.
Kolmisoft 2006-2012
80
Default location does not act as Global location on reseller's account. Only the rules set in the
device's settings will be applied.
Route to DID
Admin and Reseller PRO users are can route calls to a DID according to localization rules.
1. Open the localization menu to find the "Change Call's Owner" field.
2. Enter the incoming prefix that needs to be cut in the "Cut" section.
3. Afterwards, choose a user from the drop down list and the device to which the call
should be assigned:
See also
Number Manipulation
Kolmisoft 2006-2012
81
o Provider Rules
o DID handling by Localization
o Number Manipulation Examples
Provider Rules
Provider Rules transforms an E.164-compatible number to any number format the
Provider requires.
Description
Different providers expect different number formats from you. You can send them whatever
they want using Provider Rules.
Provider Rules can be reached by clicking the icon next to a provider in the Providers
window:
We see a similar window as the one in Localization. The rules to manage Provider Rules are
identical to those for Localization management, which are covered in number manipulation
page.
Kolmisoft 2006-2012
82
Let's say our provider expects to get a number with the technical prefix 89765#. We can do
this in following way:
That's it – very simple. Now every number that is sent to this provider will be transformed by
adding our created tech. prefix.
For example, if 37063042438 should be sent to this provider, this rule will be activated and
the number 89765#37063042438 will be sent to provider.
REMINDER: You can check whether Provider Rules are applied correctly in Call Tracing
Special cases
With rule Cut: *# it is possible to cut everything till # (# included) in the dialed destination:
Kolmisoft 2006-2012
83
For example:
This function can be used in fancy MNP (Mobile Number Portability) schemes and perhaps
elsewhere.
NOTE: Add value still can be used to add any value after Cut is used on the Destination.
In this example, all calls going to this Provider will have CallerID = 9999999999
Kolmisoft 2006-2012
84
Destination same as received
If you want to send a number to a Provider exactly as it was received, set Cut = '-' (minus sign
as shown in the screenshot).
That way, the same number that comes to MOR also leaves MOR:
See also
Number Manipulation
o Localization
o DID handling by Localization
o Number Manipulation Examples
Kolmisoft 2006-2012
85
To do this, each Provider also has a Location. This means that Location rules can be created
and applied for the Provider. You can do this in the Provider settings window:
For example, you have DID 37052058393 and the provider sends you 0037052058393. You
need to strip this international prefix with the following rule:
Special case: In some countries when E1 is connected to the server, only the four last digits of
the number reach MOR. Localization should be used here to add the remaining part of the
number.
Kolmisoft 2006-2012
86
See also
Number Manipulation
o Localization
o Provider Rules
o Number Manipulation Examples
Lets say 868555666 is calling to 868777888. The first number is the source (CallerID), and the
other number is the destination. Localization source rules are used to modify the CallerID
which comes to MOR, and provider source rules are used to modify the CallerID that will be
sent to the provider. They aren't used all the time, only when owner of system wants them to
be.
Take, for example, a provider that only accepts calls that are nine numbers in length and that
begin with 8. MOR works only with E.164 standard callerID's if you want to run billing on
them.
First of all, we need to make a Localization source rule for our situation:
So now the caller's number is 3708555666, not 868555666. MOR identifies the caller as being
from Lithuania (by country code 370), which means he can bill him.
Now we need to send a call to 868777888, but our number must be in the old format
(868555666), so we need to apply a suitable provider source rule:
Kolmisoft 2006-2012
87
Examples
Example 1 - Italy
My customers are mainly in Italy. To call Italy, they are not going to add the 0039 country
code, while they do put 00 and the country code when they want to call other countries.
Then, on the other side, my provider aspects numbers to Italy without the 0039 country code,
while to other countries it does aspect the country code before the called number.
NOTES:
The numbers that clients dial are 10 digits in length. For more info about the Italian
number format, see: http://en.wikipedia.org/wiki/%2B39
'+' is not used. It should be changed to '00'.
Localization rules:
Kolmisoft 2006-2012
88
Now the call should be sent to the provider which accepts numbers in following format:
Example 3 - Brasil
Example 4 - Spain
Kolmisoft 2006-2012
89
Block wrong short numbers with Localization
NOTE: Such a rule will route calls to Empty LCR, where they will be dropped.
If you want to allow some short numbers to pass, you need to create more granular rules to
handle your situation.
This example is very strict and is only for demo purposes to illustrate the principle.
Make sure you understand Number Manipulation to proceed with rules for your case.
See also
Number Manipulation
o Localization
o Provider Rules
o DID handling by Localization
o Number Manipulation Examples
Kolmisoft 2006-2012
90
LCR/Tariff change based on call prefix
The main purpose of this function is for calls to be routed through a provider or providers
based on call prefix.
You have to create a provider, tariff, LCR (where the specified provider has to be), and a user
with his device. And most important, the localization rule or rules. It should be applied per
device basis (Device settings -> Location), making sure the specified device has the correct
rule applied. It must be noted that specified rules have higher priority than global rules.
You can find more info on how to make rules in Number Manipulation.
Example
Let’s say we have a provider that provides three quality routes: bad-cheap/normal/good-
expensive.
The bad-cheap route is selected when dialing an E.164 number with prefix 00.
The normal route is dialed when dialing the normal E.164 number.
The good-expensive route is selected when dialing the E.164 number with the prefix
000.
Kolmisoft 2006-2012
91
Create three Tariffs for providers:
o Provider_Tariff_Bad
o Provider_Tariff_Normal
o Provider_Tariff_Good
Enter/Import appropriate rates to these Tariffs.
Assign these Tariffs to providers.
That's it.
Now when the user dials E.164 numbers, he will be using the normal route; when 00, the bad
route; and when 000, the good route.
Kolmisoft 2006-2012
92
Users
User Details
Where to find user details?
Kolmisoft 2006-2012
93
3. You will get into the following menu:
Kolmisoft 2006-2012
94
In this window you will see a lot of user settings.
There are several groups: General, Blocking, Warning Balance Email, Invoices, Payments,
Details, Taxes, Registration Address and Recordings.
General
Username – username for user to login to MOR GUI.
Password – password for user to login to MOR GUI.
User type – by default it is "user".
LCR – LCR indicating which of the user's devices will be used to dial out.
Tariff – prices for the user.
Balance – the user's balance.
Credit – the user's credit, showing how low the user's balance can go.
Minimal Charge for Calls - minimum charge user pays for voice calls.
Minimal Charge for Calls Date - date since when the previous option is valid.
Postpaid/Prepaid – type of user.
Not Hidden/Hidden – is this user hidden?
Primary device – the primary device for this user.
Allow loss calls - should loss calls be allowed for this user?
Call Limit - how many simultaneous calls the user can make?
Warning balance
Description
This function allows a number of actions to be taken when a user's balance drops lower than
the set value.
Kolmisoft 2006-2012
95
Check Active to activate this function.
Upon activation, the user will receive an email when his balance drops lower than the balance
set in the field after: Send email when balance drops lower than.
Additionally, you can play an audio message whenever the user makes a call.
Check Play before every call and select the audio file to play.
Use this with caution - not many users will like this!
User Blocking
Definition
NOTE: the User is still able to receive calls. Unassign DID for him to keep him from receiving
incoming calls.
Direct blocking
Kolmisoft 2006-2012
96
Unconditional blocking
NOTE #1: if you want to block the user in the future, set this date in Block at BUT do not mark
this user as Blocked (if you do so, the block will take effect instantly). The system will mark the
user as Blocked at your selected date.
NOTE #2: If you want to block the user today, just mark the user as Blocked. DO NOT enter
today's date into Block at field - the system will not block it if you do so, because it will not
check until tomorrow 00:00:00.
Conditional blocking
Under this option, select day of the month when to perform check.
Kolmisoft 2006-2012
97
On the day the user is checked, the following questions are asked:
Is he POSTPAID ?
Is his BALANCE < 0 ?
Has he UNPAID INVOICES ?
See also
Monitoring Addon
Blocking
Various options for User Blocking.
If you want to send an email notification to a user (or take another action) when his balance
drops lower than a certain amount, check this setting and enter the desired amount.
Invoices
Kolmisoft 2006-2012
98
Generate Invoice - should we generate an invoice for this user when we choose to
generate invoices for a period?
Invoice, Detailed, By CallerID, By Destinations and PDF/CSV show various types of
invoices which should be sent to the user as an email attachment.
Show zero Calls - if the call price = 0, should such calls appear in the invoice or not?
Payments
Cyberplat - check this option if you want to allow the user to use this payment
gateway.
Details
Self-explanatory.
Taxes
Registration Address
Self-explanatory.
Recordings
This section is available when the Recordings Addon is installed in the system.
Kolmisoft 2006-2012
99
Hide Users
Why should I hide users?
As it is not allowed to delete users who have at least 1 call, after some time such 'non-active'
users accumulate and we need to do something about them to have a clear control panel.
For this reason, we just Hide them. They remain active - nothing changes for them - except
that we do not see them in the GUI.
1. Go to users list:
Kolmisoft 2006-2012
100
Additional Notes
The same icon can be found in user's details. It works the same way.
Also you can hide user by selecting an option Hidden in user's details in General
section
Navigate to Hidden Users list and press the same icon again as in a hide user example
See also
Users
o Create a User and a Device
o Why MOR does not allow to delete users?
o User Details
Block User
o (SECURITY) How to change Admin username and password
Providers
o Hide a Provider
Kolmisoft 2006-2012
101
Why MOR does not allow to delete users
MOR does not allow users to be deleted who have made at least one call (or has at least
1 payment) in the past.
WHY?
P.S. Because of this reason you are also not allowed to delete providers and devices.
Simple example
Let's say we have 2 (TWO) users U1 and U2 and 1 (ONE) provider P1.
During the month, one user U1 dialed 20,000 calls and the other user U2 dialed 10,000.
So user U1 should pay you 20,000 EUR and user U2 should pay you 10,000 EUR. Total 30,000
EUR.
You sell with 100% margin, so that way you have to pay 15,000 EUR to your provider P1 for
the calls.
Imagine now what happens if you delete user U1 from the system with all his calls.
During the month user U2 made calls worth 10,000 EUR and you see that you should pay
provider 50% of that = 5,000 EUR to your provider P1.
BUT!!!! Provider P1 sees that he sent 30,000 EUR worth of calls and not 10,000 as you say. And
these calls are worth 15,000 EUR.
So you will be at -10.000 EUR (MINUS 10.000 EUR) after one month!
Kolmisoft 2006-2012
102
What to do?
Hide users if you don't want to see them any more in your system. Note: currently it's not
possible to hide devices.
Video
This video demonstrates the process WITHOUT setting additional settings. Make sure you
read and understand User Details and Device Settings.
http://wiki.kolmisoft.com/index.php/How_to_create_User_and_Device
See also
Users
Devices
Video
This video demonstrates how to change the Admin username and password (for greater
security).
See also
Users
Kolmisoft 2006-2012
103
MOR forgot user password
What is Forgot Password functionality
This MOR functionality resets current user password and sends it to his email.
Kolmisoft 2006-2012
104
How to use this functionality?
Click Forgot Password and the following input box will ask you for an email.
If the entered email matches with the one that already exists in the system - the password will
be sent.
Requirements
http://wiki.kolmisoft.com/index.php/Configuration_from_GUI#Emails
To set this functionality go to SETTINGS -> Users. Click on the chosen users name and you
will see this window:
Kolmisoft 2006-2012
106
Select Enabled? as shown in the picture. Now you can set the minimum charge and select
since when the setting will be valid. If you can't see those fields it is possible that your chosen
user is prepaid. This feature is only available for postpaid users.
Specialties
If clients total billing is below the set charge he will have to pay the minimum amount
anyway
If clients total billing is above the set charge he will have to pay the whole amount
Minimum time period per which you can set Minimum contract billing is 1 month
Minimum contract billing starts to be valid only since the first day of the month. It
means if today is February 15 and you set Minimum charge for calls date current years
February, client will start to be billed for it since 1st of March anyway.
Can only be applied for postpaid users
Can only be applied for voice calls
An invoice includes the line with the difference between the minimum amount and the
total amount.
Tariffs
Directions and Destinations
About
Directions refers to countries, or perhaps to a satellite network. The term merely describes
the direction in which the call is routed.
Directions can be found in SETTINGS –> Billing –> Directions. You can see all Directions
with their details in the main window.
Destinations - these are more concrete concepts of the calls course. Let's say we are dialing
number 37068547771. From this number MOR knows that the Direction is Lithuania, but the
Destination is the mobile network Bite. Destinations are determined by Prefix. Each
destination has a unique Prefix. The Prefix from the example is 370685.
Kolmisoft 2006-2012
107
Destinations can have several types/codes:
IMPORTANT NOTE: When adding new destinations, make sure you include them in some
Destination Group. Otherwise you will get corrupted invoices if the user uses a retail tariff.
NOTE: You can get a CSV file with all Destinations in the Tariffs window. It is suitable
for rate entering and importing back to MOR.
Destinations Groups
In order to make life easier and to manage prices for destinations, destinations are grouped.
With grouped destinations, one price applies for a group of destinations, rather than for
destinations separately. (A group can contain one destination also.)
Destinations groups are for users, not for providers, because providers need to have very
exact rates for each destination.
You can edit Destination Groups settings in SETTINGS –> Billing –> Directions –> Groups.
HINT: If you want to split a Destination Group, remove all Destinations from it, delete the old
Destination Group, and create new ones. Then add the removed Destinations to the newly
created Destination groups.
Kolmisoft 2006-2012
108
Block some Destination to User
Block Destination to User
Now, when the user dials a number with this prefix (Destination), the call will be routed to the
empty LCR, which is to say it will be dropped.
If you need to block a special prefix (Destination) to all Users, follow these steps:
Kolmisoft 2006-2012
109
2. In Localization Global Rule, add a rule for your prefix and set it to route to Empty LCR:
Now, when the user dials a number with this prefix (Destination), the call will be routed to the
empty LCR, which is to say it will be dropped.
(In this example we are blocking UK numbers starting with 44, change in your system
accordingly).
Bulk management
Starting from MOR 10 you can reassign multiple destinations to other direction by specifying
a regexp pattern:
Kolmisoft 2006-2012
110
3. Enter a prefix regexp which destinations should be reassigned, select a group to assign to
and specify type:
4. Press Reassign
6. If you want to proceed - press Reassign at the bottom of the window again and the
destinations will be reassigned
Kolmisoft 2006-2012
111
MOR supported regexp patters
Examples
Day setup
MOR lets you set different dates for different types of days. There are two types of days: work
days (WD) and free days (FD).
National holidays and other days that do not meet the default settings should be set
manually.
This can be done in SETTINGS –> Billing –> Tariffs –> Day setup:
Kolmisoft 2006-2012
112
Entering Rates for Wholesale Tariff
Description
This method is used to enter rates one by one by hand. It is primarily used for editing rates
because it's very time-consuming to enter thousands of rates by hand. CSV import is also
available for this task.
Click on Rates:
Kolmisoft 2006-2012
113
Click on Details to get more details:
Here you can Split to Work Days and Free Days, delete a rate or Edit it:
Here you can add a different End Time for different rates in a time period and change other
values that are simpler than Advanced Rates.
NOTE: if there are no rates for some destinations, the user will not be able to dial these
destinations using the provider to which the tariff is assigned. This is usual gotcha when call
does not go through – always use Call Tracing if you have problems dialing-out!
Kolmisoft 2006-2012
114
Adding new Rates
It is possible to add Rates using GUI in three different ways. It is also possible to import Rates
using CSV.
New Rate
This way lets you add many rates for selected countries by first letter - for example, for all
Destinations starting with A:
Enter Rates and click the Update button to add the desired Rates.
Kolmisoft 2006-2012
115
Quickly add a new Rate
This way allows you to quickly add a Rate. Fill in the fields (most important
are Prefix and Price). Make sure the software shows you which Destination it is (if it says that
there is no such Destination, you need to create it) and click Add Rate:
This method is similar to previous one except that it allows you to enter rates only to a
selected country (Direction). If a country has all rates already set, it will not let you choose
that country:
Kolmisoft 2006-2012
116
User wholesale tariff
This tariff is used by users and is no different from the provider wholesale tariff. All the
functions are the same. This tariff type can be enabled or disabled in Settings.
When a wholesale tariff type is assigned to the user, he will not be able to see all rates online.
He will be able to download them in PDF or CSV format.
NOTE: you can't have Custom rates for a user if he is using the Wholesale tariff.
Prefix
Price
Kolmisoft 2006-2012
117
Value Separator and Decimal Separator MUST be set correctly in SETTINGS -> Setup ->
Settings -> Functionality:
File and CSV separator settings should match. If they do not, you will get errors when trying
to import file.
Kolmisoft 2006-2012
118
Description
It is very tedious work to add several thousand rates by hand, so you can import them from a
CSV file.
There are seven steps for importing rates from a CSV file:
1. File upload
2. Column assignment
3. Column confirmation
4. Analysis
5. Creating destinations
6. Updating rates
7. Creating new rates
IMPORTANT NOTE: When importing, prefixes should be in E.164 format!!! For example,
no international prefixes!
File upload
Select Import from CSV for the Tariff you want to import rates.
Then click on Browse and select CSV file with rates. Click Upload file:
Kolmisoft 2006-2012
119
Column assignment - wrong separators detected
Sometimes the system is able to detect that CSV separators are wrong and suggests you to
change them:
Column assignment
The file is uploaded and the first five lines of the file are available to check:
Kolmisoft 2006-2012
120
This helps us in the next step, to assign CSV file's columns to MOR's variables. We have the
following window:
Here we must assign columns from the CSV file. Prefix and Rate are mandatory fields. All
other fields can be empty. Connection Fee, Increment and Min. Time have their defaults. If
you wish, you can enter values manually for them. Manually entered values have the
highest priority. If you omit them, then MOR inserts values from the CSV file. If there is
no assigned column for these fields, then default values will be added to database (DB).
There are a group of values under the name USA specifics. These are only for USA/Canada.
Users from these countries need to use these fields with their CSV files.
Kolmisoft 2006-2012
121
In the following example, we select fields which match our CSV file. Also entered are some
manual values for Increment and Min.Time. We count time by 30s increments and minimum
time for the call is 60s, with these settings:
This way of selecting CSV rows and assigning them to MOR values lets us import various CSV
file formats.
It is possible to select to which Day Type rates apply before importing them.
So in two steps it is possible to import separate rates for Work Days and Free Days, or (in a
single step) to import rates for All Days at once.
Kolmisoft 2006-2012
122
Destination name update on rate import
When this option is selected destination name is updated from csv file during rate import
Column confirmation
The next step is to review our selection and confirm that everything is correct. We can go
Back or forward to the next step:
Analysis
It will take some time to accomplish this step. MOR checks many things from DB and CSV
files: it compares rates, searches for duplicates, fixes small errors and so on. After the analysis
is completed, we get something like this:
Kolmisoft 2006-2012
123
The most interesting line is 9 bad destination(s). We click on the List to check them. In the
new window, we can see which destinations are bad and we can decide what to do with them.
Is it possible that there are no directions for them, MOR doesn't know to which country to
assign this destination, or maybe these destinations have duplicates in CSV file? You have to
fix this if you want to import the whole file. Here you can stop and fix your CSV file, or you
can ignore these errors and continue.
The following steps are separated to avoid excessive demands on processing power if a rate
file is huge. This keeps the browser from crashing and allows it to successfully import
160.000+ destinations from one CSV file (this has been tested).
Creating destinations
MOR creates new destinations here. These destinations are necessary for the rates, which will
be added in step 7. This window is just informative, no decisions here:
MOR creates only Destinations for prefixes which are not yet in MOR's DB and determines
whether it is possible to find out the Direction (Country) for these new prefixes (Destinations).
1. The system checks the available prefixes for the best match and selects found Direction as
a basis for the new prefix (Destination).
For example: if you try to import the rate for prefix 370630 and this prefix is unknown to
MOR, MOR checks the longest matching prefix - 3706 in this case - and finds out that it is
Lithuania MOB. So it creates a new Destination with Prefix 370630 in which the Direction will
be Lithuania and the subcode MOB (mobile network).
2. If Country code is available in the imported file, MOR assigns this Direction to the newly
created Destination.
Kolmisoft 2006-2012
124
For example: if again you try to import 370630 and it is unknown to MOR, but you have LTU
in same CSV line for Country Code field, MOR will create such a Destination with Direction =
Lithuania.
Updating rates
Here MOR updates rates with the values from CSV files. These rates already exist in DB. Just
click Proceed:
Kolmisoft 2006-2012
125
NOTES
If there are a lot of rates, please be patient and let MOR finish its job. It may take some time
to count everything and come back to life.
At some point it may seem that browser is not responding. That is not the case – it is just
working very hard, importing your very own rates from the CSV file.
If you get a timeout error, try to import the file in smaller pieces.
When importing rates from the CSV file, you can check which Destinations will be created
automatically.
You can view them in a separate window when you click List in step 4 in the field
"Destinations to create".
Such destinations do not exist in MOR's database but MOR will create them when importing
the rate file.
Example Videos
http://wiki.kolmisoft.com/index.php/Rate_import_from_CSV#Example_Videos
See also
Good CSV rate file examples
Bad CSV rate file examples
Kolmisoft 2006-2012
126
Wholesale Tariff
What is a Wholesale Tariff?
This tariff is a price list which you get from your provider, later you can transform this tariff
into retail or user wholesale tariffs. Without a transformation this tariff cannot be assigned to
user.
Min Time
Min(imal) Time is the minimum time that will be billed if a call is answered.
For example:
1 10
2 10
... 10
9 10
10 10
11 11
Kolmisoft 2006-2012
127
Increment
Then:
If the increment is 1, then the call length will be counted as 15s and the call price will
be 0.25 EUR (1/60*15). As the increment is 1, the call can be 1, 2, 3... in length. 15s is
the exact length of the call.
If the increment is 10, then the call length will be counted as 20s and the call price will
be 0.333 EUR (1/60*20). As the increment is 10, the call can be 10, 20, 30... in length.
20s is nearest to 15.
If the increment is 20, then the call length will be counted as 20s and the call price will
be 0.333 EUR (1/60*20). As the increment is 20, the call can be 20, 40, 60... in length.
20s is nearest to 15.
See also
Tariffs
Kolmisoft 2006-2012
128
Entering Rates for Retail Tariff
In order to manage rates for Retail Tariff, click the Rates next to Tariff:
Here you can enter Rate and Round by values for every rate. If you finished entering what you
want, click Update at the bottom of the page. All rates will be updated.
View shows you the Destinations which belongs to this particular group.
Here you can click on Split to Work Days and Free Days to split the rate into two parts - for
Work Days and Free Days.
Now we have control over different types of days: Work Days and Free Days. We can enter
different rates for these days.
We can also set different rates for different times in the day. For this, we need to create hour
intervals. To do so, select a time in the column End Time and click on .
And here you should add/edit/delete Advanced rates as described in Advanced Rates.
Kolmisoft 2006-2012
129
Advanced Rates for Users
Make sure they will understand them before showing these Rates to Users.
In SETTINGS –> Setup –> Settings –> Functionality check Show rates for users and Show
Advanced Rates for users settings
Kolmisoft 2006-2012
130
Advanced Rates
Description
Please see video below where to find and edit advanced rates.
In order to manage rates for destinations more easily, destinations are grouped, so that one
rate applies for a group of destinations, not for one destination separately. (A Group can
contain only one destination if necessary.) Destinations groups are for users, not providers,
because providers need to have very exact rates for every destination.
Each rate for a destination group may have many rate details. This means: a destination
group may have one rate, but this rate has many rate details (sub-rates). Each rate detail
describes one interval of the call. If the first rate detail is RD1, the second is RD2, and so on,
all calls can be expressed as RD1 + RD2 + .. + RDn. The number is finite. The rate detail can
be seen as the time intervals for all call durations. The time interval could also be zero length.
It is explained further below.
The type 'minute' describes an interval that lasts some time. This time is billed by rate and
rounded accordingly. An Interval starts at FROM and lasts for DURATION seconds. The type
'event' describes a zero-length interval, which we call EVENT. This might, for example, be a
connection fee. If the type is 'event', the rate detail has no DURATION (it's always zero) or
ROUND BY fields.
The call should have 0.2 connection fee (regardless of the currency) and all other time must
be billed by 6-second intervals with a rate of 0.1 per minute. Such a rate should be described
like this:
Example #2
The first 30 seconds of the call cost 0.1, the next time till 5 minutes is billed at rate 0.05
rounded by 30 seconds, and the remaining time is billed by rate 0.02 and rounded by 1
second.
Kolmisoft 2006-2012
132
Example #3
The rate for the call is 0.01 per minute rounded by 1s. The maximum price for call is 0.1.
Example #4
The rate for the call is 0.01 per minute rounded by 1s. The first 15 seconds of the call are not
billed.
It is not possible to import (upload) Advanced rates from the CSV file directly.
Here is a workaround:
Video that shows where to find advanced rates can be found here:
http://wiki.kolmisoft.com/index.php/Advanced_Rates#Where_to_find_advanced_rates
Kolmisoft 2006-2012
133
Additional Notes
See also
Tariffs
Destinations Groups
Custom Rates
Custom Rates are rates that differ from a default user's tariff.
For example: users A and B both have the tariff 'GOLD', but customer A has a rate to Russia of
0.5 and customer B has a tariff to Spain of 0.6. 'GOLD' rates for these destinations are 0.7 and
0.8. Put new values for each customer in their Custom Rates and the new rates will be used
instead of the default tariff rates. This makes it possible to assign different rates for different
customers, without creating a new tariff for everyone.
Most of the time, customers are only interested in calling a few destinations. Nobody needs
complete A-Z destinations. With Custom Rates, it is possible to adjust rates to the relevant
destinations.
You can reach Custom Rates by clicking the yellow coins icon in the Users window.
From the drop-down list, select the Destination Group for which you want to create a Custom
Rate and click the green Plus Add icon.
NOTE: Custom Rates are available for users whose main Tariff type is Retail.
Kolmisoft 2006-2012
134
Tariff Transformation
Wholesale tariffs can be transformed to user retail tariffs. This can be done in the main tariffs
window by clicking on Make user retail tariff or Make wholesale Tariff (these links
appear when a tariff has at least one rate):
Enter the values you want to add to change from a wholesale tariff to a retail tariff. Let's say X
is the wholesale rate. There are three possible ways of making the change:
1. Enter value Y into the Add amount field. The retail rate will be X + Y.
2. Enter value Z into the Add percent field. The retail rate will be X + (X/100 * Z).
3. Enter value Y into the Add amount field AND Z into Add percent field. The retail rate will
be (X + Y) + ((X + Y) / 100 * Z).
NOTE: When performing this transformation, the largest value from the wholesale tariff is
taken for the Destination group in the retail tariff (by prefix). For a more detailed explanation,
check Make Retail Tariff from Wholesale Tariff explained.
HINT: This function can be used when importing a user retail tariff. First you create a fake
wholesale Tariff, then import Rates into it, and finally transform to the user retail Tariff with
values 0/0.
See also
Make Retail Tariff from Wholesale Tariff explained
Kolmisoft 2006-2012
135
Make Retail Tariff from Wholesale Tariff explained
Retail Tariff from Wholesale Tariff is done by the following algorithm:
1. The highest Rate in Wholesale Tariff for Destinations in Destination Group (DG) is selected.
2. This rate is modified by adding a value or percentage to it.
Example
Imagine we have a Wholesale Tariff with the following rates for the USA:
Now, if we want to create a Retail Tariff by adding 0.005 to the Wholesale tariff, we will have a
price for USA Destination Group = 0.035.
For example, the highest rate from Destinations is selected and modified.
Inner mechanics
connection_fee
min_time
increment_s
Kolmisoft 2006-2012
136
When transforming to Retail, these Advanced Rates are created:
Based on which
FROM DURATION TYPE ROUND BY RATE Comments
variable
Show rates for users is disabled by default. Enable it to show the Rate menu option for
resellers/users.
Kolmisoft 2006-2012
137
Devices
Kolmisoft 2006-2012
138
Each device can have many settings. The screenshot shows settings for an SIP device. These
settings are similar to those for other device types as well.
There are several groups of settings: General, Authentication, CallerID, Network Related,
Groups, Voicemail, Codecs, Allowed Addresses, Advanced, Tell Options, Debug and
Recordings.
General
Authentication
Channel – which channel (or channel group) to use on PRI/BRI/PSTN card. Channels
and groups should be configured in zapata.conf.
Kolmisoft 2006-2012
139
For all other device types:
CallerID
A CallerID consists of two parts: Name and Number. The "Number" part is transferred by
default by all technologies (GSM, PSTN, SIP etc), but the "Name" part is transferred only by
some. The number you see on your mobile phone when someone is calling you is the
"Number" part.
NOTE: if you leave these fields empty, the user can set the CallerID by himself. Usually it is not
advisable to allow the user do it on his own.
Number from DID - use the DID as the CallerID (only available when the device has
DIDs), this option just sets CallerID Number to be equal to DID. Next time
you will edit Device's settings, first option - Number will be checked.
Control by DIDs (CID from DIDs) – only available when the device has DIDs.
This setting lets you control what a CID user can enter in his devices. CID numbers should be
from the set of the device's DIDs. They are mainly used when the user's PBX is connected over
Kolmisoft 2006-2012
140
Trunk and many DIDs are routed to this Trunk. Calls coming out from this PBX must have a
CallerID Number from the set of DIDs assigned to this Trunk (PBX). If "CID from DIDs" is
checked, the system checks whether the device's CID number is from DIDs assigned to this
device. If no DIDs are assigned, this value is ignored. In order for this setting to be active, CID
Name/Number fields must be empty to allow the user to enter any CID number he wants. If
"CID from DIDs" is checked and user enters any CID (not from his DIDs), the system will
change his CID by his first available DID (selected from database by lowest ID).
Control by CIDs - system checks incoming CallerID (Device's CallerID which is set on
the Device). If CallerID matches one of the Device's CIDs - then such CallerID will be
allowed. If it does not match - it will be changed to the selected CID.
1. system checks Destination and checks DIDs assigned to calling Device. Then it finds
'nearest' DID to the Destination by subtracting DID from Destination in numerical form
(Example, DID: 11111, Destination: 11112, |DID-Destination|=|1111-11112|=1) If Device
has several DIDs - the lowest value is selected and this DID is set as CallerID.
2. If Device has no DIDs - then User DIDs are used.
3. If Device does not have DIDs and User has no DIDs, then CallerID set in Number
field will be used.
4. If nothing is set here - CallerID coming from Device will be used.
Network Related
Host – the device IP or hostname; the value can be "dynamic", which means that
device should register (it should be like this most of the time).
IP Address – should be the device's IP, or disabled if the device is "dynamic".
Port – the port used to connect to the device (the defaults are 5060 for SIP, and 4569
for IAX2). If host = dynamic, this field is updated by Asterisk when the device registers.
It is the port from where the call is coming (from the device).
Last time registered – when device was last time registered to the Asterisk server.
Media control – can reinvite/transfer. Do you want your server to stay in media path
between your clients and your provider? Please note that this option will work only if it
is supported from both, device and provider, sides and it allows to handle SIP packets
only. Moreover, no codec mismatch between device and provider is available. Default
value is No. WARNING: This option can cause incorrect billing.
NAT – the available options are: yes, no, never, route. For a detailed explanation of
these settings, refer to here [http://www.voip-info.org/wiki/view/Asterisk+sip+nat].
Kolmisoft 2006-2012
141
Qualify – how often to "ask" the device about availability. More details here
[http://www.voip-info.org/wiki/view/Asterisk+sip+qualify] for SIP devices and here
[http://www.voip-info.org/wiki/view/Asterisk+iax+qualify] for IAX2 devices.
Groups
Voicemail
Codecs
NOTES:
When no fields are checked, all codecs are available – for example, settings in sip.conf
or iax.conf are effective.
If the Provider and the Device do not have similar codecs, no call can be established.
Allowed Addresses
IP, MASK – permits traffic from this IP only. You can find a detailed explanation here.
[http://www.voip-info.org/wiki/index.php?page=Asterisk+sip+permit-deny-mask]
If you do not clearly understand what these settings are used for, leave them with default
values.
Kolmisoft 2006-2012
142
Advanced
Kolmisoft 2006-2012
143
Change Failed Code To - if call fails change Hangup Cause Code to this value. This
works only for outgoing calls from device. Not for Incoming.
Forward DID - it allows to forward call to DID which is assigned to Authorization by
PIN or Calling Cards dial plan. After user enters PIN of any device or card, call gets
connected with destination.
Transport - lets you choose protocol(s) for data transfer. Appears only if device is SIP
and when Asterisk 1.8 is enabled. Default value: udp.
Tell Options
Tell balance – should MOR tell the user his balance every time he tries to dial? The
default setting is "no".
Tell time - should MOR tell the user his remaining time every time he tries to dial? The
default setting is "no".
o Time is told in MINUTES and SECONDS. Currently it is not possible to tell ONLY
in minutes.
Tell remaining time when left – when some time is left, MOR will tell the remaining
time to talk (in seconds).
Repeat remaining time when left – repeats the remaining time when some time is
left (in seconds).
Debug
Process SIPCHANINFO - shows SIP channel info in Asterisk CLI and saves this information
on database.
Save Call Log - saves whole call log on database. Log can be overviewed by click in
Last calls.
NOTE: debug should be enabled only if you are experiencing any problems. It should be
disable in any other cases, because it stores lot of information on database.
Recordings
Kolmisoft 2006-2012
144
See also
Grace time - available starting with MOR 9
Kolmisoft 2006-2012
145
Extension lines
In device settings, you can select Extension lines. It will show you Asterisk extension lines:
This information is for people who have a deeper understanding of Asterisk internals.
Kolmisoft 2006-2012
146
How to create User and Device
Here [http://wiki.kolmisoft.com/index.php/How_to_create_User_and_Device] you can see a
video demonstrating how to create a user and a device WITHOUT setting additional settings.
Make sure you read and understand User Details and Device Settings
See also
Users
Devices
Trunks
"Trunk" refers to another server/PBX that can be connected to the MOR system.
When calling such a device, we send the full number that has already been dialed.
Dial(SIP/some_device)
Dial(SIP/some_device/${EXTEN}).
This lets Trunk decide to which device (connected to the Trunk) to route the call.
If you want to make a device Trunk, just mark it as Trunk in the device details: No/Yes/Yes
with ANI.
It is sometimes necessary not to bill a whole trunk as one client, but to bill separate clients
connected to the server/pbx (trunk) separately.
Kolmisoft 2006-2012
147
Now, when a device connected to the Trunk dials through MOR, MOR checks the calling
device's CallerID. If the CallerID is present for some device in the MOR, MOR recognizes this
device as a valid device on the MOR and assigns the call to it instead of to Trunk.
See also
PBX connection to MOR
o MOR and Trixbox
It is important to understand that CLI is not the CallerID that is put on a call that goes out of
the system.
CLI is the CallerID for a call that is COMING INTO the system.
You can reach the main CLI window in device settings by selecting CLIs:
Kolmisoft 2006-2012
148
ANI/CLI ban system
This function makes it possible to ban unwanted CallerIDs.
When no IVR is selected, the call ends with the CONGESTION tone.
When an IVR is selected, it is played for the user who tries to dial.
As example IVR might say: "Sorry, but your account is blocked because..."
Kolmisoft 2006-2012
149
Blocking CallerID because of simultaneous calls
To set this functionality go to main devices edit window and in Advanced block
choose Yes in Block callerid if (number) simultaneous calls come from it:. Add a number of
simultaneous caller IDs. Default value is 2:
Kolmisoft 2006-2012
150
This scheme shows how this functionality works:
Kolmisoft 2006-2012
151
Duplicate call prevention
Sometimes, devices have poorly implemented SIP protocols and try to initiate the same call
twice at the same time.
It kills both calls and prevents the malfunctioning device from dialing.
Allow duplicate Calls is available for Providers and Devices in the Edit window under
Advanced settings.
Its default setting is No. If you are not sure what you are doing, leave it that way.
This setting allows you to decide whether you want to allow a user to use a provider if the
provider's rate to a destination is lower than the user's rate.
By allowing such a call, you will pay more to the provider than the user pays you for it,
meaning that you will take a loss on the call.
If this setting is unchecked (the default setting), cheaper providers will not be used in dialing.
Kolmisoft 2006-2012
152
Resellers
When a Reseller checks this setting for his users, the user is allowed to dial out even when his
rate is lower than the rate that the reseller is paying the system admin.
See also
204 No suitable providers found
218 Reseller does not allow loss calls
Device groups
It is possible to group devices. This feature is intended for branches of a company, so that
each device will belong to a single company group.
This functionality is not widely used and we do not recommend using it unless you really
need it.
To access groups for each user in the Users window, click Dev.Groups:
In this window you see all device groups for the selected user. Under each group, you see
devices assigned to the group.
Kolmisoft 2006-2012
153
Once new groups are added, they can be deleted. However, the primary group cannot be
deleted.
Call Flow
Definition
Call Flow is set of rules on how a call should behave when it is trying to reach a device.
Call Flow can be reached by clicking Call Flow link in device details:
A call has several states that can be seen from this image:
Kolmisoft 2006-2012
154
No Answer – call was not answered and ended after timeout.
Busy – callee was busy.
Failed – call to device failed.
Actions
We can take actions for several call states: Before Call, No Answer, Busy and Failed.
Empty
Forward
Voicemail
Fax detect (only for the Before Call state)
Empty
Kolmisoft 2006-2012
155
Forward
Device Timeout is only available in the No Answer state. It decides for how long a device
should ring before the system decides that it is unreachable (when to activate the No Answer
state).
The system owner (admin) can select any device he likes. If a user edits his devices' Call Flow,
he can only select his own devices.
CallerID options
The following options are available to manage CallerID for a forwarded call:
From device - puts CallerID for the device that is forwarding the call.
Same as comes - unchanged - leaves the CallerID as it comes from the original caller.
Kolmisoft 2006-2012
156
From DID - selects a CallerID from available DIDs.
Custom - enters any CallerID.
Forwarding example
Let's make a chain of forwards: when someone calls to a device (extension) and until the
device timeout there is no answer the call is forwarded to another device, if there is still no
answer then forwared to the next extension.
In Forward to select the second extension. Then go to Devices main page and make the same
call flow to that second extension just in Forward to select the third extension:
This action sends the call directly to voicemail. It's simple. Put in Before Call, and if a call never
reaches a device, it will go directly to voicemail.
Kolmisoft 2006-2012
158
Fax detect
This action can be set ONLY in the Before Call state and only if a Fax device is enabled in
Settings:
You can select only a FAX device to route the call if a Fax is detected. MOR will use fax
detection when this action is set.
If a fax is detected, it routes calls to the set fax device. Otherwise, they go to the basic device.
NOTE: Fax over VoIP is not reliable and this setting should be used only for testing.
Kolmisoft 2006-2012
159
Which codecs should I choose for devices
What codecs are supported?
Audio:
G.711 A-law
G.711 u-law
G.723.1
G.726
G.729
GSM
iLBC
LPC10
Speex
ADPCM
16 bit Signed Linear PCM
Video:
H.261
H.263
H.263+
H.264
Audio codecs
G711
G729
G711
PSTN quality codec which is supported in 99% of all devices/providers (but often disabled to
save traffic).
It has best quality but highest bandwidth (64kbps + ~20 kbps overhead ~= 84kbps to one
direction).
It comes in 2 flavours - G711u (ulaw) - used in USA, and G711a (alaw) - used mostly in Europe
and other countries.
Kolmisoft 2006-2012
160
G729
Little worse quality but is often used because it saves traffic (~8kbps + ~20kbps overhead ~=
28kbps to one direction).
It takes a lot of CPU power to transcode so total call count on the server is greatly reduced
using this codec.
G722
G.722 is a ITU-T standard 7 kHz wideband speech codec operating at 48, 56 and 64
kbit/s. 64 kbit/s (comprises 48, 56 or 64 kbit/s audio and 16, 8 or 0 kbit/s auxiliary data)
HD VoIP in the Asterisk world involves selecting the G722 codec for VoIP calls.
The nice thing about it is that it does not require any more bandwidth than G711.
The difference is that G722 employs compression combined with a higher sample: rate
to obtain a practical acoustic bandwidth of 50 Hz-7000 Hz as opposed to G711 which
has a practical acoustic bandwidth of 200-3000 Hz.
Instead of sounding like you are talking into a tin can it now sounds like the other
person is in the same room.
You can hear more subtle nuances in the person’s voice and certain letters/syllables
that are hard to distinguish on regular calls become much easier.
If one endpoint is using G722 and the other is using G711, the endpoint using G722
will hear better sound quality from the other end but the G711 end will not notice
much if any difference.
Kolmisoft 2006-2012
161
Transcoding overhead between G722 and g711 is minimal. Roughly equivalent to half
the transcoding overhead between G711 and GSM. G.722 patents have expired, so it is
freely available.
Video
Read manual for your device to check which codec is supported on your device.
Make sure same codec is chosen between devices you are trying to communicate.
Fax
If your system/provider/devices does not support T38 you should use G711 codec for fax
transmitting/receiving.
Notes
Make sure you have always selected audio codec! Otherwise you will not be able to place
calls!
Kolmisoft 2006-2012
162
Change Audio/Video Codecs priority
Starting from MOR 9 you can specify audio and video codecs priority. To specify the priority
you have to drag and drop codecs upwards and downwards. Remember to tick the codecs
you want to be enabled!
In this example only the codec G.711 A-law is enabled. Remember to tick other codecs you
want to be enabled.
Additional Notes
Codecs priority can be adjusted in Setup -> Settings -> Default Device (this
configuration will be applied to all new devices)
Codecs priority can be adjusted for a single device also: just navigate to a required
device edit and change the priority. You can find all Devices in Users -> Devices (hint:
you can use search from this menu). Also you can navigate to required device by
user - go to users list and select the Device icon, then select the required device for
that user.
In MOR 8 and older versions you can only enable/disable codecs. You can't prioritize
codecs in older versions.
Kolmisoft 2006-2012
163
Authentication
There are two types of authentication in MOR: IP authentication, and using login and
password.
IP authentication means accepting calls from a given IP automatically, without requesting any
additional login data.
To use login and password authentication, the sender needs to register his phone or pbx to
MOR before sending calls, otherwise MOR will reject them.
Note: IP and login/password authentication cannot work together for the same device
or provider.
Kolmisoft 2006-2012
164
IP Authentication
Kolmisoft 2006-2012
165
Restrictions
You cannot create/edit Provider if you already have Device with same IP and port
combination. However, you can have two Providers with same IP and port
combination.
You cannot have two Devices with same IP and port combination.
NOTE: if you need to send and receive calls from same IP and port, please Configure Provider
which can make calls.
Registration Status
About
This feature was developed to make MOR administrator’s life easier. With this feature an
administrator is able to track SIP device status from GUI and solve problems faster.
Example:
If a device is assigned to a server A but registers to server B - status will not be shown
(devices must register to the server they are assigned to).
Kolmisoft 2006-2012
166
Status
OK - Device is registered, all is OK
UNKNOWN - means the device state status could not be found. This is NOT an alternative
message to the previous UNREACHABLE message.
This status is created when you add a new device and the system does not yet have any data
about its registration status.
Unmonitored - Device should not register to server so its status is unmonitored, this
device made calls, so server is aware of its existence
NO STATUS - Device never tried to register to Server and Server does not know nothing
about this device.
Device list
Kolmisoft 2006-2012
167
Device edit
/usr/local/mor/mor_retrieve_peers
/etc/cron.d/mor_minute_actions
Logs
If you want to get a lot of logs put DEBUG = 1 in mor.conf
/var/log/mor/ami_debug.log
Kolmisoft 2006-2012
168
Device rules
Device Rules transforms an E.164-compatible number to any number
format the Device requires.
Description
Different Devices expect different number formats from you. You can send them whatever
they want using Device Rules.
Device Rules are only used when Device is reached over DID. Local calls between Devices will
not use Device Rules.
Device Rules can be reached by clicking the icon next to a Device in the Devices window:
IMPORTANT: Device Rules are applied ONLY to those devices which are accessible over
DID!
We see a similar window as the one in Localization. The rules to manage Device Rules are
identical to those for Localization management, which are covered in Number Manipulation
page.
IMPORTANT: Localization Rules only matter to the Trunks (Devices marked as Trunks).
Because simple Devices do not care about Destination.
Kolmisoft 2006-2012
169
Let's say our device/trunk expects to get a number with the international prefix 00. We can do
this in following way:
That's it – very simple. Now every number that is sent to this Device will be transformed by
adding our created int. prefix.
For example, if 37063011111 should be sent to this Device, this rule will be activated and the
number 0037063011111 will be sent to Device.
Special cases
With rule Cut: *# it is possible to cut everything till # (# included) in the dialed destination:
Kolmisoft 2006-2012
170
For example:
This function can be used in fancy MNP (Mobile Number Portability) schemes and perhaps
elsewhere.
NOTE: Add value still can be used to add any value after Cut is used on the Destination.
If you want to send a number to a Device exactly as it was received, set Cut = '-' (minus sign
as shown in the screenshot).
That way, the same number that comes to MOR also leaves MOR:
Kolmisoft 2006-2012
171
In the example bellow we will add international prefix to every CallerID sent to this Device:
Special case
CallerID overwrite
In this example, all calls going to this Device will have CallerID = 37063033333.
Kolmisoft 2006-2012
172
Providers
Description
In the old PSTN world, Providers were called Trunks. Providers are your route out of your VoIP
network to the outside world.
Providers can be one of several types: ZAP, SIP, IAX2, and H323. The type determines which
technology is used to connect to the Provider.
At the very start, you need to create a Provider through which you will dial out to PSTN or
other VoIP networks.
Every Provider will charge you for calling a destination through his service (although the rate
might be zero). The rate to every destination is different. Because of this, we need to have a
Tariff (or Price List) for each Provider. This Tariff will tell our billing what price we will pay to a
destination when using this Provider's services. In other words, this will be our Selfcost.
Here, enter the Name for a new provider, select its Technology, Tariff, Asterisk server which
should be used for this provider and click Create.
NOTE:
You can't create a new Provider if there are no Tariffs available for Providers.
A Provider is also able to send calls, not just receive them. In case you want to sell
services to a provider you have to create such a provider.
Provider balance
Provider balance increases when calls are made via that provider. Currently it is not available
to decrease provider's balance. You can read more about Provider Billing Addon.
Kolmisoft 2006-2012
173
Settings
General
Channel – which channel (or channel group) to use on a PRI/BRI/PSTN card. Channels
and groups should be configured in zapata.conf.
Provider CallerID
CallerID – consists of two parts: Name and Number. The "Number" part is transferred by
default on all technologies (GSM, PSTN, SIP etc), but the "Name" part only on some. The
number you see on your mobile phone when someone is calling you is the "Number" part.
NOTE: if you leave these fields empty, calls coming from this provider will have CallerID set by
the Provider. It should almost always be this way.
Network related
Kolmisoft 2006-2012
175
H323 specific network settings
Media control – can reinvite/transfer. Do you want your server to stay in the media
path between your clients and your provider? Disable if you have a lot of 1-second
answered calls.
NAT – the available options are: yes, no, never, and route. For a detailed explanation of
these settings, refer to here [http://www.voip-info.org/wiki/view/Asterisk+sip+nat].
Qualify – how often to "ask" the provider about availability. More details here
[http://www.voip-info.org/wiki/view/Asterisk+sip+qualify] for SIP providers and here
[http://www.voip-info.org/wiki/view/Asterisk+iax+qualify] for IAX2 providers.
Servers
Allows to select on which Asterisk servers this provider should be used.
Codecs
Choose the codecs your provider uses.
NOTE: When no fields are checked, all codecs are available. ( For example, settings in
sip.conf or iax.conf are effective).
Advanced
Grace time - if call duration is less than Grace Time, it will not be accounted.
Progressinband:
o yes - when "RING" event is requested, always send 180 Ringing (if it hasn't been
sent yet) followed by 183 Session Progress and in-band audio.
o no - send 180 Ringing if 183 has not yet been sent, establishing an audio path.
If the audio path is established already (with 183), then send in-band ringing
(this is the way Asterisk historically behaved because of buggy phones like
Polycom's).
Kolmisoft 2006-2012
176
o never - whenever ringing occurs, send "180 ringing" as long as "200 OK" has
not yet been sent. This is the default behavior of Asterisk.
Video support – does your provider support Video over IP? More info here
[http://www.voip-info.org/wiki/view/Asterisk+video].
Allow duplicate calls - the default setting is "no".
Interpret NO ANSWER as FAILED - default option is no (This will change the provider in
LCR like it is failed, in last calls you will see the real hangupcause - no answer).
Interpret BUSY as FAILED - default option is no (This will change the provider in LCR
like it is failed, in last calls you will see the real hangupcause – busy).
Fake Ring - should system generate Fake Ring or not? Use only if your Device/Provider
has bad protocol implementation and does not send RING signal properly.
Common Use - Provider can be used by Resellers which are able to create their own
Providers. Reseller will be billed using this Provider. If provider is marked as common
use and is used in one of reseller's LCR or is in Terminators list - admin is not allowed
to delete this provider or remove common use option.
SIP Specific
Kolmisoft 2006-2012
177
Debug
Save Call Log - when this option is enabled you can access Call info information in last
calls page.
Failover provider
You can also assign a failover provider to a LCR by selecting No in Use only one provider (Turn
off failover). Default value is Yes.
Failover provider is a provider used only in case of emergency. If all the other providers fail
(returns FAILED error code) a failover provider is used.
If you think that NO ANSWER/BUSY == FAILED, then you can use NO ANSWER/BUSY
interpretation for providers setting.
See also
Kolmisoft 2006-2012
178
Terminators
A Terminator is a group of Providers (in MOR's terms).
In reality, a Terminator is a company that sells/buys traffic to/from you. Then Providers (in
MOR's terms) are gateways of this Terminator.
Kolmisoft 2006-2012
179
Provider connection testing
It is possible to test Provider connectivity by clicking on in the Providers window:
Good response:
Bad response:
Kolmisoft 2006-2012
180
H323 Provider settings
Automatic Number Identification (ANI) for Provider is used ONLY (at least we don't know any
other situations) when the provider gives you an access number after which (IMPORTANT!)
the dialer enters the destination number WITHOUT PAUSES, so that the WHOLE number is
sent to the provider instantly.
Kolmisoft 2006-2012
181
For example:
Let's say the provider gives you the access number 1234.
When somebody wants to dial a destination (let's say 22234567890), he enters on his
phone: 123422234567890.
22234567890 comes from the provider to your MOR box.
Because the provider is with ANI, we check the user's CLI.
If CLI is found, we know which user is dialing.
Before he dials out, we change the CallerID of this call to the CallerID found in our
database - that's a minor job, but it's part of the algorithm.
After that, the call is sent to 22234567890.
IMPORTANT!!! - Do not check ANI for Provider if this description does not match your
working scenario!
If you have an access number as DID, you can enter p (pause) after your DID when calling the
provider and then enter the destination. But that is a totally different scenario. It should be
configured with DID + Auth. by ANI DialPlan, because the destination is send to MOR by
DTMF, not by the provider as in the previous example.
Example:
If your DID is 234567890 and you want to dial dst: 987654321 on (for example) your mobile
phone, you enter:
234567890p987654321
That way the call will reach MOR. When p (pause) is reached, MOR will play "Please enter
destination" and 987654321 will be sent by DTMF to MOR.
Kolmisoft 2006-2012
182
Configure Provider which can make calls
In order to allow a Provider to make calls, we need to:
Kolmisoft 2006-2012
183
For example:
Kolmisoft 2006-2012
184
When your device registers, the current IP address of the device will be in in the IP Address
field. Do not change it!
These settings limit simultaneous calls, not how many total calls the
user/device/provider(/did) can make.
When no more calls can be made, the dialer hears the BUSY signal.
Provider
Call limit - describes how many simultaneous calls the provider can make. 0 (zero) means that
calls are unlimited.
Hangupcause code 223 means that the provider can't make more simultaneous calls.
Kolmisoft 2006-2012
185
User
Call limit - describes how many simultaneous calls the user can make. 0 (zero) means that
calls are unlimited. This limit is for outgoing calls made by this user.
Hangupcause code 220 means that the user can't make more simultaneous calls.
Hangupcause code 222 means that a reseller (as a user) can't handle (allow to his users to
make) more simultaneous calls.
Kolmisoft 2006-2012
186
Device
Call limit - describes how many simultaneous calls the device can make. 0 (zero) means that
calls are unlimited.
Hangupcause code 221 means that the device can't make more simultaneous calls.
DID
Kolmisoft 2006-2012
187
Call limit - describes how many simultaneous calls DID can receive. 0 (zero) means that calls
are unlimited.
Hangupcause code 219 means that DID can't receive more simultaneous calls.
Special case
When DID points to a device and the limit is reached, calls will be routed to the device via
BUSY - Call Flow. This will ring another device or send a call to VoiceMail when the main
device already has a call.
If we have several providers in our LCR, the call ends after we receive NO ANSWER or BUSY
from a provider, and our routing ends.
This is okay for an ideal world in which all providers follow standards and send the correct call
end codes, e.g.:
NO ANSWER when calls are not answered after a certain period (timeout).
BUSY when a recipient is busy (talking with somebody else).
ANSWERED when a call has been answered and ends.
FAILED when an error occurs.
However, providers sometimes cheat (or do not have technical skills to make this correctly).
For example, if they can't deliver a call to a destination because of some problem in their
network or something similar, they may send the NO ANSWER or BUSY signal for a FAILED
call. And then our routing breaks. If we have several more providers in our LCR, our LCR will
not try to send call the over the remaining providers and will end the call.
Kolmisoft 2006-2012
188
To partly solve this problem, MOR provides a workaround: "NO ANSWER/BUSY interpretation
for providers".
That means, if a provider reports NO ANSWER and/or BUSY, MOR treats this as FAILED and
the next provider in LCR (if there are further providers) is tried to send the call.
Kolmisoft 2006-2012
189
Net2phone configuration
Kolmisoft 2006-2012
190
Broadvoice configuration
Kolmisoft 2006-2012
191
Eutelia
Kolmisoft 2006-2012
192
As Eutelia sends calls from different IPs, we need to configure it as a second provider:
Kolmisoft 2006-2012
193
Configuring DIDWW
DID World Wide, International DIDs forwarded to PSTN and VoIP by SIP, IAX, H323, Skype,
Gtalk, MSN Messenger. Origination services, SIP DIDs.
CallerID does not come in E.164 format - only in the local format.
QUESTION:
Hello! From Ukraine DID CallerID is not coming in the E.164 format.
It is coming in the local format like 80519539xx, but must be 3805019539xx.
Is it possible to fix this?
ANSWER:
Your DID number is forwarded with CLI exactly as the local carrier sends it.
Please check if it is possible to change the CLI on your end.
Best Regards,
Customer Support Department
DIDWW
Kolmisoft 2006-2012
194
Configuring multiple DIDWW IPs for receiving calls to DID
The problem with this DID Provider is that it sends calls from many IP addresses.
Please be sure you have granted access on your end to DIDWW Public IP Addresses:
[http://www.didww.com/Knowledgebase/the_list_of_didww_ip_addresses/]
Kolmisoft 2006-2012
195
3. Afterwards, enter any IP (or leave blank) in Provider Network settings, and write down
Provider Device ID value, you will need it later.
Kolmisoft 2006-2012
196
4. Now connect to your server over ssh and locate this file
/etc/asterisk/extensions_mor_didww.conf and find these lines:
[from-didww]
exten => _X.,1,Set(CDR(ACCOUNTCODE)=0)
exten => _X.,2,Goto(mor,${EXTEN},1)
Now you need to change (ACCOUNTCODE)=0 value (0) to Provider Device ID value as
follows:
#include sip_didww.conf
6. Restart Asterisk
Now your system is updated with all the DIDWW IP addresses that are listed in their
recommendations.
DID configuration
Then:
Kolmisoft 2006-2012
197
Configuration in www.didww.com
First we need to create "mapping", that is, the route to our server:
Kolmisoft 2006-2012
198
Troubleshooting
Maybe you have DID in the wrong format - for example, not E.164 compatible?
Vitelity
http://www.vitelity.com/
Kolmisoft 2006-2012
199
Vono
http://www.falevono.com.br/
Kolmisoft 2006-2012
200
How to add Voicetrading Provider
About
This manaul is an example how to configure Voicetrading provider, but it can be used
The username & password can also be used to connect to our SIP-server in order to make
calls.
Getting connected
G.729 (8 kbps)
If you cannot connect by using Username & Password, we can also authenticate your fixed IP
address(es).
Kolmisoft 2006-2012
201
After we authenticated your IP, you can connect by using the following IP-adresses:
Choose tariff and mark server which will be used for this Provider and press create.
Kolmisoft 2006-2012
202
Entering Provider details
Fill fields login/Username, password with details your Provider provided to you.
Kolmisoft 2006-2012
203
Different quality routes
Voicetrading and another Providers often uses different prefixes for different quality routes:
Press on Rules icon and enter rule add special prefix in this case 00
When Rule is added cal will work in this scenario: customer will dial 49 12345678 system will
automaticly add special prefix 00 and number will be send to Provider in this format
004912345678.
Kolmisoft 2006-2012
204
Portech GSM as Provider
Provider configuration
Make sure you do not have Device with same username/password as for your
Provider!
Kolmisoft 2006-2012
205
Create Provider (NOT user/device!!!) in MOR with following settings:
NOTE: password field is empty - somehow in our tests Portech refused to register with
password.
Create LCR, assign Provider to it, assign LCR to user, and do all other necessary steps.
Kolmisoft 2006-2012
206
Portech configuration
Kolmisoft 2006-2012
207
Port settings
Do not forget to route these ports on the firewall if your Portech is under NAT!
Problems
We do not recommend these devices because they are unpredictable and unstable. They may
stop working without notice at any time!
Some examples:
http://lists.digium.com/pipermail/asterisk-users/2009-November/241371.html
Kolmisoft 2006-2012
208
Call Routing
LCR
LCR (Least Cost Routing) is a set of Providers that should be used to send a call when trying
to dial any destination - for example, by the cheapest rate.
The correct name for such a function is a Routing Table, because the function supports other
ways of routing, not just finding the cheapest route.
LCR supports fail-over. That is, if one provider fails, the next one is dialed. This is completely
invisible for the caller and lets you increase the chances of the user reaching his destination. If
one Provider is not capable of delivering a call, the system will try to use the remaining
Providers.
The LCR window can be found in SETTINGS –> Billing –> LCR.
The user has one base LCR, so that all his calls are routed by some preset rule.
It is possible to route different destinations for a User using Call routing per destination basis.
In MOR there is also a feature that gets you a CSV with the best prices selected from the list
of Providers in LCR. Go to SETTINGS -> Billing -> LCR. You will see this window:
Kolmisoft 2006-2012
209
Click on the icon and the download should start automatically.
Sometimes you need to make a LCR which takes quite a long time to make. If you have made
a similar one before you can just copy it and change appropriate details. Go to SETTINGS ->
Billing -> LCR -> Copy LCR (as shown below in the picture). You willl see this window:
Choose Original LCR reseller and Cloned LCR reseller and click Clone button.
Please note that LCR will not be allowed to copy if reseller B is not allowed to use Providers
which are used by Reseller A.
See also
LCR Logic
How to add Provider to LCR
Call Routing by priority (Manual LCR)
Call routing per destination basis
LCR/Tariff change based on call prefix
Routing by Percent or Weight-based routing
Why was a call not routed through another provider/trunk?
Make Tariff MIN/MAX from LCR Providers to CSV
Kolmisoft 2006-2012
210
LCR Logic
Here simple LCR (Least Cost Routing) is explained.
Example
92 rate 0.1
92 rate 0.05
921 rate 0.2
MOR first dials through Provider A. If the call fails, Provider B will be used to send the call.
If the call through Provider A is ANSWERED, BUSY or there's NO ANSWER, the call ends, and
Provider B is not used.
Kolmisoft 2006-2012
211
The following graphic illustrates LCR logic:
Kolmisoft 2006-2012
212
How to add Provider to LCR
Usage
1. Go to SETTINGS -> Billing -> LCR
Advanced Options
Usage
1. Go to LCR list: SETTINGS -> Billing -> LCR
Kolmisoft 2006-2012
213
3. Enter the desired percent for call price difference:
Example 1
Provider A has a price of 0.10€ and provider B 0.11€ and we set x=20%
Example 2
Povider A has a price of 0.10€ and provider B 0.30€ and we set x=20%
so if call can´t be establish by provider A then the system wil NOT try with provider B
This method of routing is used when it is known that a Provider provides better quality for
some destinations, or for some other reason a call should go in some special order.
Kolmisoft 2006-2012
214
To set this feature, you need to set the type of priority in LCR:
You can go to Providers and click on Change Order to change the order of Providers for this
LCR:
Video at
[http://wiki.kolmisoft.com/index.php/Change_Provider_order_by_Drag%26Drop_video]
demonstrates how to do that.
Kolmisoft 2006-2012
215
Click Back when you are finished. Assign this LCR to users and route calls manually.
Each user has an assigned LCR. For some destinations, it is possible to set a different LCR.
Example
We take Paraguay as example, because this country has a small number of destinations.
Let's say we have three providers (in LCR: Primary), and we use them all together for all our
destinations. The route is picked by the least cost route, that is, the LCR order is by Price:
Kolmisoft 2006-2012
216
Then we have the situation that calls to Paraguay (except those to Mobiles) do not go
through the provider Eutelia.
To handle this situation we create a new LCR: Secondary, in which the order is Priority. It
excludes Eutalia and has only two providers:
Click on the By destinations icon for Primary LCR (because Primary LCR is used by the user
who dials):
Kolmisoft 2006-2012
217
Explanation
Now when the user dials any Paraguay FIX number, the call will be routed using LCR:
Secondary with order: priority:
We can click on Active destinations and will see for which prefixes such an LCR applies:
As we know that Eutalia can route calls to Mobile networks of Paraguay, so MOB destinations
will be handled by old LCR:
Kolmisoft 2006-2012
218
We can click on Active destinations and will see for which prefixes such an LCR applies:
Now calls to this destination will be routed ONLY through this Provider.
You can add more Providers to your LCR and use it with many Destinations.
You can create many LCR/Providers/Destinations combinations and use them in any way you
need.
Kolmisoft 2006-2012
219
LCR/Tariff change based on call prefix
Also called: Tech Prefix functionality.
The main purpose of this function is for calls to be routed through a provider or providers
based on call prefix.
You have to create a provider, tariff, LCR (where the specified provider has to be), and a user
with his device. And most important, the localization rule or rules. It should be applied per
device basis (Device settings -> Location), making sure the specified device has the correct
rule applied. It must be noted that specified rules have higher priority than global rules.
You can find more info on how to make rules in Number Manipulation.
Example
Lets say we have a provider that provides three quality routes: bad-cheap/normal/good-
expensive.
The bad-cheap route is selected when dialing an E.164 number with prefix 00.
The normal route is dialed when dialing the normal E.164 number.
The good-expensive route is selected when dialing the E.164 number with the prefix
000.
Kolmisoft 2006-2012
220
o Provider_Tariff_Bad
o Provider_Tariff_Normal
o Provider_Tariff_Good
Enter/Import appropriate rates to these Tariffs.
Assign these Tariffs to providers.
That's it.
Now when the user dials E.164 numbers, he will be using the normal route; when 00, the bad
route; and when 000, the good route.
Routing by Percent
This type of routing selects a route by percentage value of Providers.
Kolmisoft 2006-2012
221
It is similar to Priority-based routing, except that here Providers are selected randomly with
greater or lesser probability.
Example 1
A - 50%
B - 30%
C - 20%
As a first step, it randomly selects the first provider. There is a 50% chance that Provider A will
be selected, 30% for B, and 20% for C.
A - 50%
C - 20%
There is a much greater chance that A will be randomly selected than C. So let's say A is
selected.
Kolmisoft 2006-2012
222
The final order of our providers will be:
B-A-C
Every time, the order is RANDOMLY done in the same way, using percent values for
probability.
So we can get various results, such as A-B-C, A-C-B, B-A-C, C-A-B etc. BUT, following
mathematical reasoning, when we make a huge amount of tries (going till infinity), sets will
follow the rule in the first step: the Provider selected first will be A in 50% of the cases, B in
30%, and C in 20%.
Example 2
To better illustrate the method, let's take a simpler situation. We have two providers with
these percentages:
A - 99%
B - 1%
Provider A will be selected first 99% of the time, so that when we have many ordered lists,
they will look like:
The probability that the provider order will be B-A is just 1%.
Fail-over
That is, after we have ordered the provider list, if the first provider in the list fails, the second
will be dialed and so on.
Kolmisoft 2006-2012
223
Why call was not routed through other provider/trunk?
If you see that a call was not routed through the second (third/fourth/...) Provider/Trunk, take
the following steps:
1. Check Call Tracing – it is possible that other Providers can't handle the call (no rates, not
configured properly, not assigned to LCR, etc).
2. Check STATISTICS –> Calls –> Last Calls – check Hangup Cause for your failed call. If the
Hangup Cause is NO ANSWER or BUSY, then MOR does not route the call to the next
provider. More details in NO ANSWER/BUSY interpretation for providers.
And MOR is capable of routing calls over all it's servers internally.
In provided example we have only 3 servers in the Cloud but it is enough for demonstration.
In provided example all devices (phones), e.g. 1, 1-2, 1-3, 2, 2-1, 2-3, 3, 3-2, 3-3 can talk
between each other.
Kolmisoft 2006-2012
224
Each Provider can be assigned to many servers
o Shortest path to use (reach) this Provider will be used by Internal Routing
See also
Multi Server support
Kolmisoft 2006-2012
225
DIDs
DID Management
Description
What is a DID?
In short – it is an external number to have incoming calls to your VoIP network reach a
particular device. (This is a very simplified explanation that will serve for the moment. For a
more extensive explanation, please check here [http://www.voip-info.org/wiki/view/DID] ).
You can reach the DIDs window in SETTINGS –> Billing –> DIDs:
Since MOR 12 you can choose different tone zones. Tone zone is a different ring tone
depending on destination (country).
User/Dial Plan and Device show who will answer when dialing this DID.
Clicking on User or Device brings you to their DID settings. If you click on the icon, you will
go to the device's Call Flow window.
Kolmisoft 2006-2012
226
Status
Kolmisoft 2006-2012
227
Settings
1. Change Provider and language for this DID. "Language" is for voice prompts in the
Asterisk Dial Plan.
2. Reserve a DID for a user.
Kolmisoft 2006-2012
228
3. Assign to Dial Plan.
4. Terminate a DID.
When a DID is assigned to a Device (Reserve for User first), you have a few different choices:
1. Change provider/language.
2. Assign DID to a different device (for the same user).
3. Assign DID to Trunk.
4. Stop a DID subscription and reserve the DID for 90 days (by default) to this user in
case he changes his mind and wants to get the DID back.
Kolmisoft 2006-2012
229
When DID is assigned to Dial Plan, the choices are almost identical.
If call duration is less than Grace Time, it will not be accounted, for example: Grace Time = 3s,
call duration <= 3s, then price for the call = 0
See also
Provider Grace Time
Device Grace Time
Kolmisoft 2006-2012
230
Timeout Digit
The maximum amount of time permitted between digits when the user is typing in a number.
When this timeout expires after the user has started to type in a number, the number will be
considered complete, and will be interpreted (sent to the system). Works both with entering
destination and ANI/PIN.
Kolmisoft 2006-2012
231
Timeout Response
The maximum amount of time permitted for user to START entering a number. If the user
does not begin typing a number in this amount of time, system will notify that nothing was
entered. Once the user begins to type a number, system will wait for Digit Timeout to be
reached, and Response Timeout has no effect no more.
Kolmisoft 2006-2012
232
CallerID Name Prefix
By setting this option you can add a CallerID Name prefix to the incoming CallerID.
Tariff for Calling Card lets you set a tariff for DID which will be applied for a calling card. It will
not be important what tariff is assigned for that card's group.
Kolmisoft 2006-2012
233
Work days and Free days
It is available to set different DID rates for work days and free days. If you want to do this go
to SETTINGS -> Billing -> DIDs. Click on rates in the window you will see and then Split to
Work Days and Free Days. To combine back click Combine to Work Days and Free Days:
In the main DIDs window, if you want to add new DID(s), click on New DID:
Kolmisoft 2006-2012
234
In this window, you can add one DID or series of DIDs. Also, you should select the provider
which sold you this DID.
Delete DID
At first, mark it as "not used" (Free). Then terminate it. When you do, you will see next to
the DID in the main DID window. By clicking on it, you can delete the DID.
It is not possible to edit a DID number. You can only delete an old one and create a new one.
In the main DIDs window, click Bulk Management and you will be able to perform various
actions with a series of DIDs:
Kolmisoft 2006-2012
235
Assign DID to Trunk
What is trunk?
"Trunk" refers to another server/PBX that can be connected to the MOR system. For more
information please visit Trunks page .
Kolmisoft 2006-2012
236
3. Enter DID interval you want to assign to trunk and select the marked option:
Kolmisoft 2006-2012
237
5. Select a trunk you want your DIDs to be assigned to:
See also
Trunks
DID management
1. Let's say a call comes through a certain Provider. The connection type is not important.
So it could be PSTN/SIP/IAX2, or whatever.
2. Call -> Provider -> PSTN/SIP/IAX2 -> your Asterisk.
3. The call hits Dialplan [mor] exten => _X.,1, MOR:
4. Call -> Provider -> PSTN/SIP/IAX2 -> your Asterisk -> MOR.
5. MOR checks its database (DB) for the incoming DID. If it's found, MOR sees where to
route the call. In the MOR GUI, you can select to route the DID to a special Dial Plan
(CallBack, Calling Cards, Authorization by PIN/ANI) or to some local device.
6. The local device in its Call Flow can forward the call to:
1. VoiceMail.
2. Another Local Device.
Kolmisoft 2006-2012
238
3. An External Number.
7. So summed up, MOR can forward a DID to:
1. Dial Plan (CallBack, Calling Cards, Authorization by PIN, IVR).
2. A Local Device.
3. VoiceMail.
4. An External Number.
8. Call -> Provider -> PSTN/SIP/IAX2 -> DID -> Your Asterisk -> MOR -> (Dial Plan
or Local Device, Voicemail, External Number) -> ...
DID Billing
Description
DIDs can be billed. DID billing is quite complex, as they have three types of rates. That means
three prices are counted for one call. DID rates can be reached in the main DIDs window by
clicking the Rates icon for the selected DID:
Kolmisoft 2006-2012
239
Incoming rate
For incoming calls, when the Incoming rate is greater than zero, the rate is paid to the system
owner by the user who is dialing to that DID. It represents a profit for the system owner.
If the rate is less than zero, the price is paid TO the dialing user for the DID usage.
The dialing user is the user in MOR, and this rate applies only then when MOR recognizes the
dialing user (by PIN/ANI).
Owner rate
For incoming calls, when the Owner rate is greater than zero, this rate is paid to the MOR
system owner by the DID owner. This represents a profit for the system owner.
If the rate is less than zero, this price is paid TO the DID owner.
This rate is charged even if the local user dials another local user using DID with Owner Rate
set.
DID usage is not allowed if this rate is > 0 and the DID owner does not have a large enough
balance to cover call costs.
DID owner rate is not applied to the DID's owner - that is, the owner of the DID will be not
charged when dialing his own DID.
If a DID is assigned to a Dial Plan, then its Owner can be selected in the DIDs settings and any
user can be considered as the 'owner' of the DID and can be billed at this rate when anybody
dials this DID.
Kolmisoft 2006-2012
240
Select "Device" to see calls to this DID near this Device's calls:
Provider rate
For incoming calls, when the Provider rate is greater than zero, this rate is paid to the system
owner by the Provider. It represents a profit for the system owner.
If the rate is less than zero, this price is paid TO the Provider for the DID usage.
See also
DID Billing Time explained
Kolmisoft 2006-2012
241
DID Billing Time explained
Here:
So:
This page shows current DIDs status and Actions with DIDs in a selected period:
Personal DIDs
PERSONAL MENU –> Various –> DIDs
This page shows DIDs which are associated with a User. No changes to configuration can be
made in his window.
Kolmisoft 2006-2012
243
Example - Configuring DID to ring some Device
Primary situation
We have:
We want:
To dial the DID 02180995165 using our mobile phone and ring Device SIP/201.
Kolmisoft 2006-2012
244
To dial the DID 02180995165 using the local Device SIP/202 in order to ring Device
SIP/201 (local SIP-SIP call not going to PSTN).
Configuration
Plan
Kolmisoft 2006-2012
245
Configure Localization for Provider
As the DID is not in E.164 format, we must configure MOR to handle this.
Since the DID 02180995165 does not come from the provider in E.164 format, we must create
a Location for this provider and add a rule to it. We create Location: UK and add a rule to
convert the non-E1.64 DID to E.164 DID: 02180995165 -> 4402180995165.
Create Provider
Register Provider
Kolmisoft 2006-2012
246
Create/Configure DID
Kolmisoft 2006-2012
247
Assign DID to Device SIP/201
That's it.
I have DIDs with Voxbone. They send the URI using ext@sip.server.
It's okay for receiving calls, but I need to know how I can use this system to redirect to a
Calling Card Dial Plan.
Kolmisoft 2006-2012
248
Answer:
When you configure your Calling Card Dial Plan (DP), you should assign it to a DID.
Let's say your Calling Card DP DID is 12345. Configure your Voxbone DID to call to:
12345@sip.server where sip.server is your server's IP or hostname.
NOTE: 12345 is an EXAMPLE! DO NOT CREATE 12345 as your DID - create a real one!
Now when a call comes to the DID, it will be forwarded to the External Number.
Video example how to forward DID to external number can be found here:
[http://wiki.kolmisoft.com/index.php/Forward_DID_to_External_Number]
See also
Purchase DID at didx.net and forward DID to an external number
To do this, each Provider also has a Location. This means that Location rules can be created
and applied for the Provider. You can do this in the Provider settings window:
Kolmisoft 2006-2012
250
For example, you have DID 37052058393 and the provider sends you 0037052058393. You
need to strip this international prefix with the following rule:
Special case: In some countries when E1 is connected to the server, only the four last digits of
the number reach MOR. Localization should be used here to add the remaining part of the
number.
See also
Number Manipulation
o Localization
o Provider Rules
o Number Manipulation Examples
DID Blocking
If a customer is not paying or you want to block calls to his DIDs for any other reason, go to
the DID window and Close DIDs which belong to this customer.
"Blocking" in the User EDIT menu will not block his DIDs. It will only block dialing, so that the
user will not be able to dial out.
Kolmisoft 2006-2012
251
See also
DID Management
Work flow for DID
DID Billing
DIDs Usage
Example - Configuring DID to ring some Device
DID with VoxBone using his URI
Forward DID to External Number
How to charge DID on a monthly basis
DID handling by Localization
Dial Plans
Dial Plan is the name for a specific functionality in MOR. Currently it has the following types:
Authorization by PIN
Authorization by ANI
Calling Card Dial Plan
Callback Dial Plan
IVR Dial Plan
Authorization by ANI + CallCard on one DID
You can find all dial plans in SETTINGS –> Billing –> DIDs –> Dial Plans:
Kolmisoft 2006-2012
252
Authorization by PIN
Description
This function is for customers who can dial an access number and enter their device PIN
number in order to get a dial tone and enter a destination number. It is used in some
countries to get cheaper calls abroad.
The algorithm for the Authorization by PIN dial plan is seen in the following image:
Kolmisoft 2006-2012
253
First, in the main Dial Plan window, click on New Dial Plan and enter values to create an
Authorization by PIN dial plan:
IMPORTANT! Check the Use ANI? field – otherwise it will create a different type of Dial Plan.
Ask Number/PIN (times) – how many times the user can try to enter the PIN.
Ask destination (times) – how many times the user can try to enter the destination.
Click on to create this dial plan. The first step is complete – we have created our dial plan:
Now we need to assign a DID to this Dial Plan. To do this, in the DIDs edit window we assign
the selected DID to the Dial Plan:
Kolmisoft 2006-2012
254
In the main DIDs window we see that this DID is now pointing to our dial plan:
That's it. Very simple. Now, dialing 37063042439, we reach our Dial Plan. Here we hear a
message that asks us to enter our device PIN. If the PIN is correct, we can dial the desired
destination.
Sometimes the CallerID of the original Caller is changed by the CallerID set in MOR. To see
the real CallerID in CDR, it can be saved in the CallerID Name field.
See also
Dial Plans
Kolmisoft 2006-2012
255
Authorization by ANI
Authorization by Automatic Number Identification (ANI) is a variant of the Auth. by PIN
method that makes the system act in a different way. If you check the Use ANI? field in the
Dial Plan creation window, the user's CallerID will be checked automatically when he dials in,
and he will only be asked to enter his PIN if his CallerID is not found.
CallerIDs are entered for every device in Device Settings using the icon.
When a call comes into MOR, the CallerID is checked with all available CLI's in the database. If
a match is found, the call is authorized and assigned to the device which CLI has matched
against the CallerID of the call:
Kolmisoft 2006-2012
256
All other details are the same as for Authorization by PIN dial plan, and the dial plan is
created in the same way. Just check Use ANI?:
Note the difference between Auth. by PIN and Auth. by ANI dial plans.
Default device
Kolmisoft 2006-2012
257
End IVR
When making an authorization by PIN dial plan you must set and end IVR to it. You can
change the IVR by clicking Edit.
Troubleshooting
If the system asks for a PIN to be entered
This occurs if the CallerID comes in a different format from that which is entered in the Device
CID. Use Last Calls to check it and Number Manipulation to fix it.
See also
Dial Plans
Kolmisoft 2006-2012
258
Calling Card Dial Plan
Overview
Once we have generated a Calling Card Group and Cards, we can create a Dial Plan for this
Group.
A Dial Plan can be treated as a set of rules for how to handle a particular Calling Card Group.
You can set different rules for the same Calling Card Group.
The Dial Plan gives you more control over Calling Card Groups.
In this image, we see an existing Dial Plan for a Calling Card Group.
Kolmisoft 2006-2012
259
Ask destination (times) – how many times the user can try to enter Destination.
Assigned DID(s) – just for informational purposes, to see which DID(s) are assigned to
this Dial Plan.
If Card balance is lower than - self explanatory.
Balance IVR - a Balance IVR will play.
When creating a new Dial Plan, you will need to enter the correct Number and PIN length
values of an existing Calling Card Group. Otherwise you will not be able to create the Dial
Plan.
When we have created a Dial Plan for a Calling Card Group, we can assign one or more DIDs
to this Dial Plan.
A DID (in other words, an Access Number) is vital for using Calling Cards. The user will use
this number to reach IVR.
You can assign unlimited DIDs to the same Dial Plan, but a particular DID can only be
assigned to one Dial Plan.
The Calling Card Dial Plan is useful when you are selling Calling Cards in different regions,
such as different countries. In country A, the user will dial one number (which is cheaper for
him or even free), and in country B the user will dial another number. They will reach the
same IVR and will use the same service, but they will save on telephone fees.
Kolmisoft 2006-2012
260
We click on the icon for the first DID:
We select our Dial Plan and click the confirmation icon to assign our Dial Plan to this DID:
Now the user can dial number 12026911622 (in the example) and he will be able to reach IVR
and use his Calling Card.
Options
This option only applies to Calling Card Callback. You can ignore it if your Callback Dial Plan is
not for Calling Cards.
Kolmisoft 2006-2012
261
Mark it to ask for Calling Card Number/PIN only after system calls back to the caller who
initiated callback.
By default, the system asks for the caller to enter a Number/PIN at the point when he tries to
initiate the callback.
This feature provides CallerID management for callback. The following options are available:
This function is useful when Providers check Destination and CallerID and block the call when
they match. For example, without this function it is not possible to use Callback in the Telus
Mobility network in USA/Canada.
Kolmisoft 2006-2012
262
3. Enter * sign in a marked field:
Please note that the above example only illustrates how to create and IVR Dial Plan and it
does not mean that IVR Dial Plan is only applicable for Calling Cards. Using IVR you can
program automatic answering machine to redirect the caller to an appropriate departament,
for example. For better understanding of IVR logic see IVR system.
STATISTICS -> Various –> DIDs is showing various parameters of DIDs using statistics.
Kolmisoft 2006-2012
263
Calls - number of calls which was made.
Profit - amount expressed as a value that is left over from sales once all expenses have been
deducted.
Accounting
Accounting in MOR is implemented to keep track of all payment activity. It is also possible to
create various services, make subscriptions for them, and generate invoices for the clients.
Services
A Service is a product that can be sold to the client. There are various types of services. For
example:
Monthly fee.
Line rent.
Phone rent.
Internet plan.
Example:
You can create an unlimited number of Services. All of them can be found in SETTINGS –>
Accounting –> Services:
Kolmisoft 2006-2012
264
Service types
Periodic fee per month - user is charged every month for this service.
One time fee - user is charged only once for this service.
Flat-Rates - user is charged every month for this service and can dial a certain number
of minutes to certain destinations.
Selfcost
It allows you to include all your expenses to track the real profit correctly.
Example:
You have a subscription to charge your clients for internet connection by 10 EUR, but it cost 6
EUR for you. Client pays 10 EUR to you, but real profit is 4 EUR.
Subscriptions
Users can subscribe for some services. When they do, they get a service Subscription. Service
Subscriptions can be found for each user in the Users main window by clicking the icon for
the selected user:
Kolmisoft 2006-2012
265
Subscriptions can have a Memo (if you sell a DID, for example, you can make a note of its
number here). Subscriptions also has the important fields Activation start and Activation
end. This data interval will be billed in the invoice, but dates before and after this interval will
not be billed.
It is not recommended to delete subscriptions, or the user will not be billed for that
subscription. If the user stops using a service, set the Activation end value to the date when
he does so.
NOTE: A service is billed from Activation Start till Activation End, and from the start till the
end of the invoice period. The time period that fits within both the previous periods is the
actual period that will be billed.
Every month a subscription about all subscriptions made in the system during the month is
sent to admin. Also resellers' subscriptions are also sent to admin.
Date: 2012-5
Subscription calculation
Subscriptions are calculated by the following rules:
When a Subscription is assigned to a Prepaid user, the price for the first month is
deducted from the user's balance instantly (and an appropriate Payment with type =
subscription is created).
Kolmisoft 2006-2012
266
*If the Prepaid user does not have enough balance to cover this subscription, the
subscription fails.
When a Subscription is assigned to a Postpaid user, no changes are made to his
balance instantly.
Every month day 1, 00:10:00, an action is executed which performs the following calculations
(blocked users are skipped).
Prepaid users
For Prepaid users, the balance subtracts the Subscription price for this new month.
A New Payment is created, with type = 'Subscription', to mark the user's balance deduction
(only for Prepaid users).
If a Prepaid user's balance becomes negative, this user is blocked and receives a notification
email (as does his owner).
If this option is not enabled - then MOR allows user balance to drop below zero. If this
option is enabled - user is blocked when there is not enough money for a subscription - both
user and admin are informed about this by email.
Postpaid users
For Postpaid users, the balance subtracts the Subscription price for the previous month.
If the Postpaid user's balance + credit < 0, he is blocked and receives a notification email (as
does his owner).
Kolmisoft 2006-2012
267
Subscriptions scheme
Example 1: user balance is -4.00 USD, credit = 5.00 USD. Balance + credit = 1 USD, so user
will still be able to call.
Example 2: user balance is -4.00 USD, credit = 4.00 USD. Balance + credit = 0 USD, so user
will not be able call.
Balance is an amount of money user already paid you, but have not been spent yet on
services you provide (can make calls using this money). Current user balance can be
checked in user details
Kolmisoft 2006-2012
268
Allow prepaid users balance to drop below zero
Example
A user is postpaid.
-$75 is for calls. Also, the user has to pay $475 for subscriptions.
The system calculates the subscription price and deducts $475 from his balance.
The user balance becomes -$550.
The user gets an invoice for $550.
He makes a payment of $500.
The user's balance becomes -$50.
In the next month, the user gets an invoice for calls made over that month + subscription
prices in that month.
-$50 will be shown on the invoice, but will not be included in the new invoice.
Invoices
Configuration
All settings for Invoices can be set in the Invoices section of the Configuration window.
Kolmisoft 2006-2012
269
Invoices can be viewed and created in SETTINGS –> Accounting –> Invoices. In the main
window, you can see all the invoices:
Here you can view the details of all invoices and click on the or icons to generate invoice
files in PDF or CSV formats accordingly.
Kolmisoft 2006-2012
270
Invoice generation
In the main Invoices window, click Generate Invoices to generate additional invoices:
Select for which users to generate invoices. Prepaid and Postpaid users can have separate
details. Also, you can check to generate an invoice for only one particular user.
Sometimes it is needed to generate invoice when total call price is 0 anyway. By default this
possibility is disabled if you want to enable it go to SETTINGS -> Setup -> Settings ->
Invoices tab, select Calculate 0 price Calls into Invoices and click Save changes.
Kolmisoft 2006-2012
271
Detailed invoice settings
To access detailed invoice settings go to: SETTINGS -> Setup -> Settings. Click on tabs:
Invoices -> Postpaid or Prepaid -> Details. You will see this window:
In MOR 12 there are new additional options: Add Average rate in detailed invoice (shows total
price/total minutes) and Show Time in Minutes (shows time in mm:ss instead of hh:mm:ss, for
example, not 02:13:42 but 133:42).
Invoice recalculation
An invoice cannot be modified after being sent. But if you want to allow recalculations after
sending invoices, go to: Settings -> Setup -> Settings. Then click on the tabs: Invoices ->
Functionality.
Kolmisoft 2006-2012
272
Select Invoice allow recalculate after send:
Click to open more options to enter the period in which you want to send invoices. Click
Send to send invoices to their Users in this period:
Kolmisoft 2006-2012
273
PDF invoices
You can print your invoices on paper with a pre-printed logo if you want to send paper
invoices.
Invoice comment
If an invoice is not marked as paid - it can be recalculated for the same user, same period. To
achieve this - press the marked icon:
Kolmisoft 2006-2012
274
Invoice list to csv
Invoice language
Default language in MOR is English. However, you can send invoices in different languages
(click on the flag icon on the top of the page).
See also
Accounting
Invoice configuration
Pay Invoice with balance deduction
Invoice by CallerID
MOR API invoices
Cannot generate Invoice
Invoice configuration
In User's settings it is possible to configure some invoice settings for this user:
Kolmisoft 2006-2012
275
Generate Invoice
This option marks whether an Invoice for this user should be generated.
PDF/CSV Options
Here, checks decide what kind of invoices (as attachments) should be sent to users by email.
See also
Configuration from GUI -> Invoices
When an invoice for a user is generated, and the user pays it, we need to check it as
completed. After this is done, the user's balance is increased by the value of invoice.
Then in invoices (SETTINGS - Accounting - Invoices), we see an invoice for this user:
Kolmisoft 2006-2012
276
Click Details to see the invoice details. Check Create payment for completed invoice and click
the red cross icon above to mark the invoice as completed and paid:
... and in Payments (SETTINGS - Accounting - Payments), we see that payment for invoice is
created:
Other notes
Note: if you want to revert all changes, it is enough to click the green check mark in Invoice
details. The user balance will be decreased, payment deleted, and the invoice marked as not
processed.
Kolmisoft 2006-2012
277
Invoice by CallerID
This type of invoice groups all calls by CallerID.
Only outgoing calls are included in this invoice.
Starting from MOR 9 you can export invoices by CallerID into CSV:
Kolmisoft 2006-2012
278
MOR API invoices
MOR API
Request
If a user has 'admin' rights, he will get ALL invoices from the selected period. If user has 'user'
rights, he will get only HIS invoices from the selected period.
HTML POST:
http://<SERVER
IP>/billing/api/invoices?u=username&p=password&from=1188604800&till=1191196799&la
ng=en
Here:
from/till - time period for invoices in Unix Epoch Time format. Invoice's period start
should be >= from and period end <= till.
o http://www.epochconverter.com/ can help to convert time for testing.
lang - choose the language in which you want to get invoice details (mainly 'Calls').
Example result
<Invoices from="2007-09-01" till="2007-10-01">
<Invoice agreementnumber="0000000000" user_id="0" clientid="240887380">
<Product>
<Name>Monthly fee - test</Name>
<Quantity></Quantity>
<Price>10.0</Price>
<Date_added>2012.02.02</Date_added>
<Issue_date>2012.02.02</Issue_date>
</Product>
</Invoice>
<Invoice agreementnumber="0000000000" user_id="0" clientid="240887380">
<Product>
<Name>Calls</Name>
Kolmisoft 2006-2012
279
<Quantity>65</Quantity>
<Price>112.3324</Price>
<Issue_date>2010.01.01</Issue_date>
</Product>
</Invoice>
</Invoices>
Errors
<Error>user not found</Error>
<Error>no invoices found</Error>
Credit notes
About
We can say that Credit notes functionality is opposite to invoices. If "paid invoice" means
that users balance decreased then "paid credit note" means that users balance increased.
Sometimes due to various inaccuracies user pays more than he should. That is why this
functionality useful - to correct those inaccuracies by paying the money back to the user.
Kolmisoft 2006-2012
280
Click Create credit note. You will see this window:
Issue day - by default it is the day credit note was created. But you can choose different date.
User - select a user from dropdown for which you are making this credit card.
Number - same as with invoices, you can enter any symbol or symbols here.
Click Create.
A user whom you made and paid a credit note will see this in his Payments:
Kolmisoft 2006-2012
281
Possible errors
"Incorrect hash" - self-explanatory
"Bad login" - self-explanatory
"Credit note was not found":
o editable credit note was not found
o credit note does not exist
o credit note belongs to the user you cannot see
"Credit note was not updated" - if you see this error possibly something in MOR
database went wrong
"Credit note was not created" - this error shows up if Issue day or Price fields are
empty.
Kolmisoft 2006-2012
282
Payments
Definition
A Payment is created when a user pays the system owner for some Service:
Kolmisoft 2006-2012
283
Manual payments
Sometimes customers send money through a bank or other means, or they might use some
online gateway not implemented in MOR. To handle such transactions, MOR has Manual
Payments.
When a user sends an amount to you as the owner, you need to enter this amount into MOR
using the Manual Payment window, which can be found in SETTINGS –> Accounting –>
Payments –> Add manual payment.
The first window lets you choose the user and enter the amount (with TAX) in the selected
currency:
Next, click Proceed to see the calculated values for this Payment:
Kolmisoft 2006-2012
284
Click Confirm to enter this payment, which can be seen in the Payments window:
After payment is entered, the user's balance will increase and he will see the payment in his
Payment sections.
The Administrator can delete this payment by the user. After it is deleted, the user's account
will decrease accordingly.
Initial balance
Initial balance is the balance that was added to user during its creation. Initial balance is valid
for registered users (via GUI or API), users created by admin and users created by reseller.
Initial balance lets you see user's primary balance without CLI.
See also
Accounting
Kolmisoft 2006-2012
285
Vouchers
What is vouchers?
Vouchers are used to fill the balance of a user. You can sell vouchers printed on paper, or sell
them over the Internet. When a user logs in and enters a voucher number, his balance will
increase by the value issued for this voucher.
You can find vouchers here: SETTINGS –> Accounting –> Vouchers
All voucher configuration options are in the Vouchers section of the Configuration window.
You can view created vouchers in SETTINGS –> Accounting –> Vouchers:
Kolmisoft 2006-2012
286
This window show the status of the voucher. Active? shows whether we can use the voucher.
All other information is self-explanatory.
Here you can enter the necessary information to generate an array of vouchers.
The tag field is only used to mark a series of vouchers. It is just for informational purposes or
for easier search.
Kolmisoft 2006-2012
287
After that remember to enable vouchers:
2. Select tab vouchers and ensure that option Vouchers enabled is enabled.
When a user logs in, he sees vouchers icon on the main page:
He can click it and enter the voucher number. He can try up to X times, where X is set in
configuration menu. If he fails to enter the correct voucher number X times (the maximum
number he is allowed), he will not be allowed to enter the voucher number again for a set
period of time. The values for how many times he can try and for how long to disable
attempts to enter are configurable in the Configuration menu.
When the user enters a correct voucher number, his balance will increase, he will get a new
payment record, and this voucher will be marked as used.
Make sure Active Till is tomorrow or a more distant point in the future.
2. Go to "Visual" tab and check if Hide payment options for postpaid users option is set. If
so - unset it and vouchers will be visible.
Kolmisoft 2006-2012
288
See also
Accounting
PBX Functions - Use Voucher
Flat-Rates
Description
Flat-Rates means a service plan under which a Client can dial a number of minutes to certain
Destinations for a fixed amount. After the user has used all his flat-rate minutes, all additional
minutes are charged at the normal rate.
Setup
Acknowledgments
Kolmisoft 2006-2012
289
IMPORTANT: If a user is PREPAID, limit his calls to 1, because otherwise a loss is
possible. (Explanation: calls will not be cut when Flat-Minutes will run out and
small loss is possible till all Flat-Rate based calls will finish. After that no more
calls will be possible).
Only Admin can create and manage Flat-Rates and assign to Resellers/Users.
o Resellers CAN NOT create/manage Flat-Rates nor assign them to their Users.
o Admin CAN NOT put Flat-Rates on Reseller's Users
Reporting
Active Calls
Description
In Quick Stats in the main window, it is possible to see Active Calls. These are the calls that are
in the system at the moment.
It is possible to click and open a new window with detailed Active Calls. You can get to this
window in STATISTICS –> Calls –> Active Calls.
Kolmisoft 2006-2012
290
In this window all active calls are presented with more details, such as Start Date, Duration,
Src, Dst.
In order to see the correct duration on multi-server systems, the time should be synchronized
on all of the servers.
It is possible to reset statistic by clicking the "Reset active calls information" button. As the
text next to the information icon says, it will not affect your calls in any way.
NOTE: local calls are not visible on MOR GUI, only calls to/from outside.
If the call is still here, it means that Asterisk can't hang up the call. It has stuck. Stuck calls are
cleared every two hours. There's no need to do anything further.
Kolmisoft 2006-2012
291
Active Calls for Users/Resellers
In order to enable this functionality for Users/Resellers, check the relevant setting (it is
disabled by default):
Users/Resellers will now be able to see an Active Calls selection in their Personal menus:
Kolmisoft 2006-2012
292
Active Calls for Users/Resellers shows codec used for call
System requirements:
This functionality shows which codec is used and PDD for active calls in real time.
When call is answered it shows information of codec used for LegA and LegB and call time.
Kolmisoft 2006-2012
293
Show DID in Active Calls
To make a DID column appear in the Active Calls window go to SETTINGS -> Setup ->
Settings, click on the Functionality tab and look for Active Calls tab in the appeared window.
Select Show DIDs in Active Calls.
Kolmisoft 2006-2012
294
Last Calls
STATISTICS –> Calls –> Last Calls shows the most recent calls in the system. It is used in
Troubleshooting.
Please note that when occurs a call where DID is involved it consists of two legs (call from DID
to MOR and call from MOR to Destination). They will be shown seperately in Last Calls list.
Search
Starting from MOR 9 a search bar was added for Last Calls statistics.
CSV
Using the "Export to CSV" icon you can export your currently displayed calls into CSV
Kolmisoft 2006-2012
295
PDF
Using the "Export to PDF" icon you can export your currently displayed calls into PDF
When call is initiated by the caller, at least one call leg is created - from user agent
client(UAC) to user agent server(UAS) - usually called LEG A. Based on routing rules, call may
be canceled(in case there is no suficcient funds, no appropriate rule etc.) or one more call leg
may be created - from UAS to destination another UAC (LEG B). Many call legs may be
created depending on routing rules and whether call to destination was succesfull. For
instance:
there we have one failed call and one call leg (LEG A - OK, LEG B - FAILED)
Kolmisoft 2006-2012
296
but PBX can route the call through another provider D
user B answers
there we have three call legs, two of them were bridged and we would say that there
was only one call which was connected.
If user A is interested only in calls made, information, about how many attempts were made
to call user B, has no interest for him. Majority of users will be interested only in call duration,
who terminated the call etc.
Hence this is how call information is represented in call statistics, trying not to overwhelm
users with too much technical details, only information about successful call is presented,
ignoring details about made call legs (FAILED or NOT, etc). Provided you want to check the
information on FAILED and connected call LEGS, you can use the Call Info page.
See also
Troubleshooting
Reporting
Users Calls
This report shows all the calls a user has made in a selected period. It is possible to export this
list to PDF or CSV format.
Kolmisoft 2006-2012
297
To find this report go to STATISTICS –> Calls and click on icon.
Users Finances
The Finances window lets you view a user's entire financial situation in one window. It can be
reached in STATISTICS –> Finances:
Kolmisoft 2006-2012
298
To find such calls, you should use this function. Just select the desired period and all loss
making calls will be visible.
You can find this report in STATISTICS –> Calls –> Loss making calls:
This window shows you loss making calls in the selected period. If you click on the user or
provider rate, you will go directly to the rate's edit window and be able to edit it.
Providers Statistics
You can reach this report in STATISTICS –> Various –> Providers. This report shows all
providers' statistics at once:
In the selected period, you can check various statistics about all the providers in your system.
If you click on a number in the Answered/No Answer/Busy/Failed columns, you will open a
window where these calls are listed.
Kolmisoft 2006-2012
299
While making a prefix search, if you want to see all prefixes starting with a certain
combination, you should enter % at the end. For example, if you want to see all prefixes
starting with 37 you will have to enter 37%. If you enter only 37 you will only see this prefix.
Providers Calls
1. Go to SETTINGS –> Billing –> Providers:
2. In the main Providers window, click on the to open the Providers' Calls page:
Here you can see all calls for the selected provider in the selected time period. You can
change the type of the call.
You can also export the selected calls to PDF or CSV format.
Kolmisoft 2006-2012
300
First Activity
This window shows the User's First Call, if the call was made in the selected period.
NOTE: It does not necessarily show the first call the user made! It only shows the first call of
the user in the selected period. The first call of the user may have been made outside the
selected period. In that case, it will not be shown here.
Quick Stats
These stats are seen on the Main Page just after Login.
Kolmisoft 2006-2012
301
Admin Quick Stats
These are stats for all calls made in the system in this month.
Admin calls are counted same way as user calls, i.e. profit from then = user price - provider
price.
Click on the Active Calls value to go to the Active Calls page for more details.
Kolmisoft 2006-2012
302
These are calls made by the reseller or by his users.
The profit from calls made by the reseller himself = 0 for the reseller.
Go to SETTINGS –> Setup –> Settings –> Visual and check Hide Quick Stats option.
Other notes
If you have a big database quick stats might degrade your server performance. If you
have a big database it is recommended to hide quick stats.
Kolmisoft 2006-2012
303
Simultaneous Calls stats
STATISTICS -> Calls -> Load Stats
These stats help to check and find how the server is loaded during a certain time period.
Direction:
Provider - a provider that was used to send calls, not receive them.
Kolmisoft 2006-2012
304
Calls by Source
Description
NOTE: Unknown calls are calls for which the CallerID length is < 11 digits or for which the
number is invalid (does not match the E164 format).
Window is empty!
This happens when MOR cannot determine the destination calls have come from (for
example, when there are no correct CallerIDs).
MOR tries to determine the origin by CallerID. So, if we have calls like these in Last Calls:
Kolmisoft 2006-2012
305
... MOR can't know which destination calls came from.
Here all CallerIDs are local extensions, which means they are not related to any Destination.
See also
Last Calls
Login Stats
Login statistics can be viewed by the admin under STATISTICS –> Calls and clicking the
icon.
It shows in which periods the User was logged into the MOR GUI.
Kolmisoft 2006-2012
306
Profit Stats
It is important to know at any moment what profit your system is generating for you.
All fields are self-explanatory. You can check your profit by period and by selected user.
Country Stats
This report shows calls by countries.
Kolmisoft 2006-2012
307
It can be found in STATISTICS –> Various –> Country Stats:
By pressing the marked link you can export country statistics to CSV
Kolmisoft 2006-2012
308
Troubleshooting
If rates does not seem right, check Destinations Groups because based on Prefixes included in
these Groups are accounted in this report.
You can find a demo for Google Maps at Google Maps integration wiki page
You need a Google maps key to use the Google maps plugin.
Go to Google.
Write your site in the text box below. Note that http://1.2.3.4 differs from
http://yoursite.com, so enter the hostname that you will use to access your site.
Press "Generate API key" and Google will give you your key.
Insert this key in SETTINGS –> Setup –> Settings –> Google Maps –> Key.
Click Save changes.
Kolmisoft 2006-2012
309
Balance in phone
Some phones and softphones support displaying your account balance on their screens.
[http://iaxtalk.com/index.php?main_page=product_info&cPath=6&products_id=7].
In SETTINGS –> Setup –> Settings –> Various –> Allow devices to check balance over
HTTP, check to allow this functionality:
Kolmisoft 2006-2012
310
Copy and paste this link into the phone:
Optionaly you can send api request and specify currency, valid values are USER, in that case
balance is returned in user's currency. And currency code(EUR, USD etc.)
HTML POST:
http://<SERVER_IP>/billing/api/simple_balance?id=UNIQUEHASH¤cy={USER|CURRENC
Y_CODE}
Kolmisoft 2006-2012
311
Privacy to hide Destination ends
Description
This functionality is required by Italian law, which states that the last three digits of
Destinations (Numbers dialed by User) should be hidden if the User requests it. However,
they should not be hidden by default in Italy.
[http://www.garanteprivacy.it/garante/doc.jsp?ID=1501106].
[http://translate.google.com/translate?js=y&prev=_t&hl=en&ie=UTF-
8&layout=1&eotf=1&u=http%3A%2F%2Fwww.garanteprivacy.it%2Fgarante%2Fdoc.jsp%3FID
%3D1501106&sl=it&tl=en].
In MOR it is possible to set up Global settings for hiding Destination ends that are applied to
all Users by default, or to set up per User if a User requests that his destinations should not
be hidden.
Destinations are hidden only for Users and Resellers. Destinations are not hidden for Admin.
Kolmisoft 2006-2012
312
Global Settings
In SETTINGS –> Setup –> Settings –> Privacy, it is possible to set Global settings for all
Users that will be used by default:
In Users details, set to use Global settings or select different settings just for this User:
Kolmisoft 2006-2012
313
How it looks
Troubleshooting
Action log
In this window you can check what actions were done on the system at which time and who
did what.
Kolmisoft 2006-2012
314
nd (Admin/reseller) send
email_send from which user send for which user which email
(Admin/reseller) send
error to which user error error, example: error which email send
happened "Can't send description,
email" example:
"getaddrinfo:
Name or
service not
known"
backup_created shows which user what was return values:
created a backup backed up 0 - success, 1 -
error
device_created shows which user which
created a device device it
is
device_pin_changed shows which user which the old PIN the new PIN
changed the device PIN device it
is
device_secret_chan shows which user which the old secret the new secret
ged changed the Device device it
secret is
device_voice_mail_p shows which user which the old the new
assword_changed changed the device's device it voicemail voicemail
voicemail password is password password
did_assigned shows which user which DID it is which dialplan
assigned a DID it is
did_closed shows which user which DID it is
closed a DID
did_created shows which user which DID it is
created a DID
did_deleted shows which user which DID it is
deleted a DID
did_edited shows which user which DID it is
edited a DID
did_edit_provider shows which user which DID it is which
edited a DID provider provider it is
did_made_available shows which user made which DID it is
the DID available
did_rate_edited shows which user which DID it is which rate it is
edited a DID rate
did_reserved shows which user which DID it is which user it is
reserved DID
dp_created shows which user which dialplan
created a dialplan it is
dp_deleted shows which user which dialplan
deleted a dialplan it is
dp_edited shows which user which dialplan
changed a dialplan it is
first_call shows which user made which call it was
a first call
invoice_deleted shows which user which users
deleted invoice invoice it was
Kolmisoft 2006-2012
315
hacking_attempt which user request URL request which This message is not always
remote paramet related to real "hacking" it
address ers may be caused by multiple
tabs opened, with different
users logged in or by
entering direct links in
browser to call some action.
Generally this action is
registered when a user tries
to open a link which is only
available to admin. This
action is also registered
when a user instead of
clicking on some icons tries
to access the page directly
PayPal which user payment status,
example :
"Payment
completed: 5.8
EUR"
SMS_callback which user which SMS status, clicatell SMS Data 4: parameters have
SMS example : "003" charge, charge been received
example : status,
"3.000" for
example
: "0 -
user
balance
was not
charged
", or "1 -
user
balance
was
charged
."
system_validated Admin
tariff_import shows which user 'Tariff_was_imp
imported tariff orted_from_CS
V'.
user_created shows which user which
created a user user
was
created
user_edited shows which user which
changed a user user
was
change
d
user_tariff_changed shows which user which the tariff's old the tariff's new
changed a tariff user name name
Device send to shows which user which device user ID
asterisk created / updated device
device
Kolmisoft 2006-2012
316
Confline changed shows which user which device user ID from MOR 11
created / updated device
device
User actions
By pressing the 'User Log' button in the User window:
As it is seen in the picture, you can mark all the actions as reviewed.
Call Tracing
Overview
This function is for checking the setup of MOR in order to be sure a user will be able to dial
out. To set MOR up isn't simple, but we are trying to make it easier with this manual and with
improvements to GUI. It often happens that users miss some important detail while trying to
Kolmisoft 2006-2012
317
make everything work. Call Tracing will save a lot of head-scratching, and we hope it will be
helpful for beginners.
Important! This function is for testing Dialing OUT. DID testing is not yet implemented.
This function can be found in SETTINGS –> Billing –> Function –> Call Tracing. It can be
quickly accessed in the Users menu (SETTINGS – Users) as well. Just click on the icon for a
user.
User testing
The next window shows us whether we have configured everything properly for the selected
user. Let's look at each section separately.
Kolmisoft 2006-2012
318
Here we see four errors that prevent the user from operating. Let's say we want to allow a
user to make calls. We will go through each of the errors and fix them.
1. This error tells us that the user is Blocked and so unable to make calls. We should go to
User Details and unblock him.
2. Balance and Credit for this user are empty, and the user type is Prepaid. That means he has
no funds to cover the call fees. There are several ways to go about fixing this:
If the user is postpaid, he should use some payment method to increase his balance.
PayPal and Manual Payment, among others, are good ways to do this.
We can change the user type to postpaid and then we should adjust his credit. Maybe
it is unlimited, maybe some limit exists. But this will allow the user to dial out.
3. We see that the user has assigned a tariff and a type of tariff. The type of tariff is just for
informational purposes. Here 'Explanation' tells us that Tariff is empty. That is the reason why
the user is not able to dial out. In addition, the user can dial out only to those destinations
which have rates. Currently none of them has. You need to add some rates to the existing
tariff or assign a non-empty tariff to this user.
4. The user has no devices. A Device is necessary in order to dial out. Just create one for this
user.
Kolmisoft 2006-2012
319
We can proceed with the next section, which is about LCR:
It tells us that the LCR we assigned to the user has no Providers. We should fix this. When at
least one Provider is in the LCR assigned to the User, we should see:
This error happens when all providers in LCR are disabled. We need to have at least one
active provider for the user to be able to dial out:
Another problem is that none of our active providers has any rates. We should add rates to
the provider's tariff. We can click directly on the Tariff to go to its rates and add some of
them. After that, we should see:
Kolmisoft 2006-2012
320
To summarize this whole section, you should check for and read the error descriptions.
After fixing the errors, you should see . That means the problem is solved and you can
proceed. If at the bottom of the page, you see:
... that means you still have unresolved issues. After all the issues are resolved, you should see:
When you see this green message, you know that your user is configured properly. He is not
blocked, he has enough money in his balance to pay for the call, his tariff has rates for some
destinations (so only these destinations are available to dial), and he has some devices to use
for dialing. Also, his LCR has active providers with tariffs that are not empty.
Device testing
The following section lets us choose a device and a call date, and enter the destination we
want to test. For example:
This data means that we are testing a virtual call from device SIP/1004 to number 863042438
on 2009 August 26th 00:00.
Kolmisoft 2006-2012
321
When we click Press this button to continue, we will go to the next page and we will see
something like:
The Details section shows us just routine information. We already knew this information, so it
is not important.
If you see direction as Unknown, it means your number is not in E.164-compatible format.
Edit Localization rules to transform your number to E.164 number format.
Here we see the device's Location and Applied rule, and the result after localization.
IMPORTANT! Software can't read a user's mind, so it can't know where a user is dialing.
A User dials 863042438. After Localization, we see that number is still 863042438 - which
means it's somewhere in China. But this is wrong, because the user dialed a Lithuanian
number in local format! What does this mean? It means that Localization is not configured
properly. MOR can't show you an error here because there's no way to tell whether it's okay
or not.
You should decide for yourself. All MOR can do is show you all the information it can get
from the call, and it does that.
So in order to proceed with the example, we have to set a correct Localization rule for this
Kolmisoft 2006-2012
322
number format. After doing this, we will see:
Now everything is okay. The localized destination is E.164 compatible. Now MOR understands
that it's Lithuania.
... it means we do not have rates or custom rates for the dialed destination. After adding
them, we should see:
This window also shows us that we do not have a custom rate for this destination. But it's
enough to have a simple rate for a destination to be able to dial out or vice versa.
Kolmisoft 2006-2012
323
We can proceed to the providers:
We can see that our provider does not have a rate for this destination. After fixing it we
should see:
Conclusion
You will see using Call Tracing what is happening and where the call is going.
When rates for user and provider are checked using localized destination, and when all data
are in place, there's no obstacle to prevent the call from being sent to the provider.
IMPORTANT! The green message at the end of Call Tracing does not mean the call will be
successful! It only means that MOR will send the call to the provider. The last table shows
Kolmisoft 2006-2012
324
what string it will send to the provider. Applied Provider Rule parameters (Cut and Add) are
also visible in the table.
MOR can't know whether the provider accepts your dial string or not. That depends on how
you configured Provider Rules. Call Tracing shows you the formatted number which is sent to
the provider, but you should decide whether or not it is correct.
If a call fails, check Users Calls or Providers Calls and check Hangupcause Codes to find the
reason.
Integrity Check
This window tests various properties of the billing system and tells where potential problems
may be.
This window shows Destinations which are not assigned to any Destination Group. This can
lead to many problems, such as incorrect billing.
Destinations not assigned to any Destination Group appear after a tariff rate import. It is
necessary to assign these Destinations to their correct Destination Groups just after new rates
are imported.
Kolmisoft 2006-2012
325
IMPORTANT: if you have Destinations not assigned to Destination Groups, your
Detailed Invoices will have incorrect call amounts!
Actions errors
Shows actions which requires attention and possibly changes in configuration. It reports
about issues such as unsent emails and suspicious activity on accounts. Click "Fix" to see the
list.
Insecure devices
Shows a list of devices which have Dynamic IP and Insecure Invite options enabled. Such
combination allows to make call with incorrect device password.
Shows devices which have weak passwords. Passwords of these devices should be changed.
Click "Fix" to see the list.
See also
Destinations Groups
Kolmisoft 2006-2012
326
Hangupcause Codes
MOR application saves hangupcause codes (HGC in MOR terminology) to the database, so it
is easy to check what the error was and why the call failed.
These codes can be seen in the Calls window (Hangup Cause column) when selected to show
'All', 'Busy', 'No Answer', 'Failed' or 'Missed' calls.
Reseller's balance is too low to make more 232 Callback DID not available
216 simultaneous calls 233 Skype Addon Disabled
Kolmisoft 2006-2012
327
Relation between MOR hangupcause codes and Standard codes
This table describes which standard ISDN code is MOR giving when one or another
hangupcause is given.
All others not listed above and greater than 21 403 Forbidden
199 ( >=200 )
See also
Hangupcause Sounds
H323 hangupcause codes
SIP Error Codes
Kolmisoft 2006-2012
328
Hangupcause Sounds
Description
The codes are written in Asterisk CLI. The codes are visible in the Call List near each call.
To make it even simpler, MOR can play associated audio when some error happens. To
enable the audio, make play_hgc_audio = 1 in mor.conf and restart Asterisk.
If this setting is equal to 2, then sound files will be played for ALL error codes (sound files for
these error codes are not included into MOR) (This option is available starting from MOR 10.)
This setting is available to help new users start with MOR and get instant feedback about
failed calls.
IMPORTANT! For production use this setting should be disabled, because a call has to be
answered in order to play these sounds and the dialer has to pay for the call.
How to disable
play_hgc_audio = 0
To check whether this setting is disabled, you can enter in Asterisk CLI:
Kolmisoft 2006-2012
329
Server ID: 1
Active calls now/limit: 0/1000
Global call timeout: 7200 s
Use LCR Partials: 1
Check banned CLIs: 1
Use Speed Dials: 1
>>> Play HGC Audio: 0 <<<
Use Flat-Rates: 1
How to change
Sound files are stored in /var/lib/asterisk/sounds/mor/hgc. Overwrite them with sound files
(converted to Asterisk readable format).
See also
Hangupcause Codes
H323 hangupcause codes
I do not want to hear an error message at the end of the call
This is decided by the Asterisk system and MOR has absolutely no control over this behavior.
One possibility is to mark the Device as Trunk. This can help in receiving the correct code, but
it is not guaranteed.
Kolmisoft 2006-2012
330
Call Info
This window gives detailed info about the call.
It can be accessed from various pages by clicking on the icon near the call:
Kolmisoft 2006-2012
331
A new window opens with detailed call info:
Kolmisoft 2006-2012
332
Call Log
See also
SIP debug info can be enabled per SIP device basis. It is useful in debugging. When enabled,
it is saved to the Calls table.
Kolmisoft 2006-2012
333
When it is checked and the Device Type is SIP, then in Asterisk CLI you can see something
like:
In GUI, hold the mouse pointer over the special icon for this call to see the same info:
Asterisk CLI
You can see all call progress on Asterisk CLI (command line interface).
asterisk -vvvvvvvvvR
That's it.
Kolmisoft 2006-2012
334
To leave Asterisk CLI type exit and press ENTER
See also
Kolmisoft 2006-2012
335
You can get a lot of output. Look at the last line, which may look like this:
[Feb 26 16:12:14] NOTICE[32733] app_mor.c: Localized destination: 37063042438 (cut: , add: )
The most important part is in BOLD, and in this example it is: 32733]
NOTE: First brackets are not included! This is very important!
7. Now do:
cat messages | grep 32733]
... and you will get output of your call.
Version: 9.1.15
YOU DO NOT HAVE TO WORRY ABOUT THIS, BECAUSE ALL THESE CALLS FAILED.
Kolmisoft 2006-2012
336
Such calls look like this:
Other symptoms
Maintenance
How to restart Asterisk server
If you restart/shutdown your Asterisk server when there are active calls going:
1. Users will be disconnected and will not feel very happy about your service;
2. You will lose money on the active calls, because provider will charge you for these calls
but you will not be able to charge your users because calls will not be in database.
Just run:
/usr/src/mor/sh_scripts/asterisk_nice_restart.sh
to restart service.
Kolmisoft 2006-2012
337
Upgrade MOR GUI
What is MOR GUI Upgrade?
MOR GUI upgrade is a procedure to update your graphical user interface (GUI) to the newest
version.
Some features are being implemented after official version release, so if you find, that you
lack some feature documented in wiki - you should upgrade your GUI to receive that feature.
P.S. Use the procedure that matches your version, otherwise it might break your
system. To upgrade to a newer version - please contact the Kolmisoft team
rm -fr /usr/src/mor
svn co http://svn.kolmisoft.com/mor/install_script/trunk/ /usr/src/mor
/usr/src/mor/upgrade/10/fix.sh
3. Press ENTER in console again for script to reset password to previous one
Kolmisoft 2006-2012
338
Where I can get my serial key from
Login to your system and execute:
This will shows your key from mor in format where serial = xxxx (xxxx will be your serial).
Testing
VoIP Bandwidth Calculator
What is a VoIP Bandwidth Calculator?
VoIP Bandwidth Calculator is a tool which helps you determine the bandwidth you will need
depending on codecs, protocols other factors you will be using.
http://telconassociates.com/voip-bandwidth-calculator.html
http://www.voipcalculator.com/calculator/lipb/
http://www.asteriskguru.com/tools/bandwidth_calculator.php
Kolmisoft 2006-2012
339
Payment gateways
PayPal
WARNING
You can lose money using PayPal because of the way PayPal
works.
IMPORTANT! PayPal will not cover your loss, because they classify it as: "Seller Protection -
Ineligible".
Kolmisoft 2006-2012
340
2. Select the PayPal tab:
Kolmisoft 2006-2012
341
Return URL on successful payment - redirect user to this page after a successful
payment.
Return URL on canceled payment - redirect user to this page after a canceled
payment.
Test - enable or disable test mode.
Details
A user can pay for services or increase his balance using PayPal. MOR is fully integrated into
PayPal and does not need any manual intervention from an
administrator.
All PayPal options can be set in the Configuration menu of the PayPal section.
Kolmisoft 2006-2012
342
The PayPal payment option can be reached by clicking on the PayPal picture in the main
entry window:
When the user clicks on this image, he will be able to enter the amount he wishes to pay:
Note the minimum value which can be set in Configuration menu. If the user enters a lower
value, he will not be able to proceed.
After clicking on Confirm, he gets another window which shows him how much he will pay:
After pressing on Pay, he goes to the PayPal webpage, where he enters his account details
and confirm the transfer.
After PayPal completes the transfer, the user gets back to the MOR interface. Now, under his
payments he will see a PayPal payment with a Status regarding his payment.
There are many reasons why a PayPal payment may not be completed. To make these
reasons clear, all this information is presented on the Payments page.
Some possible reasons for a PayPal payment not being completed:
echeck: The payment is pending because it was made by an eCheck that has not yet
cleared.
Kolmisoft 2006-2012
343
intl: The payment is pending because the seller holds a non-U.S. account and does not
have a withdrawal mechanism. Seller must manually accept or deny this payment.
multi-currency: Seller does not have a balance in the currency sent. Seller must
manually accept or deny this payment.
unilateral: The payment is pending because it was made to an email address that is
not yet registered or confirmed.
upgrade: The payment is pending because it was made via a credit card and seller
must upgrade his account to Business or Premier status in order to receive the funds.
verify: The payment is pending because seller is not yet verified. Seller must verify his
account before he can accept this payment.
other: The payment is pending for a reason other than those listed above. For more
information, contact PayPal Customer Service.
Denied: Seller refused to accept this payment.
When payment is completed, the user's balance will increase by the value (without TAX) he
paid by PayPal.
This integration makes possible a fully autonomous system in which a user can register
online, pay using PayPal, configure his device and dial instantly WITHOUT any intervention
from the system administrator.
ATTENTION – for PayPal to work, your server should have a real IP and should be reachable
from the internet.
Resellers
Each reseller can enter his own PayPal address.
If you change PayPal as System Administrator, the new Reseller will have same the PayPal
address upon creation. He is able to change this address later.
Question:
What kind of PayPal account is needed to interwork with MOR?
Paypal offers two account types: a Business Account and a Web Account.
Answer:
Both types appear to work with MOR. I can verify that a business account works 100%.
You can create a Web account and try it with MOR. If it doesn't work, it can be upgraded free
to a Business account.
Kolmisoft 2006-2012
344
Notes
Testing mode
If you get a message such as this when trying to use PayPal:
Please login to use the PayPal Sandbox features.
it means you are using PayPal in Testing mode. Turn it off in SETTINGS -> Setup -> Settings
-> Payments -> PayPal:
Kolmisoft 2006-2012
345
Webmoney
Description
This payment gateway is popular in Russia and neighboring countries. Now MOR users can
use http://www.webmoney.ru/ to pay for services.
MOR configuration
Kolmisoft 2006-2012
346
Enabled: check this if you want to enable Webmoney for new signups and existing
accounts.
WebMoney purse: your purse ID consisting of a letter and twelve digits.
WebMoney currency: currency for WebMoney.
Default Amount: default amount.
Min. Amount: minimum allowed transfer amount.
Test: check this if you want to test your online Webmoney transactions.
WebMoney SIM MODE: testing mode.
WebMoney Secret Key: an optional set of symbols which you entered when setting
your purse. Make sure you have the same key in your WebMoney account.
WebMoney logic requires it to prerequest payment before it sends final confirmation about a
successful (or failed) payment.
Sometimes WebMoney does not send any information in a prerequest. To avoid this
situation, this setting can be checked to complete payment.
It is against WebMoney rules and policy. Security level is decreased! USE IT AT YOUR
OWN RISK!
Webmoney configuration
Make sure in your WebMoney account that you choose MD5 hash encoding. (Do not use
SIGN encoding).
Kolmisoft 2006-2012
347
Below is an example of how to configure your Merchant gateway (click on the picture to
enlarge it):
Technical details
Troubleshooting
Kolmisoft 2006-2012
348
payment 1.00 WM via merchant.wmtransfer.com has failed.
NOTE: make backup of environment.rb before editing it, restart Apache after editing
(/etc/init.d/httpd restart).
http://ouroboros.hr/index.php?home_en
Kolmisoft 2006-2012
349
Enabled – yes or no.
Merchant Code – a merchant code
Secret Key – a secret code.
Default amount – amount to show for customer when he tries to enter payment. User
can change this amount.
Minimal amount – the minimum amount a user can send you.
Currency – select a currency which matches your account's supported currency. If they
do not match, you will get errors.
Language – in which language Ouroboros should display the web page.
Cyberplat
Other functionality
IVR system
Kolmisoft 2006-2012
351
This system makes it possible to configure advanced IVR (Interactive Voice Response)
systems.
Definitions
Voices – a set of audio files, such as male/female recordings, that together form a
"voice" for the same IVR.
Time Periods – a start date/time and end date/time that describe a time period.
IVR – a set of IVR blocks.
o Blocks – a part of IVR in which the caller can take some action (press a button-
extension, listen to a recording, etc). Basically block in IVR is "set of rules".
o Extensions – possible button presses (0-9, *, # and some other special cases).
o Actions – what action the system should take when a new Block is reached.
Setup logic
Create Voice
o Record and upload the necessary sound files to Voice.
Create Time Period(s).
Create IVR.
o Create and configure Block(s).
Create the IVR Dial Plan.
Assign this IVR Dial Plan to a DID.
Call this DID to test it.
IVR Voices
Here it is possible to create several Voices. A Voice consists of a set of sound files. Usually all
the sound files in one Voice are recorded by one person to keep the sound consistent.
Time Periods
Here time periods can be set. Time period defines the exact time period IVR will be active.
There is a limit of three periods in Dial Plan. There is a fourth period, but it only consists of all
the remaining time that is not covered by the previous three periods.
IVR Structure
The main part of IVR is Blocks. The whole of IVR is a set of Blocks. A Block can be considered
as a part of IVR logic where a caller can take some action.
Extension is what the user does – presses a button (0-9, *, #), waits (Timeout), or presses any
non-described extension – which can be described as an Invalid Extension. We explain this in
detail later.
Actions are actions which will be activated when the caller comes to a Block.
Kolmisoft 2006-2012
353
Example
A caller calls a DID and IVR answers with a recording: "Thank you for calling SOME
COMPANY. For sales press 1, for management press 2, to speak to a consultant please
hold or press 3."
Here we have only one block: the user listens to the recording and can take some Action ->
press some button (Extension) or wait (Wait is also Extension but is special - it is called
Timeout).
If the user presses something different than 1, 2 or 3, the message will be played again. This is
called an Invalid Extension, or (i) for short.
1 Block.
Extensions: 1, 2, 3, t (timeout), i (invalid).
Actions: call to sales, call to management, call to a consultant, play recording again.
This example is to illustrate the main IVR building parts. We will show how they operate
together to build a working IVR.
Extensions
Extensions are button presses on the dialpad: 0, 1, 2, 3, 4, 5, 6, 7, 8, 9, * and # and two special
extensions:
The 'i' (invalid) extension in the previous example could be triggered when buttons 4, 5, 6, 7,
8, 9, 0, *, # are pressed, because only 1, 2 and 3 are described.
Actions
An Action is some (yes...) action which is executed when a new Block is reached.
Kolmisoft 2006-2012
354
Possible Actions:
Timeouts
Timeout digits
The maximum amount of time permitted between digits when the user is typing in an
extension. When this timeout expires after the user has started to type in an extension, the
extension will be considered complete, and will be interpreted. Note that if an extension
typed in is valid, it will not have to timeout to be tested, so typically at the expiry of this
timeout, the extension will be considered invalid (and thus control would be passed to the 'i'
extension, or if none exists the call would be terminated). The default timeout (in MOR IVR) is
3 seconds.
Timeout Response
The maximum amount of time permitted after falling through a series of priorities for a
channel in which the user may begin typing an extension. If the user does not begin typing an
extension in this amount of time, control will pass to the 't' extension if one exists, or if none
exists, the call would be terminated. Once the user begins to type an extension, Asterisk will
wait for digit timeout to be reached, and response timeout has no effect. The default timeout
(in MOR IVR) is 10 seconds.
Kolmisoft 2006-2012
355
Deleting IVR
If an IVR is not assigned to any Dial Plan, you can delete the IVR by clicking the icon
near an IVR in the IVR menu.
If the IVR is assigned to a Dial Plan, you need to unassign the IVR from the Dial Plan to
be able to delete it.
Setup Hints/Tips
If you want to play a sound file, make sure you have set the correct Voice. By default,
Voice = 'en'. If you have uploaded a sound file for a different Voice, select it before
playing your Sound File:
Kolmisoft 2006-2012
356
Limitations
Currently it is not possible to record calls for a device which is accessed from IVR. For
example, if calls go like this: IVR -> Device, and device has option to record calls for
this device, these calls will not be recorded.
See also
Description
Usually it is a greeting saying, "Welcome to X Cards, thank you for using our services..."
We need to have a Calling Card Dial Plan already created to proceed (check the main guide
for how to do this).
Kolmisoft 2006-2012
357
Steps
1. Create a Voice.
2. Upload a Sound file to this Voice (e.g. a greeting).
3. Create a Time Period in which our IVR will be active (we will make it active all the time
in this example).
4. Create the IVR. The IVR should:
1. Wait 2 seconds for a call to be established.
2. Change the language/Voice to 'zn' - e.g. Chinese.
3. Play the greeting.
4. Transfer the call to the Calling Card Dial Plan (through DID).
Logic
User dials into IVR Dial Plan DID (we will use 111 for this example).
DID 111 forwards to IVR Dial Plan.
IVR Dial Plan plays greeting.
IVR forwards to Calling Card Dial Plan DID (we will use 222 for this example).
DID 222 forwards to Calling Card Dial Plan.
Calling Card Dial Plan executes with normal Calling Card logic.
Note that DID 222 is a middle DID used for inner routing. It can be fake. DID 111 should be
real, so that real calls can come to it.
Video
Video at [http://wiki.kolmisoft.com/index.php/IVR_for_Calling_Cards] demonstrates the whole
setup process:
See also
IVR system
Kolmisoft 2006-2012
358
IVR Greeting for DID
Description
This section shows how to add a simple Greeting in front of any DID. When a caller calls the
relevant DID, the Greeting will be played and then the call will be routed to the the
appropriate action described in DID settings (to Local User, to Calling Card Dial Plan, to
ANI/PIN Dial Plan, to Callback Dial Plan, to PBX Function and similar).
Setting
Go to DID's settings and add sound file which was previously uploaded in IVR-Voices section:
PBX Functions
Tell balance
This function allows one to hear the balance of the account. The account holder can be a user
or card.
Kolmisoft 2006-2012
359
It is possible to hear the balance in different currencies and languages.
First MOR tries to find the user by accountcode, then by CallerID using ANI. Later, if these
methods fail, it asks for a PIN.
MOR asks for the Card PIN if the card balance should be told.
Milliwatt
Generate a Constant 1000Hz tone at 0dbm (mu-law) - good for testing line quality for loss-
packets.
[http://www.voip-info.org/wiki/index.php?page=Asterisk%20cmd%20Milliwatt]
Use Voucher
This function allows one to enter a voucher number over the phone to top up the user's
balance.
Dial Local
This function allows one to dial a local extension.
Most often it is used to allow one to reach local users by dialing DID from outside.
DTMF Test
System will ask you to enter a destination and press #. After that, it will tell you what you
entered.
Kolmisoft 2006-2012
360
If the system asks you again to enter the destination WITHOUT first telling you what you
entered, you have problems with DTMF.
Check VoiceMail
Voicemail
Description
Voicemail (or voice mail, voice-mail, vmail or VMS, sometimes called messagebank) is a
centralized system of managing telephone messages for a large group of people. The term is
also used more broadly, to denote any system of conveying voice messages, including the
answering machine. (http://en.wikipedia.org/wiki/Voicemail)
Voicemail is automatically sent to a user's email if the email address is specified in the device
details.
Kolmisoft 2006-2012
361
Configuration
This section can be found in SETTINGS –> Billing –> DIDs –> PBX Functions –> VoiceMail:
VoiceMail Extension (local) - describes which local extensions a local user can dial to
retrieve his voicemail (the system will ask him to enter his voicemail password, which
can be set in the device's details).
Kolmisoft 2006-2012
362
If you want to setup VoiceMail (VM) on a different server, then the following settings are
important:
VoiceMail Server active - turns VM server on/off. When on, all VM requests will go to
distant VM server; when off, VM will be handled locally on Asterisk.
VoiceMail Server connection/device - describes connection to VM server.
VoiceMail Retrieve Extension (local) - which extension to dial on a distant VM server
to retrieve voicemail for an extension.
Example:
Let's say we have our server on IP 23.45.67.89 connected with SIP to our Asterisk.
We create a separate user/device (vm_device) to describe this connection. Device's
type is SIP, IP = 23.45.67.89; set other settings also (codecs/etc).
VoiceMail Retrieve Extension (local) = 999.
So now when the VM server is ON and the user with device 201 gets a VM, the call is
redirected like this:
Dial(SIP/vm_device/201)
This means that the server on 23.45.67.89 will receive a call to extension 201. The server
SHOULD BE configured so that it will process VM correctly when it receives such a call.
When user wants to retrieve his VM on a distant machine he dials VoiceMail Extension
(local).
Dial(SIP/vm_device/999#201)
Again, the distant server should know how to process such a request.
Kolmisoft 2006-2012
363
So in our example its configuration in /etc/asterisk/extensions.conf should look like this:
[incoming]
# to retrieve VM
exten => _999#.,1,VoiceMailMain(${EXTEN:4})
exten => _999#.,2,Hangup
# to record VM
exten => _X.,1,VoiceMail(${EXTEN})
exten => _X.,2,Hangup
FROM string
To change the Voicemail email sending FROM field, edit the /etc/asterisk/voicemail.conf file
line:
to:
serveremail
This setting can be used to identify the source of a voicemail notification message.
;serveremail=asterisk
to:
Kolmisoft 2006-2012
364
OR:
;serveremail=asterisk@linux-support.net
to
Dial Voicemail access number (default *97) and press 01; then, after the signal, dictate your
UNAVAILABLE message.
[http://en.wikipedia.org/wiki/Message-waiting_indicator]).
See also
Kolmisoft 2006-2012
365
Dial Local
Description
Most often it is used to allow one to reach local users by dialing DID from outside.
Configuration
Video how to create PBX Function "Dial Local" and assign it to a DID:
If you want to play some audio before entering the local extension, assign such DID to IVR
(which plays the necessary audio).
Video on how to do this (ALL ACTIONS IN THE FIRST VIDEO MUST ALREADY BE DONE
BEFORE STARTING ON THIS VIDEO!):
Now, when DID 22222 is dialed, audio will be played asking for the local extension to be
entered.
NOTE: DIDs 11111 and 22222 are just for demo purposes - instead of 22222, use a real DID.
You can use Fake DID 11111 if you will not be using it directly.
Checking
DIDs in example 11111 and 22222 are JUST for DEMO purposes! Use your own correct
DIDs!
For this configuration you will need two DIDs. One of them can be fake (11111 in our
example), and the other should be real (22222 in our example).
Kolmisoft 2006-2012
366
If you do configuration following the instructions in the videos and it fails to work, the first
thing to do is to call your primary DID (11111 in our example) and see if you end up in your
IVR, where you can enter the local extension.
If you can - then you made a mistake in following the second video.
If you can not - you made a mistake in following the first video (at least).
The following screenshots are for a quick check on configuration. Change 11111/22222 to
your DIDs.
The important parts are marked in red. Check whether you have a similar configuration.
Kolmisoft 2006-2012
367
Kolmisoft 2006-2012
368
In the last picture, 't' and 'i' actions forward back to IVR, which means that if the user presses
anything in IVR, he will be routed back to IVR to retry.
In other words, the user needs to hear the whole recording before he can start entering the
local extension.
Starting with MOR 9 after selecting Dial Local you can also specify a sound file to play in edit
menu. This sound file will be played when user calling to DID is connected to Dial Local,
afterwards system asks to enter local destination:
Kolmisoft 2006-2012
369
Troubleshooting
... this means that the device which you dialed (1007 in our example) is offline and cannot be
reached. This is not an IVR problem. Make sure the device is registered to Asterisk, or dial
another device.
External DID function allows you to implement different PBX (or other Asterisk related
functions) into MOR.
When you assign some DID number pbxfunction External DID your call is forwarded to an
extension file in Asterisk called:
extensions_mor_external_did.conf
located in:
/etc/asterisk
When call comes to DID, for example DID number 123456 it will be forwarded to the dial plan
in that file with extension:
exten=> 1234567890
Kolmisoft 2006-2012
370
In this file you can basically configure any function that Asterisk supports to handle your call,
like:
Queues [http://www.voip-info.org/wiki/view/Asterisk+call+queues]
2. When creating a PBX function select the marked option 'External DID':
Kolmisoft 2006-2012
371
Ring-Groups
About
A ring group acts like any other Asterisk extension number except it rings a collection of
Asterisk extensions which you specify. If you dial a ring group number, it will ring all of the
Asterisk extensions associated with that ring group.
Kolmisoft 2006-2012
372
3. New Ring Group setup will appear:
Ring Group name: enter your Ring Group name here, for example "Sales ring group";
Comment: (optional) enter your Ring Group description, for example "This is my Sales Ring
group";
This Ring Group will be reached by such local extension: Enter an extension, that will be
used to dial this ring group
locally. Remember not to duplicate your extensions!;
Ring Time (how long device will ring): Define how many seconds to ring the group of
devices (default is 60 seconds);
Options to use when dialing (Advanced): !!!ATTENTION!!! Do not use this field if you are
not sure what you are doing.
This field allows you to enter more advanced Dialing options. More information can be
found here: [http://www.voip-info.org/wiki/view/Asterisk+cmd+Dial#Dialmacros]
Dialing Strategy: Choose the ring strategy from the drop down list;
CallerID Prefix: Define what callerID prefix should be added for the incoming call. For
example, if your ring group is used for sales department, you can add a "sales" CallerID name;
Route to DID if No Answer: Choose a DID number from the drop down list, to which route
the call if none of the ring group devices answer the call. DID must be assigned to device or
dialplan to be displayed in this drop down.
Kolmisoft 2006-2012
373
How to add devices to a Ring Group?
This Ring Group will be reached by such DIDs: Click on the to assign a DID
number from a drop down menu that will be used to call this Ring Group;
Will ring these devices: Click on the and choose users with
their devices which will be used in this Ring Group;
Show Extension lines Click on this link in order to check the Extension lines which will be used
when dialing. This is for information purposes only.
Kolmisoft 2006-2012
374
After you have successfully completed the configuration, you should see a similar result on
the right hand side on the window (This is ONLY an example!!):
Fax2Email
Definition
This feature allows the user to receive a normal fax and get it to email in PDF format. The
following image shows the common implementation of the Fax2Email functionality:
NOTE: Fax over VoIP does not work reliably and should only be used for testing
purposes.
Kolmisoft 2006-2012
375
Setup
In order to start using this feature, Fax enabled should be selected in in SETTINGS –>
Functionality –> Fax enabled.
When it's enabled, you need to create a device and make it FAX type. This can be done in
Device Settings:
When a device's type is FAX, it is marked as a FAX device everywhere with the icon .
Then you need to add the email address or addresses to which the received fax should be
sent. You can enter unlimited addresses.
When the fax device has been created, you have two possibilities for using it:
The second choice lets you save one DID by receiving calls and faxes on the same number.
Kolmisoft 2006-2012
376
The first method is very easy to implement – you just need to assign the FAX device to a DID:
When you want to do fax-detection, you need to set this in a device's Call Flow. In the Before
Call state:
Here, when a call comes, the system will try to decide whether it is a fax. If it decides that it is,
the call is routed to the FAX device and sent to the appropriate email addresses. If the call is a
simple call, it is sent to an IAX2/101 device.
Kolmisoft 2006-2012
377
For received faxes and various statistics, check Fax statistics in the STATISTICS -> Various ->
Faxes section:
Stats
This report show all information about faxes received (or not received). It can be found in
STATISTICS –> Various –> Faxes:
All users are visible here. A fax can have three states:
Received – everything okay with this fax. It's been received and sent to the
appropriate email addresses.
Corrupted – the fax has been received but is corrupted. It cannot be to sent to an
email address.
Mistaken – this was simple call to a fax number, not a fax.
Kolmisoft 2006-2012
378
You can click on a number for each state to get a list of these faxes:
See also
Recordings
It is possible to record selected users' calls for monitoring purposes.
In order to use Recording, you have to set up which users' calls you want to record.
Go to SETTINGS –> Users –> Recordings and you will see this window:
Kolmisoft 2006-2012
379
Here you can check the Record? field for the users you want to record. Click Change at the
bottom for the changes to take effect.
Sound format
Recordings are saved into mp3 format. 1mb can save around 4min of recordings.
Limitations
Currently it is not possible to record calls for a device that is accessed from IVR. If a call
goes like this: IVR -> Device, and the device has the option to record calls for this
device, these calls will not be recorded.
Recordings Addon
To extend Recordings functionality, a Recordings Addon is available. It allows more advanced
functions with recordings.
See also
Recordings Addon
Kolmisoft 2006-2012
380
PhoneBook
When is PhoneBook applied?
PhoneBook is applied when user call is authenticated. This means you have to use either
Authentication by PIN or ANI dial plan if call comes from outside.
Purpose
Definitions
Global PhoneBook
This PhoneBook is managed by System Admin and is applicable to all system Users (e.g.
Global).
Kolmisoft 2006-2012
381
A good use for it is to create some short numbers for Users to call for
Support/Emergency/etc.
The Speed Dial feature is explained Speed dials for users page at wiki.
Simple PhoneBook
Each user has his own Simple PhoneBook, which has higher priority than Global PhoneBook.
For example, if records from Simple PhoneBook match those of Global PhoneBook, the
record from Simple PhoneBook will be used. (Again, in other words - the user can overwrite
the System Admin's PhoneBook record.)
NOTE: Record '22'. It is Global - that is, created by System Admin. A User can use it, but he
can't manage it.
The Speed Dial feature is explained Speed dials for users page at wiki.
When a number (CallerID Number) which is in PhoneBook calls in, MOR checks this number
and sets the CallerID Name to the value from PhoneBook.
Kolmisoft 2006-2012
382
It’s visible on phones which support CallerID Name:
Speed Dials
This functionality lets the user enter a short number (Speed Dial) which transforms into an
actual long number. For example, if the user dials '11', the system will transform this to a full
number such as 37063042438. It saves the user time by allowing him to avoid dialing long
numbers.
Speed Dials can't be equal to extensions of local devices. If they are, they are ignored and
local devices are dialed instead.
Speed Dials are applicable for both Users and Calling Cards. For example, Speed Dials are
active for the following dialing types:
Kolmisoft 2006-2012
383
Speed Dials for Calling Cards
Speed Dial for Calling Cards is pretty simple: Speed Dials for Calling Cards page at wiki.
Limitation
Speed Dials cannot be a single digit in length. They must have two or more digits because of
the system architecture.
Backup system
The backup system backs up the MOR database and allows it to be restored at any time.
If Run Backup according below schedule is checked, the following settings become active:
Kolmisoft 2006-2012
384
Now in Settings -> Backups, we can click New Backup to create a new Manual Backup:
Enter any comment and click on Create to create the Manual Backup:
You can download the backup by clicking the Download icon or restore the backup by
clicking the Restore icon:
When Scheduler (which runs every hour) makes an auto backup, it is seen as type = auto in
the backups list:
Kolmisoft 2006-2012
385
Data import
User/Device/DID import
You must import the data in the following order from CSV files:
1. Users data.
2. Devices data.
3. DIDs data.
You can upload your data from a CSV file that has the following structure:
5. The first line can be used for your own needs, such as for naming each field of information.
If you use this line, do not select the "include first line?" option when asked.
For example:
Kolmisoft 2006-2012
386
Explanation:
The first line is used in this case for naming the fields, so when asked, do not select the
"include first line?" option. (If you won't use the first line for naming the fields, please do
select "include first line?")
The other three lines (starting 1, 2, 3) are for data records. Each record (the first one is: 1,
"username1", "verySecretPassword", "example@example.com") represents:
1 - user id.
Your CSV file can have any number of lines with any number of fields (each line must have
the same number of fields).
P.S. The file should not have any other symbols than those mentioned above. Be careful, as
some editors can add their own formatting symbols. In Windows we recommend using
Notepad, and in Linux: gedit, kedit, nano.
37067531061,38,38
37065431061,45,22
37062431031,2138,2138
In this example I have used the first column for DID, the second for Temporary User ID, and
the third for Temporary Device ID. Your data order can be completely different. You just need
to select the correct values when asked.
Kolmisoft 2006-2012
387
users csv file example:
45,2,0,"95757bfa00bf85b17921d709b5af0234","NULL",TRUE,"12969247-2-03","Example
Ákos","Example Example, Kft","Example's 38","70/235-45-
89","example@example2.hu",04/06/09 11:28 AM,"
","en",97,20,0,FALSE,TRUE,5,0,04/07/09,"NULL","NULL",0,FALSE,04/06/09,"Kecexample",6000,1,
0,1,1,TRUE,"NULL","NULL","NULL"
2138,2,0,"cc1b3ae8986559b10786d6ea73912bd5","NULL",TRUE,"11871633-2-03","Kos
Tas","Ks Kft","Alsó ast","20/229-36-78","pli@example.hu",12/13/07 09:42 AM,"
","en",97,20,0,FALSE,TRUE,5,0,12/13/07,"NULL","NULL",0,FALSE,12/13/07,"Sirly",6031,1,0,1,1,TR
UE,"NULL","NULL","NULL"
In the first column is a Temporary User's ID; the other columns represent other data. As
mentioned above, it does not matter in which order your data is represented in the CSV file. It
only matters that each column (the data between commas) represents the same data value
(id, email, password or other).
38,38,76824435,"3676586421","asd dsa
u.12","jamaica","7ewfw@sip.example.com",TRUE,"dynamic","sip",TRUE,"NULL","NULL","NULL",
"NULL","NULL","NULL","NULL","NULL","NULL","NULL","NULL","NULL","NULL","NULL"
45,45,76846301,"3676886421","fgh hgf
u.","ergerSiP","76886421@sip.example.com",TRUE,"dynamic","sip",TRUE,"NULL","NULL","NULL
","NULL","NULL","NULL","NULL","NULL","NULL","NULL","NULL","NULL","NULL","NULL"
2138,2138,76505921,"3676505921","jkl lkj
u.12","treK","6654@sip.example.com",FALSE,"dynamic","sip",TRUE,"NULL",FALSE,FALSE,10,FAL
SE,FALSE,FALSE,FALSE,FALSE,FALSE,FALSE,FALSE,,FALSE
The first column here represents "id", the second "user_id", and the others represent other
data. YOUR ORDER CAN BE DIFFERENT. The main thing is that each type of data (email,
password, id...) must be in the same column. When you are asked to provide data when
importing, be sure to assign the correct data from CSV for each column and MOR will know
which column represents which data.
Kolmisoft 2006-2012
388
Importing data
Firstly, from the MOR Graphical User Interface (GUI), navigate to: Settings -> Users ->
Import, as in the picture:
These fields are necessary to map DIDs to Devices and Devices to Users.
Example:
You have some other system with some user_ids, device_ids, DID_ids. You export them into
CSV files. The relations between them are kept by these IDs, so importing them to MOR will
keep these relations.
First you need to import a User with some temporary ID, then make sure this ID is near each
Device you are trying to import. Select this ID as Temporary User ID when importing Devices.
That way these devices will be mapped to this User.
Importing users
Kolmisoft 2006-2012
389
Now locate the CSV file in your local system by clicking the Browse button. As indicated
above, don't click the Include first line? checkbox if you have used the first line for
commenting on the fields.
In next menu, please fill in the requested data (you should select the correct field from your
CSV file). You must select a field for each selection box marked with an asterisk (*)
symbol. Having finished, press the Assign columns button.
Kolmisoft 2006-2012
390
On the next page, check whether all the data was assigned correctly. If not, click the Back
button and correct the mistakes. If all the data was assigned correctly, click the Confirm
columns button. After the Columns assigned notification informs you that the columns are
assigned, click the Back to Menu button. Having completed all these steps, you should see a
page similar to this:
Importing devices
Click on the Import Devices from CSV link and follow the same procedure for uploading a CSV
file as in the Importing users section. That is, locate the CSV file in your local system by
clicking the Browse button. As stated before, don't click the Include first line? checkbox if you
have used the first line for commenting on the fields. Click on the Upload file button. Now
you should see a menu similar to this:
Kolmisoft 2006-2012
391
In this menu, once again select a matching field from your CSV file for each selection box. It
is very important to correctly select Temporary User ID and Temporary Device ID,
because these fields are necessary to map DIDs to Devices and Devices to Users.
Once the columns are assigned, check whether all the data is correct. If not, press the Back
and correct the mistakes. Click Back to Menu. Now, if you haven't made any mistakes, you
should see two tables similar to these:
Importing DIDs
Click on the Import Devices from CSV link and follow the same steps for uploading a CSV file
as in the Importing users section. That is, locate the CSV file in your local system by clicking
Browse. As stated before, don't click on the Include first line? checkbox if you have used the
first line for commenting on the fields. Click on Upload file. Now you should see a menu
similar to this:
Kolmisoft 2006-2012
392
Select all matching fields from your CSV here. It is very IMPORTANT to select the CORRECT
Temporary User ID and Temporary Device ID! Having selected everything correctly, click
Assign columns button. In the next page, if all imported data is assigned correctly, click the
Confirm columns button. If you haven't made any mistakes, you should now see a DIDs
created message.
Success!
You can now check whether all your data has been imported.
Explanation of IDs
Many users find it difficult to understand what User_ID or Device_ID mean in Data Import.
These are temporary IDs created only for import purposes. These IDs have NO relation to
User ID/Device ID in the Users/Devices windows of the MOR system.
1. We have Users/Devices/DIDs.
Kolmisoft 2006-2012
393
2. We create a separate file with Users and add a unique ID to every User. The ID is NOT
related to User ID in MOR DB/GUI.
3. We create a separate file with Devices and add a unique ID to every Device. The ID is NOT
related to Device ID in MOR DB/GUI. Near each device we add a temporary User ID from
previous file, which shows which Device belongs to which User.
4. We create a separate file with DIDs and near each DID add a User_ID/Device_ID that shows
which DID belongs to which User/Device.
5. We import the User file, and MOR remembers the temporary User_ID.
6. We import the Device file, and MOR remembers the temporary Device_ID and checks the
User_ID for such Devices which have a User_ID near them in the file. It assigns this Device to
the appropriate User.
7. We import the DID file. MOR checks the Device_ID/User_ID in the DIDs file and assigns a
DID to this Device/User.
NOTE: in all processes, only a TEMPORARY User_ID/Device_ID is used. In the database, Users'
ID/Devices' ID are not used directly. They have no relation to the User_ID/Device_ID from
import files.
CDR Import
Configuration
In Configuration, make sure you select the correct options for these values:
If the settings do not match your CSV file, you will not be able to import CDRs.
Kolmisoft 2006-2012
394
Import
Sometimes MOR can be used as separate billing software (that is, other than for real-time
billing). When using MOR as separate billing software, it is possible to import CDRs from
other switches (they need not be Asterisk) and bill these CDRs.
CDR Import can be found in SETTINGS –> Billing –> CDR –> Import.
Sometimes MOR system is able to detect wrong CSV separator settings. If CSV separator
settings are wrong MOR will suggest you to change them:
Kolmisoft 2006-2012
395
Next you will have to assign columns to CDR values:
In step 2, you can see the necessary fields to select. They are marked by a star (*). You can
select to enter Date/Time in one line OR Date AND Time in separate lines. Without selecting
at least one field marked by *, you will not be able to continue the import process.
Here you will be presented with a parsed file. If something is not right, click Back. If it's okay,
click Confirm columns:
Kolmisoft 2006-2012
396
Here we select the User to which we want to assign all these calls.
Here we select Device to which all these imported calls will be assigned, and Provider.
Export
You can export CDR in either the PDF or the CSV format. This can be done in the Call Stats
page (STATISTICS – Calls) and other places where you see:
Export to PDF
Export to CSV
Just cick on one of these links and you will get CDR in the selected period.
Kolmisoft 2006-2012
397
Calls to DIDs
Calls to DIDs which belong to the caller are not billed at all (Price = 0).
CDR Rerating
Description
This function is used when you edited rate for some customer and you want to recalculate
price for his calls in the past. You need to select user, period and system recalculates all prices
for all calls in selected period for selected user. The rating mechanism is the same as in MOR
application but here rating is done by GUI. Be patient – if there are many calls – it can take
some time to rerate all of them.
You can reach Rerating in: SETTINGS –> Billing –> CDR –> Rerating:
Select date interval and user which calls you want to rerate and press Proceed:
Kolmisoft 2006-2012
398
Here you see call stats for selected date interval. Also you can save old data in PDF or CSV
formats. When you are sure everything is correct – press Rerate:
Select 'All Users' from User selection to rerate all users at once in selected period.
Testing mode
You can check Testing mode and select any Tariff for user.
Testing mode is useful for testing "What if User had this Tariff" scenarios.
If call's prefix is in Localization Rule which has some Tariff, this Tariff is used to count call's
price instead of User's Tariff.
Kolmisoft 2006-2012
399
Other notes
Re-rate does not take into account flat rates and user will be charged for such calls. Do
not do rerating for such user.
Re-rate does not work when call's DID, LCR or Owner Device is changed by
Localization rules.
Re-rate does not work for reseller users calls and reseller when you try to rerate the
reseller account only. You can re-rate one user at a time, for example if the reseller
made calls through his/hers account which is created by admin.
Online registration
This function lets a user register online. It can be accessed in MOR's entry page by clicking on:
If you are new user you can signup here:
Registration should be enabled in Settings in order to work. Various settings are also set in
Settings -> Registration.
Kolmisoft 2006-2012
400
In the following window, the user should enter his details. Fields marked by * are mandatory:
Note: if phone number is entered, it will be automatically added as CLI for user device.
Kolmisoft 2006-2012
401
After clicking on Sign up, the user is registered, his account is created and he will see
connection info on his screen:
If email sending is enabled (in Settings) and the email SMTP server details are valid, the user
will receive an mail containing all the settings. The administrator will also get an email with
information about the user who has registered with the system. These two settings should
also be enabled.
If you have set every setting to send email to Admin when a new user registers, but no email
arrives - check whether you have Email set for Admin user.
See also
Registration Configuratin
ReCAPTCHA
Kolmisoft 2006-2012
402
Online registration customization
We often get requests for information about how to customize the Online registration form.
See also
Online registration
Registration Configuration
Quick Forwards
About
Some DIDs can be assigned to Quick Forwards functionality. When this is done, each user can
enter a different number to be forwarded when he calls a DID.
The main advantage of this function is to use a limited number of DIDs to allow different
users to call these DIDs and be forwarded to different numbers (which are assigned by
users).
Example
1111111111.
2222222222.
Kolmisoft 2006-2012
403
User B sets his forwards:
When User A dials DID 1111111111, his CallerID (8888888888) is checked, the user is
recognized, and the call is automatically forwarded to number 3333333333.
When User A dials DID 2222222222, his CallerID (8888888888) is checked, the user is
recognized, and the call is automatically forwarded to number 4444444444.
When User B dials DID 1111111111, his CallerID (9999999999) is checked, the user is
recognized, and the call is automatically forwarded to number 5555555555.
When User B dials DID 2222222222, his CallerID (9999999999) is checked, the user is
recognized, and the call is automatically forwarded to number 6666666666
IMPORTANT: Correct CallerIDs should be set for users in order for them to be recognized
them. Only the system administrator can do this.
If the system doesn't recognize the caller, it asks for a PIN number of the device to be
entered.
If a user is dialing a DID that has not been assigned a Forward Number, the user is
asked to enter such a number.
The user can manipulate his Quick Forwards in his menu. He needs to log in to GUI to change
numbers.
Moreover, Default Device allows not to bill the user who calls to that DID but bill an other
user instead. To see why it is useful here's another example: let's assume that calling to DID
costs the same as calling to a premium rate line. When you call to such a line you pay at once.
MORs owner gets payment from DIDs provider (which itself gets it from the user). Quick
forwards based on diversion allows creating such services where user does not have to pay
for anything, i.e. forwards for him are "free" because he pays for a DID.
Kolmisoft 2006-2012
404
To make such a dial plan go to SETTINGS -> Billing -> DIDs -> Dial Plans. Click New dial
plan, you have to create a Quick Forward dial plan:
By default calls via Quick forward DID will not play Balance and Time. If you want it to go to
SETTINGS -> Billing -> DIDs -> Quickforwards -> Quickforward Settings. You will see this
window:
Tell Time/Tell Balance options also can be found in device's edit window:
Here you can also select Global. Value (Yes or No) in the brackets depends on what is selected
in quickforward settings. In this example there is Global (No) to both options because in
quickforward settings both Tell Time and Tell Balance are set to No.
Kolmisoft 2006-2012
405
Why is the Quick Forwards window empty?
The window may be empty because one or more DIDs should be assigned to Quick Forwards
before calls can be forwarded.
See also
DID Management
Quickforwards rules
About
Quickforwards rules are used to restrict users which DIDs they can use for quickforwards.
Quickforwards rules can be created by:
Admin - can create rules for any DID range assigned to quickforwards DialPlan
Reseller - can create rules only for DIDs which are assigned for him with
a Quickforwards rule by admin
Reseller PRO - can create rules only for DIDs which are assigned for him with
a Quickforwards rule by admin
Kolmisoft 2006-2012
406
How to create a quickforwards rule?
Kolmisoft 2006-2012
407
Transfers with MOR
Transfers by default are not available in MOR because Asterisk cannot guarantee correct
CDRs with Transfers.
In other words - it is possible to dial for free using Transfers with Asterisk (MOR).
If you really want transfers and do not care about possible loss, here is the way to enable
them:
In file /etc/asterisk/sip.conf
change line
allowtransfer = no
to
allowtransfer = yes
Kolmisoft 2006-2012
408
GUI on Mobile Devices
Description
If you access MOR GUI over your mobile phone or similar device with a reduced screen, you
will see something like this:
The mini option is used currently only if you want to send an SMS from the MOR interface as
shown here: SMS Addon iPhone.
If you want to get the full MOR interface, select the full option.
If you do not have an SMS Addon installed, the mini option is no of use to you, so you
should always use full option.
See also
Kolmisoft 2006-2012
409
PBX connection to MOR
Common connection diagram
To simplify the diagram, this is the common way for a PBX to be connected to MOR:
Here the main principles will be explained. For a detailed example, see the Trixbox section.
In this diagram, one PBX is connected to the MOR Billing system. Two phones (Phone 1 and
Phone 2) are connected to the PBX. Now both phones can dial out to the PSTN through PBX
and MOR.
Kolmisoft 2006-2012
410
In MOR we need to create one User/Device for PBX.
We need to create a Device for this PBX to describe how it is connected to MOR.
You should mark this device as Trunk with ANI.
To create one virtual device for each real device connected to PBX.
In the device's CLI menu we need to add CallerIDs of these devices as described in
PBX. Using the CallerID of the device, MOR recognizes who is calling and assigns the
call to the correct device.
Dialing to PBX
DIDs should be forwarded to the PBX for a real device to get the call.
In order to assign a DID to a virtual device, the following steps are required:
That way, when a call goes to the virtual device through a DID, it should go through PBX
Trunk.
If you do not forward the call to the PBX device, the call will fail.
This lets the user log in to GUI and see all incoming calls to his device.
ATTENTION! In order for the virtual device to receive calls from the DID, the PBX
should route calls to the correct device. MOR does not know the real
location/connection type of the virtual device, it just sends the call to the PBX, and the
PBX should send the call to the correct device. MOR CAN'T influence the PBX's
configuration, so the PBX should be configured separately to handle incoming calls
from the DIDs.
Kolmisoft 2006-2012
411
MOR and Trixbox
MOR and Trixbox (FreePBX) can't work nicely on the same server, because they use same
Asterisk .conf files, which makes a lot of mess.
In order to integrate Trixbox with MOR you need to connect in the following way:
Connection diagram
As an example, we will configure one phone dialing. The phone is connected to Trixbox,
which is connected to MOR:
Here, for simplicity, all the devices are in the same LAN:
username: mor_trixbox.
password: mor_trixbox_psw.
username: 201.
Kolmisoft 2006-2012
412
password: 201psw.
Let's connect a phone to Trixbox. In FreePBX, create an extension for phone 201:
Kolmisoft 2006-2012
413
The most important details are:
Here we set the CallerID number that should be applied to the call from this device. The
password and dial string are also here.
Kolmisoft 2006-2012
414
Define a route in Trixbox to use this Trunk (this is just an example):
When passing multiple CallerIDs from multiple extensions in TrixBox through a single ANI-
enabled trunk to MOR, be sure to define the outbound TrixBox PEER CallerID as empty, using
callerid="" <>.
If you don't include this, your MOR trunk will publish whichever CallerID was last passed to it.
This will not allow you to correctly track different users' CallerIDs in MOR to provide them
with separate call cost tracking.
Also, be sure NOT to define the inbound USER CallerID on the same TrixBox trunk as the
same empty entry. If you do, the CallerID will be stripped from all incoming calls.
We need to create a connection between MOR and Trixbox. In this example, we will configure
the MOR-Trixbox connection by using SIP.
Kolmisoft 2006-2012
415
We need to create a user for Trixbox: pbx_user. Put any details for it - it does not matter
which:
Kolmisoft 2006-2012
416
MOR configuration for phone
To correctly bill phone calls, you need to create a separate user and device for it on MOR.
Make sure you configure this user correctly by entering the password/LCR/Tariff and other
necessary details. This user will be used for real dialing out.
The settings for this device are not at all important, but you should:
1. Make sure you have marked this device as Trunk. This is important for receiving calls.
2. Make sure you have a good password for security.
3. Make sure that this device's host = dynamic (for security reasons, you cannot enter the
Trixbox IP here, because 201 is not Trixbox!)
In order for MOR to recognize a device/phone, we need to assign a CallerID to our phone's
device:
Kolmisoft 2006-2012
417
NOTE: currently it is not possible to enter a CallerID that is the same as the name of the
device. That way, the call will fail. This happens because of the way Asterisk handles
authentication.
MOR configuration
You need to create DID 2222222222 in MOR and assign the phone's user/device to this DID:
Kolmisoft 2006-2012
418
In this device's Call Flow, you need to forward the call to Trixbox:
Trixbox configuration
Now when the call arrives in Trixbox, it should know how to route the call to phone 201.
Kolmisoft 2006-2012
419
Inbound Route configuration
Final notes
In the example, we used DID 2222222222 and CallerID 1111111111. In real installations, these
values are the same in most cases. This means that if the user is dialing out and his CallerID is
(for example) 3333333333, he can receive calls by DID 3333333333. You can configure this in
the same way using this manual. Different values for DID and CallerID are chosen here to
make the example easier to understand.
Kolmisoft 2006-2012
420
5. Make sure Trixbox knows how to route calls from DID to the phone.
Limitations
Using this configuration to connect Trixbox (actually, FreePBX) to MOR has some limitations:
1. The MOR device's CallerID can't be the same as the device's name.
2. Phones connected to Trixbox can't have similar CallerIDs. (Actually they can, but MOR
will not be able to distinguish which device is making the call, so these devices with
identical CallerIDs will be billed together using one account (user/device) in MOR).
Errors
This error may occur when configuring the connection between MOR and Trixbox.
--note--
This is not a connection problem. This happens when you have an incorrect (or no) outbound
CallerID set within Trixbox. Thus "201" (the display name) is being passed through to MOR.
--VCCS
MOR API
About
MOR API lets other software interact with MOR without knowing the internal structure of the
database (DB) and other logic.
Kolmisoft 2006-2012
421
MOR accepts requests by HTML POST and returns results in XML.
Functions
API Related
Login
User
Callback
Accounting
Kolmisoft 2006-2012
422
Calls
Balance
Rates
Rate - check user rate by prefix
get_tariff - get all tariff's rates
import_tariff_retail - import xml retail tariff
wholesale_tariff - update or create wholesale tariff
Device
device_create - create device
delete_device - delete device
Phonebooks
Monitorings
ma_activate - turn on monitorings addon
Payments list
payments_list - payments list.
Kolmisoft 2006-2012
423
Credit notes
credit_notes - credit notes list.
credit_note_update - credit note update.
credit_note_create - credit note create.
credit_note_delete - credit note delete.
Financial statements
financial_statements - financial statements list.
Payments
create_payment - create payment.
Calling cards
cc_by_cli - creats and update calling cards, including adding and transferring funds, by
being identified according the Caller_ID.
buy_card_from_callingroup - solds cards from calling card group.
show_calling_card_group - Show calling group info.
MOR version
get_version - get MOR version number.
Send SMS
send_sms - send SMS.
HTML POST
username/password - the user name and password of the user who is asking for the
data.
Kolmisoft 2006-2012
424
If the user has 'admin' rights, he will get more results and can perform more actions
compared to a user who does not have such rights.
API Configuration
Please note that MOR does not allow you to enable Allow API if API Secret Key is not
entered. In such case you will get a message Invalid API secret key. Enter API Secret
Key in order to fix this.
Kolmisoft 2006-2012
425
Cron actions
What is cron actions
Cron actions is MOR functionality which allows you to do some tasks at a specified time.
Currently supported actions are these:
Example: User starts a call at 9:58 PM and is talking for 5 minutes, you have an action which
changes tariff at 10:00 PM. When call will be finished MOR will bill user using older tariff. If
user starts a call after tariff change - he will be charged using the new tariff assigned for him.
Kolmisoft 2006-2012
426
How to create a cron action?
Settings are self explaining here is an example with an action Change tariff (applied for users)
Name - enter here something that will help you to remember what this settings is about
Kolmisoft 2006-2012
428
MOR Addons
Calling Cards Addon
Kolmisoft 2006-2012
429
From Wikipedia, the free encyclopedia
A telephone card, calling card or phone card for short, is a small card, usually resembling a
credit card, used to pay for telephone services. Such cards can either employ prepaid credit
system or credit card style system of credit. The exact system for payment, and the way in
which the card is used to place a telephone call, depend on the overall telecommunication
system. Currently, the most common types of telephone cards involve pre-paid credit in
which the card is purchased with a specific balance, from which the cost of calls made is
deducted. Pre-paid phone cards are disposable. When the balance is exhausted you simply
buy a new card. Cards purchased can often be refilled. The other main type of card involves a
card with a special PIN printed on it that allows one to charge calls to a land-line telephone
account.
Short description
The Calling Card module makes it possible to manage cards printed on plastic/paper or sold
over the Internet for international calling.
The calling card platform is dedicated to calling cards, i.e. the plastic/paper cards with a
scratch surface that can be sold in shops or in streets. These cards (or their number/PIN) can
also be sold over the Internet.
When a user buys a card, he gets the number/PIN of the card. Then he dials an access
number and IVR asks him to enter this number/PIN.
The user hears the credit and time remaining and can enter a destination. If the destination is
okay, he is connected and can talk. After the call is finished, the call's price is deducted from
the card's balance.
Kolmisoft 2006-2012
430
Differences between Users and Cards in MOR (for A2billing users)
There are two main ways for a person to use the MOR system to dial out:
The main difference is that the User account is for permanent users. Calling Cards are used by
occasional dialers who use the service from time to time and often anonymously.
Users and cards are not related in any way. This means:
NOTE: MOR is not A2Billing. So the Calling Cards Addon is ONLY for Calling Cards which are
sold over the Internet/in the streets/shops/etc.
System Setup
Work-Flow
PINless dialing
This lets the user enter the Card's number/PIN only once, after which the system remembers
the CallerID. Next time, when the system receives a call from same CallerID, it will not ask the
user to enter the Card's number/PIN.
If the Card's balance is empty, the user will be asked to enter a new Card number/pin.
When a CallerID is not empty and is numeric and/or has a '+' sign, then it is valid. If CallerID is
invalid (has some non-numeric symbol in it, except '+'), PINless functionality will be disabled.
Kolmisoft 2006-2012
432
Can more than one Caller ID use Pinless Calling Card?
CallerID #1
CallerID #2
Then:
Description
This option allows to select which End IVR to use for Calling Card Dial-Plan.
End IVR #1
This is default IVR.
When call ends or caller presses * to terminate call, he comes into this IVR.
Here he hears message: "Press 1 to dial new destination, press 2 to dial same destination,
press 3 to check your balance, press 4 to use new card"
Kolmisoft 2006-2012
433
When user presses some button [1,2,3,4] he will be able to do such actions:
1 - Can enter new destination
2 - Can dial same old destination (redial)
3 - Can hear his balance
4 - Can enter new PIN to use new Card
End IVR #2
This type of IVR allows to enter new Destination or redial old one by pressing 1#.
User can enter destination and # to dial to it, o he can enter 1# and then system will redial
old destination.
End IVR #3
This IVR is just a hangup. E.g. call will end at once using this IVR and no further actions will be
possible.
Kolmisoft 2006-2012
434
Calling Card Groups
Properties
Kolmisoft 2006-2012
435
Card Image – just for informational purposes and eye pleasure to view on the GUI.
Can be (and should be) the same as the real printed card for consistency. But that's not
the rule.
Description – a short memo for admin to view some more info for the cards. It is
useful when there are a lot of Card Groups and the Card Group name is not enough.
Price with TAX – the price which all Cards in this Group will have before first use. It
does not include VAT. It's in the default currency.
Setup Fee – the fee which will be charged when a call is connected the FIRST time
when the card is used.
Ghost minute percent – a value to trick the user into thinking he has more minutes
when he really has less.
Example:
A user has enough balance in his card to call for 50 minutes. Ghost minute percent = 120. So
when the user enters his number/PIN, the system tells: "You have 60 minutes remaining"
(50/100 * 120). Note: this is not an increase in percent; it is the value by which the actual
minutes should be multiplied to tell them to the user.
Ghost balance percent - same as Ghost Minute Percent, but this value only applies to
the Balance which is told to the user (This option is available starting from MOR9).
Daily Charge – the amount which will be deducted EACH day from the card starting
from the date when the card is used for the first time. This means, if the user makes his
first call on Monday and his second call on Friday, his card will be deducted for 5 days
using this value (Mo, Tu, We, Th, Fr).
Currency - default currency for all cards
Tell cents - enable or disable telling cents when announcing card balance (This option
is available starting from MOR 10).
Tell balance in currency - choose in which currency to tell balance when announcing
it. (This option is available starting from MOR10).
TAX percent – the actual value which will be used when presenting the Card's price to
the User, i.e. when telling the user his remaining balance on the Card or showing the
same information on the screen.
Least Cost Routing (LCR) – which LCR will be used for all Cards in this Card Group.
Tariff – the price list which will be used for this Card Group.
Location – this is useful when Cards will be sold in a region with specific dialing rules.
Rules for location can vary for different Calling Card Groups.
Number Length – the length of the Card's number. You can select any value here. It is
recommended to select different values for different Card Groups to minimize the risk
of anyone guessing another card's number and using it unauthorized. Card numbers
are generated in sequence order.
Kolmisoft 2006-2012
436
PIN Length – the number of the Card's PIN. The same recommendation applies as for
the Card's Number. PINs are generated randomly.
Valid from - from which date Cards are valid.
Valid till - till which date Cards are valid.
Valid after first use - how many days a Card is valid after first use. Default 0 means
that card is valid forever.
Allow loss calls - enable this feature on calling card group if you want to let card users
to make calls when there might be loss.
Deny to double-use a Card with Pinless dialing, when Card is assigned to some
CallerID
Disable Voucher with same Number as Card if Card is used? - this option allows
you to print cards which can be used both for vouchers and for Calling Cards. If one is
used - the other one is deactivated.
Management
If a Calling Card module is enabled, you can find it (as Administrator) in: ADDONS –> Calling
Cards.
(..) - shows the Cards window, where you can manage the Group's Cards.
Kolmisoft 2006-2012
437
- edits the Group's details.
Overview
In this window, you can manage all Cards which belong to the Calling card group. All fields
are self-explanatory.
Card Creation
Cards for the Calling Card Group can be generated or imported from CSV file.
Kolmisoft 2006-2012
438
Generating Cards
Starting from MOR 10 MOR allows you to generate only 20% cards of total possible unique
PIN number count. For example: you have defined that your card group will have 2 digits
length PIN, that means that there is 10*10=100 possible unique PIN combinations. So MOR
allows you to create: 100*0.2 = 20 cards. To generate more cards you have to increase PIN
length.
Add cards – opens the window where you can add additional Cards to the Card Group:
In this window, you should enter the Card's start and end numbers. They will form an interval
which will be created. If any Card of the same number exists, the old Card will remain and a
new one will not be created.
The card's PIN number is created automatically – it's random and unique. It is wise to make it
reasonably long to avoid cheating by users who may guess a short PIN number.
When you want to print Cards on plastic/paper, you need to provide the necessary
information for the Card Printing service.
This can be done using a CSV file. Clicking on the icon lets you download all Card
information in one file.
You can process this file later in MS Excel or other compatible software. Use the correct
format for your Card manufacturer and send it to him.
Kolmisoft 2006-2012
439
The CSV file fields are:
Number
PIN
Balance
Sold
First_use
Daily_charge_paid_till
You can delete unnecessary fields and make it look as you need.
Kolmisoft 2006-2012
440
Minimal balance
Minimal balance is the lowest card's balance when it is still available to make calls from that
card. For example if you set 10 as minimal balance if card's balance is lower than 10 no calls
will be made from that card. You can find this functionality in main calling card's edit window:
A distributor is a user who can manage admins cards. Please note that distributor is not an
owner.
Kolmisoft 2006-2012
441
To assign distributor to a card go to ADDONS -> Calling Cards. Open any groups cards list
and click Edit. You will see this window:
Assigned distributor will see his cards here: PERSONAL MENU -> Various -> Calling Cards.
Kolmisoft 2006-2012
442
Disabled cards
Disabled calling cards are those which you can't call from. The reasons for disability are:
Card is not sold
Cards balance equals to zero
Card is not valid anymore.
Overview
Once we have generated a Calling Card Group and Cards, we can create a Dial Plan for this
Group.
A Dial Plan can be treated as a set of rules for how to handle a particular Calling Card Group.
You can set different rules for the same Calling Card Group.
The Dial Plan gives you more control over Calling Card Groups.
In this image, we see an existing Dial Plan for a Calling Card Group.
Kolmisoft 2006-2012
443
Let's review each field:
When creating a new Dial Plan, you will need to enter the correct Number and PIN length
values of an existing Calling Card Group. Otherwise you will not be able to create the Dial
Plan.
A DID (in other words, an Access Number) is vital for using Calling Cards. The user will use
this number to reach IVR.
You can assign unlimited DIDs to the same Dial Plan, but a particular DID can only be
assigned to one Dial Plan.
The Calling Card Dial Plan is useful when you are selling Calling Cards in different regions,
such as different countries. In country A, the user will dial one number (which is cheaper for
him or even free), and in country B the user will dial another number. They will reach the
same IVR and will use the same service, but they will save on telephone fees.
Kolmisoft 2006-2012
444
In SETTINGS –> Billing –> DIDs:
We select our Dial Plan and click the confirmation icon to assign our Dial Plan to this DID:
Now the user can dial number 12026911622 (in the example) and he will be able to reach IVR
and use his Calling Card.
MOR has a simple Calling Card shop for demo purposes where you can sell Calling Cards.
It can be reached by the same IP as MOR, just using 'ccshop' instead of 'callc'.
Kolmisoft 2006-2012
445
For example, http://<domain/ip>/billing will lead to MOR, while
All Card Groups with cards which can be sold are shown here with their images.
If we want to buy one card, we enter the amount and click the Add to cart button for that
Card:
The shopping cart shows what we have selected to purchase. We can continue shopping,
empty the cart, or proceed to the checkout.
Let's go directly to the checkout, because all the other functions are very simple:
Kolmisoft 2006-2012
446
Clicking on the PayPal button, you will be directed to the PayPal site, where you will be able
to pay for the Card.
Kolmisoft 2006-2012
447
Speed Dials for Calling Cards
When a Calling Card owner logs in to the Calling Card portal (/billing/ccshop), he is able to
manage his Speed Dials:
Here the Calling Card owner created a new Speed Dial: '11'. When he dials '11', the system
will dial to '37063042438'.
This means that the system owner incurs a loss. However, there is no way of preventing a user
from initiating such a call and not paying for it.
Kolmisoft 2006-2012
448
The format is simple:
CARDNUMBER,CARDPIN
When importing, make sure your CARDNUMBER length and CARDPIN length match the
lengths in the Calling Card Group.
1000000001,6258
1000000002,5725
1000000003,9737
1000000004,9694
....
Your Calling Card number length is 10 and your PIN length is 4. So you can only import cards
into the Card Group which have the following values:
You can find a video which demonstrates Card import from a CSV file here
[http://wiki.kolmisoft.com/index.php/Card_import_from_CSV_file]
It took ~2h.
phpMyAdmin:
MOR GUI:
Kolmisoft 2006-2012
450
Questions about Calling Cards
Q. When MOR asks for CC Number and PIN number, it asks one to enter NUMBER +
PIN + #. Is it possible for it to ask for NUMBER+# and then PIN+# (not only the PIN)?
A. No, it is not possible. It is only possible to ask for the PIN without the number: PIN + #.
Q. Can I modify the first page of the CCSHOP to include some other information or
links to the rate list for each card, for example?
A. Ruby On Rails knowledge is necessary to do that. Also, custom changes will be overwritten
by the next system update.
A. Yes if Reseller and Calling Card addons are installed and a reseller permission group is
assigned to a reseller as described in Reseller permissions wiki page.
Q. Where do we see Payments for Calling Cards when we recharge them over web?
Kolmisoft 2006-2012
451
Q. Can I create calling cards in different currency?
A. You cannot create cards in different currency. And there is no need to do it. Create Cards in
USD, and in Dial Plan select Currency which will be used for such Cards. Users will hear
EUR/GBP and will not know that in DB card's balance is saved in USD.
Description
By default, the button to end the current _CONNECTED_ call when using Calling Cards and
ANI/PIN dialing is '*'.
Configuration
[featuremap]
;blindxfer => #1 ; Blind transfer (default is #)
;disconnect => *0 ; Disconnect (default is *)
[featuremap]
blindxfer => #1 ; Blind transfer (default is #)
disconnect => ## ; Disconnect (default is *)
Restart Asterisk
REMEMBER: this option is only applicable when using a Calling Card or ANI/PIN dialing when
the call is already CONNECTED.
Kolmisoft 2006-2012
452
How to set language for Calling Cards
Description
The language in which Calling Card is played can be set in several places in the following
order of priority:
1. Default (en).
2. IVR.
3. DID.
Default language
If Calling Card does not use IVR and the DID language is set to empty, the default language
will be used.
This image shows how to set to "use default language" (when IVR is not used and DID
Language is set to empty):
If Calling Card Dial Plan (DP) is using IVR, then the language set in IVR overwrites Default
Language and is used IF DID Language is empty.
Kolmisoft 2006-2012
453
This picture shows how Language (Voice) is set in IVR:
Once again: it overwrites Default Language (en) only when DID Language is empty!
And most important is DID Language, which can be set in user DID:
This example shows ru language which will be used no matter what Default Language is and
no matter which Language (Voice) is set in IVR.
Kolmisoft 2006-2012
454
Examples
Language/Voice
NOTES:
1. When Default is 'empty' it means that sip.conf file is messed up and is set to language
=.
2. When IVR is 'empty' it means IVR is used but no Language is changed in it, OR IVR is
not used at all.
3. When DID is 'empty' it means the Language field in DID configuration is empty.
Calling Cards Payments list lets you to see your calling cards payments in one place for each
card.
Kolmisoft 2006-2012
455
How to make a Calling Card payment?
1. Go to Calling Card group list (Addons -> Calling Cards -> Cards) and press one of the
marked icons (later in this example always press the same icon):
Kolmisoft 2006-2012
456
Now having your card sold make a payment for it:
2. Now enter the amount you want to add to the current card balance
1. Press on the marked icon and you will get into the payments list for that Calling Card
Kolmisoft 2006-2012
457
2. Calling Card payment list:
This topic is ADVANCED and shows how to MOD MOR. Please do not use this
functionality if you are not sure what you are doing!
What is it for?
This functionality is designed to allow clients to modify the way how MOR Core behaves with
Calling Cards.
MOR itself has some logic which allows to change this from the GUI.
This functionality is made as external script in which clients (with enough programming skills)
can define the way how MOR reacts to some situations.
With this script it is possible to achieve various functionality, as example some of them:
By default it is OFF:
Turn it ON:
Kolmisoft 2006-2012
459
NOTE: When External Script is ON, Ghost Minutes and Ghost Balance
functionality is NOT used from the GUI. It is defined in External Script.
It is written in C with a lot of commentaries which explains all the logic INSIDE THE FILE.
Make changes to this file, execute ./install.sh in same folder to compile and move it to correct
place.
Make a call using Calling Cards with enabled Tell Time/Balance and watch Asterisk CLI:
This shows the output BEFORE telling the balance to the Card User.
NOTE: default External Script DOES NOT change any values, it is just for demo.
Kolmisoft 2006-2012
460
This shows the output BEFORE telling the time to the Card User.
NOTE: default External Script DOES NOT change any values, it is just for demo.
IMPORTANT: To make sure script works OK, you SHOULD see line:
Kolmisoft 2006-2012
461
We go to SETTINGS –> Addons –> Calling Cards and click New card group. In the new
window, we enter our Card's details:
Kolmisoft 2006-2012
462
After creating a Card Group, we will see all its details:
Kolmisoft 2006-2012
463
Change image for Card Group
Click on and go back to the Group's details and select the image for your card:
Click Upload:
Generate Cards
Now we have a Calling Card Group, we need to generate some Cards. Click Add cards:
Kolmisoft 2006-2012
464
Here we will create ten Cards, starting from 2000000001:
Now that we have a Calling Card Group and Cards, we need to create rules on how to handle
all these cards.
For that, we need to create a Dial Plan. Let's go to SETTINGS –> Billing –> DIDs –> Dial
Plans and click New Dial Plan.
Kolmisoft 2006-2012
465
Name is just for informational purposes. Number and PIN length should match the settings
of our newly created Calling Card Group.
We want IVR to ask for the number and PIN, so we leave Ask only PIN unchecked. IVR will tell
the remaining time and balance.
IVR will ask for number/PIN and destination three times at most:
In the last window, we see that we have no DID(s) assigned to our Dial Plan.
We need to go to SETTINGS –> Billing –> DIDs, select some available DIDs and click the
icon:
Here we select our Calling Card Test DP and click the confirmation mark.
Kolmisoft 2006-2012
466
The new window shows the status of our action:
In order to be able to use Cards, they should be Sold, i.e. ready for usage.
Go back to the Cards list and click the icon near a card:
Kolmisoft 2006-2012
467
... and Confirm the purchase:
Conclusion
In our example, number 37063042438 is the Access number to be dialed to reach IVR.
When you dial this number (in the example), IVR will ask for the card number/PIN to be
entered and follows all other Calling Card logic.
Kolmisoft 2006-2012
468
Callback Addon
About
This Addon must be purchased separately in order to use a Callback functionality.
Definition
In order to use a callback service, a subscriber is allocated a unique number, which must first
be dialled in order to trigger a return call. This is known as a Direct Inbound Dialing (DID)
number (Access Number). Where Caller ID is available, it may be possible to use the same DID
number for many different subscribers, as the callback system will be able to recognize each
subscriber's registered number.
On hearing a ringing tone for a few seconds, the subscriber simply hangs up and awaits the
callback. On receiving this, usually within a few seconds, the customer picks up the phone and
dials the required number.
The cost of making a telephone call via callback consists of two parts, as the caller is
effectively paying for an outbound and an inbound call at the same time. If it costs 20 US
cents a minute to call Nigeria from the US, and 8 cents a minute to call Spain from the US,
then the caller will pay a total of 28 US cents a minute.
NOTE: If you want to use Callback, make sure your DID provider sends correct CallerID
information. Without CallerID, you will not be able to use Callback.
Kolmisoft 2006-2012
469
Common Callback diagram
Implementation in MOR
Callback in MOR is implemented in very simple way. It's enough to tell the system the Access
Number (DID) and the way Callback should act. All of this will be described in following
paragraphs.
Supported Callback methods in MOR, listed by initialization method (which triggers Callback),
are:
Call
Over GUI
Over Email
Over API
First of all, by the nature of Callback it is important to know that before calling back to the
user, the system does not know who the user is (when not using ANI). For example, it does
not know whether the user is a client, whether he has an account in the system, and so on.
This means that when the system makes the callback to the user and the user picks up, the
call is ANSWERED, but the system still does not know who the user is. Let's say the user
Kolmisoft 2006-2012
470
unsuccessfully tries to enter a PIN several times. Then he hangs up. The call is ANSWERED.
Does the user pay for this call? No. Who pays? You, as the owner of the system. It's sad, but
true.
In order to keep track of Callback calls, you need to configure MOR in the proper way. For
this we need:
1. Callback User
2. Callback Device
3. Callback Tariff
Callback User is the user who will pay for answered but not authenticated calls to the user.
100% of the time, this user is the system owner. But creating a new user in MOR lets you keep
track of all Callback activity in your system. The other reason to have Callback User (and not
use the System Admin account) is the ability to create and assign a Callback Tariff to this user.
Callback Device is the necessary entity in MOR which will actually 'make' callback calls to
user. The type and other details do not matter. This device is pure virtual.
Callback Tariff – a separate tariff which should be assigned to the Callback User. In this tariff
you enter rates only to those destinations from which you expect the user will make an
Initiation Call. This is important! Make sure you do not have some Inmarsat rates defined
here. Guess how much you will pay if the user initiates a callback from Inmarsat and, when he
gets the call, enters the PIN several times incorrectly and hangs up? In short, this tariff decides
from which destinations you allow users to initiate callback.
Callback in MOR can be classified three ways depending on how the user is
authenticated/authorized:
Kolmisoft 2006-2012
471
Callback with Device's PIN authentication/authorization
The main part here is that user gets authenticated/authorized when he enters Device PIN.
System checks for such PIN in database and if user is found – user can proceed.
Kolmisoft 2006-2012
472
This way of Callback is extended User auth. by PIN Callback. In order to ask user for Device's
PIN system checks user's CallerID (ANI). If such CallerID is found in database – user gets
authenticated/authorized and can proceed entering destination. If CallerID is not found – user
is asked to enter his Device's PIN number.
Attention! It is very easy to fake CallerID so be careful when you are enabling Callback
with ANI. Anybody can put anybodies CallerID and use your service for free.
This type of Callback lets user enter Calling Card's Number/PIN to get
authenticated/authorized. System checks for such Calling Card in database. If call is made – it
is assigned to particular Calling Card.
Kolmisoft 2006-2012
473
Setting Callback in MOR
1. Callback User
2. Callback Device
3. Callback Tariff
4. Access Number (DID)
5. Calling Card or Auth. by PIN Dial Plan
See also
WEB Callback
Callback over Email
API Callback
Callback setup example
217 Callback not initiated because device not found by ANI
Can't setup callback
Callback and Calling Cards
Kolmisoft 2006-2012
474
WEB Callback
You can find Web Callback in PERSONAL MENU –> Various -> Callback.
When you enter the source (and destination if you wish), press Execute and you will get a call
to Source. After that, you will be connected to Destination (or asked to enter the destination
and only then connected).
See also
Callback
Description
This function receives email and initiates callback using details in this email.
A device can have one CallerID from which it is able to initiate Callback.
Admin sets up the email box, which should be monitored for callback execution.
Kolmisoft 2006-2012
475
An SMS to initiate callback can look like:
first_number#second_number
first_number - will ask destination
Then SMS gateway should send email to MOR to initiate callback in following format:
CallerID change:
Callback inititation:
MOR_PARAM1 auth_callerid
MOR_PARAM2 first_number
MOR_PARAM3 second_number
Inner mechanics
CallerID change:
Callback inititation:
Kolmisoft 2006-2012
476
Email body:
MOR_PARAM1 auth_callerid
MOR_PARAM2 first_number
MOR_PARAM3 second_number
callback: "|/usr/local/mor/mor_email2callback.sh"
SMS Callback
About
Callback Addon is needed in order to use API callback.
Request
http://<YOUR_SERVER_IP>/billing/api/callback?u=<USERNAME>&p=<PASSWORD>&device
=<DEVICE_ID>&src=<SOURCE>&dst=<DESTINATION>
USERNAME/PASSWORD – login and password from the USER, not from the device!
DEVICE_ID – which device should be used to initiate callback and which Caller ID will
be set on the call (Device ID = Device ACC, or accountcode). You can find ACC in
/billing/devices/devices_all).
Kolmisoft 2006-2012
477
SOURCE – which number to dial first.
DESTINATION – will be dialed when SOURCE answers.
You can omit <DESTINATION>. If you do so, SOURCE will be asked to enter it.
Response
<Status>Ok</Status>
Errors
Not authenticated
<Status>Not authenticated</Status>
Bad device
<Status>Bad device</Status>
No source
<Status>No source</Status>
No source in request.
Check your CDR for a FAILED call and reason why it failed.
Check Asterisk CLI for error.
Use Call Tracing to locate the error and fix it.
Kolmisoft 2006-2012
478
Callback setup example
This example will demonstrate the basic steps needed to make a calling card callback setup:
Before proceeding, make sure you understand the concepts of dial plans in MOR!
d) Two dial plans (or more), one for callback and one for Calling Cards or Authorization by
PIN/ANI.
2. When you create a callback user make sure to assign a correct Tariff for the callback.
Our suggestion is to include only those destinations in the tariff from which clients will be
calling to the callback.
Kolmisoft 2006-2012
479
The Device's settings are not at all important – leave everything empty. They will not be used,
anyway.
Here you can find Video which demonstrates how to create user and device.
4. Calling Card or Authorization by PIN dial plan should be created depending on your needs:
Open dial plans menu: SETTINGS -> Billing -> DIDs -> Dial Plans
Assign the dial plan to the DID, through which it will be reached, in the DIDs menu (the DID
can be fake).
Important! This Dial Plan are active by themselves. That is, dialing the associated DID, you
will get the service described by this Dial Plan. Callback is not configured yet.
Kolmisoft 2006-2012
480
5. Select your created autodialer device here.
6. Ask for card - if enabled system will was to enter PIN after callback is
made
6. Save the dial plan and edit the settings, you will be forwarded to this page:
Kolmisoft 2006-2012
481
Important steps here - Assign the correct DID through which the client will reach callback
service
Set the callerID which is needed. In many cases enter the Asterisk sign * - for example using
Pinless services.
7. And in the Dial Plans section, the same information is given in another perspective:
See also
Callback
Auto-Dialer Addon
Auto-Dialer addon lets you call an array of numbers automatically. When they are answered,
it plays back a prerecorded message to the receiving end of the call.
Overview
The user can find the AD menu under PERSONAL MENU -> Various -> Auto Dialer.
Kolmisoft 2006-2012
482
The user can Activate or Stop the Campaign by clicking the or button near the
Campaign's status.
A Campaign can only be Activated if it has free (not-called) numbers AND some Actions.
So please, before activating a Campaign, import some Numbers and create Actions.
Auto-Dialer can be found under PERSONAL MENU -> Various -> Auto Dialer.
Kolmisoft 2006-2012
483
Numbers
The user can import phone numbers from a TXT file. Numbers should be in correct format.
In a new Campaign there are no numbers, so click on Import numbers from file and
select the file to upload:
Kolmisoft 2006-2012
484
After uploading the file, you will see status of imported numbers:
Actions
Kolmisoft 2006-2012
485
In this window, the user programs the Actions for the Campaign:
Types of Actions:
Admin interface
When Auto-Dialer (AD) is installed, Admin can find it under the SETTINGS –> Addons –>
Auto Dialer menu. Here he can get a view of all users' campaigns:
It is possible for admin to see the Actions for users' Campaigns. Just click on the Actions
button.
Kolmisoft 2006-2012
486
Redial all failed Calls
Workflow
Each 5 minutes, "cron job" is activated to check whether any campaigns are activated.
If there are some active campaigns, the script creates call files for the future.
It puts calls in Time Period in equal time periods, to balance the workload for Asterisk.
For example, if you have 10 calls to make, the script will execute them in 6s intervals to start
all calls in 1 min time.
Variables in /var/lib/asterisk/agi-bin/mor.conf:
calls_one_time - how many calls to distribute per one minute. (PLEASE NOTE, this value is not
for simultaneous calls! It has a very different meaning, which is explained below).
cron_interval - the interval of time (in minutes) in which we should 'put' calls.
Example #1:
calls_one_time = 10.
cron_interval = 1.
That means that in 1 minute the script will put 10 calls. So each call will be executed at a 6s
interval:
1st call: 0s
2nd call: 6s
3rd call: 12s
....
9th call: 54s
Kolmisoft 2006-2012
487
10th call: 60s
Example #2:
calls_one_time = 5.
cron_interval = 2.
That means that in 1 minute the script will put 5 calls and it will do so for 2 minutes. So each
call will be executed at a 12s interval:
1st call: 0s
2nd call: 12s
3rd call: 24s
4rd call: 36s
5th call: 48s
6th call: 60s
7th call: 72s
8th call: 84s
9th call: 96s
10th call: 108s
NOTE: Auto-Dialer is not the tool to generate a lot of calls simultaneously. Auto-Dialer
distributes calls in even intervals in a particular time period to minimize the load on Asterisk.
Logs
/var/log/mor/mor_ad_cron.log
Reseller Addon
Description
Kolmisoft 2006-2012
488
When this user logs into the system he is able to:
1. Create tariffs
2. Create users
3. Setup their own tariffs and assign them to their users
4. View calls and other stats for his own users
5. Add own logo to GUI
6. Customize invoice with their details (logo is not supported)
7. Can calculate own profit
When his users are making calls - reseller's balance decreases along with user's balance. If
reseller is prepaid and he is out of balance or postpaid and credit limit is reached - his users
will not be able to make calls even if they have money in their balance.
DIDs
DIDs can be created only by admin. Reseller can assign DIDs available to him to his users.
Complete Calls
To get all Calls in selected period for Reseller and his User use following link:
Kolmisoft 2006-2012
489
Manual
3. Select the required user type from the marked drop down box:
Kolmisoft 2006-2012
490
Web access
Each Reseller has it's own Homepage. URL can be found in MAIN MENU -> Settings Global
tab.
It is possible to have different domain name for each Reseller. Domain name should be
pointed to Reseller's URL in such case.
NOTE: Kolmisoft does not provide domain names, so you need to check with certain domain
provider for such option.
See also
Reseller Permissions
Reseller Permissions allows system administrator to select which addons can be used by
Reseller Group.
To create a Reseller Group, set Permissions and assign reseller to Reseller Group please follow
these steps:
Kolmisoft 2006-2012
491
2. Create a new Reseller Group:
Write - reseller is allowed to use and configure this addon. Addon configuration made by
reseller is actual for his account only.
5. Go to reseller settings (Users -> ) and assign the reseller to a permissions group:
You can create more than one Reseller Group and assign more than one reseller to each
Reseller Group.
Reseller Settings
Kolmisoft 2006-2012
493
Show Hangup Cause Codes for Resellers - if this option is enabled, resellers are able
to see Hangup Cause Codes in Calls list.
Allow use ZAP devices - allows resellers to use ZAP/DAHDI devices.
Allow use Virtual devices - allows resellers to use Virtual devices.
Resellers can add their own DIDs - allows resellers to add DIDs. If this option is
disabled, only admin can add DIDs by assigning them to resellers.
Default DID Provider for Resellers - which DID provider should be assigned to DIDs
which are created by resellers.
Allow resellers to change device PIN - allows resellers to change their users devices
PINs.
Also it lets Admin to mark some of his Providers to be optionally used for Resellers.
Reseller PRO can have his own providers and create his own LCRs, but he is able to change
tariffs for his providers only.
Reseller PRO cannot affect tariff which is assigned for him by admin.
Kolmisoft 2006-2012
494
2. Check Allow to have own providers option:
Now reseller can add own Providers from Reseller Menu: MAIN MENU ->Routing ->
Providers
http://wiki.kolmisoft.com/index.php/Material_for_testing_users#Add_a_provider_in_MOR
Kolmisoft 2006-2012
495
How Admin providers can be used by reseller?
MOR 10
You have to edit provider settings and select an option common use. All providers with
option Common use set will be visible for all resellers who have Own providers option set in
their user details.
MOR 11
Starting from MOR 11 separate Common use providers can be dedicated to separate
resellers with different tariffs.
Configuration
1. Enable Common use option for a desired provider.
1) Press a button marked with number 1 - this will create associations for all available
common use providers for all resellers, later you can delete unneeded associations. Please
note that when you will add a new reseller to the system - you will need to press this button
again or create associations manually as stated in option 2).
2) Using menu marked with number 2 you can manually assign common use providers for
each reseller with different tariffs.
Kolmisoft 2006-2012
496
Manual for Resellers
Dear MOR prospective reseller, before reading any further, please note that all rates,
and taxes below are only sample rates to show you around our reseller panel but do not
reflect and are not related to our current real rates.
Dear MOR prospective reseller, This is your guide on how to navigate through your reseller
panel page by page with screen caps.
Login
When you first login from the URL http://<YOUR_URL>/billing with your reseller ID and
password, you will go to the following page:
On this page you can see on the Very Top Right, a group of flags, by clicking each flag you
can change the language of your display to your own native language or your preference, try
to click on every flag if you want to change the language.
Kolmisoft 2006-2012
497
Then you see info about Your Balance and Calls made by your
users Today and During this month.
Now please take a look at the Navigation buttons on the left side
one by one from the Top Side Downwards:
Under Reseller Menu you can manage your reseller data, create
and set your rates to destinations and your Tariffs while under
Personal menu you can see your own data and see how much
rates you pay for us and your own personal calls made by you
and not by users.
Tariffs
Now under Reseller Menu, Check out the first button called
Tariffs.
By clicking on this button you can start creating your own Tariffs
and Rates to destinations, and please note the following:
Before creating any users, you must complete this step first, this
step will take time and it is manual, but you only must do it one
time only.
Kolmisoft 2006-2012
498
Now click on the Tariffs:
Enter any name, this is for you. And Purpose of Tariff chose "User Retail" for (demo purposes
now) then click the Create button.
Kolmisoft 2006-2012
499
You will be directed to the page, which means your Tariff was created successfully:
Rates
Name of the Tariff we created for the demo purpose of User Retail is "Test Tariff"
Before someone can dial-out, rates to the destination any user will use must be filled first.
Kolmisoft 2006-2012
500
To do this, click on the Rates:
On this page you need to enter rates manually one by one. ( Retail Rates can be transformed
from Wholesale Rates also).
Enter all the rates per minute you need to charge your customers for every destination.
Rounded by field, is in seconds, it usually is either, per one second, or per 60 seconds which
will mean the call will be rounded per minute. So make sure you change it to rounded by 60.
And enter your rates per minute for every destination or only the destinations you want.
Then click on the Update button at the end of the page, and you will see your rates have been
filled out and saved.
Kolmisoft 2006-2012
501
More info about Tariffs/Rates can be found here
[http://wiki.kolmisoft.com/index.php/MOR_Manual#Tariffs].
Users
Now you can start creating Users and Devices for them, and those Devices can start calling if
they have enough balance in their account.
Now go to the Reseller Menu again to your left and this time click on Users to create a new
User:
Now you need to start filling out this data for the user you created:
Username/Password - For user to login to this interface to checkout his balance, rates
and later he will be able to pay affiliates automatically using Paypal inside this panel.
Tariff - from this drop down menu, you select which tariff to apply for this user since
you can create unlimited tariff plans.
Balance - enter initial balance (WITHOUT TAXES) for user here
Credit - if user is prepaid - leave it untouched
Prepaid - Make sure you check the user to PREPAID user and NOT postpaid if you do
not trust user
Kolmisoft 2006-2012
502
After you fill in all the fields properly, click on Create button to create your first user:
Kolmisoft 2006-2012
503
Devices
Now this user cannot start calling unless you create a device or extension for him.
This page lists all devices or extensions for this user, while each user can have unlimited
devices, only you can add for them devices and not the users themselves, now as you can see
this user still has no devices created.
To create the first device for this user click on Add new device:
Kolmisoft 2006-2012
504
Once you have filled in the description (Which you can also leave empty if you wish), click on
the Create button:
Kolmisoft 2006-2012
505
Please do not edit any settings in this page, it is better if you do not know what you are
doing, that you leave this page like this, like the default settings, and hit the update button
below.
In this page you can see the device or extension number that users need to put in X-lite (or
other softphone or real phone) to dial out, for this device for example
If you put this info on your X-lite and our SERVER_IP_ADDRESS you will be able to start
making calls from this X-Lite until this User has balance in his account.
Now you can email this user his info and how to use the system, you need to only email him:
His username
His Password
Login to GUI URL http://<SERVER_IP>/billing
Device username
Device password
Devices overview
About
Kolmisoft 2006-2012
506
Calls
If you want to check calls made by your users go to RESELLER MENU -> Calls:
Here you can press on icon near each user to check their calls.
Kolmisoft 2006-2012
507
Personal Details
You can change your personal details in PERSONAL MENU -> Details:
Personal Rates
PERSONAL MENU -> Details -> Rates lists rates as given to you by us, this is the rates WE
CHARGE YOU per minute, So this can be your guide when you are creating your own rates for
your users, you can open both windows at the same time and make reference before you add
your rates.
Kolmisoft 2006-2012
508
SMS Addon
Description
It is possible to:
Kolmisoft 2006-2012
509
2. Select the marked checkbox (marked with number 1) and press the button to save changes
(marked with number 2)
P.S. This SMS form will be visible only for users which have SMS subscription
Troubleshooting
1 - failed, system owner does not have rate for this destination
This means that Provider does not have rate for destination where you are trying to send
SMS.
Kolmisoft 2006-2012
510
Solution - add such rate to appropriate prefix.
See also
MOR Addons
SMS Addon iPhone
SMS Addon - Clickatell configuration
SMS Addon - Providers
SMS Addon - Status codes
Recordings Addon
Functionality
The Recordings Addon gives more options for managing recordings, such as making it
possible to:
NOTE: Resellers do not have the same functions as an administrator - they can't manage
recordings of their users.
Kolmisoft 2006-2012
511
Settings
SETTINGS –> Setup –> Settings –> Addons –> Recordings
Kolmisoft 2006-2012
512
Administrator functionality
Here the System administrator can see all recordings. He can search Recordings by:
Period.
Source (CallerID).
Destination (Dialed number).
User.
Device.
Whether or not the user can use Recording Addon functionality (set to record calls,
send recordings to email, etc).
Which user calls should always be recorded (without user knowledge).
Kolmisoft 2006-2012
513
SETTINGS –> Users –> Edit (on selected user)
Allow to use recording functionality - can this user use the Recording addon
functionality?
Forced record calls for this User - record calls for this user (all devices) without user
knowledge.
Server space - how much HDD space to reserve for recordings of this user.
Send deleted recordings to this email. If HDD space is used, the recording will be
deleted and sent to this email. If this email is empty, the recording will be sent to the
default user email.
Record calls for this Device - record calls for this Device (without user knowledge).
Send Recording to Email - when recording is completed, send to it email.
Recordings Email - send to this email address.
Keep Recordings on Server after sent to Email - should the recording be left on the
server after being sent to email?
This feature allows an administrator to quickly delete recordings for selected period or
selected device
Kolmisoft 2006-2012
514
Check an option to delete by device or by date, select device/date and click Delete:
User settings
The Administrator must authorize the user to use the Recording Addon functionality before
User can use its functions. This can be done by checking Allow to use recording
functionality in the User Edit window.
Kolmisoft 2006-2012
515
PERSONAL MENU –> Details –> Devices –> Edit
Record calls for this Device - user can set to record calls for this device or not.
Send Recording to Email - should recording be sent to email?
Recordings Email - the email address email to which recordings should be sent.
Keep Recordings on Server after sent to Email - should recordings be left on the server
after being sent to email?
Guides
How to set up user so he can see his calls
1. As admin, go to User Edit settings and check Allow to use recording functionality.
User will be able to use Recording addon functionality.
2. Log in as this User and in PERSONAL MENU –> Details –> Devices, click for Device and
in the Recordings section check Record calls for this Device: YES.
3. Now the user will be able to see his calls in PERSONAL MENU –> Call –> Recordings.
MNP Addon for MOR allows system owner to check number if it belongs to other network
and if so - route it through different providers or bill it with different price.
Current implementation allows to save numbers in MySQL database on any server (possible
not on local server).
Before each call MOR MNP Addon checks dialed number and if number is found in database
- some prefix is added in front of it.
Kolmisoft 2006-2012
516
By prefix MOR can set different routing(LCR) or billing(Tariff) for this number.
As Kolmisoft cannot make one unique database for all MNP services in all countries all over
the world. MOR admin has to manually enter numbers in MNP database (process described
below) in order for this solution to work. mor_mnp database has to contain only the
necessary data (telephone numbers).
NOTE: It is important to take care of various number formats user can use to dial a number.
As a solution to it is to insert MNP number into DB in several possible formats.
Installation
Do such steps:
1. Upgrade MOR
2. cd /usr/src/mor/sh_scripts
3. ./install_mnp.sh
Upgrade
Database
Make sure you have set correct MySQL permissions for mor_mnp database and also local or
remote asterisk must have correct settings in /usr/local/mor/mor_mnp.conf . If your number
is still not recognized, double check if you have it in your mor_mnp database!
http://www.2checkout.com
2checkout needs some additional configuration on your side. In order to make it work, you
should login to your vendor account in 2checkout's site and do the following:
"http://YOUR_IP/billing/payment_gateways/integrations/two_checkout/notify".
Kolmisoft 2006-2012
518
Set Pending URL to
"http://YOUR_IP/billing/payment_gateways/integrations/two_checkout/pending"
Kolmisoft 2006-2012
519
Authorize.net
http://www.authorize.net/
What is Authorize.net?
Authorize.net in Wikipedia
This example is made using ING bank as an example. Control panels of other banks may differ
but the process should be similar.
Kolmisoft 2006-2012
520
This is Authorize.net setup page in MOR:
Enabled - Check this box to make Authorize.net available for your clients.
Tax in amount - "Include" tax into amount that user has to pay or "Exclude" if you
want to exclude the tax from the amount that is added to user's balance
Kolmisoft 2006-2012
521
Payment confirmation by you
o Not required - No confirmation is required. Every payment is added to clients
balance immediately.
o Required for suspicious payments - currently Authorize.net doesn't provide
enough info to calculate suspiciousness.
o Required for all payments - When payments are completed they must be
confirmed manually.
Test mode - Turns on the test mode. Use this option only if you know what you are
doing. In test mode MOR will send payment requests to bank's test environment, so
the payments will not transfer actual money. On the other hand MOR still counts these
payments as real and updates user's balance.
Logo - You can select and upload a custom logo picture. MOR accepts images that are
*.jpg, *.png or *.gif and less that 100Kb in size.
Google Checkout
http://checkout.google.com
Before proceeding you need a valid (not self signed) SSL certificate
[http://support.google.com/checkout/sell/bin/topic.py?hl=en&topic=12156] implemented in
MOR.
All the valid certificates recognized by Google checkout are listed here
[http://support.google.com/checkout/sell/bin/answer.py?hl=en&answer=134466&from=578
56&rd=1].
Kolmisoft 2006-2012
522
What is Google Checkout?
http://YOUR_SERVER_IP/billing/payment_gateways/google_checkout/google_checkout/notify
Kolmisoft 2006-2012
523
2. Select the marked setting:
Kolmisoft 2006-2012
524
3. The marked settings are the most important:
Kolmisoft 2006-2012
525
More examples of configuration
Kolmisoft 2006-2012
526
Moneybookers
http://www.moneybookers.com
What is Moneyboookers?
Kolmisoft 2006-2012
527
How can I setup Moneybookers?
Enabled - Check this box to make Moneybookers available for your clients.
Tax in amount - "Include" tax into amount that user has to pay or "Exclude" if you
want to exclude the tax from the amount that is added to user's balance
Kolmisoft 2006-2012
528
Payment confirmation by you
o Not required - No confirmation is required. Every payment is added to clients
balance immediately.
o Required for suspicious payments - currently Moneybookers doesn't provide
enough info to calculate suspiciousness.
o Required for all payments - When payments are completed they must be
confirmed manually.
Test mode - Turns on the test mode. Use this option only if you know what you are
doing. In test mode MOR will send payment requests to bank's test environment, so
the payments will not transfer actual money. On the other hand MOR still counts these
payments as real and updates user's balance.
Logo - You can select and upload a custom logo picture. MOR accepts images that are
*.jpg, *.png or *.gif and less that 100Kb in size.
Kolmisoft 2006-2012
529
Enter an amount of money, specify currency and click Confirm:
Click Confirm:
Kolmisoft 2006-2012
530
Click Continue:
Payment is done!
Kolmisoft 2006-2012
531
Payment is done!
PayPal PRO
http://www.paypal.com/cgi-bin/webscr?cmd=_wp-pro-overview-outside
iDeal
What is iDeal?
Wikipedia [http://en.wikipedia.org/wiki/IDEAL]
Supported Banks
Firstly it is the merchant (your) bank. This is where we send payment requests and that
requires configuration. Currently we have configuration for only one bank (ING).
Secondly there is a client bank (your customers). iDeal implementation fetches those
on the runtime so it always contain full list of iDeal banks.
Kolmisoft 2006-2012
533
2. Select the marked iDeal logo:
Kolmisoft 2006-2012
534
How can I setup iDeal?
This example is made using ING bank as an example. Control panels of other banks may differ
but the process should be similar.
Enabled - Check this box to make iDeal available for your clients.
Merchant ID - Your merchant ID from iDEAL. You can find it in iDeal control panel.
Passphrase - Enter passphrase that you used when you generated you certificates. To
get more information about generating certificates refer to the section Generating
Certificates
Kolmisoft 2006-2012
535
Payment description - Custom textual description that describes what your customer
is paying for.
Private key (*.pem) - Upload private key that you have generated. More information
in "Generate certificates"
Private certificate (*.cer) - Upload a certificate that you have generated. More
information can be found in "Generate certificates"
Ideal certificate (*.cer) - Select certificate file that can download from your iDeal
provider.
Tax in amount - "Include" tax into amount that user has to pay or "Exclude" if you
want to exclude the tax from the amount that is added to user's balance
Client pays transaction fee - Check to additionally charge the client for the
transaction fee.
Transaction fee amount - Enter transaction fee amount if you have enabled "Client
pays transaction fee"
Test mode - Turns on the test mode. Use this option only if you know what you are
doing. In test mode MOR will send payment requests to bank's test environment, so
the payments will not transfer actual money. On the other hand MOR still counts these
payments as real and updates user's balance.
Logo - You can select and upload a custom logo picture. MOR accepts images that are
*.jpg, *.png or *.gif and less that 100Kb in size.
Kolmisoft 2006-2012
536
Generating certificates
In Linux console type these commands, but replace the_passphrase with your desired
passphrase. Do not forget your passphrase because you will have to enter it in iDeal
configuration window.
To find your iDeal Private key, Private certificate and Ideal certificate issue these commands:
mysql mor;
please note that these commands can retrieve more than 1 certificate, the one you
need is that matches owner_id field to the user id in users list.
paste to an empty text files and save. Then you can import them in MOR as normaly.
Kolmisoft 2006-2012
537
Payment status
Successful:
Unsuccessful:
Troubleshooting
2. Check certificates.
If iDeal fails to deliver money instantly (lag between issuer and acquirer banks) then MOR
marks this payment as "waiting_response" and then waits for another hour and checks iDeal
again, so be patient. If waiting_response stays like that for several hours then contact our
Support.
Kolmisoft 2006-2012
538
OSMP
www.osmp.ru [Russian]
What is OSMP
OSMP is a payment gateway that lets your clients to top up their balance. The main difference
from other payment gateways is that OSMP allows you to pay using physical OSMP payment
terminals rather than MOR GUI.
Client enters his username and amount into OSMP payment terminal.
OSMP checks payment details with MOR (is there such user in MOR; amount sizes;
other technical technical details )
o User is checked buy matching user name provided by user in OSMP terminal
with MOR username. Example. if we have user with username "admin" in MOR
he should enter "admin" as his user name in OSMP.
o Other details include:
Is this transaction unique and it is not a hacking attempt.
Is amount greater that Min Amount (if Min Amount is provided in
configuration)
Is amount smaller that Max Amount (if Max Amount is provided in
configuration)
If payment can be created inside MOR and no errors occur.
If everything is correct then user pays using OSMP terminal.
After the payment has been successfully completed OSMP announces MOR about this
and MOR tops up users balance.
Kolmisoft 2006-2012
539
In what countries OSMP is available
Kolmisoft 2006-2012
540
How to configure SSL for OSMP?
In order to use OSMP securely SSL certificates are being used. Certificate configuration and
payment gateway testing is being done by OSMP staff.
NameVirtualHost *:80
NameVirtualHost *:443
<VirtualHost *:80>
RewriteCond %{REQUEST_URI} !^/billing/public
RewriteRule ^/billing(/.*)?$ /billing/public
<Directory /var/www/billing/public/>
Options ExecCGI FollowSymLinks
AllowOverride All
Allow from all
Order allow,deny
</Directory>
<Directory /var/www/html/stats/>
AddHandler cgi-script .pl
Options +ExecCGI
DirectoryIndex index.pl
</Directory>
</VirtualHost>
<VirtualHost *:443>
SSLEngine on
SSLCipherSuite
ALL:!ADH:!EXPORT56:RC4+RSA:+HIGH:+MEDIUM:+LOW:+SSLv2:+EXP:+eNULL
SSLCertificateFile /etc/ssl/billing.crt
SSLCertificateKeyFile /etc/ssl/billing.key
SSLCACertificateFile /etc/ssl/comodo.intermediate.crt
<Location /billing/payment_gateways/osmp/osmp/notify>
Allow from 195.22.241.194 195.22.228.238 89.28.59.10 #contact OSMP for exact details
which IP's must be allowed
Deny from All
</Location>
<Directory /var/www/html/stats/>
AddHandler cgi-script .pl
Options +ExecCGI
DirectoryIndex index.pl
</Directory>
</VirtualHost>
Advices
I found a bug, OSMP logo cannot be clicked like other payment gateway logos!
This is not a BUG, that's because of the way OSMP works - payments are made from physical
terminals, please read ―what is OSMP― section in osmp technical details page
HSBC
http://www.hsbc.com/
Kolmisoft 2006-2012
542
Client ID - Your client ID from HSBC. You can find it in HSBC control panel.
Password - HSBC account password.
XML url - The URL to send the request in XML.
Tax in amount - "Include" tax into amount that user has to pay or "Exclude" if you
want to exclude the tax from the amount that is added to user's balance
Minimum amount - Minimum payment amount
Maximum amount - Maximum payment amount.
Payment confirmation by you
o Not required - No confirmation is required. Every payment is added to clients
balance immediately.
o Required for suspicious payments - currently iDeal doesn't provide enough
info to calculate suspiciousness.
o Required for all payments - When payments are completed they must be
confirmed manually.
Notify by email - Check to receive notifications by email.
Logo - You can select and upload a custom logo picture. MOR accepts images that are
*.jpg, *.png or *.gif and less that 100Kb in size.
Test mode - Turns on the test mode. Use this option only if you know what you are
doing. In test mode MOR will send payment requests to bank's test environment, so
the payments will not transfer actual money. On the other hand MOR still counts these
payments as real and updates user's balance.
Other Notes
About SSL Certificates in Russian
Van's Apache SSL/TLS mini-HOWTO
Monitorings Addon
What is Monitorings Addon?
Kolmisoft 2006-2012
543
You can find monitorings in ADDONS -> Monitorings.
Remember, you will only find this addon if you have purchased it.
Monitoring Addon crawls the MOR database and counts user's call price sum over specified
period. If user's call price sum over specified period will be higher or lower than the amount
specified in monitoring - an action will be taken. Possible action are:
All users
Postpaid users
Prepaid users
1 user (separate monitorings for each user, also called personal monitorings)
Also it is possible to create 2 or more monitorings for each group, for example:
First monitoring only reports admin about quickly increasing sum, let's say 50 Euro
If an administrator takes no action and someone tries to abuse the system when call
sum for that user reaches for example 100 Euro the second monitoring can block that
user
System's administrator can turn on monitorings for resellers. If they are off, resellers' users are
under the terms set by administrator.
Kolmisoft 2006-2012
544
Monitorings for resellers
As it is mentioned above, administrator can turn on monitorings for resellers. If you want to
do it go to ADDONS -> Resellers -> Reseller permissions. Choose or create a group and
click the Edit icon. You will see this window:
Choose whether you want to permit reading writing or to keep monitorings for resellers
disabled (this is default).
Global Monitoring will be applied to all users which meet the requirements (this will be
explained later)
Kolmisoft 2006-2012
545
2. Select the desired options for new global Monitoring:
Period - this option let's you specify how often the monitoring must run and check all
users balance.
Amount - this option let's you specify the amount of money and whether it is
maximum limit or minimum call price limit. When user's balance drops to or
reaches the amount you specified an action will be taken against him depending on
other parameters.
Block user - if this option is set to Block - user will be blocked. He will not be able to
make any calls.
Send Email to Admin - here you may choose to be informed about the action by
email.
User type - this options specifies a user group an action must be taken against.
o All - Monitoring will be applied to All users
o Postpaid - Monitoring will be applied to Postpaid users
o Prepaid -Monitoring will be applied to Prepaid users
Additional Notes
You can create as many Monitorings for any group as you want. For example you can
create 2 monitorings for Postpaid users:
o 1 monitoring could just inform the administrator about the high user's balance
(in this case select these options: enter the amount and choose Increases more,
choose Do not block, choose Send, choose Postpaid)
o 2 monitoring could block the user with high balance if the administrator is
sleeping and didn't saw the warning email (in this case enter a bigger amount
Kolmisoft 2006-2012
546
than in the first monitoring and choose Increases more, choose Block,
choose Send, choose User type: Postpaid)
o 3 monitoring could inform the administrator that some users stoped calling for
some reason, maybe because of some technical problems, that otherwise would
not be noticed so quickly (in this case enter some amount and choose Drops
bellow, choose Do not block, choose Send, choose User type: Postpaid)
Personal Monitorings
Kolmisoft 2006-2012
547
3. Select the marked icon:
4. Depending on your scenario enter correct settings for a monitoring. Some information
about marked fields:
Kolmisoft 2006-2012
548
5. Press the marked button to create the monitoring:
In MOR it is also possible to monitor if users call price sum is under some certain certain sum.
This is useful to detect that something is wrong with user's settings, providers assigned to
him, etc.. Go to ADDONS -> Monitorings if you want to make a monitoring for users' group
or SETTINGS -> Users if you want to make a monitoring for single users.
Kolmisoft 2006-2012
549
You will see this window:
Select Drops below, choose other settings and click Create. The text next to the information
icon below shows what actions will be taken under what conditions depending on your
choices.
In some situations you might need to disable global monitorings for some users leaving only
personal monitorings. You can do that by navigating to user settings and enabling the
marked setting:
Kolmisoft 2006-2012
550
Recommended hardware
Minimum requirements:
20GB of free space on HDD
2GB of RAM
See also
User Blocking
About
This functionality is a part of Monitorings Addon and is used to spy user's real-time calls. This
functionality allows call-center managers to assess their employees work. It is also used in
prisons where such functionality is also necessary.
Admin
Reseller (active calls must be enabled for resellers)
Kolmisoft 2006-2012
551
3. Manager goes to active calls and presses a Spy icon on a desired call:
5. Manager answer's the call from the system and is able only to listen.
Please note that it is not possible to spy calls if their Server IDs do not match Spy Device
Server ID of the user (admin/reseller) who is viewing the calls. Icons for such calls are fainted:
2. Select a desired device where you want the system to send a call being spied:
Kolmisoft 2006-2012
552
Disable
You can also globally disable ChanSpy. Go to ADDONS -> Monitorings -> Settings. You will
see this window:
Reseller:
Other setttings
When spying you can press # to increase/decrease sound volume.
1 2 3 4 -4 -3 -2 -1 0(default)
Here:
-4 - is the quietest
4 - is the loudest
Kolmisoft 2006-2012
553
Limitations
If you have 2 Asterisk servers in your system, both devices for the "Spy action" have to
registered to the same Asterisk server.
A callshop is a business that physically provides phones for the purpose of making long-
distance telephone calls. More information can be found in Call shop page at wiki.
It is an additional functionality which allows to have and manage Call Shops for Admin and
Resellers.
[http://www.kolmisoft.com/uploads/files/Call_Shop_Brochure.pdf].
Kolmisoft 2006-2012
554
Postpaid
Manager's view
Kolmisoft 2006-2012
555
Terms
Reseller
Reseller is a Call Shop owner. Reseller can have many Call Shops.
Manager
Manager is a person who works for reseller. He works in a Call Shop and does these tasks:
Call booth
Call booth is a special user in MOR billing system dedicated for use in a Call Shop.
Manager's interface language - this will be the default language for Call Shop manager (the
person who will accept payments, enables call booths, etc.)
Invoice details (as seen in the invoice header) - the information you will enter here will be
displayed in the invoice.
Kolmisoft 2006-2012
557
5. Now you have to assign some call booths, select the marked icon to do that:
6. Select a required user from dropdown box (marked with number 1) and press a Add user as
booth (marked with number 2):
Very important! You have to dedicate user's for call shop booths, that means you must
not use these users anywhere else in MOR.
When there is no manager assigned in Call Shop when adding new call booth you will be
offered to mark it as a manager. Please do so. If you skip this step you can mark a booth as a
manager by pressing a marked icon:
Kolmisoft 2006-2012
558
Now you can see, that user's type was changed to manager and you can see a new icon:
Login as manager. You can use this icon to quickly access the manager's view to help him
solve problems.
P.S. The manager has his own way to access his manager view. Check „How can manager
access his management interface?― section in Call shop addoin page for more info.
1. The manager has to enter the server address in his browser (the same way as you access
MOR gui). Most commonly it would look like this: http://www.example.com/billing or
http://x.x.x.x/billing, where x.x.x.x is an IP address.
2. In open window the manager has to enter his Login and Password:
Kolmisoft 2006-2012
559
3. If Login and Password is correct the manager is redirected straight to his manager
interface:
Kolmisoft 2006-2012
560
2. After pressing the start button the following settings window will appear:
3. Now the manager has 2 options - to mark the user as prepaid or postpaid:
1) To mark a user as Prepaid select the marked check box (number 1).
Kolmisoft 2006-2012
561
3) Press the button marked with number 3
Kolmisoft 2006-2012
562
2) Press the marked button with number 2
The field Comment can be used to remind yourself some specific details about a user like
"The man with a hat" or/and to include some personal info about this user like his Name,
Surname, Driver's licence number etc. as this is a requirement in some countries. This field is
not limited by any size limits.
4. The booth status changes to reserved (user didn't called any number yet):
Kolmisoft 2006-2012
563
How can the manager stop the user call session, write invoice and take
money?
2. The window expands and you will see a lot of valuable information about the current user
call session. You can see how much money the user has paid and how much money should
be returned to user if his call session type was Prepaid.
The session is NOT ENDED until you press the marked button:
Kolmisoft 2006-2012
564
3. When you press the marked button (End Session and Generate Invoice) the call session is
stopped (the user will not be able to make any calls) and an invoice is generated. You can find
the generated invoice in Invoices section - press the marked button:
User type is prepaid, how can I top up his balance during the call?
Kolmisoft 2006-2012
565
2. Enter the required amount (marked with number 1) and choose to increase (marked with
number 2) or to decrease (marked with number 3) the current user balance.
3. Depending on what you have chosen (Increase or Decrease) you will see a similar
confirmation:
Kolmisoft 2006-2012
566
Call Shop taxes
Taxes are counted and shown in Call Shop invoices only if they are set in that call
booth's user settings (this allows you to have different call booths with different taxes)
2. Go to Call booths:
Kolmisoft 2006-2012
567
4. Find a displayed section in settings and set tax for a call booth:
More information about taxes can be found in multi-tax system page at wiki.
5. Save the changes
Now when you will end a calling session an invoice will be generated with taxes:
Rate search
Kolmisoft 2006-2012
568
Internal information on how Call Shop addon works
When an ordinary user is added to callshop - it is automatically blocked so he would not be
able to make calls. When calling session is started by the manager - it is unblocked (can make
calls now). When the session is ended - the user account is blocked again. You can always
check current booth blocked/unblocked status from admin or reseller in that booth details.
Please do not interfere with MOR system and do not change Blocked/Not blocked
status for call booth users.
When Call Shop Manager creates Prepaid or Postpaid session in Call Shop - MOR system also
changes Postpaid/Prepaid option and balance for that call booth user. Please do not edit
these options manually - it is not necessary.
Hide Settings
Other notes
1 call booth (phone) = 1 MOR user with 1 device. If there are more than 1 device
assigned for a user - please leave only 1.
The number of call booths (phones) is unlimited for each Call Shop
Which browser should I use for manager view for best user experience?
For best experience use Mozilla Firefox. You can get it here [www.mozilla.com]
You should add 1 manager (you will not be able to see this user in Call Shop
manager's view as it is needed only for administrating purposes)
You should add as many ordinary users as you need. This number depends on how
many phone booths (to simplify: phones) you have in your 1 call shop.
For example: You have 8 call booths (phones) in your call shop - then you need to create 9
users. 1 user account for a manager and 8 for call booths (phones).
Basic scenario how admin/reseller should setup a Call Shop with tariff
1. Create rates (tariff import). More information about: rates
2. Assign that tariff to the users he will use in Call Shop
3. Create Call Shop and assign users to Call Shop as booths
Done, now Call Shop manager (the person who sits in Call Shop and collects money) enables
call booths from manager interface by assigning them credit/balance.
Kolmisoft 2006-2012
570
Other notes
Admin/Reseller can change Call Shop prices by assigning a different tariff for a call
both (user).
Call Shop booths (users) cannot change prices.
Admin can check his resellers rates by loging in as reseller.
How to setup a call booth that it would bill in increments: per second, per minute or
preferential?
This can be achieved by creating a separate tariff with such settings. Then you will have
to assign this tariff for each Call Shop call booth (phone).
I would like that Call Shop owner would be able to import tariffs for his Call Shops, how
to do that?
Create a Reseller account per each Call Shop and configure Call Shops on these
Resellers. Billing information will be separated per Reseller.
See also
What is a reseller?
What is a Call Shop?
Tariffs
MOR Addons
Kolmisoft 2006-2012
571
Skype Addon
IMPORTANT! Skype channels for Asterisk are no longer available for sale after Microsoft
bought Skype, so this addon is not usable for this moment. For existing users, who have
bought Skype channels, Skype for Asterisk will be supported till July 26, 2013.
What is Skype?
Skype is a software application that allows users to make voice calls and chats over the
Internet. Read more about at wikipedia here [http://en.wikipedia.org/wiki/Skype].
Kolmisoft 2006-2012
572
Calling to Skype account from any other Skype account.
Calling from Skype and reaching Asterisk - then you can do something with that call.
For example you can set up an IVR which will pass the call to right person in your
company.
If you have bought Skype Addon you will find it in ADDONS section in MOR menu: ADDONS
–> Skype
Skype configuration
Skype provider
In order to use Skype you must configure a provider of type Skype in MOR:
Kolmisoft 2006-2012
573
4. Fill Skype Name and Password, choose audio Codec (we recommend G.711 u-law when
possible):
Skype Device
In order to use Skype in MOR you have to create (please note that you can't edit existing
device and change Technology to Skype, you must create a new one) a device of type
Skype for a desired user:
4. Press Create
Kolmisoft 2006-2012
574
5. Enter a correct Skype Name:
Skype FAQ
Yes, but please note: Skype consumer subscription prices for unlimited calling do not
apply.
No.
See also
Skype for Asterisk admin manual
Kolmisoft 2006-2012
575
Skype channel installation guide
How to buy Skype credits from Digium?
2. After submitting the registration you will get an email from Digium. Validate you email and
activate the account by clicking the link in email.
Kolmisoft 2006-2012
576
4. Go to Digium store
5. Select how many channels you would like to buy and press "Add to Cart":
7. Complete the transaction by paying for selected amount of Skype channels via your
preferred payment method (Visa, Mastercard, American Express, PayPal are supported as of
time of writing this article).
Skype installation
cd /usr/src
mkdir -p digium
cd digium
wget http://downloads.digium.com/pub/register/linux/register
chmod 777 register
Kolmisoft 2006-2012
577
After completing these steps you will see a similar output:
http://downloads.digium.com/pub/telephony/skypeforasterisk:
wget
http://downloads.digium.com/pub/telephony/skypeforasterisk/asterisk-1.4/x86-
64/skypeforasterisk-1.4_1.1.2-x86_64.tar.gz
Now check in Asterisk CLI how many licensed channels you have:
Licenses Found:
File: S4A-D3Z8TJAQZNCQ.lic -- Key: S4A-D3Z8TJAQZNCQ -- Expires: 2031-03-08 --
Host-ID: 25:d3:8b:cd:0c:0d:65:ec:a9:f8:87:7a:52:cd:aa:f9:a9:8b:a1:a1 -- Channels:
1 (OK)
Configuration
Configurations for Skype are located in /etc/asterisk/chan_skype.conf
Kolmisoft 2006-2012
578
3. You will receive an email from Skype. Activate your Skype Business account by visiting the
provided activation link in email.
1.
Kolmisoft 2006-2012
579
2.
3.
Kolmisoft 2006-2012
580
4.
5.
DO NOT CREATE ACCOUNTS IN ANY OTHER METHOD - THEY WILL NOT WORK WITH
Skype For Asterisk
Kolmisoft 2006-2012
581
Skype troubleshooting
Skype For Asterisk does not compile successfully
[root@ns356744 skypeforasterisk-1.4_1.1.2-x86_64]# make
gcc -I/usr/include -o chan_skype.o -c chan_skype.c -pipe -O3 -fPIC -
DAST_MODULE=\"chan_skype\" -MD -MT chan_skype.o -MF .chan_skype.o.d -MP
chan_skype.c: In function 'indicate':
chan_skype.c:457: error: 'AST_CONTROL_SRCUPDATE' undeclared (first use in this
function)
chan_skype.c:457: error: (Each undeclared identifier is reported only once
chan_skype.c:457: error: for each function it appears in.)
make: *** [chan_skype.o] Error 1
Your Asterisk version is too old. Please contact Kolmisoft to upgrade it to 1.4.37 or later
This could be because a previous instance of this binary is running and was not properly shut
down. Since any new instances try to bind to the same port, they fail. If 'ps aux|grep
skypeforasterisk' returns any skypeforasterisk processes when Asterisk is not running, kill
them and restart asterisk.
Another reason for failure could be that disable_tcpauto is set to no (the default) and can not
bind to ports 80 and 443 due to asterisk running as a non-root user or other services being
bound to those ports.
Kolmisoft 2006-2012
582
Failure can also occur if the engine_directory is set to a directory which is mounted with the
'noexec' flag or to a directory where the user does not have execute permission.
[http://wiki.kolmisoft.com/index.php/Skype_channel_installation_guide#Create_Skype_accoun
ts_for_calling].
Provider billing addon allows reversed billing - it counts provider's balance which increases
when admin or reseller makes a call through it.
Balances
Provider has balance which increases when call goes over this Provider. E.g. Provider receives
money for the calls over him.
Kolmisoft 2006-2012
583
If Provider is assigned to the User then such Provider can make calls. When Provider (which is
assigned to the User) makes calls, such calls goes over other Providers and User's (to which
Provider is assigned) balance is decreased.
IMPORTANT! Provider's balance and User's balance are two different values. They are not
connected and do not impact each other. They change independently of each other.
To add manual payment for provider in main provider billing addon window click and you
will be lead to this window:
Click Proceed:
Kolmisoft 2006-2012
584
Click Confirm. You will be redirected to Payments window and see this payment if everything
is correct.
Please note that adding positive Amount will decrease provider's balance and adding
negative will increase it. Balance - amount = new balance.
Reseller can use this feature only on that reseller's providers.
To reach the provider billing go to ADDONS -> Provider billing. You will see this window:
After you were lead to provider's edition page you can select a minute limit per day for
provider. You will find it in Advanced block.
If the limit is exceeded that provider is disabled which means it is not available to make calls
through it anymore. If you add a value of zero, no limit will be applied.
Kolmisoft 2006-2012
585
To apply this functionality to device go to SETTINGS -> Setup -> Default device and
see Advanced block.
Tutorials
Usual configuration sequence
1) Make a provider's tariff, then import it.
2) Make a provider, then assign the provider's tariff to the provider itself.
4) Make a user.
6) Make LCR.
9) Register your device to MOR using your user's device details (username and password (not
PIN)) and then make a call.
If you have any questions or suggestions, or can't solve a problem on your own, please use
our forum or support system, or just send an email to support@kolmisoft.com
Kolmisoft 2006-2012
586
Tested with 0.7, 0.8 MORs and 2.6.2.3 Trixbox.
Kolmisoft 2006-2012
587
Create a DID and map it to the device.
Log in as administrator to Trixbox and create a Trunk with the following settings: Change
192.168.0.148 to your MOR server IP address and 1005 username and secret to the
appropriate settings.
Kolmisoft 2006-2012
588
Create a Conference with these settings:
Kolmisoft 2006-2012
589
Then create a DID (Inbound route):
Kolmisoft 2006-2012
590
Then try to call from any device to 8000 in MOR. You should hear a woman's voice and
instructions on what you need to do.
Of course, if you change settings everywhere from 8000 to your real DID, it will work as well.
A few hints
For each new conference room you will need a separate device and a DID in MOR.
This guide will show how to configure 911, 411 or any other similar service.
[http://www.myvoipprovider.com/VoIP_911_Service].
First of all, you need a provider that will allow you to use such a service. Some such providers
may be found here [http://www.voip-info.org/wiki/view/VOIP+911+Service+Providers].
When you buy a service from such a provider, he will give you an access number to dial.
As an example, let's take the number 12125551212, which should be dialed to access the
service.
Short guide
Kolmisoft 2006-2012
591
Detailed guide
Kolmisoft 2006-2012
592
Create a DID 911 and assign a Virtual Device to it:
Another way
Create User 911.
Create Virtual Device with Extension 911 for this user.
Make correct LCR for this user (with correct Provider which can handle 911 calls).
In Devices Call Flow, Forward the call to the External number given by your Provider.
If the devices are not configured properly, then a call from external server to MOR is possible,
but only one device will be billed all the time or only one trunk will be active (it depends on
the misconfiguration).
Kolmisoft 2006-2012
593
SIP INVITE packet
As described previously, the correct SIP INVITE packet should be received in order for MOR to
authenticate the user correctly.
Example
Kolmisoft 2006-2012
594
Let's say we have MOR and another Asterisk server from which we want to configure two
connections to MOR.
MOR configuration
First, on MOR we need to describe such connections as Devices for different Users.
We will create two devices, 1028 and 1009, for these connections:
Kolmisoft 2006-2012
595
Remote server configuration
The remote server in our example is Asterisk, so its configuration should be in sip.conf file,
which describes both connections and registers to MOR:
[general]
[authentication]
[mor1028]
canreinvite=no
host=82.215.xxx.xxx
user=1028
username=1028
secret=ewpjxxxx
type=peer
fromuser=1028
[mor1009]
canreinvite=no
host=82.215.xxx.xxx
user=1009
username=1009
secret=ca5hxxxx
type=peer
fromuser=1009
Limitations
It is not possible to send CallerID from a remote server this way, because "fromuser"
overwrites the CallerID field.
You can only hardcode CallerID in MOR for every user account.
Kolmisoft 2006-2012
596
How to forward calls when device is offline
1. Go to SETTINGS -> Users -> Devices and from opened device list choose a device.
Click icon which will lead you to Call Flow page.
Kolmisoft 2006-2012
597
4. In Data section select whether you want it to be forwarded to a local device (choose one
from the dropdown) or an external number (enter the number), choose CallerID settings and
click Change:
Kolmisoft 2006-2012
598
Kolmisoft 2006-2012
599
Kolmisoft 2006-2012
600
Kolmisoft 2006-2012
601