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 🙏

© 2025 – Pkg Stats / Ryan Hefner

@hpkv/rest-client

v1.0.1

Published

A NodeJS REST client for high-performance key-value store (HPKV)

Readme

HPKV REST Client

A NodeJs client for the high-performance key-value store (HPKV)

Features

  • High-performance key-value operations:
    • Set/Get records
    • Range queries
    • Atmoic Increment/Decrement
    • Partial updates
  • Semantic search and query capabilities:
    • Semantic search in records
    • Natural language querying records

PreRequisites

You need an HPKV API key. You can sign up and generate a free key here.

Find your HPKV API key and urls at HPKV Dashboard

Installation

npm install @hpkv/rest-client

Quick Start

import HPKVRestClient from '@hpkv/rest-client';

const client = new HPKVRestClient('your-hpkv-api-base-url', 'your-hpkv-nexus-api-base-url', 'your-api-key');

// Set a value
await client.set('my-key', 'my-value');

// Get a value
const result = await client.get('my-key');

// Store JSON
await client.set('user:1', {
  name: 'John Doe',
  email: '[email protected]',
});

// Partial update - updates the value of email and adds a new address property
await client.set(
  'user:1',
  {
    email: '[email protected]',
    address: 'John Doe address'
  },
  true
);

// Atomic Increment counter
const counter = await client.atomicIncrement('visits', 1);

// Range query 
const records = await client.range('start', 'end', 100);

// Semantic search
const searchResults = await client.nexusSearch('find John Doe''s information');

// AI-powered query
const answer = await client.nexusQuery('What is John Doe''s email address?');

API Reference

Constructor

new HPKVRestClient(baseUrl: string, nexusBaseUrl: string, apiKey: string)

Methods

set(key: string, value: unknown, partialUpdate?: boolean): Promise<RecordResponse>

Set a value for a key. If partialUpdate is true, the value will be appended to the existing. If the existing and new values are valid JSON, it performs an atomic JSON patching.

get(key: string): Promise<RecordResponse>

Get a value by key.

delete(key: string): Promise<RecordResponse>

Delete a key-value pair.

atomicIncrement(key: string, increment: number): Promise<RecordResponse>

Increment or decrement a numeric value atomically.

range(startKey: string, endKey: string, limit=100): Promise<RangeResponse>

Query records within a key range.

nexusSearch(query: string, options?: SearchOptions): Promise<SearchResponse>

Perform semantic search using Nexus Search.

nexusQuery(query: string, options?: QueryOptions): Promise<QueryResponse>

Get AI-generated answers using Nexus Query.

Read more

License

MIT