New:Introducing Socket Scanning for VS Code Marketplace Extensions.Learn more →
Get Started

koa-datadog

Package Overview
Dependencies
Maintainers
1
Versions
11
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

koa-datadog

Datadog middleware for Koa

latest
Source
npmnpm
Version
0.7.0
Version published
Maintainers
1
Created
Source

koa-datadog

Datadog middleware for Koa

This is a fork of node-connect-datadog with modifications for Koa.

Usage

Add middleware immediately before your router.

import koaDatadog from 'koa-datadog';
import Koa from 'koa';

const app = new Koa();
app.use(koaDatadog({}));

Options

All options are optional.

  • dogstatsd hot-shots client. default = new require("hot-shots")()
  • stat string name for the stat. default = "node.express.router"
  • tags array of tags to be added to the histogram. default = []
  • routeboolean include route tag (koa-route and koa-router are supported). default = false.
  • path boolean include path tag. default = false
  • method boolean include http method tag. default = false
  • protocol boolean include protocol tag. default = false
  • response_code boolean include http response codes. default = false
  • delim string char to replace pipe char with in the route default = '-'

License

View the LICENSE file.

Keywords

datadog

FAQs

Package last updated on 08 Feb 2023

Related posts