Receiving AOC data

This topic describes:

When Advice of Charge data is available, the application receives an ACU indication or confirmation message, containing an acu_ss_aoc_inform_invoke extended data structure with:

The following listing shows the acu_ss_aoc_inform_invoke extended data structure:

struct acu_ss_aoc_inform_invoke
{
  struct acu_ext_hdr ext_hdr; /* Extension header                  */
  struct acu_ss_hdr  ss_hdr;  /* Supp. services header             */
  uchar  aoc_type;            /* From ACU_SS_AOC_TYPE... constants */
  pad7
  union
  {
    tAcuSSAocSInform aoc_s;   /* aoc_type==AOC_SS_TYPE_AOC_S_INFORM*/
    tAcuSSAocDInform aoc_d;   /* aoc_type==AOC_SS_TYPE_AOC_D_INFORM*/
    tAcuSSAocEInform aoc_e;   /* aoc_type==AOC_SS_TYPE_AOC_E_INFORM*/
  } aoc_data;
};

The following table lists the fields in this structure (other than the header fields), and when they are used:

Field

Description

Will be filled in this response?

aoc_type

Indicates the type of AOC service returning the data. From SS_AOC_TYPE constants.

Yes

aoc_data

aoc_s contains data if aoc_type= ACU_SS_AOC_TYPE_AOC_S_INFORM

aoc_d contains data if aoc_type= ACU_SS_AOC_TYPE_AOC_D_INFORM

aoc_e contains data if aoc_type= ACU_SS_AOC_TYPE_AOC_E_INFORM

Yes


Charging information is delivered to the application using the extended service data area of an ACU primitive during the active part of the call.

Advice of charge - start of call (AOC-S)

If AOC-S is active, the aoc_type field in acu_ss_aoc_inform_invoke is set to ACU_SS_AOC_TYPE_AOC_S_INFORM. The tAcuSSAocSInform data structure and substructures are used to carry Advice of Charge data.

The following listing shows the tAcuSSAocSInform structure.

typedef struct tAcuSSAocSInform
{
  uchar type_of_info;           /* From ACU_SS_AOC_TYPE_OF_INFO_ constants*/
  uchar charged_item;           /* Bitmap of charged item constants       */
  uchar charging_rate;          /* One of charging rate constants         */
  pad5
  union 
  {
    tAcuSSAocDuration duration; /* charging_rate=CHARGING_RATE_DURATION   */
    tAcuSSAocSpecific specific; /* charging_rate=CHARGING_RATE_SPECIFIC   */
    tAcuSSAocVolume   volume;   /* charging_rate=CHARGING_RATE_VOLUME     */
  }rate;
};

The following table lists the fields in this structure (other than the header fields):

Field

Included

Description

type_of_info

Mandatory

From SS_AOC_TYPE_OF_INFO constants.

charge_item

Optional

Bitmap of charged item constants. From SS_AOC_CHARGED_ITEM constants.

charging_rate

Optional

One of SS_AOC_CHARGING_RATE constants.

rate

Optional

References structure containing data associated with charging rate.


If there is charging rate information returned, the type_of_info field in the tAcuSSAocSInform structure contains CHARGE_RATE. Otherwise, the field contains NOT_AVAILABLE.

If type_of_info in tAcuSSAocSInform contains CHARGE_RATE, the charged_item field in the structure contains the charged item. The following are valid values for this field:

Value

Description

BASIC

Indicates the basic communication charged item. This charged item indicates the rate to be applied to the basic communication between the users. If the rate changes, the served user is informed by a repetition of this charged item indicating the new rate.

ATTEMPT

Indicates the call attempt charged item. This charged item indicates the cost applied for successful call attempt before the called user accepts the call.

SETUP

Indicates the call setup charged item. This charged item indicates the cost applied when the connection between the users is established.

SPECIAL

Indicates the special charging arrangement charged item. This charged item indicates that a special arrangement exists for calculating the cost of the call. Note that the use of this charged item is not standardized: its meaning is a matter for the network operator and the user to which it is sent.

