Lightweight SDK to access Datadog API
Install with npm:
$ npm install --save datadog-light
const Datadog = require('datadog-light');
const dd = Datadog('DATADOG_API_KEY');
dd.DistributionMetric.enqueue('metric.name', [new Date() / 1]);
dd.DistributionMetric.flush();
All input is validated using Joi.
Initialize this sdk with a Datadog api key. Provided tags are sent with all metrics without having to specify them again.
Enqueue distribution metric counts
Flush all metric events currently enqueued.
This package was built to be used in serverless environments where state is hard to come by. Convenient when e.g. tracking certain actions within an AWS Lambda function.