API DocsRESTView service

CreateView

Creates a view.

POST
/api/v1/views

Request Body

application/jsonRequired

viewIdstring

namestring

axisGroupsobject

channelsarray<object>

createdDatestring

Format: "date-time"

modifiedDatestring

Format: "date-time"

createdByUserIdstring

organizationIdstring

modifiedByUserIdstring

isPinnedboolean

curl -X POST "<API_URL>/api/v1/views" \
  -H "Authorization: Bearer <API_KEY>" \
  -H "Content-Type: application/json" \
  -d '{
    "viewId": "string",
    "name": "string",
    "axisGroups": {
      "left": [
        "string"
      ],
      "right": [
        "string"
      ]
    },
    "channels": [
      {
        "name": "string",
        "component": "string",
        "dataType": "string",
        "axisGroup": "string",
        "bitFieldNames": [
          "string"
        ],
        "calculatedChannelConfig": {
          "channelKey": "string",
          "channelReferences": {
            "property1": {
              "name": "string",
              "component": "string"
            },
            "property2": {
              "name": "string",
              "component": "string"
            }
          },
          "expression": "string",
          "unit": "string"
        }
      }
    ],
    "createdDate": "2019-08-24T14:15:22Z",
    "modifiedDate": "2019-08-24T14:15:22Z",
    "createdByUserId": "string",
    "organizationId": "string",
    "modifiedByUserId": "string",
    "isPinned": true
  }'

A successful response.

{
  "view": {
    "viewId": "string",
    "name": "string",
    "axisGroups": {
      "left": [
        "string"
      ],
      "right": [
        "string"
      ]
    },
    "channels": [
      {
        "name": "string",
        "component": "string",
        "dataType": "string",
        "axisGroup": "string",
        "bitFieldNames": [
          "string"
        ],
        "calculatedChannelConfig": {
          "channelKey": "string",
          "channelReferences": {
            "property1": {
              "name": "string",
              "component": "string"
            },
            "property2": {
              "name": "string",
              "component": "string"
            }
          },
          "expression": "string",
          "unit": "string"
        }
      }
    ],
    "createdDate": "2019-08-24T14:15:22Z",
    "modifiedDate": "2019-08-24T14:15:22Z",
    "createdByUserId": "string",
    "organizationId": "string",
    "modifiedByUserId": "string",
    "isPinned": true
  }
}