Nexthink
Overview
The Nexthink connector enables your Leena AI Agents to integrate with your organization's Nexthink platform, facilitating automated digital employee experience management, remote action execution, workflow orchestration, and proactive IT remediation workflows.
Nexthink provides digital employee experience (DEX) management, enabling IT teams to monitor, manage, and improve the digital workplace through real-time analytics and automated remediation. The Nexthink connector allows Leena AI to trigger campaigns, execute remote actions on devices, run workflows, query telemetry data using NQL, and enrich device or user fields seamlessly.
API Details
Leena AI integrates with Nexthink via REST APIs.
Documentation link: https://docs.nexthink.com/api
Setup
The Nexthink connector uses OAuth 2.0 authentication with the client credentials grant type.
Prerequisites
Before setting up the Nexthink connector, ensure you have:
- Administrator access to your Nexthink instance
- Permission to access the Account Management section in the Nexthink web interface
- Ability to create API credentials in Nexthink
- Knowledge of your Nexthink instance name and hosting region
- Access to your Leena AI workspace with connector management permissions
Get credentials
Here is how to create API credentials in the Nexthink web interface:
- Log in to your Nexthink web interface as an administrator.
- Navigate to API Credentials:
- Select Administration from the main menu
- Under the Account Management section, click on API credentials
- Create a new credential:
- Click on New credential (or the equivalent "+ Add" option)
- Provide a descriptive Name for the credential (e.g., "Leena AI Integration")
- Select the appropriate Roles and Scopes required for the actions Leena AI will perform (e.g., service:integration, remote actions, NQL access, workflows, campaigns, enrichments)
- Generate and save credentials:
- Click on Save and generate credentials
- A new modal appears displaying the Client ID and Client Secret
- Copy and save both values securely — for security reasons, the credentials appear only once and cannot be retrieved later
- Note your instance details:
- Identify your Instance Name (the prefix in your Nexthink URL, e.g.,
mycompanyfromhttps://mycompany.api.us.nexthink.cloud) - Identify your Region (United States, European Union, Asia-Pacific, or Middle East, Turkey and Africa)
- Identify your Instance Name (the prefix in your Nexthink URL, e.g.,
Add connection
Here is how to add a connection on Leena AI:
- Log in to your Leena AI workspace
- Navigate to Settings > Integrations
- Search for "Nexthink" and select it from the list to add its new connector
- Start configuring the connector with the following fields:
- Instance Name: The Nexthink instance prefix (e.g.,
mycompanyfrom your Nexthink URL) - Region: The region where your Nexthink instance is hosted, options:
- United States
- European Union
- Asia-Pacific
- Middle East, Turkey and Africa
- Client ID: The OAuth 2.0 Client ID generated in Nexthink
- Client Secret: The OAuth 2.0 Client Secret generated in Nexthink
- Scope: The list of permissions required to perform actions through Leena AI (Pre-filled with
service:integration)
- Instance Name: The Nexthink instance prefix (e.g.,
- Click Connect to validate the credentials
- Leena AI will obtain an OAuth access token using the client credentials flow
- Upon successful validation, the connector will be saved and ready to use
Actions
The following actions are supported for the Nexthink connector. Actions are grouped logically into Workflows, Remote Actions, Campaigns, NQL Queries, and Enrichments.
Trigger Campaign
Triggers a Nexthink campaign to send a survey or notification to a targeted set of users. The Agent can leverage this action to gather user feedback, deliver important communications, or run pulse surveys directly within the Nexthink platform. Common use cases include:
- Pulse Surveys: Send periodic engagement or sentiment surveys to specific user groups
- IT Notifications: Communicate planned maintenance, outages, or new tooling rollouts
- Targeted Feedback: Collect feedback from users impacted by a specific incident or change
- Personalized Outreach: Send role-based or department-based campaigns
Input Parameters
Here are the input parameters required to set up this action:
Mandatory
| Name | Description |
|---|---|
| Campaign NQL ID | The NQL ID of the campaign to send (e.g., #general_survey) |
| User SIDs | Comma-separated SIDs of users that the campaign should be sent to (maximum 10,000 users) |
Optional
| Name | Description |
|---|---|
| Expires In (Minutes) | Number of minutes before the campaign response expires (range: 1 to 525600) |
| Parameters | Key-value campaign parameters used to replace placeholders in the campaign content |
Response
Upon successful trigger, the action returns:
- Campaign trigger acknowledgement
- Number of users targeted
- Status of the campaign request
Trigger Workflow
Triggers a Nexthink workflow on specified devices or users. The Agent can leverage this action to automate IT processes such as remediation, provisioning, or diagnostics that have been pre-defined as workflows in Nexthink. Common use cases include:
- Automated Remediation: Trigger fix-it workflows for common issues (slow boot, app crashes, VPN issues)
- Onboarding/Offboarding: Run workflows to configure or de-provision user devices
- Self-Service IT: Allow employees to invoke approved workflows through Leena AI conversations
- Proactive Intervention: Trigger workflows in response to detected anomalies
Input Parameters
Here are the input parameters required to set up this action:
Mandatory
| Name | Description |
|---|---|
| Workflow ID | The unique identifier of the workflow to be triggered |
Optional
| Name | Description |
|---|---|
| Devices | List of devices on which to run the workflow; each device entry supports the following identifiers: Collector UUID, Device Name, Device UID |
| Users | List of users for whom to run the workflow; each user entry supports the following identifiers: Security ID (SID), User Principal Name (UPN), User UID |
| Parameters | Key-value parameters passed to the workflow at runtime |
Response
Upon successful trigger, the action returns:
- Workflow execution ID
- List of targeted devices and/or users
- Execution status
List Workflows
Retrieves a list of available workflows configured in the Nexthink instance. This action helps the Agent discover which workflows are available to trigger and what their current status is. Common use cases include:
- Workflow Discovery: List all workflows available for triggering
- Filter by Trigger Type: View only API-triggered or manually-triggered workflows
- Active Workflow Audit: Show only workflows that are currently active
Input Parameters
Here are the input parameters required to set up this action:
Optional
| Name | Description |
|---|---|
| Dependency | Filter workflows by their input dependency, options: NONE, USER, DEVICE, USER_AND_DEVICE |
| Trigger Method | Filter workflows by their trigger method, options: API, MANUAL, MANUAL_MULTIPLE, SCHEDULER |
| Fetch Only Active Workflows | When enabled, returns only workflows in the active state |
Response
The action returns a list of workflows, each containing:
- Workflow UUID
- Workflow name and NQL ID
- Trigger method
- Dependency type
- Active/inactive status
Get Workflow Details
Retrieves detailed information about a specific Nexthink workflow, including its configuration, input parameters, and current state. The Agent can use this action to understand what a workflow expects before triggering it.
Input Parameters
Here are the input parameters required to set up this action:
Mandatory
| Name | Description |
|---|---|
| Workflow | The unique identifier of the workflow to retrieve details for |
Response
The action returns the workflow details, including:
- Workflow UUID and NQL ID
- Workflow name and description
- Input parameter schema
- Trigger method and dependency
- Current status
Query Workflow Executions
Retrieves the execution history and status of workflows using a saved NQL API query. This action is useful for auditing past workflow runs and tracking outcomes. Common use cases include:
- Audit Trail: Review which workflows ran for specific users or devices
- Status Tracking: Check whether triggered workflows completed successfully
- Reporting: Generate workflow execution reports for stakeholders
Input Parameters
Here are the input parameters required to set up this action:
Mandatory
| Name | Description |
|---|---|
| Query ID | The saved NQL API query ID for retrieving workflow executions (e.g., #query_workflow_executions) |
Optional
| Name | Description |
|---|---|
| Query Parameters | Key-value pairs for parameterized queries to filter execution results |
Response
The action returns a list of workflow executions matching the query, each containing:
- Execution UUID
- Workflow UUID and name
- Trigger details (user/device)
- Execution status (succeeded, failed, in progress)
- Start and end timestamps
Trigger Wait For Event
Resumes a workflow execution that is currently in a wait-for-event state. The Agent uses this action to send the awaited input or signal back to the workflow so it can continue. Common use cases include:
- Approval Flows: Resume workflows that paused for manager or user approval
- External Acknowledgements: Continue workflows after a third-party action is completed
- Conditional Branches: Provide runtime parameters that determine the next step
Input Parameters
Here are the input parameters required to set up this action:
Mandatory
| Name | Description |
|---|---|
| Workflow UUID | The unique identifier of the workflow that contains the wait-for-event step |
| Execution UUID | The UUID of the specific waiting workflow execution to resume |
Optional
| Name | Description |
|---|---|
| Parameters | Key-value parameters sent to the thinklet to continue the execution |
Response
Upon successful trigger, the action returns:
- Confirmation that the wait-for-event was triggered
- Updated workflow execution status
List Remote Actions
Retrieves a list of remote actions available in the Nexthink instance. Remote actions are pre-defined scripts that can be executed on managed endpoints. Common use cases include:
- Action Discovery: Browse available remote actions before invoking
- Platform Filtering: Identify which remote actions support Windows or macOS
- Capability Audit: Review the remote action library for governance purposes
Input Parameters
Here are the input parameters required to set up this action:
Optional
| Name | Description |
|---|---|
| Has Windows Script | Filter remote actions that include a Windows script |
| Has macOS Script | Filter remote actions that include a macOS script |
Response
The action returns a list of remote actions, each containing:
- Remote action NQL ID
- Name and description
- Supported operating systems (Windows, macOS)
- Input parameters required to execute
Get Remote Action Details
Retrieves detailed configuration of a specific remote action, including its parameter schema and supported platforms. The Agent uses this action to understand what inputs a remote action requires before executing it.
Input Parameters
Here are the input parameters required to set up this action:
Mandatory
| Name | Description |
|---|---|
| Remote Action NQL ID | The NQL ID of the remote action to retrieve details for |
Response
The action returns the remote action details, including:
- NQL ID and display name
- Description and category
- Input parameter schema
- Supported operating systems
- Default expiration
Execute Remote Action
Executes a Nexthink remote action on one or more target devices. The Agent can leverage this action to run pre-defined scripts (diagnostics, fixes, configuration changes) on endpoints. Common use cases include:
- Endpoint Remediation: Execute fix scripts directly on impacted devices
- Diagnostic Collection: Gather logs or system information from a user's device
- Configuration Push: Apply configuration changes across multiple devices
- Self-Service Resolution: Allow employees to trigger approved fixes via Leena AI
Input Parameters
Here are the input parameters required to set up this action:
Mandatory
| Name | Description |
|---|---|
| Remote Action | The remote action to be executed |
| Device IDs | One or more device identifiers on which the remote action will run |
Optional
| Name | Description |
|---|---|
| Parameters | Key-value parameters passed to the remote action at runtime |
| Expires In (Minutes) | Number of minutes after which the remote action expires if not picked up by the device |
Response
Upon successful execution, the action returns:
- Remote action execution ID
- List of targeted devices
- Execution status per device
Execute NQL Query
Executes a saved Nexthink Query Language (NQL) query and returns the results immediately. NQL is Nexthink's query language used to retrieve telemetry, device, user, and event data. Common use cases include:
- Device Lookup: Retrieve information about specific devices or users
- Real-Time Reporting: Get up-to-the-minute analytics for a dashboard or summary
- Conditional Logic: Use query results to drive subsequent automation steps
Input Parameters
Here are the input parameters required to set up this action:
Mandatory
| Name | Description |
|---|---|
| Query ID | The NQL API query ID to execute (e.g., #get_devices) |
Optional
| Name | Description |
|---|---|
| Query Parameters | Key-value pairs for parameterized queries to filter the result set |
Response
The action returns the query result data, including:
- Result rows matching the query
- Column metadata (field names and types)
- Total record count
Export NQL Query
Initiates an asynchronous export of an NQL query result. This action is suited for large datasets that exceed the limits of the synchronous Execute NQL Query action. Common use cases include:
- Large Dataset Extracts: Export thousands of device or event records for analysis
- Bulk Reporting: Generate periodic data extracts for downstream systems
- Compliance Exports: Produce audit datasets that need to be archived
Input Parameters
Here are the input parameters required to set up this action:
Mandatory
| Name | Description |
|---|---|
| Query ID | The NQL API query ID to export |
Optional
| Name | Description |
|---|---|
| Query Parameters | Key-value pairs for parameterized queries to filter the export |
| Compression | Compression algorithm for the export file, options: None, GZIP, ZSTD |
Response
Upon successful initiation, the action returns:
- Export ID — used to track export status and retrieve the download URL
- Initial export status
Get Export Status
Retrieves the current status of an asynchronous NQL export initiated via the Export NQL Query action. The Agent uses this action to poll for completion before downloading the export.
Input Parameters
Here are the input parameters required to set up this action:
Mandatory
| Name | Description |
|---|---|
| Export ID | The export ID returned by the Export NQL Query action |
Response
The action returns the export status, including:
- Current status (e.g., IN_PROGRESS, COMPLETED, FAILED)
- Results file URL (S3 URL, available once status is COMPLETED)
- Number of records exported
- Error details (if status is FAILED)
Download Export
Downloads the result file of a completed NQL query export from the URL returned by the Get Export Status action.
Input Parameters
Here are the input parameters required to set up this action:
Mandatory
| Name | Description |
|---|---|
| Results File URL | The S3 URL returned by the Get Export Status action when status is COMPLETED |
Response
The action returns the exported file content, which can then be processed downstream within the workflow.
Enrich Fields
Updates custom fields on Nexthink entities (devices, users, etc.) with additional context from external sources. The Agent can use this action to write back enrichment data such as ownership, criticality, asset tags, or HR attributes. Common use cases include:
- Asset Enrichment: Push CMDB or asset management data into Nexthink for richer analytics
- HR Data Sync: Tag users with department, location, or role information
- Criticality Tagging: Mark VIP devices or users for prioritized monitoring
- Cross-System Context: Make data from ITSM, IAM, or HRIS visible inside Nexthink dashboards
Input Parameters
Here are the input parameters required to set up this action:
Mandatory
| Name | Description |
|---|---|
| Enrichments | A JSON array of enrichment objects, where each object contains an identification array (with name/value pairs identifying the target entity) and a fields array (with the name/value pairs to write) |
| Domain | The domain for which the enrichment applies, used for information and tracking purposes |
Response
Upon successful enrichment, the action returns:
- Number of records enriched
- Confirmation per identification entry
- Any validation errors for entries that could not be enriched
Updated 1 day ago
