IDTech iOS Framework Guide  1.1.088
API reference for UniPay
UniPay Main Transaction Commands

The methods below are provided as a reference to the main commands needed to execute an EMV transaction or perform a swipe.

EMV Methods

Start EMV Transaction
IDTechEMV::startEMVTransaction:timeout:transactionType:additionalTags:()

Begins an amount authorization request with the ICC. Returns authorization decision (approved, denied, or go online) in delegate method.


Complete Online EMV Transaction
IDTechEMV::completeOnlineEMVTransaction:resultCode:issuerAuthenticationData:issuerScripts:()

After receiving a host response, pass the result code as a string ("00"). The tags will be returned in the emvTransactionData delegate protocol.

If there was a communication error with host, you must still finish the EMV transaction by passing "EMV_COMPLETION_RESULT_UNABLE_TO_GO_ONLINE".

typedef enum{
EMV_COMPLETION_RESULT_ACCEPTED = 0X00,
EMV_COMPLETION_RESULT_UNABLE_TO_GO_ONLINE = 0X01,
EMV_COMPLETION_RESULT_TECHNICAL_ISSUE = 0X02,
EMV_COMPLETION_RESULT_DECLINED = 0X03,
EMV_COMPLETION_RESULT_ISSUER_REFERAL = 0X04
} EMV_COMPLETION_RESULT;

Terminal Configuration
IDTechEMV::retrieveTerminalData()
IDTechEMV::setTerminalData:()

Methods for terminal configuration. When setting the terminal data, you populate and pass and UniPay_TerminalData structure.


AID Management
IDTechEMV::retrieveApplicationData:()
IDTechEMV::removeApplicationData:()
IDTechEMV::setApplicationData:()
IDTechEMV::retrieveAIDList()

Methods for AID management. When setting the AID, you populate and pass UniPay_ApplicationID. When retrieving the AID list, the list of AID Names/length can be retrieved from the populated NSArray


Kernel Version
IDTechEMV::getEMVKernelVersion()

Method to retrieve kernel version.


APDU Communication
icc_exchangeAPDU:encrypted:response: (IDT_UniPay)

Allows the direct sending of APDU packets to ICC

MSR

Encryption Type
msr_setSwipeEncryption: (IDT_UniPay) msr_getSwipeEncryption: (IDT_UniPay)

Sets and gets the encrypted MSR Data Output Format.

Request Swipe
msr_startMSRSwipe: (IDT_UniPay)

Enables MSR to receive Swipe. Results are returned as IDTMSRData in swipeMSRData

- (void) swipeMSRData:(IDTMSRData*)cardData;
Cancel Swipe
msr_cancelMSRSwipe (IDT_UniPay)

Disables the MSR from receiving swipes.