Click or drag to resize

LoyaltyClientSelectHomePartnerForCard Method

Return the default Partner Details from the submitted values or authenticated Member Token.

Remarks
  • If Card Number or UserSecurityAccount_RSN is not submitted, then the authenticated Member Token will be used by default
  • If the Card has not linked to a Program Membership, a descriptive FaultCode and Fault Descritpion will be returned
  • If the Card has not linked to a Security Account, a descriptive FaultCode and Fault Descritpion will be returned
Syntax
C#
public ResultOfDefaultPartners SelectHomePartnerForCard(
	ManagementGroupRequestOfDefaultPartnerSearch request
)

Parameters

request
Type: LoyaltyServiceManagementGroupRequestOfDefaultPartnerSearch

Return Value

Type: ResultOfDefaultPartners
Examples
C#
using (var svc = new LoyaltyService.LoyaltyClient())
{
  var request = new LoyaltyService.ManagementGroupRequestOfDefaultPartnerSearch();
  request.Token = "Token";//Required - Token returned from AccountService.ManagementGroupLogin
  request.ManagementGroup = "Management group";//Required - ManagementGroup supplied when calling AccountService.ManagementGroupLogin

  var search = new LoyaltyService.DefaultPartnerSearch();
  search.CardNumber = "21000005";//Required
  search.UserSecurityAccount_RSN = new Guid("693674c1-0bc6-4c7a-9db4-8c1125f377dc");;//Required - RSN of security account

  //add search to request
  request.Value = search;

  LoyaltyService.ResultOfDefaultPartners result = svc.SelectHomePartnerForCard(request);

  if (result.FaultCode == 0)
  {
    //Request succeeded
  }
  else
  {
    //Request failed
    throw new Exception(result.FaultDescription);
  }
}
See Also