enter_service.cgi

Used to create or modify a Service or Package record.

Usage

/usr/local/billmax/cgi-bin/enter_service.cgi

Environment

All data is passed via environment variables of the form FORM_variablename with the following exceptions:
  • Dates are passed as FORM_variablename_year, FORM_variablename_month and FORM_variablename_day. A four digit year is required. Two digits for month and day respectively are required.
  • Times are passed as FORM_variablename_hour, FORM_variablename_minute and FORM_variablename_second. Two digits are required for each.
Name Type Description Required
srchnumber Integer If non zero, the number of an existing Service. Yes
number Integer The number to use for the Service. Recommended to use 0 for a new Service. Yes
override Integer Used to change a Service number. Use of this variable is not recommended.
0
Non-zero srchnumber must equal non-zero number.
1
Non-zero srchnumber may not equal non-zero number. If srchnumber does not equal number, the Service number field will change to number from srchnumber.
 
mkemail Integer Used to set the email field on an Account and User if the emails fields are blank.
0
Do not set either the Account or User email fields.
1
If either the Account or User field is blank, the email field will be set using the service.d01 field. If the field value does not contain the "@" character, then "@" and the Virtual Company Default Domain value will be concatenated to the field value when setting the email.
 
refdeposit Integer Deprecated  
user Integer Number for user table representing User to which the Service belongs Yes if a new Service.
state Integer Status of the Service.
0
Open
1
Closed
2
Suspended
3
Wait for Payment
5
Prospective
Yes if a new Service.
startdate Date   Yes if a new Service
enddate Date    
servdef Integer

Number of the Service or Package Definition of the underlying Product of the Service or Package.

Yes if a new Service
package Integer Number of the Package to which the Service is associated.  
service Integer Number of the Service to which this Service is associated. Only specify if this Service is a Service Fee  
free Integer Usage is not recommended. If a Service is marked Free, no billing activity is recorded. A better method is to give a 100% discount.
0
Service is not free.
1
Service is free.
 
taxable Integer Used in conjunction with the User Tax Region to assess taxes.
-1
Tax Not Applicable
0
Tax Exempt for all taxes
1
Taxable
Yes if a new Service.
wsetup Integer
0
Assess the Setup amount immediately
1
Do not assess the Setup amount
2
Assess the Setup amount when the Service is opened for the first time.
 
descr String Description. May be displayed on Invoice.  
d01 String Primary identifier for a Service.  
copypw Integer If non-zero, the number of a Service from which to copy the password and plain text password fields to the current Service.  
d02 String A value that is encrypted when stored. Typically used for passwords.  
d03 String    
d04 String    
d05 String    
d06 String    
d07 String    
d08 String    
d09 String    
d10 String    
invdate Date Next Billing Date for a Service. Yes if a new Service.
nextusagedate Date Next Usage Billing Date for a Service. Yes if a new Service.
pop Integer

Point of Presence

0 or a value from the popregions List.
 
iprice Money First Price  
iduration Integer First Duration. A value from the durations List.  
icnt Integer Number of times to assess First Price. Must be greater that 0. "1" is suitable for a single recurring price.  
price Money Second Price  
duration Integer Second Duration. A value from the durations List.  
cnt Integer Number of times to assess Second Price. If 0, Second Price and Third Price not used.  
lprice Money Third Price  
lduration Integer Third Duration. A value from the durations List.  
lcnt Integer Number of times to assess Third Price. If 0, Third Price not used.  
setup Money Setup amount  
setup_taxable Integer Used in conjunction with the User Tax Region to assess taxes.
-1
Tax Not Applicable
0
Tax Exempt for all taxes
1
Taxable
 
ponumber String Purchase Order Number  
ou_notice Float Used for metered billing.  
ou_susp Float Used for metered billing.  
ouprime_notice Float Used for metered billing.  
ouprime_susp Float Used for metered billing.  
refaccount Integer The number of an existing referring Account.  
misc01 Integer    
misc02 Integer    
misc03 Integer    
misc04 Integer    
misc05 Integer    
misc06 String    
misc07 String    
misc08 String    
misc09 String    
misc10 String    
misc11 Date    
misc12 Date    
misc13 Date    
misc14 Date    
misc15 Date    
misc16 Time    
misc17 Time    
misc18 Time    
misc19 Time    
misc20 Time    
generation Time stamp
Blank
Used for new Account
YYYY-MM-DD HH:MM:SS
The time stamp of the existing Account record.
Yes
reason Integer The reason an Service is not open. 0 or a value from the reasons List.  
wdeposit Integer
0
Assess the Deposit amount immediately
1
Do not assess the Deposit amount
2
Assess the Deposit amount when the Service is opened for the first time.
 
quantity Float

Quantity to bill.

 
quantityfree Float Portion of Quantity that is not subject to billing.  
cyclept Integer Point in a billing cycle. Used for cyclical billing.  
taxrule Integer -1 or a number reference a Tax Rule from the taxrule table.  
salesrep Integer Deprecated.  
datetoreopen Date If a Service is not Open, the date in the future to reopen the Service automatically.  
flags String Comma separate list of values, each value a power of 2.
1
Issue Sales Returns for Services/Packages billed in the future when Closing the Service.
4
Issue Deposit Returns when Closing the Service/Package.
8
Reopen Services of Packages that where Suspended or Closed when the Package/ was Suspended or Closed.
16
Issue Sales Returns for period billed but Account was Suspended or Closed.
64
Bill a following full term if the first billing is prorated.
256
Create a Package, not a Service.
1024
Display zero priced usage sales on Invoices
2048
Ignore Discounts
4096
Automatically issue Store Credits against recurring Sales
8192
Automatically issue Store Credit against usage Sales
131072
Bill one full term. Used when billing in Prospective State.
524288
One term was billed.
 
enddatereason Integer Reason that the End Date has been set.
4
The End Date was set because the Service is closing. Normal Suspend then Close will take place.
8
The End Date was set at the customer's request. The Service will be Suspended indefinitely until further action is taken.
 
executehook Integer
0
Do not execute the Service Hook program.
1
Execute the Service Hook program.
 
importid String If imported from another billing system, the key in the old system for the Service  
pctdiscount Decimal Percent discount that all non-Usage Sales to the Account will get. Implemented as a Store Credit for each Sale. Supply "2.5" for a 2.5 percent discount.  
pctdiscountexpdate Date Date that the discount expires.  
usagepctdiscount Decimal Percent discount that all Usage Sales to the Account will get. Implemented as a Store Credit for each Sale.  
usagepctdiscountexpdate Date Date that the Usage discount expires.  
discountamount Money A fixed amount for automatically generating a Store Credit.  
cardid String Used for Prepaid Services.  
pin String Used for Prepaid Services  
vcarddef Integer Used for Prepaid Services  
contractenddate Date Date representing the date the Contract for the Service expires.  
locationuser Integer Number for user table representing alternative Location for the Service from User.  
salesagent String Comma separated numbers representing Authorized Users for whom should included in commission reports for this Service  
etfee Money Early termination fee.  
dobilling Integer
0
Do not billing the Service immediately.
1
Bill the Service immediately. This is the default.