Preparing Viewable Object for Display - Intergraph Smart API Manager - 2020 (4.0) - Help

Intergraph Smart API Manager Help

Language
English
Product
Intergraph Smart API Manager
Search by Category
Help
Smart API Manager Version
4.0

Some viewable object resources need to be prepared before the display. For example, a workspace needs to evaluate the underlying parametric filter and build a new working set (collection of graphic IDs). Smart APIs provide an OData action and a corresponding OData function to prepare the viewable object for display:

  • PrepareViewableObject – Call this OData action to prepare a viewable object for display.

  • GetPrepareViewableObjectAsync – Call this OData function to monitor the viewable object preparation process. This is relevant only if PrepareViewableObject action is called asynchronously.

Here are the sample URLs you can use to start and monitor the viewable object preparation defined for the SampleService:

OData actions are called with HTTP POST.

  • POST https://sam.spclouddave.com/sampleservice/sppid/v3/Sites('Site A')/Plants('Plant A')/Pipes('302')/Files('Primary 302')/Com.Ingr.Core.V1.ViewableObject/Com.Ingr.Core.V1.PrepareViewableObject

    The Com.Ingr.Core.V1.PrepareViewableObject action does not have any parameters, therefore you can post an empty request body.

    The result of this action execution is a JSON object that contains the base service URI and the relative resource URI that can be used to uniquely identify the viewable object resource within this Smart API.

  • GET https://sam.spclouddave.com/sampleservice/sppid/v3/Sites('Site A')/Plants('Plant A')/Pipes('302')/Files('Primary 302')/Com.Ingr.Core.V1.ViewableObject/Com.Ingr.Core.V1. GetPrepareViewableObjectResultAsync(resultId='435aa787-444a-4a01-a6da-f6cc9b37b1a5')

The URI to get the file preparation result shown is just an example. The URI represents a status monitor resource returned as an HTTP Location header in the response when PrepareViewableObject is called asynchronously. See Asynchronous support for full details.