Get entity instance

GET/projects/{projectId}/entities/{entityId}

Base URL: https://api.tinkermode.com

Get the specified entity instance.

Authentication

Send an Authorization header of the form ModeCloud <AUTH_CODE>.

Must contain a user API key of a user with permission to read the entity instance, a service account token with the same permission, or a project API key.

Path parameters

NameTypeRequiredConstraintsDescription
projectIdintegerYesThe unique ID for a specified project.
entityIdstringYesEntity ID (unique within project)

Responses

200 Successful retrieval of entity instance.

Content type: application/json

PropertyTypeRequiredConstraintsDescription
attributesobjectNoThe attributes that belong to the entity instance, separated as key-value pairs.
createdAtstringNoread-only (server-generated); format: date-timeTimestamp of entity creation.
displaySettingsobjectNoVarious user interface settings used for display of the entity instance.
Properties of displaySettings
PropertyTypeRequiredConstraintsDescription
descriptionstringNoAn intuitive description for the entity instance for display.
iconDataobjectNoMetadata used for the uploaded icon of the entity instance.
Properties of iconData
PropertyTypeRequiredConstraintsDescription
fileNamestringNoFileName represents the name of the file uploaded.
urlstringNoA temporary signed URL for file download.
imageDataobjectNoMetadata used for the uploaded image of the entity instance.
Properties of imageData
PropertyTypeRequiredConstraintsDescription
fileNamestringNoFileName represents the name of the file uploaded.
urlstringNoA temporary signed URL for file download.
namestringNoThe display name for the entity instance.
entityClassstringYesread-only (server-generated)The entity class that the entity was instantiated from.
entityIdstringYesread-only (server-generated)Unique entity ID.
homeIdintegerYesread-only (server-generated)Home that this entity belongs to.
metricsarray<object>Noread-only (server-generated)Meta data of the metrics associated with this entity instance.
Properties of metrics
PropertyTypeRequiredConstraintsDescription
metricsDefinitionIdstringNoCorresponding metrics definition ID in entity class.
parentIdstringNoThe ID of the entity instance that is a parent of the instance.
projectIdintegerYesread-only (server-generated)Project that this entity belongs to.
suspendAlertRuleEvaluationConditionsarray<object>NoAn array of condition for suspending alerts, which are evaluated as if they are concatenated with OR
Properties of suspendAlertRuleEvaluationConditions
PropertyTypeRequiredConstraintsDescription
alertConditionTypesarray<string>NoAn array of alert condition types. This allows suspending alerts based on the alert types. All rules of the specified condition type will be suspended.
fromstringNoformat: date-timeTimestamp of the begin of the interval. Null applies this rule without this time constrains
includeDescendantsbooleanNoBoolean value that shows whether alert rules are suspended for only this entity or this entity and descendants
rulesarray<number>NoAn array of alertRuleId. Empty array means all rules
tostringNoformat: date-timeTimestamp of the end of the interval. Null applies this rule without this time constrains
timeZonestringYesread-only (server-generated)The time zone that the entity exists in. This should be a time zone name defined in the IANA TZ Database.
uiSettingsobjectNoAn opaque object used by UI applications to store any additional settings. These will override the entity class uiSettings.
updatedAtstringNoread-only (server-generated); format: date-timeTimestamp of the last update on the entity.

Response example

{
  "attributes": {
    "group": "samsung_freezer_model_4",
    "minTemperatureCelsius": -40.2
  },
  "createdAt": "2021-09-02T22:19:39Z",
  "displaySettings": {
    "description": "A warehouse freezer in warehouse room #003.",
    "iconData": {
      "fileName": "freezer_icon.png",
      "url": "https://example.com/icons/freezer_icon.png"
    },
    "imageData": {
      "fileName": "freezer.png",
      "url": "https://example.com/images/freezer.png"
    },
    "name": "Warehouse Freezer 001"
  },
  "entityClass": "warehouse_freezer",
  "entityId": "warehouse_freezer_001",
  "homeId": 5,
  "parentId": "warehouse_room_003",
  "projectId": 1,
  "timeZone": "Europe/Berlin",
  "updatedAt": "2021-09-02T22:19:39Z"
}

401 Authorization is required to access this resource.

Content type: application/json

PropertyTypeRequiredConstraintsDescription
dataobjectNoread-only (server-generated)Any relevant data related to error.
reasonstringYesread-only (server-generated)Reason of error.

403 Request failed because of denied permission.

Content type: application/json

PropertyTypeRequiredConstraintsDescription
dataobjectNoread-only (server-generated)Any relevant data related to error.
reasonstringYesread-only (server-generated)Reason of error.

404 The requested entity does not exist or is not accessible.

Content type: application/json

PropertyTypeRequiredConstraintsDescription
dataobjectNoread-only (server-generated)Any relevant data related to error.
reasonstringYesread-only (server-generated)Reason of error.

429 Request failed because of rate limit.

Content type: application/json

PropertyTypeRequiredConstraintsDescription
dataobjectNoread-only (server-generated)Any relevant data related to error.
reasonstringYesread-only (server-generated)Reason of error.

500 An unexpected error has occurred.

Content type: application/json

PropertyTypeRequiredConstraintsDescription
dataobjectNoread-only (server-generated)Any relevant data related to error.
reasonstringYesread-only (server-generated)Reason of error.

503 The service is temporarily unavailable.

Content type: application/json

PropertyTypeRequiredConstraintsDescription
dataobjectNoread-only (server-generated)Any relevant data related to error.
reasonstringYesread-only (server-generated)Reason of error.