|
Uses
URL https://secure.paymentclearing.com/cgi-bin/rc/xmltrans.cgi Mime Type xmltrans.cgi is accessed with a HTTP POST and requires a CONTENT_TYPE header to be specified. Either 'application/x-www-form-urlencoded' or 'text/xml' must be used. If 'application/x-www-form-urlencoded' is sent then the HTTP body must contain valid form markup. See WW3 Form Spec for details. If 'text/xml' is used then the HTTP body should only contain the XML request. XML StructuresSaleRequest
<SaleRequest>
<!-- Only required if using Registered Customer. -->
<RegisteredCustomerData>
<CustCode>Cust ID here</CustCode>
<Pwd>password</Pwd>
</RegisteredCustomerData>
<!-- Required if using Non-Registered Customer -->
<CustomerData>
<Email>name@domain.com</Email>
<BillingAddress>
<Address1>100 This Street</Address1>
<FirstName>John</FirstName>
<LastName>Smith</LastName>
<City>Yourtown</City>
<State>NY</State>
<Zip>55555</Zip>
<Country>USA</Country>
<Phone>230-555-1212</Phone>
</BillingAddress>
<!-- Optional Shipping Address -->
<ShippingAddress>
<Address1>100 This Street</Address1>
<City>Thatcity</City>
<FirstName>John</FirstName>
<LastName>Smith</LastName>
<State>NY</State>
<Zip>55555</Zip>
<Country>USA</Country>
<Phone>231-555-1212</Phone>
</ShippingAddress>
<AccountInfo>
<!-- Include either credit card or check info. Not both. -->
<!-- For Credit card transaction. -->
<CardInfo>
<CCNum>5454545454545454</CCNum>
<CCMo>05</CCMo> <!-- CCMo must be two digits. -->
<CCYr>2002</CCYr> <!-- CCYr must be four digits. -->
<!-- CVV2 information is optional. Pass only if your Gateway account requires it. -->
<CVV2Number>123</CVV2Number>
<CVV2Illegible>1</CVV2Illegible> <!-- Submit only if CVV number is illegible. -->
</CardInfo>
<!-- For Check transactions. -->
<CheckInfo>
<ABA>124000054</ABA>
<Account>12345</Account>
<AccountType>business</AccountType> <!-- business or personal -->
<!-- Optional -->
<CheckNum>100</CheckNum>
<!-- Optional -->
<CheckMemo>Memo text here</CheckMemo>
</CheckInfo>
</AccountInfo>
</CustomerData>
<TransactionData>
<!-- AuthCode optional. (INDICATES FORCE TRANSACTION) -->
<AuthCode>12345</AuthCode>
<!-- Preauth optional. (INDICATES PREAUTH TRANSACTION) -->
<Preauth/>
<VendorId>gateway id here</VendorId>
<VendorPassword>gateway password</VendorPassword>
<HomePage>www.this.com</HomePage>
<!-- Optional -->
<RecurringData>
<RecurRecipe>test</RecurRecipe>
<RecurReps>5</RecurReps>
<!-- Optional (For Split Recurring) -->
<RecurTotal>100.00</RecurTotal>
<!-- Optional (For Split Recurring) -->
<RecurDesc>test2</RecurDesc>
<!-- Optional (For Split Recurring) -->
</RecurringData>
<!-- Optional. Text here will be included in transaction confirmation emails. -->
<EmailText> <!-- Up to 10 EmailTextItem elements allowed.-->
<EmailTextItem>line1<EmailTextItem>
<EmailTextItem>line2<EmailTextItem>
</EmailText>
<OrderItems>
<Item>
<Description>item1</Description>
<Cost>5</Cost>
<Qty>1</Qty>
</Item>
</OrderItems>
</TransactionData>
</SaleRequest>
SaleResponse The SaleResponse is essentially a duplicate of the information provided in the SaleRequest. Note that ALL fields are provided in the response even if they were not included in the request. Schema is shown here with demo data.
<SaleResponse>
<CustomerData>
<Email>name@domain.com</Email>
<BillingAddress>
<Address1>100 This Street</Address1>
<City>Yourtown</City>
<FirstName>John</FirstName>
<LastName>Smith</LastName>
<State>NY</State>
<Zip>55555</Zip>
<Country>USA</Country>
<Phone>230-555-1212</Phone>
</BillingAddress>
<ShippingAddress>
<Address1>100 This Street</Address1>
<Address2>Building 3</Address2>
<City>Thatcity</City>
<FirstName>John</FirstName>
<LastName>Smith</LastName>
<State>NY</State>
<Zip>55555</Zip>
<Country>USA</Country>
<Phone>231-555-1212</Phone>
</ShippingAddress>
<AccountInfo>
<!-- For Credit card transactions. -->
<CardInfo>
<CCLastFour>5454</CCLastFour>
<CCName>Mastercard</CCName>
</CardInfo>
<!-- For Check transactions. -->
<CheckInfo>
<AccountType>Business</AccountType>
<CheckNum>100</CheckNum>
<CheckMemo>Memo text here.</CheckMemo>
</CheckInfo>
</AccountInfo>
</CustomerData>
<TransactionData>
<Status>OK</Status> <!-- Will be one of: ERROR, FAIL, OK -->
<!-- ErrorCategory will be one of :
AVS_FAILURE - Transaction will be automatically voided.
CVV2_FAILURE - Transaction will be automatically voided.
INTERNAL_ERROR - Something unexpected happened.
PROCESSOR_ERROR - Something such as DECLINED, etc .
PROCESSOR_FAIL -
REQUEST_FORMAT - Request received has an invalid format.
REQUEST_VALIDATION - XML content is invalid.
-->
<ErrorCategory></ErrorCategory>
<!-- ErrorMessage could be anything. -->
<ErrorMessage></ErrorMessage>
<!-- Authorization code received from processing network. -->
<AuthCode>12345</AuthCode>
<!-- AVSResponse is actual AVS response received from processing network. -->
<AVSResponse>A</AVSResponse>
<!-- AVSResponseCategory will be one of :
address - Address Matched
address_postal - Address and postal patched
address_zip5 - Address and five digit zip matched
address_zip9 - Address and nine digit zip matched
address_ok_postal_format_error - Address matched, postal format error
global_non_participant - International with no AVS support
international_address_not_verified - International with no AVS support
no_match - No address or postal match
no_response - No response
not_allowed - Not allowed
postal - Postal match
postal_ok_address_format_error - Postal matched, address format error
service_not_supported - AVS service not supported for card
unavailable - AVS service unavailable.
zip5 - Five digit zip matched
zip9 - Nine digit zip matched
-->
<AVSResponseCategory>Address</AVSResponseCategory>
<!-- CVV2Response is actual CVV response received from the processing network. -->
<CVV2Response>M</CVV2Response>
<TimeStamp>20021003172303</TimeStamp>
<!-- TestMode indicates the test status of your gateway account. 0=off 1=on -->
<TestMode>0</TestMode>
<Total>100</Total>
<XID>10000</XID>
<RecurringData>
<RecurRecipe>test</RecurRecipe>
<RecurReps>5</RecurReps>
<RecurTotal>100</RecurTotal>
<RecurDesc>test2</RecurDesc>
</RecurringData>
</TransactionData>
</SaleResponse>
GatewayFailureResponse This response is returned when an invalid response structure or mime type is sent <?xml version="1.0" standalone="yes"?> <GatewayFailureResponse> <Status>FAILED</Status> <ErrorCategory>REQUEST_FORMAT</ErrorCategory> <ErrorMessage>Unexpected mime type: </ErrorMessage> </GatewayFailureResponse> |