Getting started

Operating System Requirements

Before you install the PowerShell module, check you have the pre-requisites, .NET 4.5 and PowerShell 3. The following chart will show you which components you need depending on the Operating System

 Default PowerShell versionAdditional software required 
Windows 105.0-Install using WMF 5
Windows Server 105.0-Install using WMF 5
Windows Server 2012 R24.0-Download and install MSI
Windows 8.14.0-Download and install MSI
Windows 83.0.NET 4.5 and above http://go.microsoft.com/fwlink/?LinkID=242919Download and install MSI
Windows 72.0

.NET 4.5 and above http://go.microsoft.com/fwlink/?LinkID=242919

PowerShell WMF 3.0 Windows Management Framework 3.0

Download and install MSI
Windows Server 2008 R23.0.NET 4.5 and above http://go.microsoft.com/fwlink/?LinkID=242919Download and install MSI
Windows Server 20082.0

.NET 4.5 and above http://go.microsoft.com/fwlink/?LinkID=242919

PowerShell WMF 3.0 Windows Management Framework 3.0

Download and install MSI

Installation using WMF 5

If you have Windows Management Framework 5, you can install the PowerShell module by running the following command

 

Installation using the MSI

  1. Download the latest MSI installer from the Releases page to a local folder on your computer
  2. Run the MSI as Administrator or provide access to UAC
  3. Click Next
  4. Read and accept the terms of license.
  5. Click Install to run the installation
  6. Click Finish to complete the installation

Writing your first script

  1. After installing the module, you need to open up the PowerShell ISE,

  2. Start->Run (or Windows+R) and enter
    powershell_ise
  3. PowerShell ISE will open, 
  4. on the right hand side, set the “Modules” in the Commands window to CaaS. This will show you a list of available commands for the CaaS API.

The first command to cover is the New-CaaSConnection command, this command creates a session with the CaaS API and is required for all further commands.

New-CaaSConnection requires 3 parameters

  1. The Vendor
  2. The Geo to connect to
  3. The API Credentials
  4. Name (optional)

As you start to type the command, you will see that PowerShell ISE prompts you with possible values.

Set the Vendor as Dimension Data and set the region as the region you normally connect to with your account.

Now, add a –ApiCredentials parameter and have the value as (Get-Credential), this is a shortcut to open the login window.

 

Press F5 to test your script. You will be prompted to enter your credentials.

In the Window output you will see:

This shows we have successfully connected to the API and the command has returned the account.

Related pages