npm package discovery and stats viewer.

Discover Tips

  • General search

    [free text search, go nuts!]

  • Package details

    pkg:[package-name]

  • User packages

    @[username]

Sponsor

Optimize Toolset

I’ve always been into building performant and accessible sites, but lately I’ve been taking it extremely seriously. So much so that I’ve been building a tool to help me optimize and monitor the sites that I build to make sure that I’m making an attempt to offer the best experience to those who visit them. If you’re into performant, accessible and SEO friendly sites, you might like it too! You can check it out at Optimize Toolset.

About

Hi, 👋, I’m Ryan Hefner  and I built this site for me, and you! The goal of this site was to provide an easy way for me to check the stats on my npm packages, both for prioritizing issues and updates, and to give me a little kick in the pants to keep up on stuff.

As I was building it, I realized that I was actually using the tool to build the tool, and figured I might as well put this out there and hopefully others will find it to be a fast and useful way to search and browse npm packages as I have.

If you’re interested in other things I’m working on, follow me on Twitter or check out the open source projects I’ve been publishing on GitHub.

I am also working on a Twitter bot for this site to tweet the most popular, newest, random packages from npm. Please follow that account now and it will start sending out packages soon–ish.

Open Software & Tools

This site wouldn’t be possible without the immense generosity and tireless efforts from the people who make contributions to the world and share their work via open source initiatives. Thank you 🙏

© 2026 – Pkg Stats / Ryan Hefner

@badmachine/influxdb3-napi

v1.0.10

Published

Influxdb3 client written in rust and built for nodejs with napi-rs

Downloads

10

Readme

influxdb3-napi

High-performance Node.js client for InfluxDB 3.0 with native Rust bindings, supporting both read and write operations.

Installation

npm install @badmachine/influxdb3-napi

Features

  • High Performance - Native Rust bindings for optimal performance
  • SQL Queries - Execute SQL queries with async iterator support
  • Line Protocol Writing - Write data using InfluxDB line protocol
  • TypeScript Support - Full TypeScript definitions included
  • Type Safe - Built with type safety in mind

Why?

  • This library was initially inspired by the need to handle edge cases where other libraries fail to decode certain Arrow Flight data types (see InfluxCommunity/influxdb3-js#590). It correctly supports all data types returned by InfluxDB.
  • Unlike this library, some requests to https hosts were failing with other JS libraries due to self-signed certificate check errors
  • ~~Blazingly™~~ Much faster than other libraries when querying the data.
  • Includes three different serializers for maximum flexibility:
    • Default serializer — conveniently converts time intervals.
    • Serde-based serializer — leverages serde for basic json serialization.
    • Raw serializer — returns the raw byte array buffer.

Quick Start

import { InfluxDbClient, Point } from '@badmachine/influxdb3-napi';

// Initialize client
const client = new InfluxDbClient(
  'http://your-influxdb-host:8086',
  'your-api-token'
);

// Write data using Point builder
const point = Point.fromMeasurement('temperature')
  .setTag('location', 'office')
  .setTag('sensor', 'temp01')
  .setBooleanField('active', true)
  .setFloatField('value', 23.5);

const lineProtocol = point.toLineProtocol('ns');
await client.write([lineProtocol], 'your-database');

// Query data with async iteration
const result = client.query({
  database: 'your-database',
  query: 'SELECT * FROM temperature WHERE time > now() - 1h',
  type: 'sql'
});

// Stream results efficiently
for await (const row of result) {
  console.log(row);
}

TypeScript Support

Full TypeScript definitions are included:

Contributing

Contributions are welcome! Please read our contributing guidelines and submit pull requests to our repository.

License

MIT License - see LICENSE file for details.

Support

Changelog

See CHANGELOG.md for version history and changes.