Click or drag to resize

PointOfSaleClientValidateInStoreCard Method

Returns the Card Status for the submitted Card Number and Access Code.

Access Code may be configured to be an optional parameter.

Syntax
C#
public ResultOfstring ValidateInStoreCard(
	RequestOfValidateInstoreCard request
)

Parameters

request
Type: PointOfSaleServiceRequestOfValidateInstoreCard

Return Value

Type: ResultOfstring
Examples
C#
using (var svc = new PointOfSaleService.PointOfSaleClient())
{
  var request = new PointOfSaleService.RequestOfValidateInstoreCard();
  request.Token = "Token";//Required - Token returned from PointOfSaleService.Authenticate

  var validateInstoreCard = new PointOfSaleService.ValidateInstoreCard(); //Required
  validateInstoreCard.CardNumber = "Card number"; //Required
  validateInstoreCard.AccessCode = "Access code"; //Required - May be optional depending on configuration

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

  PointOfSaleService.ResultOfstring result = svc.ValidateInStoreCard(request);

  if (result.FaultCode == 0)
  {
    //Request succeeded
    //result.Value contains the card status ('ACTIVE', 'INACTIVE', 'CLOSED' or 'PENDINGACTIVATION')
  }
  else
  {
    //Request failed
    throw new Exception(result.FaultDescription);
  }
}
See Also