Solution: Stream Updates

Document created by jkim Employee on Jun 24, 2019Last modified by jkim Employee on Jul 18, 2019
Version 2Show Document
  • View in full screen mode
  1. Register for Stream Updates to the "\\PIAF\Nugreen\Nugreen\Houston\Cracking Process\Equipment\B-210|Fuel Gas Flow” attribute

    HTTP Verb: GET

    URL: https://HostName/piwebapi/streams/WebId/updates

    Request Body: (null)

  2. Delete the current value for this attribute using Fiddler

     

    HTTP Verb: POST

    URL: https://HostName/piwebapi/streams/WebId/value?updateOption=Remove

    Request Body:

    {

    "Timestamp": "2019-03-22T13:33:16.9649047Z",

    "Good": true,

    "Questionable": false,

    "Value": 2

    }

    // Replace for the Current Snapshot Time

  3. POST this value back to the attribute using Fiddler

    HTTP Verb: POST

    URL: https://HostName/piwebapi/streams/WebId/value

    Request Body:

    {

    "Timestamp": "*",

    "Good": true,

    "Questionable": false,

    "Value": 2

    }

     

  4. Retrieve the stream updates using the marker received in step 1

    HTTP Verb: GET

    URL: https://HostName/piwebapi/streams/updates/{Marker_from_First_Request}

    Request Body: (null)

Attachments

    Outcomes