[Asterisk-Users] app_prepaid.c

Alexander Romanov
Wed, 10 Mar 2004 18:39:03 -0000

Hi Gus,

Thanks for your help. But I am still struggling to get it to work.
How do you put the data into 'provider' to allow a call which works in
asterisk (extensions.conf)

exten => s,1,Dial(IAX2/Username:Password@iax.voiptalk.org/${EXTEN})

Where ${EXTEN} is a dialed number

Thanks in advance.
Alex.

-----Original Message-----
From: asterisk-users-admin@lists.digium.com
[mailto:asterisk-users-admin@lists.digium.com] On Behalf Of CW_ASN
Sent: Thursday, 11 March 2004 11:35 AM
To: asterisk-users@lists.digium.com
Subject: Re: [Asterisk-Users] (no subject)


Alex:

In 'call' table stores call details.
'card' stores user & pin (10 digits in original version)
'country'
associates a short description with a long description of destination.
'countryprefix' associates prefix (i.e. 1305) with short description (of
'country' table) and type of destination (fixed, mobile).
'internationalprefix' contains a copy of countryprefix.prefix. Used in
the store procedure for match registers. 'providers' contains outgoing
details:
    'prefix' is the string added to the dialled string.
    'providercode' is a code used to match rates, etc.
    'providertech' is the protocol used. In the original version is not
posible to use zap devices. You must remove the ip in the dial command.
    'providerip' is the ip for your gateway.
'providerdestination'
contains the route codes for this provider.
'providerdestination.destination' is the same as countryprefix.prefix
'providerrate' stores the rate for each destination.
    'providerrate.countrycode' is the same as short description for
'countryprefix' table.
    'providerrate.subcode' is the same as type of destination in
'countryprefix' table.
    'providerrate.rate' is the price (in cents) per minute.
'reseller','resselercard' and 'sale' unused at this time
(I think).
'tariff' contains a tariff code and tariff name definitions.
'tariffrate' is almost the same as providerrate.

If your need more details or examples please advise.

Hope this helps.

Regards,

Gus


----- Original Message -----
From: "Alexander Romanov" <alex@rnsinternational.com.au>
To: <asterisk-users@lists.digium.com>
Sent: Wednesday, March 10, 2004 8:35 PM
Subject: [Asterisk-Users] (no subject)


> Hi guys,
>
> Has anyone played around/got it to work app_prepaid.c?
> (http://www.voip-info.org/wiki-Asterisk+callingcard)
> With what data do you populate the database with cards, providers,
> tariffs, tariffrates etc.. (format) to make it work. What is the
> meaning/purpose of each table/field?
>
> I am getting stuck here:
>
> Mar 11 10:33:28 DEBUG[1255670720]: app_prepaid.c:253
> prepaid_ivr_authorize: app_prepaid: SQL Authorize command as follows:
> SELECT * FROM asterisk_authorize('standard','61294332207')
AS
> authorize(rate integer, tech text, prefix text, ipaddress text) Mar 11

> 10:33:28 DEBUG[1255670720]: rtp.c:950 ast_rtp_raw_write: Difference is

> 86856, ms is 10877 Mar 11 10:33:28 DEBUG[1255670720]: channel.c:956
> ast_settimeout: Scheduling timer at 160 sample intervals
>     -- Playing 'prepaid-dest-unreachable' (language 'en')
>
> Thanks
> Alex.
>
> _______________________________________________
> Asterisk-Users mailing list
> Asterisk-Users@lists.digium.com
> http://lists.digium.com/mailman/listinfo/asterisk-users
> To UNSUBSCRIBE or update options visit:
>    http://lists.digium.com/mailman/listinfo/asterisk-users



_______________________________________________
Asterisk-Users mailing list
Asterisk-Users@lists.digium.com
http://lists.digium.com/mailman/listinfo/asterisk-users
To UNSUBSCRIBE or update options visit: