Run a check credit transaction.
This method uses ACH to sends funds to a customer, employee, vendor, etc. It can be used to “refund” a sale or make a payment to someone (ie payroll). This transaction type is “stand alone” and does not pull the account and routing number from a previous sale. You must provide the Routing and Account properties in the CheckData object. If you want to use the account data from a prior transaction by referencing the RefNum, use the refundTransaction or runQuickCredit methods.
This feature, sometimes referred as “Reverse ACH”, “Check Credit” or “Disbursement”, is not available with all check processors. For those processors that do support it, merchants must request that it is enabled for their account. Contact your merchant service provider for further information.
If this method is used to reverse or refund an electronic check transaction, please be aware that both the original transaction and the refund will appear as separate transactions on the customer's bank account statement. To reverse a sale without creating a new transaction, you must use the voidTransaction method. Please see the description of the voidTransaction method for more details on how to determine which of these methods is most appropriate.
TransactionResponse runCheckCredit ( ueSecurityToken Token, TransactionRequestObject Params )
Type |
Name |
Description |
Token |
Merchant security token: used to identify merchant and validate transaction. |
|
Params |
Request transaction details from all fields of the transaction form, including reference number, transaction amount, customer ID, currency, authorization code, and any other information entered at the time of the transaction. |
Returns a TransactionResponse object containing the results of the transaction and all relevant data. |
<?php
try {
$Request=array(
'AccountHolder' => 'Tester Jones',
'Details' => array(
'Description' => 'Example Transaction',
'Amount' => '4.99',
'Invoice' => '44539'
),
'CheckData' => array(
'CheckNumber' => '1234',
'Routing' => '123456789',
'Account' => '11111111',
'AccountType' => 'Savings',
'DriversLicense' => '34521343',
'DriversLicenseState' => 'CA',
'RecordType' => 'PPD'
)
);
$res=$client->runCheckCredit($token, $Request);
}
catch (SoapFault $e) {
echo $client->__getLastRequest();
echo $client->__getLastResponse();
die("runCheckCredit failed :" .$e->getMessage());
}
?>
try {
TransactionRequestObject params = new TransactionRequestObject();
//set account holder name
params.setAccountHolder("Test Joe");
// populate transaction details
TransactionDetail details = new TransactionDetail();
details.setAmount(22.34);
details.setDescription("My Test Sale");
details.setInvoice("119891");
params.setDetails(details);
// populate credit card data
CheckData checkdata = new CheckData();
checkdata.setRouting("123123123");
checkdata.setAccount("321321");
params.setCheckData(checkdata);
// Create request object
RunCheckCredit request = new RunCheckCredit();
request.setToken(token);
request.setParams(params);
// Create response object
TransactionResponse response;
// run credit
response = client.runCheckCredit(token, params);
System.out.println("Response: " + response.getResult() + " RefNum: " + response.getRefNum());
} catch (Exception e) {
System.out.println("Soap Exception: " + e.getMessage());
}
Dim client As eBizCharge.eBizChargeService = New eBizCharge.eBizChargeService
Dim token As eBizCharge.ueSecurityToken
token = Me.CreateToken("714SSUxv1uohng2XkMJ7kLpETsu58G66", "1234")
Dim transaction As eBizCharge.TransactionRequestObject = New eBizCharge.TransactionRequestObject
transaction.CheckData = New eBizCharge.CheckData
transaction.CheckData.Account = "1112223333"
transaction.CheckData.Routing = "123456789"
transaction.CheckData.DriversLicense = "D5555555"
transaction.CheckData.DriversLicenseState = "CA"
transaction.Details = New eBizCharge.TransactionDetail
transaction.Details.Amount = "1.00"
transaction.Details.AmountSpecified = True
transaction.Details.Invoice = "55555"
transaction.Details.Description = "Test Check Sale"
transaction.AccountHolder = "Test Guy"
Dim response As eBizCharge.TransactionResponse
response = client.runCheckCredit(token, transaction)
If response.ResultCode = "A" Then
MsgBox("Transaction Approved, Reference Number: " & response.RefNum)
ElseIf response.ResultCode = "D" Then
MsgBox("Transaction Declined, Reason: " & response.Error)
Else
MsgBox("Transaction Error, Reason: " & response.Error)
End If
eBizCharge.TransactionRequestObject tran = new eBizCharge.TransactionRequestObject();
tran.Details = new eBizCharge.TransactionDetail();
tran.Details.Amount = 1.00;
tran.Details.AmountSpecified = true;
tran.Details.Invoice = "1234";
tran.Details.Description = "Sample Check Credit";
tran.CheckData = new eBizCharge.CheckData();
tran.CheckData.Account = "1112223333";
tran.CheckData.Routing = "123456789";
tran.CheckData.DriversLicense = "D5555555";
tran.CheckData.DriversLicenseState = "CA";
tran.AccountHolder = "Test Guy";
eBizCharge.TransactionResponse response = new eBizCharge.TransactionResponse();
try
{
response = client.runCheckCredit(token, tran);
if (response.ResultCode == "A")
{
MessageBox.Show(string.Concat("Transaction Approved, RefNum: ",
response.RefNum));
}
else
{
MessageBox.Show(string.Concat("Transaction Failed: ",
response.Error));
}
}
catch (Exception err)
{
MessageBox.Show(err.Message);
}
<?xml version="1.0" encoding="UTF-8"?>
<SOAP-ENV:Envelope xmlns:SOAP-ENV="http://schemas.xmlsoap.org/soap/envelope/" xmlns:ns1="urn:eBizCharge"
xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xmlns:SOAP-ENC="http://schemas.xmlsoap.org/soap/encoding/"
SOAP-ENV:encodingStyle="http://schemas.xmlsoap.org/soap/encoding/">
<SOAP-ENV:Body>
<ns1:runCheckCredit>
<Token xsi:type="ns1:ueSecurityToken">
<ClientIP xsi:type="xsd:string">192.168.0.1</ClientIP>
<PinHash xsi:type="ns1:ueHash">
<HashValue xsi:type="xsd:string">11ac55b0a0b59f8f028dbf85bc32266fa973dd0e</HashValue>
<Seed xsi:type="xsd:string">12678150211876663375</Seed>
<Type xsi:type="xsd:string">sha1</Type>
</PinHash>
<SourceKey xsi:type="xsd:string">HB4P7C4K2w2ZCQQQXRqrxDj6agrS2NIT</SourceKey>
</Token>
<Params xsi:type="ns1:TransactionRequestObject">
<AccountHolder xsi:type="xsd:string">Tester Jones 111</AccountHolder>
<CheckData xsi:type="ns1:CheckData">
<Account xsi:type="xsd:string">11111111</Account>
<AccountType xsi:type="xsd:string">Savings</AccountType>
<CheckNumber xsi:type="xsd:integer">1234</CheckNumber>
<DriversLicense xsi:type="xsd:string">34521343</DriversLicense>
<DriversLicenseState xsi:type="xsd:string">CA</DriversLicenseState>
<RecordType xsi:type="xsd:string">PPD</RecordType>
<Routing xsi:type="xsd:string">123456789</Routing>
</CheckData>
<Details xsi:type="ns1:TransactionDetail">
<Amount xsi:type="xsd:double">4.99</Amount>
<Description xsi:type="xsd:string">Example Credit</Description>
<Invoice xsi:type="xsd:string">44539</Invoice>
</Details>
</Params>
</ns1:runCheckCredit>
</SOAP-ENV:Body>
</SOAP-ENV:Envelope>