Get custom log data

GET/projects/{projectId}/entities/{entityId}/customLogs/{customLogDefinitionId}/data

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

Get the custom log data.

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 custom log, 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)
customLogDefinitionIdstringYesCustom log definition ID (unique within entity class).

Query parameters

NameTypeRequiredConstraintsDescription
beginstringYesThe beginning time of the data entries. The format follows RFC3339.
endstringYesThe end time of the data entries. The format follows RFC3339.
fieldsFilterstringNoA filter string starting with a conjunction. Supported conjunctions are AND() and OR(). A conjunction takes a comma-separated condition string like AND(group==="group_1",maxSpeed<5). Each condition string defines a filter for the field value. The left-hand side must be a valid field name. The right-hand side must be a value condition. For example, group==="group_1" matches any records that the group field value exactly matches "group_1". Supported operators are following: | Operator | | | --- | --- | | === | exact match | | == | substring match | | ~== | included in array as exact match. name~==["john"|"jeff"|"jack"] matches one of the three. | | ~= | included in array as substring match. name~=["j"|"e"] matches "john", "jeff", "jack", and "ethan". | | < | less than | | <= | less than or equal to | | > | greater than | | >= | greater than or equal to |
limitintegerNodefault: 1000; min: 1; max: 1000Maximum number of log records to return.
skipintegerNodefault: 0; min: 0Number of log records to skip over.
sortBystringNoThe sort order of the log records in the format field:order (e.g. timestamp:desc). Currently, only the timestamp field is supported. The default order is ascending.

Responses

200 The requested custom log records are returned.

Content type: application/json

PropertyTypeRequiredConstraintsDescription
beginstringNoread-only (server-generated)The begin time of data entries. The format follows RFC3339.
endstringNoread-only (server-generated)The end time of data entries. The format follows RFC3339.
limitintegerNoread-only (server-generated)The maximum number of data entries to be fetched.
recordsarray<object>Noread-only (server-generated)Log entries. Each entry is a log record object.
Properties of records
PropertyTypeRequiredConstraintsDescription
entryIdstringYesread-only (server-generated)Unique ID of the log record entry.
eventKeystringNoread-only (server-generated)Event key of the log record.
fieldsobjectYesread-only (server-generated)An object of key-value pairs containing the log data.
timestampstringYesread-only (server-generated)Time in RFC3339 format.
skipintegerNoread-only (server-generated)Number of data entries skipped over.
totalintegerNoread-only (server-generated)The total number of data entries for the query.

Response example

{
  "begin": "2022-03-01T00:00:00.000Z",
  "end": "2022-03-31T23:59:59.999Z",
  "limit": 1000,
  "records": [
    {
      "eventKey": "20220317012345678-1",
      "fields": {
        "result_code": "100",
        "tester_model": "MODE-123",
        "value": 0.3
      },
      "timestamp": "2022-03-17T01:23:45.678Z"
    },
    {
      "eventKey": "20220317012345678-2",
      "fields": {
        "result_code": "000",
        "tester_model": "MODE-123",
        "value": 0
      },
      "timestamp": "2022-03-18T01:23:45.678Z"
    }
  ],
  "skip": 0,
  "total": 210
}