USER_TO_USER

Indicates the user-to-user information transfer charged item. This charged item indicates the rate to be applied to the transfer of user-to-user information. If the rate changes, the served user is informed by a repetition of this charged item indicating the new rate.

SUP_SERV

Indicates the operation of supplementary services charged item. This charged item indicates the cost applied for the operation of requested supplementary services.


Note: Network providers will only use those charged items that are appropriate to the service provider's charging mechanism. Therefore, in some networks, users may or may not receive some of these items or combinations of items. Different networks may give information about the same call in different ways.

Different charging rates are associated with each of the charged item types. If a charged item is not included, the default value is interpreted as free of charge.

Charged item

Included

Possible charging rate values

Basic Communication

Always.

Price per time unit and time unit.

Flat rate (a fixed currency value per event).

Free of charge.

Special charging code.

Not available.

Call Attempt

Only in the initial charging information sent to the served user.

Flat rate (a fixed currency value per event).

Free of charge.

Special charging code.

Not available.

Call Setup

Only in the initial charging information sent to the served user.

Flat rate (a fixed currency value per event).

Free of charge.

Special charging code.

Not available.

Operation of Supplementary Services

Only if the served user has requested a supplementary service.

Price per time unit and time unit.

Flat rate (a fixed currency value per event).

Free of charge.

Special charging code.

Not available.

User-to-User Information Transfer

Only if the served user has requested the user-to-user signaling supplementary service.

Price per volume unit and volume unit.

Flat rate (a fixed currency value per event).

Free of charge.

Special charging code.

Not available.


The charging rate is specified in the charging_rate field in the tAcuSSAocSInform structure. Depending upon its setting, one of the following data structures contains additional data:

The following table lists the charging_rate field setting and associated data structure for each charging rate type:

Rate type

charging_rate field setting

Associated data structure

Structure description

Price per volume unit and volume unit

VOLUME

tAcuSSAocVolume

Currency value for a particular volume unit, together with the length of the volume unit.

Price per time unit and time unit

DURATION

tAcuSSAocDuration

Currency value for a particular time unit, together with the length of the time unit.

Flat rate

SPECIFIC

tAcuSSAocSpecific

A fixed currency value per event. rate_type in this structure is set to FLAT_RATE.

Free of charge

SPECIFIC

tAcuSSAocSpecific

A fixed currency value per event. rate_type in this structure is set to FREE_OF_CHARGE or FREE_OF_CHARGE_FROM_BEGINNING.

Special charging code

SPECIFIC

tAcuSSAocSpecific

A fixed currency value per event. rate_type in this structure is set to SPECIAL_CHARGING.

Not available

SPECIFIC

tAcuSSAocSpecific

rate_type in this structure is set to NOT_AVAIL.


tAcuSSAocDuration structure

The following listing shows the tAcuSSAocDuration structure:

typedef struct tAcuSSAocDuration
{
  struct op_byte_field multiplier;        /* Applies to currency amount   */
  struct op_long_field currency_amount;   /* No. of currency units charged*/
  struct op_long_field time;              /* Number of time units charged */
  struct op_long_field granularity;       /* Integer or not included      */
  struct op_byte_field time_scale;        /* Applies to time              */
  struct op_byte_field granularity_scale; /* Applies to granularity       */
  struct op_byte_field currency_id_size;  /* 0 if currency ID not included*/
  uchar  currency_id[MAX_CURRENCY_SIZE];  /* Currency ID                  */
  uchar  type_of_charging;                /* From SS_AOC_S_TYPE_OF_CHARGE */
  pad3                                    /* constants                    */
};

The following table lists the fields in the tAcuSSAocDuration structure:

Field

Included

Description

multiplier

Mandatory

This value plus currency_amount indicates the currency amount. From ACU_SS_AOC_MULTIPLIER constants.

currency_amount

Mandatory

This value plus multiplier indicates the currency amount.

time

Mandatory

This field plus time_scale indicates the length of time unit.

granularity

