4D Payments SDK 2016 .NET Edition
4D Payments SDK 2016 .NET Edition
Questions / Feedback?

Authorize Method

Authorizes an FSA card for a Healthcare transaction.

Syntax

[VB.NET]
Public Sub Authorize()
[C#]
public void Authorize();

Remarks

This method sends an authorization request through Datawire to the FDMS transaction processor. The credit card is specified through the Card property . Whether the card is manually entered, track1 swiped, or track 2 swiped is specified by the EntryDataSource field.

An authorization blocks funds on the customer's credit card, but does not actually transfer funds. In order for funds to be transferred and the transaction completed, you must settle the transaction. To do this, you must pass an XML aggregate containing the results of the transaction to the Settlement component. For example:


  FDMSHealthCare1.URL = "https://staging1.datawire.net/sd/";
  FDMSHealthCare1.IndustryType = itRetail;    
  FDMSHealthCare1.DatawireId = "YOURDATAWIREID";
  FDMSHealthCare1.MerchantNumber = "000000925990";
  FDMSHealthCare1.MerchantTerminalNumber = "573138";
  FDMSHealthCare1.TPPID = "VNT001";
  FDMSHealthCare1.VisaIdentifier = "0B34567890123456789";
  FDMSHealthCare1.ClinicAmount = "";
  FDMSHealthCare1.DentalAmount = "";
  FDMSHealthCare1.VisionAmount = "";
  FDMSHealthCare1.PrescriptionAmount = "6000";
  FDMSHealthCare1.TotalMedicalAmount = "8000";
  FDMSHealthCare1.TransactionAmount = "20200" ;   
  FDMSHealthCare1.Card.MagneticStripe = "B4662060000000005^FDCS TEST CARD^120410123456789";
  FDMSHealthCare1.Card.EntryDataSource = edsTrack1;
  FDMSHealthCare1.TransactionNumber = 1;
  FDMSHealthCare1.Authorize();

  if (FDMSHealthCare1.ResponseCaptureFlag) {    
    FDMSSettle.DetailRecords.Add(new FDMSRecordType(FDMSHealthCare1.GetDetailAggregate()));
  }

Note that FSA cards may be only partially approved. If the card is authorized for less than the full amount, the ApprovalCode field will begin with "AL" instead of "AP", and the AuthorizedAmount will contain the amount that was actually removed from the card. The customer must then pay the remainder via another means. If the customer cannot pay the remainder or wishes to cancel the transaction, use the ReversePartialAuth method to reverse the authorization.

Important Note: You must ping your list of service provider URLs and update the URL property to the service provider with the shortest response time every 100 transactions, as well as when your application initially starts. This is not a normal ICMP ping - to determine the fastest transaction URL you must use the special Ping method inside the FDMSRegister component. (You may update your list of service provider URLs with the FDMSRegister component's ServiceDiscovery method).

 
 
Copyright (c) 2020 4D Payments Inc. - All rights reserved.
4D Payments SDK 2016 .NET Edition - Version 16.0 [Build 7311]