Skip to main content

Get CWM Configurations - Active And Managed Only

Summary

The script fetches basic information from ConnectWise Manage configurations and stores it in a custom table CWM - Automate - Custom Table - pvl_cwm_configurations, which is further displayed by the CWM - Automate - Dataview - Asset Report - Purchase and Expiration Date dataview.

Sample Run

Sample Run

Sub-Script

CWM - Automate - Script - OverFlowedVariable - SQL Insert - Execute

Variables

NameDescription
ProjectNameGet-CWMConfiguration
WorkingDirectoryC:/ProgramData/_automation/Script/Get-CWMConfiguration
JsonFileNameGet-CWMConfiguration.Json
TableNamepvl_cwm_configurations
SQLDeleteStatementStores SQL query to remove stale data from pvl_cwm_configurations table
SQLStartStatementStores SQL query to input new data into pvl_cwm_configurations table

Global Parameters

NameExampleRequiredDescription
serverurlstage.cwmanage.comTrueConnectWise Manage Instance URL without http or https.
CompanyIDCWManageTrueCompanyID used to access the CW Manage instance. CompanyID
PublicKeyabC1dEFg23HIjk45LTruePublic API Key
PrivateKeyL54kjIH32gFEd1ae87TruePrivate API Key
CWMClientid97e76471-52b5-43c9-a5ec-0153ec905881TrueClientID provided by ConnectWise for API development

How to create API Keys: How to Create API Keys

How to get clientID: Request to get a Client ID

Output

  • Script Log
  • Custom Table
  • Dataview