Actions64
- Alert Actions
- Backup Actions
- Device Actions
- Approve/Reject
- Cancel Maintenance
- Delete
- Get
- Get Activities
- Get Alerts
- Get Custom Fields
- Get Dashboard URL
- Get Disks
- Get Jobs
- Get Last Logged On User
- Get Many
- Get OS Patch Installs
- Get OS Patches
- Get Policy Overrides
- Get Processors
- Get Software
- Get Software Patch Installs
- Get Software Patches
- Get Scripting Options
- Get Volumes
- Reboot
- Reset Policy Overrides
- Run Script
- Schedule Maintenance
- Update
- Update Custom Fields
- Group Actions
- Location Actions
- Organization Actions
- Query Actions
- Ticket Actions
- Webhook Actions
- Windows Service Actions
Device → Run Script
AI-generatedSummary
Run a predefined script on a specified device in NinjaOne RMM, optionally passing parameters and specifying the credential or role to execute the script as.
Inputs
- Device (required) — Select the target device on which to run the script. Supports selecting from a list of devices or providing the device ID directly. Expressions are supported.
- Script (required) — Select the script to run from a list of available scripts or provide the script ID directly. Supports expressions.
- Script Parameters — Optionally provide parameters to pass to the script as a string, e.g., 'param1=value1'. Supports expressions for dynamic values.
- Run As (Credential) — Specify the credential or role under which to run the script. This can be 'system' (default if empty), a credential name like 'sysop', or a credential ID number.
Output shape
a single record with the API response indicating the script invocation result
The output contains the NinjaOne API response to the script run request. If the request is successful, it typically includes details such as the script job ID or status. Errors are reported if the script ID is invalid or execution fails.
Examples
Example 1: Run a Script Without Parameters
Select a device, choose a script, leave parameters and runAs empty (defaults to system), and execute.
Example 2: Run a Script With Parameters and Custom Credential
Choose device and script, provide script parameters as a string (e.g., 'param1=value1'), and specify a runAs credential name or ID.