Please ensure Javascript is enabled for purposes of website accessibility
Powered by Zoomin Software. For more details please contactZoomin

PI Web API Reference

2021 SP3 - Detailed Changes (PI Web API OMF Services)

2021 SP3 - Detailed Changes (PI Web API OMF Services)

Non-Breaking Change: Simplified DELETE for TYPE, CONTAINER, and Static DATA

PI Web API 2021 SP3 implements simplified handling of DELETE messages when deleting Types, Containers, and Static Data. The table below shows the updated required fields for DELETE processing.

Target Entity Required Fields Example Message Body
TYPE id [{"id":"TypeIdToDelete"}]
CONTAINER id
typeid
[{"id": "ContainerIdToDelete", "typeid": "Widget"}]
STATIC DATA typeid
values[{index}]
[ { "typeid":"Widget", "values": [{ "WidgetId": "WidgetToDelete" }] } ]
Where WidgetId is the index property of the TYPE

If any other fields are provided in the DELETE message, they will be ignored. This change relaxes the requirement that PI Web API clients persist the full entity definitions to be able to delete them.

Note: Previously a successful DELETE message required that all fields were present and matched the entity definition. With this simplified behavior, the entity will be deleted as long as it was found given the required fields provided. For the message types referenced above, there is no longer a case that will return a mismatch error, e.g. "A type with the supplied ID and version already exists, but it does not match the supplied type."

Non-Breaking Change: Case Insensitivity for Type Id, Container Id, and Static Index

PI Web API 2021 SP3 relaxes the requirement that a provided Type Id, Container Id, or Static Index match in case with the value in the entity definition. For example, if a Static Type is defined with id WidgetType, a client can create a new static data instance of that type with the message field "typeid": "widgettype". This new behavior applies to all id, typeid, containerid, and index fields.

Note: In some rare cases an ambiguity may arise if the provided field value does not exactly match an existing entity, but does case-insensitvely match multiple entities. In that event, PI Web API will proceed with the first entity found and will return a warning level message in the response indicating an ambigous action was taken, e.g. "More than one static instance with the specified ID was found. Affected instance may not be the intended one." The exception to this is during DELETE operations in which case an error is returned and no action is taken.

Non-Breaking Change: Warning on Precision Loss

Precision loss may occur when converting values in OMF messages to their corresponding data types as defined in their type definition. For example, a decimal value with more digits than are supported by the float32 format. Previously this would result in an error status which could halt execution. In PI Web API 2021 SP3, precision loss detected while processing data values or property min/max values will instead result in a warning in the repsonse, but the action will proceed.

Non-Breaking Change: Container CREATE/UPDATE Does Not Overwrite Step If Not Specified

When creating or updating a CONTAINER, if the PI Point already exists on the server PI Web API will no longer overwrite the existing Step attribute of the point unless an interpolation value is specified in the message.

Non-Breaking Change: Container UPDATE Does Not Overwrite DataSource If Not Specified

When updating a CONTAINER, if the datasource field is not present in the message, PI Web API will no longer overwrite the existing PointSource attribute of the corresponding PI Point(s).

In This Topic
TitleResults for “How to create a CRG?”Also Available in