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

@journiq/node-sdk

v0.3.3

Published

Journiq Server-Side Node.js SDK — deep linking, event tracking, user identity, and notifications

Downloads

82

Readme

Installation

npm install @journiq/node-sdk

Quick Start

import { Journiq } from '@journiq/node-sdk';

const journiq = new Journiq({
  apiKey: 'jq_app_your_secret_key',
});

// Create a deep link
const link = await journiq.links.create({
  title: 'Summer Sale',
  redirectUrl: 'https://yourapp.com/sale',
  data: { promoCode: 'SUMMER25' },
});

// Track an event
await journiq.events.track({
  userId: 'user_123',
  event: 'purchase',
  properties: { amount: 49.99, currency: 'USD' },
});

API Keys

| Key Prefix | Type | Access | |---|---|---| | jq_pub_ | Public | Events, Users, Notifications | | jq_app_ | Secret | Full access (includes Links CRUD) |

Secret keys should only be used server-side. Never expose them in client code.

API Reference

Links (requires secret key)

// Create
const link = await journiq.links.create({ title: 'My Link', redirectUrl: 'https://example.com' });

// List
const { data, total } = await journiq.links.list({ page: 1, limit: 20 });

// Get by ID
const link = await journiq.links.get('link_id');

// Update
const updated = await journiq.links.update('link_id', { title: 'New Title' });

// Delete
await journiq.links.delete('link_id');

// Get stats
const stats = await journiq.links.getStats('link_id');

Events

// Track single event
await journiq.events.track({
  userId: 'user_123',
  event: 'sign_up',
  properties: { plan: 'pro' },
});

// Track batch
const result = await journiq.events.trackBatch([
  { userId: 'user_1', event: 'page_view', properties: { page: '/home' } },
  { userId: 'user_2', event: 'page_view', properties: { page: '/pricing' } },
]);

Users

// Set identity
await journiq.users.setIdentity({ userId: 'user_123', deviceId: 'device_abc' });

// Remove identity
await journiq.users.removeIdentity({ userId: 'user_123', deviceId: 'device_abc' });

// Set user properties
await journiq.users.setProperties({
  userId: 'user_123',
  properties: { name: 'John', plan: 'enterprise' },
});

Notifications

// List notifications
const { notifications, total } = await journiq.notifications.list({
  userId: 'user_123',
  unreadOnly: true,
  limit: 10,
});

// Mark as read
await journiq.notifications.markRead('notification_id', 'user_123');

// Get unread count
const { count } = await journiq.notifications.getUnreadCount('user_123');

Configuration

const journiq = new Journiq({
  apiKey: 'jq_app_xxx',
  baseUrl: 'https://api.getjourniq.com', // default
});

Error Handling

import { JourniqError, SecretKeyRequiredError } from '@journiq/node-sdk';

try {
  await journiq.links.create({ title: 'Test', redirectUrl: 'https://example.com' });
} catch (err) {
  if (err instanceof SecretKeyRequiredError) {
    // Called a secret-key-only method with a public key
  } else if (err instanceof JourniqError) {
    console.error(err.status, err.message);
  }
}

Requirements

  • Node.js 18+

License

MIT