Bundle-rates rate calls using a special rate, until certain conditions are respected. Then normal rates are applied.
bundle-1000
pays 10 EUR monthly, and he has 1000 free minutes of national calls. The calls not
matched by the bundle conditions (e.g. international calls in this case) are rated
using normal rates, and they do not decrease the limit of the bundle. Calls without
an cost (for the consumer) are not considered inside the bundle.
bundle { id: bundle-1000 service-cdr-type: iBundle 1000 service-cdr-description: 1000 minutes on all national directions schedule: monthly schedule-from: 1 apply-for-each: bundle-1000 limits-are-proportionals-to-activation-date: true only-for-calls-with-a-cost: true bundle-cost: 10 rate { id: cost match-call-direction: outgoing # NOTE: without an explicit filter on outgoing calls, # also incoming calls can be theorically applied to a bundle. # In this case the "only-for-calls-with-a-cost" can prevent this. match-communication-channel: local,national,mobile limit-on-first-calls: none limit-on-first-seconds: 60000 set-cost-for-minute: 0 } }
allinc-500
pays 50 EUR monthly, and he:
bundle { id: allinc-500 service-cdr-type: Bundle Rate service-cdr-description: All inclusive: 500 fixed-line minutes, 500 minutes mobile schedule: monthly schedule-from: 1 apply-for-each: allinc-500 limits-are-proportionals-to-activation-date: true only-for-calls-with-a-cost: true bundle-cost: 50 rate { id: national match-telephone-number: 39* match-call-direction: outgoing limit-on-first-calls: none limit-on-first-seconds: none set-cost-for-minute: 0 rate { id: fixed-line match-telephone-number: 390* # fixed-line operators limit-on-first-calls: none limit-on-first-seconds: 30000 set-cost-for-minute: 0 } rate { id: mobile-line match-telephone-number: 393* # mobile operators limit-on-first-calls: none limit-on-first-seconds: 30000 } } }
bundle { id: [reference] service-cdr-type: [textual description] # a short textual description/name for the type of service-cdr. # Usually something like "Bundle Rate", "Bundle Service", "Service", and so on. # This name can be shared between different bundle-rates. # It does not contain details about the service, but only an high level classification. service-cdr-description: [textual description] # a textual description, associated to the service-cdr, # describing the details of the service offered/billed from the bundle-rate, # in the call report, and invoices. # It will be generated only if the bundle-rate service-cdr cost is greather than 0. # It will be generated for each organization associated to the bundle-rate. # There will be a unique service-cdr, with the sum of all the cost of nested bundle-rates. schedule: [monthly|weekly] # after each scheduling period (time-frame), the bundle rate status is resetted, # and the bundle-rate service-cdrs are produced. schedule-from: [1..28] | [Monday|Tuesday|...] # specify the day of the month, or the day of the week, or the time-frame in days, # when starting the new bundle-rate time-frame. schedule-at: 00:00:00 # (optional) schedule at hh:mm:ss, of the new rating-frame day. apply-for-each: [list of price-category] # This bundle-rate is applied to organizations/extensions # with an explicit assignment to this specified price-categories. # # If an organization/extension inherits the price-category from its parent # organization, but it has no explicit assignment, # then it has no a distinct bundle-rate status: # * a service-cdr is generated only for its parents with explicit assignment; # * there is no separate limits allocated for the extension, # but the limits of the parent organization are used instead; # # The date of price-category assignment is used for determining when the bundle-rate # can be applied. # # Service-cdr is generated also if there are no calls for him, inside the time-frame. limits-are-proportionals-to-activation-date: [true|false] # true if the bundle-rate limits on an organization/extension created not at the beginning of a time-frame, # but after X% days, must be scaled of X%. # # If true, then also the bundle-rate costs are proportional to the activation date. # # Only the activation (starting) date is considered, but not the date on which an organization/extension change # price-category, and exit from the bundle-rate. The consequences are that if an organization enters # at day 15 into a monthly bundle-rate A, and it exits from it at day 20 entering in monthly bundle-rate B, # then the organization pays both the bundle A at 50%, and the bundle B at 66% for the month with the change. # # In case there are repeated assignments to the same price-category, inside the same time-frame of the bundle-rate, # only the first assignment is taken in account. only-for-calls-with-a-cost: [true|false] # true for applying the bundle only to calls having a positive cost. # So free calls are not counted as inside the bundle. # This is an advantage for end customers, because they can use the bundle # only for calls with a cost. bundle-cost: [monetary-value] # what the customer pays for activating the bundle. # Default value: 0 rate { id: [reference] [match conditions] # apply the rate/bundle only if the rating conditions are respected limit-on-first-calls: [number|none] # apply the bundle-rate only to the first specified calls, then use normal rates. # "none" for no limit on the number of calls. # # If this rate has a parent rate, then check and decrease also the limits # of the parent rate. limit-on-first-seconds: [number|none] # apply only for calls until the specified seconds. # "none" for no limit on duration of calls. # # In case of nested rates, the behaviour is similar # to the case of "limit-on-first-calls". [rating params] # calc the cost of the CDR according these params [other nested rates] } [other nested rates] }
bundle { id: A [...] bundle-cost: 50 rate { id: outgoing match-call-direction: outgoing match-telephone-number: 39* limit-on-first-calls: none limit-on-first-seconds: none rate { id: B match-telephone-number: 390* limit-on-first-calls: none limit-on-first-seconds: 1000 } rate { id: C match-telephone-number: 393* limit-on-first-calls: none limit-on-first-seconds: 1000 } } }
A/outgoing
:
A/outgoing/B
or A/outgoing/C
, otherwise an error is generated
A/outgoing
and the bundle limits of the matched A/outgoing/B
or A/outgoing/C
A/outgoing
and of the matched A/outgoing/B
or A/outgoing/C
are respected, otherwise it is rated using normal rates
A/outgoing
, is rated using normal rates
A
.
rate
follows the matching and application semantic of rates.
A*
A/B*
A*/C
where A/B*
and A*/C
are children of the parent organization A*
.
A*
is explicitly assigned to price-category PA
A*/B*
is explicitly assigned to price-category PB
A*/C
is not assigned explicitly to any price-category, so its inherit the price-category
of A*
A*/C
, it tries to apply the bundle-rate associated to A*
, because C
has no bundle-rate, but A*
is subscribed to PA
bundle-rate, and so it must take advantage of this for all its extensions. If the
bundle-rate can be applied to A*/C
, then the limits of A*
are updated.
A*/B*
organization, it tries to apply the bundle-rate associated to PB
price-category, because organization A*/B*
is associated explicitly to PB
. If the PB
bundle-rate can be applied to A*/B*
, then only the limits of A*/B*
are updated, while A*
is not updated.
A*/B*
, B*
is explicitly assigned to a normal (no-bundle) rate, then this normal rate is applied,
without using the A*
bundle-rate.
A*/B*
is a bundle-rate that has consumed all its bundle-limits, then the system will rate
the call using normal rates, and not the PA
bundle-rate associated to A*
.