Skip to content

Calling Card application

The Calling Card application turns any phone into a prepaid calling service: the caller dials an access number, chooses a language, identifies a card, hears the balance and dials destinations that are billed to the card. Each card is an account; the application only identifies it and places the calls. For a product walkthrough see Set up a calling card product.

  1. The caller reaches the application through a DID assigned to it, or through a connection with the keyword callingcard.
  2. A custom greeting or an early greeting prompt plays, then the language menu offers the languages of Language List in order.
  3. The card is identified: by the caller’s number if it is a trusted number of a card, otherwise by the card number and, unless disabled, the PIN.
  4. A late greeting prompt plays, then the balance and, after the destination is dialled, the time the caller can talk.
  5. The application calls the destination as the card’s account, through its service plan and routing group. After the call the caller can dial another destination or use the menus: hot dial, CLI registration, password change, top-up.

The card number is the account’s Account Name, or its VoIP Login with Use VoIP Login As Card Number. The PIN is the account’s VoIP Password.

  1. Open DIDs & IVR Apps → IVR Applications and click Add New.
  2. Enter Name, select Type Calling Card and the languages in order.
  3. Click Save, open Advanced Parameters and add the options from the tables below that differ from the defaults.
  4. Assign the access number’s DID to the application in DIDs & IVR Apps → DID Pool.
Option Default Meaning
Card Number Length 20 Maximum digits of a card number; input stops at this length
Minimum Card Number Length Minimum digits of a card number
Use Word PIN true Say “PIN code” instead of “card number” in every menu; disables the password check
Allow Empty PIN true Accept cards whose account has no PIN
Use VoIP Login As Card Number false Look cards up by VoIP Login instead of Account Name
Number Of Attempts To Enter A Card 3 Attempts to enter a valid card number
Number Of Timeouts 3 Input timeouts in a row before hang-up
Allow Own Accounts Only false Accept only cards of the customer that owns the application

A trusted number links a caller’s phone number to a card, so the caller is recognised without entering the card. Trusted numbers are listed on the account’s Trusted Numbers screen.

Option Default Meaning
Trusted CLI Authentication false Recognise callers by trusted numbers
PIN-less CLI Authentication false Do not ask for the PIN after a caller was recognised by number
CLI As Card Number false Try the caller’s number as the card number before asking
Use CLI Authentication Only false Admit only callers with a trusted number
Enable CLI Registration true Offer the menu where a caller registers their number to the card
CLI Registration Menu Extension Number Extension of that menu
Automatic CLI Registration false Register the caller’s number after the first successful card entry
Silent Automatic CLI Registration true Register without asking the caller
Minimum Valid CLI Length 6 Shorter numbers are never registered
Trusted Numbers Limit Maximum trusted numbers per card registered through the IVR
Balance Threshold Minimum Balance Below this balance the card number is asked even for a trusted number
Option Default Meaning
Announce Balance true Announce the balance at the start of the session
Say Negative Balance As Zero true Announce a negative balance as zero
Minimum Balance Below this available balance the card is blocked; 2 USD or a plain number
Say ‘No Card’ On Low Balance true Answer a card below the minimum balance as a wrong card number
Announce Duration true Announce the time the caller can talk before connecting
No Seconds In Duration false Leave seconds out of the announcement
No Hours In Duration false Announce minutes only: “80 minutes” instead of “1 hour 20 minutes”
Play Service Plan Minutes Only false Announce the minutes of the service plan only
Ignore Connect Fee false Leave the connect fee out of the duration calculation
Minimum Call Duration 10 Below this computed duration the caller hears there are insufficient funds
Maximum Call Duration 3600 Longest outbound call, in seconds
Disconnect Warning Time Seconds before the end of the balance when a warning is played
Normal Calls Are Allowed true With false only the menus work, no outside calls
Call Several Destinations true Let the caller dial again after a call
Number Of Wrong Destinations 3 Failed destinations in a row before hang-up
Disconnect On Failure false End the session after a failed call instead of asking for another destination
Preserve Original CLI false Present the caller’s own number to the destination instead of the card number
Destination Number Completion Regex Regular expression that ends number entry without #
Suppress Pound Phrase false Do not say “followed by the pound key”
Outbound SIP Proxy Host and port the application sends outbound calls to
The Reason For Diversion unconditional Reason in the Diversion header of outbound calls
Option Default Meaning
Enable Hot Dial true Let callers store numbers behind single keys
Hot Dial Menu Extension, Hot Dial Edit Menu Extension Extensions of the hot dial menu and of its editor
Enable Direct Hot Dial false A single key from the main menu dials the stored number
Limit Hot Keys false Only keys 1, 2 and 3 act as hot keys
Smart Dial Exclusive Mode false A smart dial DID serves one account only
Enable Password Change true Offer the PIN change menu
Change Password Menu Extension Number Extension of that menu
Enable Top-Up feature true Offer the top-up menu
Top-Up Menu Extension Extension of the top-up menu
Top-Up Card Length 10 Maximum digits of a top-up card
Enable Black List false Limit a caller number to one card attempt per call after repeated wrong cards
Number Of Attempts To Blacklist 3 Wrong card numbers in a row before the caller number is blacklisted
Option Default Meaning
Language List en Languages offered at the start, normally set with the language selectors of the form
Default Calling Card Language en Language when no choice was made
Fallback To Default Calling Card Language false Fall back to it after too many wrong language choices
Enable Custom Greeting, Custom Greeting File false Play an audio file before the language menu
Early Greeting Prompt ID Prompt played before the language menu, the same in every language
Late Greeting Prompt ID Prompt played after the card is identified, per language
Option Default Meaning
Custom Script To Check Destination Python script on the switch that allows or refuses each destination
Custom Script To Change Announced Duration Script on the switch that changes the announced duration without changing the real limit

Greetings use IVR prompts: audio recordings stored on the switch with an id, optionally one recording per language. Prompts are created on the server with the ivr_prompt_utils tool from 8 kHz signed linear audio; support or your server administrator can create them for you. Set the prompt id in Early Greeting Prompt ID or Late Greeting Prompt ID, or per access number with greet<id> and lgreet<id> in the dialled number. Callers whose language has no recording of a late greeting hear the default recording.

One application can serve several access numbers with different behaviour: parameters appended to callingcard in the CLD override the configured options for that call. Two-letter parameters are taken as the language list.

Parameter Meaning
en, es, ru, … Languages offered, in order
playbalance, noplaybalance or nobalance Announce or do not announce the balance
noplayduration or noduration Do not announce the duration
planminutes Announce service plan minutes only
trustcli Trust caller numbers; never ask for the PIN
trycliauth or cliauth, nocliauth Try or do not try the caller’s number as the card number
nocardenter or climaponly End the session if the caller has no trusted number
keepcli, nokeepcli Present the caller’s own number, or the card number, to the destination
nodial Menus only, no outside calls
noredial Hang up after the first call attempt
earlymedia Stay in early media until the destination answers
greet<id>, lgreet<id> Early and late greeting prompts
hotdialext<ext>, hotdialeditext<ext>, directhotdial, nohotdial Hot dial menus and direct hot dial
cliregext<ext>, noclireg CLI registration menu
chpassext<ext>, nochpass Password change menu
topupext<ext>, notopup Top-up menu
topup Run the top-up menu only. See Top Up application

Example: s/.*/callingcard_en_es_ru_cliregext003_trustcli_noplaybalance/.

The balance is not announced when the account’s service plan has minutes, when the plan is suspended, or when the balance is zero.