Optional

This value plus granularity_scale indicates the time unit applied for calculation of charges by the network. Integer or not included.

time_scale

Mandatory

This field plus time indicates the length of time unit. From SS_AOC_SCALE constants

granularity_scale

Optional

This value plus granularity indicates the time unit applied for calculation of charges by the network. Only included if granularity field is included.

currency_id_size

Mandatory

Size of currency_id.

currency_id[MAX_CURRENCY_SIZE]

Mandatory

Currency ID.

type_of_charging

Mandatory

Step function (charge is incurred for the time unit, or part thereof) or continuous (charges are incurred evenly throughout). From SS_AOC_S_TYPE_OF_CHARGE constants.


tAcuSSAocSpecific structure

The following listing shows the tAcuSSAocSpecific structure:

typedef struct tAcuSSAocSpecific
{
  struct op_byte_field multiplier;       /* From ACU_SS_AOC_MULTIPLIER_  */
                                         /* constants                    */
  struct op_long_field currency_amount;  /* No. of currency units charged*/
  struct op_byte_field charge_code;      /* 10                           */
  struct op_byte_field currency_id_size; /* No. of bytes from currency_id*/
  uchar  currency_id[MAX_CURRENCY_SIZE]; /* Currency ID string           */
  uchar  rate_type;                      /* From ACU_SS_AOC_RATE_TYPE_   */
  pad3                                   /* constants                    */
};

The following table lists the fields in the tAcuSSAocSpecific structure:

Field

Included

Description

multiplier

Mandatory

Yes when rate_type is FLAT_RATE. This value plus currency_amount indicate the currency amount. From ACU_SS_AOC_MULTIPLIER constants.

currency_amount

Mandatory

Yes when rate_type is FLAT_RATE. This value plus multiplier indicate the currency amount. Raw numeric value.

charge_code

Mandatory

Yes when rate_type is SPECIAL_CHARGING. Integer value from 1 to 10. Identifies special charge arrangement for the NAI.

currency_id_size

Mandatory

Number of bytes from currency_id.

currency_id[MAX_CURRENCY_SIZE]

Mandatory

Character array identifying the currency.

rate_type

Mandatory

Free of charge, flat rate (a fixed currency value per event), special charging code, or not available. From ACU_SS_AOC_RATE_TYPE constants.


tAcuSSAocVolume structure

The following listing shows the tAcuSSAocVolume structure:

typedef struct tAcuSSAocVolume
{
  struct op_long_field currency_amount;    /* No of currency units charged*/
  struct op_byte_field currency_id_size;   /* No of bytes from currency_id*/
  struct op_byte_field multiplier;         /* From ACU_SS_AOC_MULTIPLIER_ */
                                           /* constants*                   /
  uchar    currency_id[MAX_CURRENCY_SIZE]; /* Currency ID string          */
  uchar    volume_type;                    /* From ACU_SS_AOC_VOLUME_TYPE_*/
  pad3                                     /* constants                   */
};

The following table lists the fields in the tAcuSSAocVolume structure:

Field

Included

Description

currency_amount

Mandatory

This value plus multiplier indicates the currency amount. Raw numeric value.

currency_id_size

Mandatory

Number of bytes from currency_id.

multiplier

Mandatory

This value plus currency_amount indicates the currency amount. From ACU_SS_AOC_MULTIPLIER constants.

currency_id[MAX_CURRENCY_SIZE]

Mandatory

Character array identifying the currency.

volume_type

Mandatory

Octet, segment, or message to which UUI has been attached. From ACU_SS_AOC_VOLUME_TYPE constants.


Advice of charge - during call (AOC-D)

If AOC-D is active, the aoc_type field in the acu_ss_aoc_inform_invoke structure is set to ACU_SS_AOC_TYPE_AOC_D_INFORM. The tAcuSSAocDInform data structure and substructures are used to carry Advice of Charge data.

The following listing shows of the tAcuSSAocDInform structure:

