CustomerAdd XML API Documentation (Last Modified: 7/12/2006 10:38:40 PM)

Basic Concepts
The CustomerAdd XML API provides a method to add a customer account to the system.
The base URL of this API is http://api.cisp.com/CustomerAdd.XML.asp.
 
Input Variables
Name Description
ClientID Client code identifying the client information to access
Password Customer password for accessing the customer support account management web utility
PaymentTypeID ID of the payment type to be used for service plans on the account
ACHAccountNumber Account number for ACH payment type
ACHAccountType Account type for ACH payment type
ACHBankAddress Bank street address for ACH payment type
ACHBankCity Bank city for ACH payment type
ACHBankName Name of bank for ACH payment type
ACHBankState Bank state for ACH payment type
ACHBankZip Bank zip (or postal) code for ACH payment type
ACHFullName Full name on the bank account for ACH payment type
ACHFullName2 Second full name on the bank account for ACH payment type
ACHRoutingNumber Routing number for the bank account for ACH payment type
CheckPONumber PO number for a check payment
CreditCardExpireMonth Expiration month (2-digit) for credit card payment
CreditCardExpireYear Expiration year (2-digit) for credit card payment
CreditCardNumber Number of the card for credit card payment
CreditCardZip Zip (or postal) code of the name on the card for credit card payment
FirstName First name of the customer
MiddleName Middle name (or initial) of the customer
LastName Last name of the customer
Company Company of the customer
Address Street address of the customer
City City of the customer
State State of the customer
Zip Zip (or postal) code of the customer
CountryID ID of the country of the customer
PhoneHome Home phone number of the customer
PhoneBusiness Business phone number of the customer
PhoneFax Fax number of the customer
ContactEmail Email address to be used for all communication to the customer
SendInvoice ID of the method for sending invoices to the customer
SendStatement ID of the method for sending statements to the customer
SendNews Should the system send news to the customer?
Name Min Max Type Required
ClientID 4 4 String True
Password 6 8 String True
PaymentTypeID N/A N/A Long True
ACHAccountNumber N/A N/A String If PaymentType is ACH
ACHAccountType N/A N/A String False
ACHBankAddress N/A N/A String False
ACHBankCity N/A N/A String False
ACHBankName N/A N/A String If PaymentType is ACH
ACHBankState N/A N/A String False
ACHBankZip N/A N/A String False
ACHFullName N/A N/A String If PaymentType is ACH
ACHFullName2 N/A N/A String False
ACHRoutingNumber N/A N/A String If PaymentType is ACH
CheckPONumber N/A N/A String False
CreditCardExpireMonth 1 2 Integer If Payment Type is Credit Card
CreditCardExpireYear 1 2 Integer If Payment Type is Credit Card
CreditCardNumber N/A N/A String If Payment Type is Credit Card
CreditCardZip N/A N/A String False
FirstName N/A N/A String True
MiddleName N/A N/A String False
LastName N/A N/A String True
Company N/A N/A String False
Address N/A N/A String True
City N/A N/A String True
State N/A N/A String True
Zip N/A N/A String True
CountryID 1 3 Long True
PhoneHome N/A N/A String If PhoneBusiness is not provided
PhoneBusiness N/A N/A String If PhoneHome is not provided
PhoneFax N/A N/A String False
ContactEmail N/A N/A String True
SendInvoice 1 1 Integer True
SendStatement 1 1 Integer True
SendNews 1 1 Bit False
 
