Reference for the individual classes in the MagTek Universal SDK — the data objects used to configure commands and read structured results back from the device. Entries are listed alphabetically across two pages, Classes A–I and Classes N–Z.
Reference Section
Information Available
Alphabetical reference for the SDK's data and result classes (Classes A–I).
Alphabetical reference for the SDK's data and result classes (Classes N–Z).
These constructors initialize an NFCData object. Use NFCDataBuilder.GetNFCData with the data byte array from the NFCData event to return an NFCData.
NFCData NFCDataBuilder.GetNFCData(deviceType, byte[] dataBytes);
new NFCData(byte[] Data, boolean Encrypted);
new NFCData(
byte[] Data,
boolean Encrypted,
byte EncryptionType,
byte[] KSN
);Data()
Returns the data payload.
Encrypted()
Return Value:
Returns an instance of NFCData.
These constructors initialize an NFCRAPDUData object. Use NFCDataBuilder.GetNFCRAPDUData with data byte array from the NFCRAPDUResponse event to return an NFCRAPDUData.
Return Value:
Returns an instance of NFCRAPDUData.
This class assist in parsing NFCEvent data.
These constructors initialize a PersonalInfoEntry object.
Call startPersonalInfoEntry().
At OnEvent():TouchscreenPersonalInfoEntry, build the object.
Return Value:
Returns an instance of PersonalInfoEntry.
Returns the encryption status. false = data is not encrypted true = data is encrypted
EncryptionType()
Returns the encryption type.
KSN()
Returns the Key Serial Number.
NFCRAPDUData NFCRAPDU(
byte[] response,
byte[] data,
boolean encrypted,
);
NFCRAPDUData NFCRAPDU(
byte[] response,
byte[] data,
bool encrypted,
byte encryptionType,
byte[] ksn
);
NFCRAPDUData NFCDataBuilder.GetNFCRAPDUData(
DeviceType deviceType,
byte[] dataBytes,
);response
Response data.
data
The data payload.
encrypted
GetDetail(string data)
String
Returns a string containing NFC detail.
GetEventValue(string data)
NFCEvent
NFC_MIFARE_ULTRALIGHT
String
"nfc_mifare_ultralight"
MIFARE_CLASSIC_1K
PersonalInfoEntry PersonalInfoEntryBuilder.GetPersonalInfoEntry(
DeviceType deviceType,
byte[] dataBytes);
new PersonalInfoEntry(
byte[] data,
CaptureType dataType,
bool encrypted,
);
new PersonalInfoEntry(
byte[] data,
CaptureType dataType,
bool encrypted,
byte encryptionType,
byte[] ksn
);deviceType
Type of device.
dataBytes
Data to pass in after set from OnEvent().
data()
Encryption status. false = data is not encrypted true = data is encrypted
encryptionType
The encryption type.
ksn
The Key Serial Number.
deviceType
Device type.
dataBytes
Data bytes from the NFCAPDUResponse event.
Returns the NFCEvent enumeration.
GetString(NFCEvent value)
String
Returns a string representation of NFCEvent enumeration.
String
"mifare_classic_1k"
MIFARE_CLASSIC_4K
String
"mifare_classic_4k"
MIFARE_DESFIRE_LIGHT
String
“mifare_desfire_light”
MIFARE_MINI
String
"mifare_mini"
MIFARE_PLUS_EV1
String
"mifare_plus_ev1"
MIFARE_PLUS_EV2
String
"mifare_plus_ev2"
MIFARE_PLUS_SE
String
"mifare_plus_se"
MIFARE_PLUS_X
String
"mifare_plus_x"
MIFARE_DESFIRE_EV1
String
"mifare_desfire_ev1"
MIFARE_DESFIRE_EV2
String
"mifare_desfire_ev2"
MIFARE_DESFIRE_EV3
String
"mifare_desfire_ev3"
MDL
String
"mdl"
TAG_REMOVED
String
"tag_removed"
FAILED
String
"failed"
IO_FAILED
String
"io_failed"
AUTHENTICATION_FAILED
String
"authentication_failed"
Returns the data payload.
dataType()
Returns the capture type.
encrypted()
Returns the encryption status. false = data is not encrypted true = data is encrypted
encryptionType()
Returns the encryption type.
ksn()
Returns the Key Serial Number.
These classes are equipped with helper classes named Builders. Builders can parse the raw data byte array of an OnEvent() into a format required by a builder’s class.
For the complete documentation index, see llms.txt. This page is also available as .
These constructors initialize a BarCodeData object. Use BarCodeDataBuilder.GetBarCodeData with data from the BarCodeData event to return a BarcodeData.
BarCodeData BarCodeDataBuilder.GetBarCodeData(
DeviceType deviceType,
byte[] dataBytes
);
new BarCodeData(byte[] Data, boolean Encrypted);
new BarCodeData(
byte[] Data,
boolean Encrypted,
byte EncryptionType,
byte[] KSN
);Return Value: Returns an instance of BarCodeData.
CertificateInfo is used for the connection to a device requiring client credentials. See the following for details on installing a certificate chain: D998200550 DynaFlex II PED Using Wireless LAN Guide.
This constructor initialize a CertificateInfo object. Once created, it is to be passed to CoreAPI.createDevice().
Return Value: Returns an instance of Certificate Info. Example of using CertificateInfo.
This class returns the connection state of the device when supplied the data object of the OnEvent() ConnectionState event.
Return Value: Returns an instance of ConnectionStateBuilder.
DirectoryEntry is similar to an InputRequest for Application during a transaction. Other fields of information are included besides Application Label. During a transaction, the device selects the PPSE. The directory entries are the PPSE response starting from the BF0C tag. The number of directory entries correspond to the number of applications on the card.
These constructors initialize a DirectoryEntry object.
Return Value: Returns an instance of DirectoryEntry.
This supplies a directory entry list for application selection after a card has been presented to the device during a transaction. To be implemented, Application Selection Behavior property 1.2.1.1.1.2 must be set to 0x03 – Enhanced Prompt Cardholder.
The data byte array from the EnhancedInputRequest event is parsed and returned as an enhanced application selection list (directory entry). This list is the PPSE response starting from tag BF0C. EnhancedInputRequest class extends InputRequest.
IData is used for the payload of events and passing data to functions. When assigning the member StringValue, the member ByteArray is automatically assigned. Same is true vice versa. In this way either a string or an array can be accessed without need of data conversion.
Use the BaseData() function to assign an instance of IData.
Example of using IData.
This is used for displaying messages prompted by the card during a transaction. The data byte array from the InputRequest event is parsed and returned as an application selection list.
Return Value: Returns an instance of InputRequest.
This is the interface used as the parameter for startTransaction(). For an example, see the sample code in IDevice Walk Through.
Data()
Returns the data payload.
Encrypted()
Returns the encryption status. false = data is not encrypted true = data is encrypted
EncryptionType()
Returns the encryption type.
KSN()
Returns the Key Serial Number.
new CertificateInfo(
String format,
byte[] data,
String password
);format getFormat()
String
Certificate data format. “PKCS12” – for .p12 file. “PFX” – for .pfx file.
data getData()
byte[]
String ConnectionStateBuilder.GetString(ConnectionState value);
ConnectionState ConnectionStateBuilder.GetValue(string data);CONNECTED
Returns string of connected.
CONNECTING
Returns string of connecting.
DISCONNECTED
new DirectoryEntry();
new DirectoryEntry(
String Aid,
String Label,
byte Priority,
byte[] ProprietaryData,
byte KernelIdentifier,
byte[] IssuerIN,
byte[] IssuerINE,
byte[] IssuerCountryCodeAlpha2,
byte[] IssuerCountryCodeAlpha3,
byte[] CardProductDetails
);Aid
String
Application Identifier. Tag 4F
Label
String
new EnhancedInputRequest();
new EnhancedInputRequest(byte[] data);EnhancedSelectionList()
List<DirectoryEntry>
Returns a list of enhanced application selection.
setEnhancedSelectionList()
List<DirectoryEntry>
StringValue()
String
Returns a string value.
ByteArray()
byte[]
// String usage
IData data1 = new BaseData(“3030”);
// Array usage
IData data2 = new BaseData(new byte[] {0x30, 0x30});new InputRequest ();
new InputRequest (byte[] data);Type() setType()
byte
Input type.
0x00 = INPUT_TYPE_APPLICATION
0x01 = INPUT_TYPE_LANGUAGE
Timeout() setTimeout
byte
INPUT_TYPE_APPLICATION
0x00
Selection type is for Application.
INPUT_TYPE_LANGUAGE
0x01
Timeout
byte
Transaction timeout in seconds. Default is 60 seconds. 0 to 255 - Depending on the device, 0 means no timeout.
Certificate data.
password getPassword()
String
Password to access the certificate data.
Returns string of disconnected.
DISCONNECTING
Returns string of disconnecting.
ERROR
Returns string of error.
GetString()
Returns string of the ConnectionState enum.
GetValue()
Returns ConnectionState enum from the event data string value.
Application Label. Tag 50
Priority
byte
Application Priority Indicator. Tag 87
ProprietaryData
byte[]
Application Selection Registered Proprietary Data. Tag 9F0A
KernelIdentifier
byte
Kernel Identifier. Tag 9F2A
IssuerIN
byte[3]
Issuer Identification Number. Tag 42
IssuerINE
byte[4]
Issuer Identification Number Extended. Tag 9F0C
IssuerCountryCodeAlpha2
byte[2]
Issuer Country Code (alpha2 format). Tag 5F55
IssuerCountryCodeAlpha3
byte[3]
Issuer Country Code (alpha3 format). Tag 5F56
CardProductDetails
byte[2]
Card Product Details. Tag 9F7D
Sets a list of enhanced application selection.
Title()
String
Title to display.
Type()
int
Selection type.
Timeout()
long
Timeout in seconds to make selection.
Returns a byte array.
Timeout in seconds
Title() setTitle()
string
Title
SelectionList() setSelectionList()
List<String>
List of selections for Application and Language depending on the Type.
Selection type is for Language.
INPUT_STATUS_COMPLETED
0x00
To send the status of completed for sendSelection().
INPUT_STATUS_CANCELLED
0x01
To send the status of canceled for sendSelection().
INPUT_STATUS_TIMED_OUT
0x02
To send the status of timed out for sendSelection().
PaymentMethods
List of Payment Method
List of the PaymentMethod enumeration.
MSR = For magnetic stripe cards.
Contact = For EMV chip cards.
Contactless = For NFC contactless cards.
ManualEntry = Manually entry, no card. When set, other payment methods must not be included.
Barcode = For barcode.
BarcodeEncrypted = For barcode with encrypted response.
AppleVAS = For Apple VAS.
GoogleVAS = For Google Wallet VAS.
NFC = For NFC tag.
QuickChip
boolean
In QuickChip mode, the device does not prompt for an amount. Device sends an ARQC request to the host. Device automatically populates the ARPC response data with EMV Tag 8A set to “Z3”. Card holder is prompted to remove the card. Transaction result is later determined by the processor and not by the card.
false - Do not enable QuickChip mode.
true - Enable QuickChip mode. Default.
EMVOnly
boolean
Flag that determines whether or not to start an EMV transaction.
false - Do not start transaction if the device does not support EMV.
true - Only start transaction if the device supports EMV. Default.
PreventMSRSignature ForCardWithICC
boolean
Flag that forces the device to skip signature capture during an MSR-only transaction if the card’s service code indicates it is a chip card.
false – Allow the prompt for a signature if requested.
true – Do not prompt for signature.
SuppressThankYouMes sage
boolean
By default, devices with a display signal the end of a transaction by briefly showing “THANK YOU,” then “WELCOME.”
false – Do not suppress the thank you message.
true – Suppress the thank you message.
DisplayAmountForQuic kChip
boolean
Display Amount for Quick Chip Transaction Flow.
false = Do not display Amount when QuickChip mode is true. Default.
true = Display Amount when QuickChip mode is true.
OverrideFinalTransacti onMessage
byte
By default, devices with a display signal the end of a transaction by returning to the idle page and showing “WELCOME.” This parameter directs the device to show a message based on the Message ID from the command displayMessage(). This option completely overrides the device’s idle page behavior until the next transaction, power cycle, or other similar state change.
Example but not limited to:
0x00 - reserved, do not use. 0x01 - “AMOUNT”
0x02 - “AMOUNT OK?”
0x03 - “APPROVED”
0x04 - “CALL YOUR BANK”
0x05 - “CANCEL OR ENTER”
0x06 - “CARD ERROR”
0x07 - “DECLINED”
0x08 - “ENTER AMOUNT”
0x09 - reserved, do not use. 0x0A - reserved, do not use. 0x0B - “INSERT CARD”
0x0C – “NOT ACCEPTED”
0x0D - reserved, do not use. 0x0E - “PLEASE WAIT”
0x0F - “PROCESSING ERROR”
0x10 - “REMOVE CARD”
0x11 - “USE CHIP READER”
0x12 - “USE MAGSTRIPE”
0x13 - “TRY AGAIN”
0x14 - “WELCOME”
0x15 - “PRESENT CARD”
0x16 - “PROCESSING”
0x17 - “CARD READ OK - REMOVE CARD”
0x18 - “INSERT OR SWIPE CARD”
0x19 - “PRESENT ONE CARD ONLY”
0x1A - “APPROVED PLEASE SIGN”
0x1B - “AUTHORIZING PLEASE WAIT”
0x1C - “INSERT, SWIPE OR TRY ANOTHER CARD”
0x1D - “PLEASE INSERT CARD”
0x1E - Null prompt (empty screen) 0x1F - reserved, do not use.
0x20 - “SEE PHONE”
0x21 - “PRESENT CARD AGAIN”
0x22 - “INSERT/SWIPE/TRY OTHER CARD”
0x23 - “TAP or SWIPE CARD”
0x24 - “TAP or INSERT CARD”
0x25 - “TAP, INSERT or SWIPE CARD”
0x26 - “TAP CARD”
0x27 - “TIMEOUT”
0x28 - “TRANSACTION TERMINATED”
EMVResponseFormat
byte
The format of the EMV response.
0x00 – Legacy. Default.
0x01 – RFU
TransactionType
byte 1
EMV Tag 9C - The type of financial transaction, represented by the first two digits of the ISO 8583:1987 Processing Code.
Examples:
0x00 – purchase. Default.
0x01 – cash advance
0x09 – purchase with cashback
0x20 – refund
Supported transaction types can found in the commands programmers manual specific to the device.
Amount
String 12
EMV Tag 9F02 - Authorized amount of the transaction.
Example:
“000000000123” – $1.23
“000000009999” – $99.99
CashBack
String 12
EMV Tag 9F03 - Secondary amount associated with the transaction.
Example:
“000000000123” – $1.23
“000000009999” – $99.99
CurrenyCode
byte[] 2
EMV Tag 5F2A - Currency code of the transaction according to ISO 4217. The byte array is null by default.
Example:
0x0840 = US Dollar 0x0978 = Euro 0x0826 = UK Pound
CurrencyExponent
byte[] 1
EMV Tag 5F36 - The decimal point position from the right of the transaction amount. The byte array is null by default.
Example:
0x02 – decimal point at 2 position from the right.
TransactionCategory
byte[] 1
EMV Tag 9F53 - The type of contactless transaction being performed. The byte array is null by default.
MerchantCategory
byte[] 2
EMV Tag 9F15 - The type of business being done by the merchant, represented according to ISO 18245. The byte array is null by default.
MerchantID
byte[] 15
EMV Tag 9F16 - Used to uniquely identify a given merchant. The byte array is null by default.
MerchantCustomData
byte[] 20
EMV Tag 9F7C – Proprietary merchant data that may be requested. The byte array is null by default.
ManualEntryType
byte
User interface sequence.
0x00 - Card Number, Expiration Date, Security Code
0x01 - Name on Card, Card Number, Expiration Date, Security Code (Reserved for Future Use)
0x02 – Qwick Code, Last 4 digits of Card Number, Security Code (Reserved for future use)
ManualEntryFormat
byte
Card number valid format.
0x00 - PAN min 8, max 21 digits
ManualEntrySound
byte
Beeper feedback.
0x00 - On keypress sound disabled
0x01 - On keypress sound enabled
AppleVASMode
VASMode
An enumeration for the Apple VAS Mode.
AppleVASProtocol
VASProtocol
An enumeration for the Apple VAS Protocol.
ECP2FrameData
byte[] 3-18
Apple ECP2.0 frame from Byte 2 to Byte N. See Apple ECP2.0 specification.
· For example, if ECP2.0 VASUP-A frame is 6A02C3020003FFFF
then Byte 2-N is 0xC3020003FFFF.
· By default, ECP2.0 frame (Byte 2 -N) is 0xC3020003FFFF
CustomNFCTransactionMode
List of NFC TransactionMode
List of NFC transaction modes.
CustomNFCReadDataMode
NFCDataMode
Custom NFC data mode.
TipMode
byte
Tip mode.
0x00 = Disable Tip Mode
0x01 = Show Tip GUI immediately using %
0x02 = Show Tip GUI immediately using $
0x11 = Enable Read Channel(s), with +Tip Button using %
0x12 = Enable Read Channel(s), with +Tip Button, using $
Tip1DisplayMode
byte
Display mode for Tip button 1.
0x00 = % or $
0x01 = Display Custom 0x02 = Display NO TIP 0x03 = Disabled
Tip2DisplayMode
byte
Display mode for Tip button 2.
0x00 = % or $
0x01 = Display Custom 0x02 = Display NO TIP 0x03 = Disabled
Tip3DisplayMode
byte
Display mode for Tip button 3.
0x00 = % or $
0x01 = Display Custom 0x02 = Display NO TIP 0x03 = Disabled
Tip4DisplayMode
byte
Display mode for Tip button 4.
0x00 = % or $
0x01 = Display Custom 0x02 = Display NO TIP 0x03 = Disabled
Tip5DisplayMode
byte
Display mode for Tip button 5.
0x00 = % or $
0x01 = Display Custom 0x02 = Display NO TIP 0x03 = Disabled
Tip6DisplayMode
byte
Display mode for Tip button 6.
0x00 = % or $
0x01 = Display Custom 0x02 = Display NO TIP 0x03 = Disabled
Tip1Value
String
Display value for Tip button 1.
“1.00” = $1.00 (Display Mode is $)
“10.0001” = 10.0001% (Display Mode is %)
Tip2Value
String
Display value for Tip button 2.
“1.00” = $1.00 (Display Mode is $)
“10.0001” = 10.0001% (Display Mode is %)
Tip3Value
String
Display value for Tip button 3.
“1.00” = $1.00 (Display Mode is $)
“10.0001” = 10.0001% (Display Mode is %)
Tip4Value
String
Display value for Tip button 4.
“1.00” = $1.00 (Display Mode is $)
“10.0001” = 10.0001% (Display Mode is %)
Tip5Value
String
Display value for Tip button 5.
“1.00” = $1.00 (Display Mode is $)
“10.0001” = 10.0001% (Display Mode is %)
Tip6Value
String
Display value for Tip button 6.
“1.00” = $1.00 (Display Mode is $)
“10.0001” = 10.0001% (Display Mode is %)
TaxAmount
String
Tax amount.
“1.00” = $1.00
FunctionalButtonRight Option
byte[] 2
String ID to use for the Right functional button. The byte array is null by default.
When user presses this button, device sends a notification to the host to indicate the present card functional button Right is pressed. Device then waits for the next command from the host. While waiting, the screen shows “PLEASE WAIT”.
null = Disable.
0x0000 to 0x00FF = String ID