PowerShell Module: Tutorial
This feature is only available in the Nerdio Manager Premium edition.
This document explains how to download, install, and use the PowerShell Module for Nerdio Manager. The PowerShell Module for Nerdio Manager is a wrapper for the Nerdio Manager REST API.
Note: The PowerShell Module for Nerdio Manager is in public preview. Please submit your feedback here.
Install the PowerShell Module from the PowerShell Gallery
The following steps must be performed to install the PowerShell Module from the Microsoft PowerShell Gallery.
To install the module:
Open PowerShell ISE as Administrator.
Execute the following command:
Install-Module -Name NerdioManagerPowerShell
When prompted, select Yes to All.
Install the PowerShell Module from GitHub
The following steps must be performed to install the PowerShell Module.
To install the module:
Open a browser and navigate to https://github.com/Get-Nerdio/NerdioManagerPowerShell.
Select Code > Download Zip.
Optionally, based on OS security, unblock the zip file.
Right-click the zip file and select Properties.
At the bottom of the General tab, select Unblock.
Unzip the file.
Note: When using Windows Extract Compress file remove NerdioManagerPowerShell-Main for the end of the path. If that is not done, there will be a nested NerdioManagerPowerShell-Main in the path.
Open PowerShell ISE and navigate to the folder from the previous step. (for example, CD C:\Users\ssa\Downloads\NerdioManagerPowerShell-Main)
Note: When using this PowerShell module in development, you may want to install it so it is accessible by default. See this Microsoft article for instructions.
In PowerShell, run the following command to import the PowerShell Module:
Run the following command to verify the installation completed properly:
Get-Command -Module NerdioManagerPowerShell
Note: When successfully installed, the previous command returns output that looks like this:
Use the PowerShell Module
To use the PowerShell Module, you must connect to the Nerdio Manager deployment using the following command:
Connect-NME -ClientId $NmeClientId -ClientSecret $NmeClientSecret -TenantId $NmeTenantId -ApiScope $NmeScope -NmeUri $NmeUri
You need to retrieve the required parameters from your Nerdio Manager deployment.
To retrieve the required parameters:
In Nerdio Manager, navigate to Settings > Integrations.
In the REST API tile, next to Credentials, select show.
A window opens that shows ClientId, ClientSecret, TenantId, and Scope.
ClientSecret is obscured. If it is unknown, it can be regenerated to view and create a new value. Save the value in a secure location such as Azure Key Vault for future reference. It is not possible to retrieve the value after navigating away from the page.
The NmeUri parameter is the URI of the Nerdio Manager deployment (for example, https://nmw-app-i55ow6qye6hc6.azurewebsites.net).