Help us improve your experience.

Let us know what you think.

Do you have time for a two-minute survey?

 

Configuring Scripts That Update Accounts (SRC CLI)

 

You can set up scripts to update balances in the accounts from which the usage of a service is charged and update accounts by assigning values to variables for the account balances.

Use the following statements to configure scripts that update accounts:

To configure scripts that update accounts:

  1. From configuration mode, access the statement used to configure scripts that update accounts. For example, to configure a script called DebtQuotaUsage in the SRC VTA group called vta1:

  2. Specify the script parameters.

    Enter a JavaScript program that updates a subscriber’s account. The script can refer to the name of any attributes in the event being processed. An account can be updated by assigning values to the following parameters:

    • balance_<accountName>—Values written to this parameter are put in the balance field of the account.

    • status_<accountName>—Values written to this parameter are put in the status field of the account.

    • lastUpdateTime_<accountName>—Values written to this parameter are put in the last_update_time field of the account.

      For example: