2. HTTP Properties

Accept Property

The response is serialized to either XML (default) or JSON, and this is controlled by theĀ AcceptĀ property in the HTTP header.

Note!

If the Accept property is not set, the response will be serialized as XML. To change serialization format to JSON, set the property value to application/json.

See the following curl command example:

$ curl -H 'Accept:application/json' http://localhost:9000/webapi/
v1/picos/ec1 -u mzadmin:dr

Authorization Property

The Web API uses basic authenticationĀ and the login information is passed to the Ā system by setting the Authorization property in the HTTP header.

Note!

All http client libraries should have support for setting the Authorization property in the HTTP header. See the following curl command example for how to set authorization:

$ curl http://localhost:9000/webapi/v1/picos/ec1 -u mzadmin:dr

TheĀ status information is updated in 5 second intervals, which is considered a sufficient resolution since it usually takes some time before workflows are up and running in full capacity.