> For the complete documentation index, see [llms.txt](https://developer.magtek.com/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://developer.magtek.com/products/card-readers/magnetic-stripe-readers/idynamo-5-gen-iii/documentation/developers-manuals/programmers-manual-ios/mtscra-functions/mtscra-functions-21-30.md).

# MTSCRA Functions - 21 - 30

#### getMagnePrint

This function retrieves the card’s encrypted MagnePrint, for readers that support MagnePrint.

```
(NSString *) getMagnePrint
```

Parameters: None

Return Value: String containing the card’s encrypted MagnePrint.

#### getMagnePrintStatus \[iDynamo Only] <a href="#id-4.22_getmagneprintstatus_-idynamo_only" id="id-4.22_getmagneprintstatus_-idynamo_only"></a>

This function retrieves the card MagnePrint status. For more information, see *D99875475*. Only available on iDynamo; it will return an empty string in audio reader.

```
(NSString *) getMagnePrintStatus
```

Parameters: None Return Value:

Return stored MagnePrintStatus string.

#### getDeviceSerial <a href="#id-4.23_getdeviceserial" id="id-4.23_getdeviceserial"></a>

This function retrieves the device serial number.

```
(NSString *) getDeviceSerial
```

Parameters: None

Return Value: String containing the device serial number.

#### getMagTekDeviceSerial <a href="#id-4.24_getmagtekdeviceserial" id="id-4.24_getmagtekdeviceserial"></a>

This function returns the MagTek serial number of the currently opened device.

```
(NSString *) getMagTekDeviceSerial
```

Parameters: None

Return Value: Return stored serial number created by MagTek.

#### &#x20;getSessionID \[iDynamo/uDynamo Only] <a href="#id-4.25_getsessionid_-idynamo-udynamo_only" id="id-4.25_getsessionid_-idynamo-udynamo_only"></a>

This function retrieves the Session ID from the currently opened device, which the host can use to uniquely identify a transaction to prevent replay. Only supported by iDynamo/uDynamo; on other devices this function will return an empty string.  For more information, see *D99875475*

```
(NSString *) getSessionID
```

Parameters: None

Return Value: Stored session ID.

#### getKSN <a href="#id-4.26_getksn" id="id-4.26_getksn"></a>

This function retrieves the Key Serial Number (KSN) from the device.

```
(NSString *) getKSN
```

Parameters: None

Return Value: String containing the stored key serial number.

#### getDeviceName <a href="#id-4.27_getdevicename" id="id-4.27_getdevicename"></a>

This function gets the device’s product name.&#x20;

```
(NSString *) getDeviceName Parameters: None
```

Return Value: String containing the device product name.

#### getDeviceType <a href="#id-4.28_getdevicetype" id="id-4.28_getdevicetype"></a>

This function gets the device type.&#x20;

```
(int) getDeviceType 
```

Parameters: None

Return Value: Device Type

#### setDeviceType <a href="#id-4.29_setdevicetype" id="id-4.29_setdevicetype"></a>

This function sets the type of device to open. Call this function before calling openDevice.

```
(void) setDeviceType:(UInt32 *)deviceType
```

Parameters:

Device Type:

* MAGTEKAUDIOREADER = Audio readers aDynamo, uDynamo.
* MAGTEKIDYNAMO = iOS 30-pin and Lightning readers iDynamo.
* MAGTEKDYNAMAX = Bluetooth LE reader DynaMAX.
* MAGTEKEDYNAMO = Bluetooth LE reader eDynamo.
* MAGTEKKDYNAMO = Lightning reader kDynamo.
* MAGTEKTDYNAMO = Bluetooth LE reader tDynamo.

Return Value: None

#### getDeviceCaps <a href="#id-4.30_getdevicecaps" id="id-4.30_getdevicecaps"></a>

This function gets the capabilities of the currently opened device.

```
(NSString *) getDeviceCaps
```

Parameters: None

Return Value: Return device capabilities.

* CAP\_MASKING = 1,
* CAP\_ENCRYPTION=2,
* CAP\_CARD\_AUTH = 4,
* CAP\_DEVICE\_AUTH = 8,
* CAP\_SESSION\_ID = 16,
* CAP\_DISCOVERY= 32,


---

# Agent Instructions
This documentation is published with GitBook. GitBook is the documentation platform designed so that both humans and AI agents can read, navigate, and reason over technical content effectively. Learn more at gitbook.com.

## Querying This Documentation
If you need additional information that is not directly available in this page, you can query the documentation by asking a question.

Perform an HTTP GET request on the following URL with the `ask` and `goal` query parameters:

```
GET https://developer.magtek.com/products/card-readers/magnetic-stripe-readers/idynamo-5-gen-iii/documentation/developers-manuals/programmers-manual-ios/mtscra-functions/mtscra-functions-21-30.md?ask=<question>&goal=<user_goal>
```

`ask` is the immediate question: it should be specific, self-contained, and written in natural language.
`goal` is what the user is ultimately trying to achieve, the reason they need the answer. Sharing it helps GitBook give you a better, more relevant answer. A goal is most helpful when it describes the outcome the user wants rather than restating the question. For example, with `ask=how do I create an API token`, a goal like `automate deployments from our CI pipeline` lets GitBook tailor the answer to that use case.

The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
