Episode #86 - Orion SDK 101: Intro to PowerShell and Orion API

April 15, 2020

In this 100-level class, Kevin M. Sparenberg, Technical Content Manager for THWACKRegistered, presents a simple introduction to the SolarWindsRegistered OrionRegistered Software Development Kit (SDK). Instructions include how to download the SDK, installing the PowerShell module, and performing basic read operations within the API. No previous PowerShell or Orion API experience is necessary. Kevin discusses when, how, and why to use the API. Be sure to register for the live cast because Kevin will be answering audience questions during the episode.


Additional Resources

PowerShell Basic Cheat Sheet:
http://ramblingcookiemonster.github.io/images/Cheat-Sheets/powershell-basic-cheat-sheet2.pdf

The Curious Case of the "Dead" Nodes
https://thwack.solarwinds.com/t5/Product-Blog/The-Curious-Case-of-the-quot-Dead-quot-Nodes/ba-p/451211

Anonymous
  • Thanks  for the much needed tutorial.

    I would also like to know how can I use verbs in SWQL for multiple nodes.

    Like if I have to add multiple nodes in NCM I can use it for one node at a time from the SWQL studio like below, but how to give multiple nodeid to perform the same operation in one go.

    prashantsingh_0-1596531622486.png

  • Nice big Microphone you've got there Kevin!

  • Do me a favor and post your complete script in the Orion SDK area with whatever you have for edits.

  • Clacky keyboards are the best.

    So, I'm running with the native Powershell ISE as we don't really want to install anything more. But we do have the SDK installed, so it has made the connection to SWIS.

    So, in trying to understand better, I have just been trying to replicate your example but everytime I try to run the script (within PS) I get:

    At line:18 char:1
    + FROM Orion.Nodes
    + ~~~~
    The 'from' keyword is not supported in this version of the language.
    + CategoryInfo : ParserError: (:) [], ParentContainsErrorRecordException
    + FullyQualifiedErrorId : ReservedKeywordNotAllowed

    So presumably I'm missing something?

    So I next tried (because I don't think you addressed this for Powershell in the vid) Preempting the query with $SwqlQuery = " insert query " and I get yet more errors.

    Clearly I'm missing a step and perhaps I'd be better asking thos over in the OrionSDK forum...