Getting HP Warranty Information

This topic contains 3 replies, has 2 voices, and was last updated by  Oliver Adams 4 years ago.

  • Author
  • #12824

    Oliver Adams

    I have tried several different ways but I cannot seem to find this information. Does anyone have any ideas or has done this before? I have been reading that you can extract the serial and productID from wmi, which I have done. Then use these to run a web query against HP's warranty page and return the date. any information on this is greatly appreciated.

  • #12880

    Oliver Adams

    function Execute-SOAPRequest {
    Param (

    write-Output "Sending SOAP Request To Server: $URL"
    $soapWebRequest = [System.Net.WebRequest]::Create($URL)

    $soapWebRequest.ContentType = 'text/xml; charset=utf-8'
    $soapWebRequest.Accept = "text/xml"
    $soapWebRequest.Method = "POST"
    $soapWebRequest.UserAgent = 'RemoteSupport/A.05.05 - gSOAP/2.7'

    $soapWebRequest.ServicePoint.Expect100Continue = $False
    $soapWebRequest.ServicePoint.MaxIdleTime = 2000
    $soapWebRequest.ProtocolVersion = []::version10

    write-Output "Initiating Send."
    $requestStream = $soapWebRequest.GetRequestStream()

    write-Output "Send Complete, Waiting For Response."
    $resp = $soapRequest.GetResponse()
    $responseStream = $resp.GetResponseStream()
    $soapReader = [System.IO.StreamReader]($responseStream)
    $ReturnXml = [Xml]$soapReader.ReadToEnd()

    write-Output "Response Received."

    return $returnxml

    $SOAPRequest = [Xml](Get-Content 'C:\Temp\SoapEnv.xml')
    $URL = ''

    Execute-SOAPRequest $SOAPRequest $URL

    With the xml file



    Any ideas?

  • #13376

    Garth Jones

    Hi Oliver, did you ever figure this out?

  • #13400

    Oliver Adams

    Hi Garth,

    You can find a copy of the script here:

    It works fine on Powershell 3.0 I am just having some problems getting it to work on powershell 2.0. I deployed it the servers I monitor using our RMM tool. It is great to see the warranty information along with everything else.

You must be logged in to reply to this topic.