Return Document
The return value is a standard XML document with ICOP as the root node.
Each section of the output variables listed below is a child node to the ICOP node. Each parameter within that section is an attribute to that section's node.
Customer Add Customer Output Variables
Name Description Type
ID ID of the customer Long
CONTACT_EMAIL Email address to be used for all communication to the customer String
PASSWORD Customer password for accessing the customer support account management web utility String
PAYMENT_TYPE_ID ID of the payment type to be used for service plans on the account Long
REG_NUMBER Unique registration number to identify the customer String
SEND_INVOICE ID of the method for sending invoices to the customer Integer
SEND_NEWS Should the system send news to the customer? Bit
SEND_STATEMENT ID of the method for sending statements to the customer Integer
Customer Add ACH Output Variables
Name Description Type
ACCOUNT_NUMBER Account number for ACH payment type String
BANK_ADDRESS Bank street address for ACH payment type String
BANK_CITY Bank city for ACH payment type String
BANK_NAME Name of bank for ACH payment type String
BANK_STATE Bank state for ACH payment type String
BANK_ZIP Bank zip (or postal) code for ACH payment type String
FULL_NAME Full name on the bank account for ACH payment type String
FULL_NAME_2 Second full name on the bank account for ACH payment type String
ROUTING_NUMBER Routing number for the bank account for ACH payment type String
Customer Add Check Output Variables
Name Description Type
PO_NUMBER PO number for a check payment type String
Customer Add Contact Output Variables
Name Description Type
ADDRESS Street address of the customer String
CITY City of the customer String
FIRST_NAME First name of the customer String
LAST_NAME Last name of the customer String
MIDDLE_NAME Middle name of the customer String
PHONE_BUSINESS Business phone number of the customer String
PHONE_FAX Fax number of the customer String
PHONE_HOME Home phone number of the customer String
STATE State of the customer String
ZIP Zip (or postal) code of the customer String
Customer Add Contact Country Output Variables
Name Description Type
ID ID of the country of the customer Long
LABEL Text label for the country String
Customer Add Credit Card Output Variables
Name Description Type
EXPIRE_MONTH Expiration month (2-digit) for credit card payment String
EXPIRE_YEAR Expiration year (2-digit) for credit card payment String
NUMBER Number of the card for credit card payment String
ZIP Zip (or postal) code of the name on the card for credit card payment String
 
Sample Output
<?xml version="1.0" ?>
<ICOP>
- <CUSTOMER ID="1" CONTACT_EMAIL="john@cisp.cc" PASSWORD="mysecret"
    PAYMENT_TYPE_ID="3" REG_NUMBER="1537959092" SEND_INVOICE="4" SEND_NEWS="0"
    SEND_STATEMENT="4">
  - <ACH ACCOUNT_NUMBER="" BANK_ADDRESS="" BANK_CITY="" BANK_NAME="" BANK_STATE=""
      BANK_ZIP="" FULL_NAME="" FULL_NAME_2="" ROUTING_NUMBER="" />
  - <CHECK PO_NUMBER="" />
  - <CONTACT ADDRESS="101 Test Dr" CITY="Springfield" FIRST_NAME="John"
      LAST_NAME="Doe" MIDDLE_NAME="G" PHONE_BUSINESS="" PHONE_FAX=""
      PHONE_HOME="(123)456-7890" STATE="OH" ZIP="12345">
    - <COUNTRY ID="1" LABEL="United States" />
    </CONTACT>
  - <CREDIT_CARD EXPIRE_MONTH="12" EXPIRE_YEAR="08" NUMBER="5424000000000015"
      ZIP="12345" />
  </CUSTOMER>
</ICOP>
 
Sample ASP Code
<%
Option Explicit
Dim objXML, objXSL
Dim strURL

' Build the URL for the call to the API
strURL = "http://api.cisp.cc/CustomerAdd.XML.asp" & _
	"?ClientID=DEMO" & _
	"&Password=mysecret" & _
	"&PaymentTypeID=3" & _
	"&CreditCardExpireMonth=12" & _
	"&CreditCardExpireYear=08" & _
	"&CreditCardNumber=5424000000000015" & _
	"&CreditCardZip=12345" & _
	"&FirstName=John" & _
	"&MiddleName=G" & _
	"&LastName=Doe" & _
	"&Address=101 Test Dr" & _
	"&City=Springfield" & _
	"&State=OH" & _
	"&Zip=12345" & _
	"&CountryID=1" & _
	"&PhoneHome=(123)456-7890" & _
	"&ContactEmail=john@doe.com" & _
	"&SendInvoice=4" & _
	"&SendStatement=4" & _
	"&SendNews=0"

' Create the MSXML DOMDocument object for the xml document output of the API
Set objXML = Server.CreateObject("MSXML2.DOMDocument")
objXML.async = False
objXML.setProperty "ServerHTTPRequest", True
objXML.load strURL

' Create the MSXML DOMDocument object for the xsl stylesheet to transform the xml
Set objXSL = Server.CreateObject("MSXML2.DOMDocument")
objXSL.async = False
objXSL.load Server.MapPath("CustomerAdd.xsl")

' Transform the xml with the xsl stylesheet and write the result HTML
Response.Write objXML.transformNode(objXSL)
%>