developer:soap:methods:getbatchtransactions

Differences

This shows you the differences between two versions of the page.

Link to this comparison view

Both sides previous revision Previous revision
Next revision
Previous revision
developer:soap:methods:getbatchtransactions [2009/07/03 16:08]
epouchak
developer:soap:methods:getbatchtransactions [2009/09/08 12:43]
charlie
Line 1: Line 1:
-<embed ..:​contents/>​====== getBatchTransactions ======+<embed ..:​contents/>​
  
-Retrieve transactions in the batch specified by BatchNum,+====== getBatchTransactions ====== 
 + 
 +Retrieve transactions in the batch specified by BatchRefNum,
  
 ===== Description ===== ===== Description =====
Line 12: Line 14:
  
 [[..:​objects:​transactionObject]][] **getBatchTransactions** ( [[..:​objects:​ueSecurityToken]] Token, ​ [[..:​objects:​transactionObject]][] **getBatchTransactions** ( [[..:​objects:​ueSecurityToken]] Token, ​
-Integer ​BatchNum ​+Integer ​BatchRefNum ​
  
  
Line 19: Line 21:
 ^Type   ​^Name ​  ​^Description ​  ^ ^Type   ​^Name ​  ​^Description ​  ^
 |[[..:​objects:​ueSecurityToken]] |Token |Merchant security token: used to identify merchant and validate transaction.| |[[..:​objects:​ueSecurityToken]] |Token |Merchant security token: used to identify merchant and validate transaction.|
-|integer |BatchNum ​|A unique batch reference number assigned by the gateway. |+|integer |BatchRefNum ​|A unique batch reference number assigned by the gateway. |
  
  
Line 37: Line 39:
  
 try {  try { 
 +  //Set BatchRefNum to the Batch Reference Number of the batch you want 
 +  //to retrieve transactions from.  0 is always the current batch
 +  $BatchRefNum=0; ​
  
-  $refnum=$this->​runQuickSale();​  +  $Result=$client->​getBatchTransactions($token,​ $BatchRefNum);  ​
-  $BatchNum=0;​  +
- +
-  $res=$client->​getBatchTransactions($token,​ $BatchNum);  ​ +
-  print_r($res);​  +
-             +
  
  
Line 50: Line 50:
   die("​get Batch Transactions failed :" .$e->​getMessage()); ​   die("​get Batch Transactions failed :" .$e->​getMessage()); ​
  
-  ​+
  
 ?>  ?> 
 </​code>​ </​code>​
  
 +
 +==== Java ====
 +
 +This example uses the [[developer/​javalibrary|USAePay Java library]]. ​ For directions on how to install the library and create the token/​client objects, go to either the [[..:​howto:​javajaxrpc|Java JAX-RPC Howto]] or the [[..:​howto:​javajaxws|Java JAX-WS Howto]].
 +
 +<code java>
 +try {
 +  //Set BatchNum to the Batch Reference Number of the batch you want
 +  //to retrieve transactions from.  0 is always the current batch
 +  BigInteger BatchNum = new BigInteger("​0"​);​
 +  ​
 +  TransactionObjectArray ResultSet = new TransactionObjectArray();​
 +  ResultSet = client.getBatchTransactions(token,​ BatchNum);
 +} catch (Exception e) {
 +    System.out.println("​Soap Exception: " + e.getMessage());​
 +}
 +</​code>​
  
 ==== Visual Basic (.Net) ==== ==== Visual Basic (.Net) ====
Line 61: Line 78:
  
 <code vb> <code vb>
-Dim BatchNum ​As String+Dim BatchRefNum ​As String
  
-' Set BatchNum ​to 0 to get the current batch. ​  +' Set BatchRefNum ​to 0 to get the current batch. ​  
-' Otherwise use batch reference num  (can be found in  Transaction.Details.BatchNum+' Otherwise use batch reference num  (can be found in  Transaction.Details.BatchRefNum
-BatchNum ​= "​0"​+BatchRefNum ​= "​0"​
  
-Dim transactions() As usaepay.TransactionObject = client.getBatchTransactions(token, ​BatchNum)+Dim transactions() As usaepay.TransactionObject = client.getBatchTransactions(token, ​BatchRefNum)
  
 MsgBox("​Found " & transactions.Length & " transactions in current batch"​) MsgBox("​Found " & transactions.Length & " transactions in current batch"​)
Line 93: Line 110:
 <​SourceKey xsi:​type="​xsd:​string">​HB4P7C4K2w2ZCQQQXRqrxDj6agrS2NIT</​SourceKey> ​ <​SourceKey xsi:​type="​xsd:​string">​HB4P7C4K2w2ZCQQQXRqrxDj6agrS2NIT</​SourceKey> ​
 </​Token> ​ </​Token> ​
-<BatchNum ​xsi:​type="​xsd:​integer">​0</​BatchNum+<BatchRefNum ​xsi:​type="​xsd:​integer">​0</​BatchRefNum
 </​ns1:​getBatchTransactions> ​ </​ns1:​getBatchTransactions> ​
 </​SOAP-ENV:​Body> ​ </​SOAP-ENV:​Body> ​
 </​SOAP-ENV:​Envelope> ​ </​SOAP-ENV:​Envelope> ​
 </​code>​ </​code>​
 +
 +
 +===== Change History =====
 +
 +^Version ^Change ^
 +|1.2 | Renamed BatchNum Parameter to BatchRefNum |
 +|[[developer:​soap-1.1:​methods:​getbatchtransactions|1.1]] | Soap 1.1 Release |
 +
developer/soap/methods/getbatchtransactions.txt · Last modified: 2009/09/08 12:43 by charlie

Page Tools