CiscoDevNet / intersight-powershell

Cisco Intersight PowerShell
Apache License 2.0
16 stars 4 forks source link

Get-IntersightMonitoringHealthStatus bug/deprecated? #134

Closed DursyArts closed 1 month ago

DursyArts commented 10 months ago

Describe the bug

The cmdlet Get-IntersightMonitoringHealthStatus doesn't seem to work, i get an error:
Get-IntersightMonitoringHealthStatus: C:\Users\x\Desktop\Intersight-PS\IntersightHealth.ps1:27:1
Line |
  27 |  Get-IntersightMonitoringHealthStatus
     |  ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
     | The JSON string
     | `{"Count":1,"ObjectType":"monitoring.HealthStatus.List","Results":[{"CategoryStatus":[{"CategoryLabel":"Alarms","Deeplink":"https://www.intersight.com/an/cond/alarms/active","Details":"","SourceId":"","Status":"Critical"},{"CategoryLabel":"Advisory","Deeplink":"https://www.intersight.com/an/tam/security-advisories/","Details":"","SourceId":"","Status":"Warning"},{"CategoryLabel":"Licensing","Deeplink":"https://www.intersight.com/an/license/license-infos/","Details":"","SourceId":"","Status":"Critical"}],"ClassId":"monitoring.HealthStatus","HealthDataSchemaVersion":"1.0","Moid":"healthstatus","ObjectType":"monitoring.HealthStatus","Source":"Intersight API","StatusTimeStamp":"2024-01-11T13:55:07.055Z","Tags":[]}]}` incorrectly matches more than one schema (should be exactly one match): MoAggregateTransform,MoDocumentCount,MoTagSummary

To Reproduce run the cmdlet without any arguments:

$onprem = @{
    BasePath = "https://intersight.com"
    ApiKeyId = "x"
    ApiKeyFilePath = "x"
    HttpSigningHeader =  @("(request-target)", "Host", "Date", "Digest")
}

Set-IntersightConfiguration @onprem

Get-IntersightMonitoringHealthStatus

Version used

Expected behavior get the health object back to work further with the information about Health status

Running PS version 7.3.10

Ghufz commented 1 month ago

This issue has been fixed. please use latest published module version 1.0.11.17956