typedef struct tAcuSSAocDInform
{
  struct op_byte_field currency_id_size; /* Used only if type_of_charging*/
                                         /* is CURRENCY_UNITS            */
  struct op_long_field currency_amount;  /* Used only if type_of_charging*/
                                         /* is CURRENCY_UNITS            */
  struct op_byte_field multiplier;       /* Used only if type_of_charging*/
                                         /* is CURRENCY_UNITS            */
  struct op_byte_field billing_id;       /* From ACU_SS_AOC_BILLING_ID   */
                                         /* constants                    */
  struct acu_ss_association charge_association; /* Returns ID of charge  */
                                         /* for AOC-E after call clearing*/
  tRecordedUnits       recorded_units;   /* Used only if type_of_charging*/
                                         /* is CHARGING_UNITS            */
  uchar currency_id[MAX_CURRENCY_SIZE];  /* Used only if type_of_charging*/
                                         /* is CURRENCY_UNITS            */
  uchar type_of_charging;                /* From SS_AOC_TYPE_OF_CHARGE...*/
                                         /* constants                    */
  uchar recorded_charges;                /* From SS_AOC_RECORDED_CHARGES */
                                         /* constants                    */
  uchar completed;                       /* Set to OFF if additional     */
                                         /* recorded units are queued    */
  pad1                                   /* in a subsequent message      */
};

The following table lists the fields in the tAcuSSAocDInform structure (other than the header fields):

Field

Description

currency_id_size

Size of currency_id. Used only if type_of_charging is CURRENCY_UNITS.

currency_amount

This value plus multiplier indicates the currency amount. Used only if type_of_charging is CURRENCY_UNITS.

multiplier

This value plus currency_amount indicates the currency amount. From ACU_SS_AOC_MULTIPLIER constants. Used only if type_of_charging is CURRENCY_UNITS.

billing_id

From ACU_SS_AOC_BILLING_ID constants.

charge_association

Currently not used.

recorded_units

Used only if type_of_charging is CHARGING_UNITS.

currency_id[MAX_CURRENCY_SIZE]

Currency ID. Used only if type_of_charging is CURRENCY_UNITS.

type_of_charging

Step function (charge is incurred for the time unit, or part thereof) or continuous (charges are incurred evenly throughout). From SS_AOC_S_TYPE_OF_CHARGE constants.

recorded_charges

From SS_AOC_RECORDED_CHARGES constants.

completed

Set to OFF if additional recorded units are queued in a subsequent message.


Advice of charge - end of call (AOC-E)

If AOC-E is active, the aoc_type field in the acu_ss_aoc_inform_invoke structure is set to ACU_SS_AOC_TYPE_AOC_E_INFORM. The tAcuSSAocEInform data structure and substructures are used to carry Advice of Charge data.

The following listing shows the tAcuSSAocEInform structure:

typedef struct tAcuSSAocEInform
{
  struct op_byte_field currency_id_size;/* Used only if type_of_charging*/
                                        /* is CURRENCY_UNITS            */
  struct op_long_field currency_amount; /* Used only if type_of_charging*/
                                        /* is CURRENCY_UNITS            */
  struct op_byte_field multiplier;      /* Used only if type_of_charging*/
                                        /* is CURRENCY_UNITS            */
  struct op_byte_field billing_id;      /* From ACU_SS_AOC_BILLING_ID   */
                                        /* constants                    */
  struct acu_ss_association charge_association; /* Returns ID of charge */
                                        /* for AOC-E after call clearing*/
  tRecordedUnits       recorded_units;  /* Used only if type_of_charging*/
                                        /* is CHARGING_UNITS            */
  uchar currency_id[MAX_CURRENCY_SIZE]; /* Used only if type_of_charging*/
                                        /* is CURRENCY_UNITS            */
  uchar type_of_charging;               /* From SS_AOC_TYPE_OF_CHARGE...*/
                                        /* constants                    */
  uchar recorded_charges;               /* From SS_AOC_RECORDED_CHARGES */
                                        /* constants                    */
  uchar completed;                      /* Set to OFF if additional     */
                                        /* recorded units are queued    */
  pad1                                  /* in a subsequent message      */
};

