3 Minute Read

| HisWrite Many 

The HisWrite many  API is used to write more than one value at a time to any particular historized data point. 

The hisWriteMany is an operation in the spirit of the Project Haystack hisWrite Op. This operation, however, lets a client write timestamped data for multiple points within the same request.

This API provides operations for writing operational data to writable points as well as historizing data for any point type.

| Request

Request Headers

Parameter Name Required Type Description
true   String array
Accept False   Contains the JWT provided by the auth endpoint. The format of the header value is Bearer JWT_TOKEN
Authorization True    
Ocp-Apim-Subscription-Key true   Product-scoped subscription key


| Response

200 OK

Empty Haystack Grid



| Procedure to Execute a Hiswrite Many API requests

Note: Only as a Secondary Manager of a site, one can sample points data or write to points data of the sites. 

 From the Developer portal home page

  • Click the Profile option.


The user profile screen displays, the user details, and the details related to the subscriptions subscribed for.

Under the products subscribed for, locate the subscription key for the relevant product.

For this example, we use the product Staging Readwrite subscription.

  • Click the option shown to view the subscription keys or simply copy the subscription key to be used to generate the Bearer token.


  • Click the API's option on the top.

The API's screen displays the list of authorized API's.

For this demo, we use the Haystack Write(Staging) API.

  • Click the API Haystack (Staging).


The Haystack Write (Staging) API screen displays the API details.

Note: To start sampling data using this Haystack write (Staging) API, the user needs to generate a bearer token using the API 75Auth {Staging) as shown above using the information shown in Oauth API

  • Click Try it to access the API.


The Try it window to try the API, displays.

  • Select the Primary: Staging Readwrite under the subscription key field.


  • Access the site explorer in the Facilisight to locate a point and its value to be changed.

From the site explorer in Facilisight:

  • Locate a point in the site for which you would like to write a value.


  • Locate the point values and Timestamps in Query Assist, at which a new value had to be posted.


  • Scroll further to locate the Header section.

The header section should have the following headers.


  • Enter the write query required for this API in the format specified in the body section, as shown above.
  • Paste the subscription key copied from the profile screen, into the header option Ocp-Apim-Subscription-Key.
  • Paste the bearer token generated, into the header option Authorization, in the format shown above, with "Bearer", and followed by the token generated.


With the below request format and quern:


  • Click Send to post the value change.

The portal generates the response as follows.

| HTTP response

HTTP/1.1 200 OK

content-encoding: gzip
content-type: text/zinc
date: Thu, 05 May 2022 10:43:29 GMT
transfer-encoding: chunked
vary: origin,access-control-request-method,access-control-request-headers,accept-encoding


The values posted in the historized data. (Confirmed below from the Query Assist)


You can see above; The changed values 71.5 and 72 for the API call.




Please sign in to leave a comment.

Was this article helpful?

0 out of 0 found this helpful
Powered by Zendesk