Skip to main content
POST
/
api
/
sys
/
sensorhistories
/
runcommand
{
  "Status": 123,
  "Message": "<string>",
  "Value": {},
  "RedirectURL": "<any>",
  "UpdatedOn": "<string>",
  "UpdatedBy": "<string>",
  "Errors": "<any>",
  "WasSuccessful": true
}

Run command for SensorHistories

This endpoint lets you run a command for one or more Sensor History records.

Authentication

This endpoint requires OAuth2 authentication. Include a valid bearer token in the Authorization header.

Request Body

Key
string
required
The key for the command to execute.
Ids
array
required
The list of record identifiers (Id field) for the Sensor History records to execute this command for.
Parameters
array
required
If this command requires any parameters, the name and value for each of them.

Response

200

Status
integer
Example: 200
Message
string
Example: The command was run correctly.
Value
object
RedirectURL
any
UpdatedOn
string
Example: 2021-04-15T12:19:07Z
UpdatedBy
string
Example: john@example.com
Errors
any
WasSuccessful
boolean
Example: true
Example Response
{
  "Status": 200,
  "Message": "The command was run correctly.",
  "Value": {
    "Id": 10605
  },
  "RedirectURL": null,
  "UpdatedOn": "2021-04-15T12:19:07Z",
  "UpdatedBy": "john@example.com",
  "Errors": null,
  "WasSuccessful": true
}

Example Request

curl -X POST \
  "https://spaces.nexudus.com/api/sys/sensorhistories/runcommand" \
  -H "Authorization: Bearer YOUR_TOKEN" \
  -H "Content-Type: application/json" \
  -d '{}'