The following table lists the fields in the tAcuSSAocEInform structure (other than the header fields):

Field

Description

currency_id_size

Size of currency_id. Used only if type_of_charging is CURRENCY_UNITS.

currency_amount

This value plus multiplier indicates the currency amount. Used only if type_of_charging is CURRENCY_UNITS.

multiplier

This value plus currency_amount indicates the currency amount. From ACU_SS_AOC_MULTIPLIER constants. Used only if type_of_charging is CURRENCY_UNITS.

billing_id

From ACU_SS_AOC_BILLING_ID constants.

charge_association

Currently not used.

recorded_units

Used only if type_of_charging is CHARGING_UNITS.

currency_id[MAX_CURRENCY_SIZE]

Currency ID. Used only if type_of_charging is CURRENCY_UNITS.

type_of_charging

Step function (charge is incurred for the time unit, or part thereof) or continuous (charges are incurred evenly throughout). From SS_AOC_S_TYPE_OF_CHARGE constants.

recorded_charges

From SS_AOC_RECORDED_CHARGES constants.

completed

Set to OFF if additional recorded units are queued in a subsequent message.


Transfer of charging information during the active state of a call

Transfer of charging information during the active state of a call

 

Transfer of charging information during the call clearing phase, clearing initiated

Transfer of charging information during the call clearing phase, clearing initiated by the calling user

 

Transfer of charging information during the call clearing phase, clearing initiated
by che called user

Transfer of charging information during the call clearing phase, clearing initiated by the called user

AOC and Explicit Call Transfer (ECT) services

The Advice of Charge service interacts with the Explicit Call Transfer service. This section describes how the services interact.

AOC-S and ECT

If AOC-S is active at the time the served user invokes the Explicit Call Transfer service, then AOC-S is stopped, and the application may get advice of charge prior to the clearing of the call.

AOC-D and ECT

If AOC-D is active at the time the served user invokes the Explicit Call Transfer service, then the application receives advice of charge information prior to the clearing of the call, and the service is stopped.

AOC-E and ECT

If the served user continues to be charged for a call after the call is transferred elsewhere, the served user can associate an identifier with the call, so AOC-E information for the call can be returned to the served user even though the served user is no longer involved in the call.

The identifier is specified in the charge_association field in the Explicit Call Transfer or data structure. When AOC-E information is returned at the end of the call, the information is presented to the application using the management SAPI (ACU_MGMT_SAPI) in the AOC_INFORM structure, using a dummy connection ID. The charge_association field in the AcuSSAocEInform data structure is filled in, enabling the application to associate the charging information to the specific invocation of the service.

If an identifier is not specified with the call, no AOC information is returned.

If AOC-E is activated for a call, and the Explicit Call Transfer service is called without a charge identifier included, then the AOC-E service is stopped, and the application receives AOC-E information for the portion of the call prior to the transfer.

AOC and call transfer

AOC and call transfer

AOC and call deflection services

The Advice of Charge service interacts with the Call Deflection service. This section describes how the services interact.

AOC-S, AOC-D, and call deflection

AOC-S and AOC-D services are not applicable to the user performing the deflection.

AOC-E and call deflection

If the served user continues to be charged for a call after the call is deflected elsewhere, the served user can associate an identifier with the call, so AOC-E information for the call can be returned to the served user even though the served user is no longer involved in the call.

The identifier is specified in the charge_association field in the Call Deflection data structure. When AOC-E information is returned at the end of the call, the information is presented to the application using the management SAPI (ACU_MGMT_SAPI) in the AOC_INFORM structure, using a dummy connection ID. The charge_association field in the AcuSSAocEInform data structure is filled in, enabling the application to associate the charging information to the specific invocation of the service.

If AOC-E is activated for a call, and the Call Deflection service is called without a charge identifier included, then the AOC-E service is stopped, and the application receives AOC-E information for the portion of the call prior to the deflection.