Skip to main content

Update reseller information


Use this method to update the details for an existing reseller entity in the Avangate platform.

Note: Updating the details of a reseller does not impact the reseller information already attached to existing partner orders. Let's assume that you added Reseller 1 to Order 1, and then update Reseller 1 changing the company name. Reseller 1 for Order 1 will continue to feature the old Reseller 1 information. To swap it for the new details, add the reseller to the order again using setOrderReseller.


This method requires you to set a specific partner using setPartner.


Parameter Type/Description
sessionID Required (string)
  Session identifier, which is the output of the Login method. An exception will be thrown if the values are incorrect.
Reseller Required (object)


Parameter Type/Description
Result Boolean



require('PATH_TO_AUTH'); // Authentication example:
require('PATH_TO_setPartner'); // setPartner example:

$Reseller = new stdClass(); // Reseller details that will be updated
$Reseller ->ResellerCode = 'YOUR_RESELLER_CODE'; // Reseller code identifying the reseller whose details are updated. Must belong to an existing reseller.
$Reseller->Company = 'NewCompanyName';
$Reseller->FirstName = ' NewFirstName';
$Reseller->LastName = 'NewLastName';
$Reseller->Email = '';
$Reseller->Phone = '123333344';
$Reseller->Fax = '12234567';
$Reseller->Country = 'US';
$Reseller->State = 'California';
$Reseller->City = 'LA';
$Reseller->Address = 'Address';
$Reseller->PostalCode = '90210';

try {
    $UpdatedReseller= $client->updateReseller($sessionID, $Reseller);
} catch (SoapFault $e) {
    Echo "UpdatedReseller: " . $e->getMessage();
var_dump ("UpdatedReseller ", $UpdatedReseller);

//If the reseller is attached to an existing order you need to reassign the updated reseller details to the order, as the info won't be refreshed automatically.
try {
    $Reseller= $client->getOrderReseller ($sessionID, $RefNo);
} catch (SoapFault $e) {
    Echo "Reseller: " . $e->getMessage();
var_dump ("Reseller ", $Reseller);

$ResellerCodeNew = $Reseller->ResellerCode;
try {
    $AddedReseller= $client->setOrderReseller ($sessionID, $RefNo, $ResellerCodeNew);
} catch (SoapFault $e) {
    Echo "orderReseller: " . $e->getMessage();
var_dump ("orderReseller ", $AddedReseller);