> For the complete documentation index, see [llms.txt](https://docs.octoxlabs.com/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://docs.octoxlabs.com/adapters/m/mobileitm.md).

# MobileITM

MobileITM is a mobile device management (MDM) platform. OctoXLabs reads devices of four platforms (Apple, legacy, EMM and Windows) and can add the last known location of each device.

## Use cases

* List the devices managed by MobileITM.

```
Adapters = mobileitm
```

* Find MobileITM devices that have not connected for 30 days.

```
Adapters = mobileitm AND NOT LastSeen last now-30d/d
```

## Before you begin

### Network

| Source              | Destination                                      | Port | Protocol |
| ------------------- | ------------------------------------------------ | ---- | -------- |
| OctoXLabs connector | MobileITM MDM host (default `mdm.mobileitm.com`) | 443  | HTTPS    |

### Required permissions

| Scope or role                                        | Permission | Needed for                                         |
| ---------------------------------------------------- | ---------- | -------------------------------------------------- |
| API key in the general category                      | Read       | Devices and locations                              |
| API key in the device category                       | Read       | Devices only (use it if you do not need locations) |
| API key in the location category or general category | Read       | Device locations (Fetch Device Locations)          |

Every API key belongs to a category and reaches only the endpoints of that category. A key can also be limited to a device group. If the key cannot read locations, the discovery still collects all devices and skips only the locations.

## Create credentials in MobileITM

{% stepper %}
{% step %}

### Open the console

Log in to the MobileITM MDM console.
{% endstep %}

{% step %}

### Open System Parameters

Go to System Management > System Parameters.
{% endstep %}

{% step %}

### Create a key

Open the API Key section and create a new key. Use the general category, or the device category if you do not need locations.
{% endstep %}

{% step %}

### Copy the key

Copy the generated key and store it in a safe place.
{% endstep %}
{% endstepper %}

## Connection parameters

| Parameter                                                       | Required | Type    | Default           | Description                                                                            |
| --------------------------------------------------------------- | -------- | ------- | ----------------- | -------------------------------------------------------------------------------------- |
| Domain (`domain`)                                               | No       | String  | mdm.mobileitm.com | Host name of your MobileITM instance, without a scheme.                                |
| Api Key (`api_key`)                                             | Yes      | String  |                   | External API access key.                                                               |
| Fetch Device Locations (`fetch_locations`)                      | No       | Boolean | True              | Add the last known latitude and longitude of each device.                              |
| Use Device Serial Number As Hostname (`use_serial_as_hostname`) | No       | Boolean | False             | Use the serial number as the identifier. Enable it when device names are not unique.   |
| Proxy (`proxy`)                                                 | No       | String  |                   | Proxy host and port, sent as an `http://` proxy URL.                                   |
| Thread Count (`thread_count`)                                   | No       | Integer | 32                | Parallel requests for device details (min 1, max 32).                                  |
| Sleep Time (`sleep_time`)                                       | No       | Integer |                   | Seconds between parallel requests. Increase it if MobileITM rate limits the discovery. |
| Timeout (`timeout`)                                             | No       | Integer | 30                | Seconds to wait for API responses.                                                     |

## Troubleshooting

| Error message                                          | Cause                                                              | Fix                                                                                                             |
| ------------------------------------------------------ | ------------------------------------------------------------------ | --------------------------------------------------------------------------------------------------------------- |
| get\_locations failed, location enrichment is skipped: | The API key cannot read `/external/device/location`.               | Use a key in the location or general category, or turn off Fetch Device Locations. Devices are still collected. |
| fetch\_platform\_devices failed for platform :         | One platform call failed. Logged and the other platforms continue. | Check the key category and whether your tenant uses that platform.                                              |

## Change history

{% hint style="info" %}
Available starting from version 6.7.2.
{% endhint %}
