/build/static/layout/Breadcrumb_cap_w.png

Systems Management Question


API Calls - KaceSMA Powershell Module issues

08/28/2019 448 views

Hi All, 

I'm trying to do some API calls and integration so that we can snag inventory info for our devices and pipe it into SalesForce. I found the KaceSMA module that ArtisanByteCrafter wrote. I'm having some issues though.

To be fair i'm new to the API calling business so i'm likely missing something obvious.

after importing the module, when i try and run a simple Get-SMAMachineInventory i'm queried for server and credentials, and i receive the following error:

Invoke-RestMethod : The remote server returned an error: (401) Unauthorized.
At C:\Program Files\WindowsPowerShell\Modules\kacesma\1.0.8\private\New-ApiGETRequest.ps1:80 char:5
+     Invoke-RestMethod @IRMSplat
+     ~~~~~~~~~~~~~~~~~~~~~~~~~~~
    + CategoryInfo          : InvalidOperation: (System.Net.HttpWebRequest:HttpWebRequest) [Invoke-RestMethod], WebException
    + FullyQualifiedErrorId : WebCmdletWebResponseException,Microsoft.PowerShell.Commands.InvokeRestMethodCommand


It doesn't seem to matter what account i use, they're all throwing that error. what did i do wrong? 


1 Comment   [ + ] Show comment

Comments

  • i played around with ARC in chrome and noticed that what i thought would be x-dell-csrf-token appears now to be kace-csrf-token...

All Answers

1

ArtisanByteCrafter is usually on slack more then here, join slack thru this invite and post there also


Answered 08/28/2019 by: SMal.tmcc
Red Belt

  • see you did get on slack. cool
    • thanks man - i actually got into the slack channel. i just targeted a message at him.
      • just went to slack and saw you posted.

Don't be a Stranger!

Sign up today to participate, stay informed, earn points and establish a reputation for yourself!

Sign up! or login

Share

 
This website uses cookies. By continuing to use this site and/or clicking the "Accept" button you are providing consent Quest Software and its affiliates do NOT sell the Personal Data you provide to us either when you register on our websites or when you do business with us. For more information about our Privacy Policy and our data protection efforts, please visit GDPR-HQ