developer:soap:methods:deletemerchant

Differences

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

Link to this comparison view

Both sides previous revision Previous revision
Last revision Both sides next revision
developer:soap:methods:deletemerchant [2008/02/13 08:36]
nell
developer:soap:methods:deletemerchant [2009/01/19 14:46]
hmcgowan
Line 34: Line 34:
  
 ==== PHP ==== ==== PHP ====
 +
 +For directions on how to set up the WSDL link, create "​$token"​ and "​$client",​ go to [[developer:​soap:​howto:​php|PHP Soap How-to]].
  
 <code php> <code php>
 <?​php ​ <?​php ​
- 
-// for directions on how to set up the  ​ 
-// WSDL link and create "​$restoken"​ and "​$client," ​ 
-// see: http://​usaepay.com/​developer/​howto/​php. ​ 
  
 try {  try { 
  
-   $MerchantID=2;​  +  ​$MerchantID=2;​  
-   ​$Reason='​Testing Soap API'; ​    +  $Reason='​Testing Soap API'; ​    
  
-   $res=$client->​deleteMerchant($restoken,​$MerchantID,​$Reason);​  +  ​$res=$client->​deleteMerchant($restoken,​$MerchantID,​$Reason);​  
-          print_r($res); ​    +  print_r($res); ​    
  
-   $this->​assertEquals($res,​true); ​+  ​$this->​assertEquals($res,​true); ​
  
-   $this->​assertEquals($res->​Zip,​ '​12311'​); ​+  ​$this->​assertEquals($res->​Zip,​ '​12311'​); ​
  
-} catch (SoapFault $e) {  + 
-     ​echo $client->​__getLastRequest();​  + 
-     ​echo $client->​__getLastResponse();​  +catch (SoapFault $e) {  
-     ​die("​deleteMerchant failed: " .$e->​getMessage()); ​+  echo $client->​__getLastRequest();​  
 +  echo $client->​__getLastResponse();​  
 +  die("​deleteMerchant failed: " .$e->​getMessage()); ​
  
  
 ?>  ?> 
 </​code>​ </​code>​
- 
-  
-  
-  
developer/soap/methods/deletemerchant.txt · Last modified: 2009/07/06 10:57 by epouchak

Page Tools