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

auralogs-sdk

v1.0.1

Published

Agentic logging and application awareness. Simplified.

Readme

auralogs-sdk

JavaScript/TypeScript SDK for Auralogs — agentic logging and application awareness.

Auralogs acts as an on-call engineer — powered by your choice of model (Claude, OpenAI, or any MCP-compatible LLM) — monitoring your logs and errors, alerting you when something's wrong, and opening fix PRs automatically.

npm version provenance verified license

Install

npm install auralogs-sdk

Quick start

import { auralogs, init } from "auralogs-sdk";

init({
  apiKey: process.env.AURALOG_API_KEY!,
  environment: "production",
  captureConsole: true,  // forward console.* to Auralogs
  captureErrors: true,   // capture uncaught errors (default: true)
});

auralogs.info("user signed in", { userId: "123" });
auralogs.error("payment failed", { orderId: "abc" });

Configuration

| Option | Type | Default | Description | |---|---|---|---| | apiKey | string | required | Your Auralogs project API key | | environment | string | required | e.g. "production", "staging", "dev" | | endpoint | string | https://ingest.auralogs.ai | Ingest endpoint override. Must be https:// unless allowInsecureEndpoint is set. | | allowInsecureEndpoint | boolean | false | Permit http:// endpoints (e.g. http://localhost:8080 for local dev). Off by default — a plaintext endpoint would leak the API key on the wire. | | flushInterval | number | 5000 | Ms between batched flushes | | maxQueueSize | number | 1000 | Max buffered log entries before the SDK drops the oldest. Bounds memory if the ingest endpoint is unreachable. | | captureConsole | boolean | false | Forward console.* calls | | captureErrors | boolean | true | Capture uncaught errors and unhandled rejections | | traceId | string | auto-generated | Custom trace ID for distributed tracing | | globalMetadata | Record<string, unknown> or () => Record<string, unknown> | undefined | Baseline metadata merged into every log entry — including captureConsole and captureErrors entries. Per-call metadata wins on key collision (shallow merge). |

Attaching session-scoped fields to every log

Use globalMetadata to attach things like user_id, org id, or feature-flag snapshots to every log Auralogs emits — including console.* captures and uncaught errors. The supplier form is the canonical recipe because it's evaluated at log time, so it always sees the current host state:

import { auralogs, init } from "auralogs-sdk";

init({
  apiKey: process.env.AURALOG_API_KEY!,
  environment: "production",
  captureConsole: true,
  captureErrors: true,
  globalMetadata: () => ({
    user_id: currentUser?.id,
    org_id: currentUser?.orgId,
  }),
});

auralogs.info("checkout started");
// metadata: { user_id: "...", org_id: "..." }

auralogs.info("admin impersonating", { user_id: "impersonated-id" });
// per-call wins: { user_id: "impersonated-id", org_id: "..." }

A few caveats:

  • Sync only. The supplier must return synchronously. If it returns a Promise (or any thenable), Auralogs drops globalMetadata for that entry, warns once, and ships the entry without it. Cache async state on the sync side (e.g. in a context-local) before reading it here.
  • Keep it cheap. The supplier runs on every log emission. Avoid I/O or expensive computation.
  • If it throws or produces a non-serializable value, the entry is still delivered — just without globalMetadata. Auralogs warns once per logger instance and stays silent thereafter.

Graceful shutdown

import { shutdown } from "auralogs-sdk";

process.on("SIGTERM", async () => {
  await shutdown();  // flushes pending logs
  process.exit(0);
});

Documentation

Full docs at docs.auralogs.ai.

Verify this package

Every release is published with sigstore provenance attestations built directly in GitHub Actions. The attestation proves the tarball was built from a specific commit in this repository via .github/workflows/release.yml — without having to trust npm or the maintainer.

To verify in your own project:

npm audit signatures

Or inspect the attestation on npmjs.com/package/auralogs-sdk under "Provenance".

Security

Found a vulnerability? See SECURITY.md for how to report it.

License

MIT © James Thomas