# Jamf Pro connector thinklet

This page outlines different actions to use when [configuring thinklets](https://docs.nexthink.com/platform/user-guide/workflows/creating-workflows/configuring-thinklets) with Jamf Pro.

The Jamf Pro connector enables seamless integration with Jamf Pro, allowing administrators to execute device management operations within their workflows. The connector interacts with [Jamf Pro’s API](https://developer.jamf.com/jamf-pro/reference/jamf-pro-api), providing various actions for retrieving inventory data, renewing profiles, posting commands, and more.

## Action: **Post MDM SETTINGS command** <a href="#chatgptconnectorthinklet-connector-chatgpt" id="chatgptconnectorthinklet-connector-chatgpt"></a>

This action sends an MDM (Mobile Device Management) SETTINGS command to a managed device.

The SETTINGS command is used to update or refresh the configuration settings on a device, ensuring it complies with organizational policies. Refer to the [MDM endpoint documentation](https://developer.jamf.com/jamf-pro/reference/post_v2-mdm-commands) for more details.

<figure><img src="https://268444917-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FxJSUDk9NTtCHYPG5EWs3%2Fuploads%2Fgit-blob-5ba7cf5c5acb3ff61faf2d6336fe9a6b7c84242d%2Fimage.png?alt=media" alt="" width="375"><figcaption></figcaption></figure>

**Parameters:**

* **Computer Management ID** (`​ComputerManagementId`) – The unique identifier assigned by Jamf Pro to manage the target computer.​

**Outputs:**

* **Command ID** (​`CommandId`) – An internal identifier for the command, useful for tracking and verifying command execution results.

The table below shows the API Service connector details needed when recreating the connector:

<table><thead><tr><th width="272">Field</th><th>Value</th><th data-hidden></th></tr></thead><tbody><tr><td>Resource Path</td><td><code>api/v2/mdm/commands</code></td><td></td></tr><tr><td>Method</td><td>POST</td><td></td></tr><tr><td>Payload</td><td><code>{</code><br><code>"clientData": [</code><br><code>{</code><br><code>"managementId": "{{ComputerManagementId}}"</code><br><code>}</code><br><code>],</code><br><code>"commandData": {</code><br><code>"commandType": "SETTINGS"</code><br><code>}</code><br><code>}</code></td><td></td></tr><tr><td>Outputs</td><td><code>CommandId</code>: <code>$[0].id</code></td><td></td></tr></tbody></table>

## Action: Get computer inventory general data <a href="#chatgptconnectorthinklet-connector-chatgpt" id="chatgptconnectorthinklet-connector-chatgpt"></a>

Retrieves general inventory details of a computer, including MDM status, supervision status, and MDM profile expiration. Refer to the [Return General section of a Computer](https://developer.jamf.com/jamf-pro/reference/get_v1-computers-inventory-id) for more details.

<figure><img src="https://268444917-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FxJSUDk9NTtCHYPG5EWs3%2Fuploads%2Fgit-blob-0003f63faaa6360683c9b25c27ac8718b060ca9d%2Fimage.png?alt=media" alt="" width="375"><figcaption></figcaption></figure>

**Parameters:**

* **Computer ID** (`ComputerId`) – The Jamf Pro computer ID.

**Outputs:**

* **Computer Management ID** (`ComputerManagementId`)
* **UDID** (`UDID`) - Apple device UDID (Unique Device Identifier)
* **Name** (`Name`) – Computer name.
* **MDM Capable?** (`MDMCapable`) – Indicates if the device supports MDM.
* **Supervised?** (`Supervised`) – Indicates if the device is supervised.
* **Report Date** (`ReportDate`) – Date of the last inventory report.
* **MDM Profile Expiration** (`mdmProfileExpiration`) – Expiration date of the MDM profile.

The table below shows the API Service connector details needed when recreating the connector:

<table><thead><tr><th width="221.33331298828125">Field</th><th>Value</th><th data-hidden></th></tr></thead><tbody><tr><td>Resource Path</td><td><code>api/v1/computers-inventory/{{ComputerId}}?section=GENERAL</code></td><td></td></tr><tr><td>Method</td><td>GET</td><td></td></tr><tr><td>Outputs</td><td><p><code>ComputerManagementId</code>: <code>$.general.managementId</code></p><p><code>UDID</code>:<code>$.udid</code></p><p><code>Name</code>: <code>$.general.name</code></p><p><code>MDMCapable</code>: <code>$.general.mdmCapable.capable</code></p><p><code>Supervised</code>: <code>$.general.supervised</code></p><p><code>ReportDate</code>: <code>$.general.reportDate</code></p><p><code>mdmProfileExpiration</code>:<code>$.general.mdmProfileExpiration</code></p></td><td></td></tr></tbody></table>

## Action: Get computer inventory purchasing data <a href="#chatgptconnectorthinklet-connector-chatgpt" id="chatgptconnectorthinklet-connector-chatgpt"></a>

Retrieves purchasing-related inventory data for a computer, including purchase order date, warranty expiration, and expected lifespan. Refer to the [Return General section of a Computer](https://developer.jamf.com/jamf-pro/reference/get_v1-computers-inventory-id) for more details.

<figure><img src="https://268444917-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FxJSUDk9NTtCHYPG5EWs3%2Fuploads%2Fgit-blob-653b18beedc5172a1f6b471a2bb49090483ec778%2Fimage.png?alt=media" alt="" width="375"><figcaption></figcaption></figure>

**Parameters:**

* **Computer ID** (`ComputerId`) – The Jamf Pro computer ID.

**Outputs:**

* **Purchase Order Date** (`PODate`) – Date of purchase.
* **Warranty Date** (`WarrantyDate`) – Warranty expiration date.
* **Life Expectancy** (`LifeExpectancy`) – Expected operational lifespan.

The table below shows the API Service connector details needed when recreating the connector:

<table><thead><tr><th width="226">Field</th><th>Value</th><th data-hidden></th></tr></thead><tbody><tr><td>Resource Path</td><td><code>api/v1/computers-inventory/{{ComputerId}}?section=PURCHASING</code></td><td></td></tr><tr><td>Method</td><td>GET</td><td></td></tr><tr><td>Outputs</td><td><p><code>PODate</code>: <code>$.purchasing.poDate</code></p><p><code>WarrantyDate</code>:<code>$.purchasing.warrantyDate</code></p><p><code>LifeExpectancy</code>:<code>$.purchasing.lifeExpectancy</code></p></td><td></td></tr></tbody></table>

## Action: Renew MDM profile <a href="#chatgptconnectorthinklet-connector-chatgpt" id="chatgptconnectorthinklet-connector-chatgpt"></a>

Requests the renewal of an MDM profile for a computer, ensuring the device remains compliant with Jamf Pro management policies. Refer to the [Renew MDM profile](https://developer.jamf.com/jamf-pro/reference/post_v1-mdm-renew-profile) for more details.

<figure><img src="https://268444917-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FxJSUDk9NTtCHYPG5EWs3%2Fuploads%2Fgit-blob-71d0eeb64fcd83ad5b44c4aa2a245e3997ea2655%2Fimage.png?alt=media" alt="" width="375"><figcaption></figcaption></figure>

**Parameters:**

* **UDID** (`UDID`) – Apple device UDID (Unique Device Identifier).

**Outputs:**

* **Not Processed ID** (`NotProcessedId`) – Indicates if the renewal request was not processed.

The table below shows the API Service connector details needed when recreating the connector:

<table><thead><tr><th width="226">Field</th><th>Value</th><th data-hidden></th></tr></thead><tbody><tr><td>Resource Path</td><td><code>api/v1/mdm/renew-profile</code></td><td></td></tr><tr><td>Method</td><td>POST</td><td></td></tr><tr><td>Payload</td><td><code>{</code><br><code>"udids": ["{{UDID}}"]</code><br><code>}</code></td><td></td></tr><tr><td>Outputs</td><td><code>NotProcessedId</code>: <code>$.udidsNotProcessed.udids[0]</code></td><td></td></tr></tbody></table>

## Action: Get computer inventory general data by name <a href="#chatgptconnectorthinklet-connector-chatgpt" id="chatgptconnectorthinklet-connector-chatgpt"></a>

Retrieves general inventory data using the computer name instead of the ID. Refer to the [Return General section of a Computer](https://developer.jamf.com/jamf-pro/reference/get_v1-computers-inventory-id) for more details.

<figure><img src="https://268444917-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FxJSUDk9NTtCHYPG5EWs3%2Fuploads%2Fgit-blob-501dd88bb127c5f3829724e2c94467f1fe84b07f%2Fimage.png?alt=media" alt="" width="375"><figcaption></figcaption></figure>

**Parameters:**

* **Computer Name** (`ComputerName`) – The Jamf Pro computer name.

**Outputs:**

* **Computer Management ID** (`ComputerManagementId`)
* **Computer ID** (`ComputerId`)
* **UDID** (`UDID`) - Apple device UDID (Unique Device Identifier)

The table below shows the API Service connector details needed when recreating the connector:

<table><thead><tr><th width="226">Field</th><th>Value</th><th data-hidden></th></tr></thead><tbody><tr><td>Resource Path</td><td><code>api/v1/computers-inventory?section=GENERAL&#x26;page=0&#x26;page-size=100&#x26;sort=general.name%3Aasc&#x26;filter=general.name=={{ComputerName}}</code></td><td></td></tr><tr><td>Method</td><td>GET</td><td></td></tr><tr><td>Outputs</td><td><p><code>ComputerManagementId</code>: <code>$.results[0].general.managementId</code></p><p><code>ComputerId</code>: <code>$.results[0].id</code></p><p><code>UDID</code>: <code>$.results[0].udid</code></p></td><td></td></tr></tbody></table>

## Action: Get MDM command information <a href="#chatgptconnectorthinklet-connector-chatgpt" id="chatgptconnectorthinklet-connector-chatgpt"></a>

Retrieves the status and type of a previously executed MDM command. Refer to the [Get information about MDM commands made by Jamf Pro](https://developer.jamf.com/jamf-pro/reference/get_v2-mdm-commands) for more details.

<figure><img src="https://268444917-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FxJSUDk9NTtCHYPG5EWs3%2Fuploads%2Fgit-blob-61bd9a24aa9c0066135bf493371c6cf8b2b784e8%2Fimage.png?alt=media" alt="" width="375"><figcaption></figcaption></figure>

**Parameters:**

* **Command ID** (`CommandId`) – ID of the executed command.

**Outputs:**

* **Command Type** (`CommandType`)
* **Command State** (`CommandState`)

The table below shows the API Service connector details needed when recreating the connector:

<table><thead><tr><th width="226">Field</th><th>Value</th><th data-hidden></th></tr></thead><tbody><tr><td>Resource Path</td><td><code>api/v2/mdm/commands?page=0&#x26;page-size=100&#x26;sort=dateSent%3Aasc&#x26;filter=uuid=={{CommandId}}</code></td><td></td></tr><tr><td>Method</td><td>GET</td><td></td></tr><tr><td>Outputs</td><td><p><code>CommandType</code>: <code>$.results[0].commandType</code></p><p><code>CommandState</code>: <code>$.results[0].commandState</code></p></td><td></td></tr></tbody></table>

## Action: Post MDM DEVICE\_LOCK command <a href="#chatgptconnectorthinklet-connector-chatgpt" id="chatgptconnectorthinklet-connector-chatgpt"></a>

Locks a device via MDM and displays a custom message and contact information. Refer to the [Post a command for creation and queuing](https://developer.jamf.com/jamf-pro/reference/post_v2-mdm-commands) for more details.

<figure><img src="https://268444917-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FxJSUDk9NTtCHYPG5EWs3%2Fuploads%2Fgit-blob-03668ae1c40b45fa6741326890591751edc6c9ee%2Fimage.png?alt=media" alt="" width="375"><figcaption></figcaption></figure>

**Parameters:**

* **Computer Management ID** (`ComputerManagementId`)
* **PIN** (`PIN`) – Lock screen PIN.
* **Message** (`Message`) – Custom message displayed on the locked screen.
* **Phone Number** (`PhoneNumber`) – Contact number displayed for unlocking assistance.

**Outputs:**

* **Command ID** (`CommandId`)

The table below shows the API Service connector details needed when recreating the connector:

<table><thead><tr><th width="226">Field</th><th>Value</th><th data-hidden></th></tr></thead><tbody><tr><td>Resource Path</td><td><code>api/v2/mdm/commands</code></td><td></td></tr><tr><td>Method</td><td>POST</td><td></td></tr><tr><td>Payload</td><td><code>{</code><br><code>"clientData": [{"managementId": "{{ComputerManagementId}}"}],</code><br><code>"commandData": {"commandType": "DEVICE_LOCK","pin": "{{PIN}}","message": "{{Message}}", "phoneNumber": "{{PhoneNumber}}"}</code><br><code>}</code></td><td></td></tr><tr><td>Outputs</td><td><code>CommandId</code>: <code>$[0].id</code></td><td></td></tr></tbody></table>

## Action: Post MDM DECLARATIVE\_MANAGEMENT command <a href="#chatgptconnectorthinklet-connector-chatgpt" id="chatgptconnectorthinklet-connector-chatgpt"></a>

Sends a declarative management command to a managed device. Refer to the [Post a command for creation and queuing](https://developer.jamf.com/jamf-pro/reference/post_v2-mdm-commands) for more details.

<figure><img src="https://268444917-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FxJSUDk9NTtCHYPG5EWs3%2Fuploads%2Fgit-blob-6b6cbefaaffaaf87ea9ead3558d5d1d7690e7a57%2Fimage.png?alt=media" alt="" width="375"><figcaption></figcaption></figure>

**Parameters:**

* **Computer Management ID** (`ComputerManagementId`)

**Outputs:**

* **Command ID** (`CommandId`)

The table below shows the API Service connector details needed when recreating the connector:

<table><thead><tr><th width="226">Field</th><th>Value</th><th data-hidden></th></tr></thead><tbody><tr><td>Resource Path</td><td><code>api/v2/mdm/commands</code></td><td></td></tr><tr><td>Method</td><td>POST</td><td></td></tr><tr><td>Payload</td><td><code>{</code><br><code>"clientData": [{"managementId": "{{ComputerManagementId}}"}],</code><br><code>"commandData": {"commandType": "DECLARATIVE_MANAGEMENT"}</code><br><code>}</code></td><td></td></tr><tr><td>Outputs</td><td><code>CommandId</code>: <code>$[0].id</code></td><td></td></tr></tbody></table>

Refer to the [Configuring connector thinklets](https://docs.nexthink.com/platform/user-guide/workflows/creating-workflows/configuring-connector-thinklet) documentation for more information about connector thinklets.
