1.0.3 • Published 3 years ago

@mattnick/aws-timestream-easy v1.0.3

Weekly downloads
-
License
ISC
Repository
github
Last release
3 years ago

ATE (AWS Timestream Easy)

ATE is a Node library for simplifying AWS Timestream operations.

Installation

Use the package manager npm to install ATE.

npm install @mattnick/aws-timestream-easy

Usage

const ate = require('@mattnick/aws-timestream-easy');

async function test() {
  const query_string = 'SELECT * FROM "weather-DB"."weather-logs" ORDER BY time DESC LIMIT 10';
  const response = await ate.query(query_string);
  console.log(response);
}

test();
/*
response {
  error: null,
  results: [...]
}
*/

Results Structure

Result structures include any dimensions you set when writing the record to timestream. The data format of the measure_value is whatever you specified when writing the record to timestream.

[
  {
    "eventID": "3e384710-f19e-11eb-9a03-0242ac130003",
    "measure_name": "temperature",
    "measure_value": 98.6,
    "time": 1609462801,
    ...
  },
  {
    "eventID": "3e384710-f19e-11eb-9a03-0242ac130003",
    "measure_name": "wind_direction",
    "measure_value": "SSE",
    "time": 1609462801
  }
  ...
]

Supported Data Types

  • VARCHAR
  • INT
  • BIGINT
  • DOUBLE
  • TIMESTAMP
  • BOOLEAN
1.0.3

3 years ago

1.0.2

3 years ago

1.0.1

3 years ago

1.0.0

3 years ago