From 43a2373f8512fc377d1dbb4b1102ab2c822b90c2 Mon Sep 17 00:00:00 2001 From: liushuyu Date: Mon, 26 Jun 2023 17:36:30 -0600 Subject: [PATCH] typings: add third-party typings for logdna-winston --- typings/logdna-winston/index.d.ts | 27 +++++++++++++++++++++++++++ 1 file changed, 27 insertions(+) create mode 100644 typings/logdna-winston/index.d.ts diff --git a/typings/logdna-winston/index.d.ts b/typings/logdna-winston/index.d.ts new file mode 100644 index 0000000..b09b4d1 --- /dev/null +++ b/typings/logdna-winston/index.d.ts @@ -0,0 +1,27 @@ +// Taken from https://github.com/efugulin/logdna-winston/blob/master/index.d.ts +import { ConstructorOptions } from 'logdna'; +import Transport from 'winston-transport'; + +declare class LogDNATransport extends Transport { + constructor(options: LogDNATransport.TransportOptions); +} + +declare namespace LogDNATransport { + interface TransportOptions + extends Transport.TransportStreamOptions, + ConstructorOptions { + /** The LogDNA API key. */ + key: string; + /** The name of this transport (default: "LogDNA"). */ + name?: string; + /** Level of messages that this transport should log (default: "debug"). */ + level?: string; + /** + * Allow meta objects to be passed with each line (default: false). + * See logger ConstructorOptions for more information. + */ + index_meta?: boolean; + } +} + +export = LogDNATransport;