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

@a5omic/veil

v0.1.0

Published

Official JavaScript helpers for the hosted Veil API

Readme

Veil Examples

Examples and the official JavaScript helpers for integrating with the hosted Veil API.

Veil lets you send prompts through a privacy layer before they reach OpenAI or another provider. Sensitive data is redacted on the way out and restored on the response back.

This repo is intentionally public and intentionally limited:

  • It shows how to use Veil
  • It does not include Veil's backend or internal implementation

Why Veil

  • Keep names, emails, phone numbers, SSNs, and other sensitive values out of upstream LLM requests
  • Keep your existing provider and model choices
  • Use an OpenAI-compatible API surface
  • Start with a hosted product instead of building your own redaction layer

Start Free

Install the JS Package

npm install @a5omic/veil openai

Get Started

  1. Sign up at veil-api.com
  2. Get a Veil API key
  3. Keep your own upstream provider key
  4. Point your client at https://veil-api.com/v1

Required Headers

  • Authorization: Bearer <VEIL_API_KEY>
  • x-upstream-key: <YOUR_PROVIDER_KEY>
  • Optional: x-upstream-provider: openai|groq|together|mistral|...

Environment Variables

export VEIL_API_KEY=your_veil_key
export OPENAI_API_KEY=your_provider_key

Quick Example: Python

from openai import OpenAI
import os

client = OpenAI(
    api_key=os.environ["OPENAI_API_KEY"],
    base_url="https://veil-api.com/v1",
    default_headers={
        "Authorization": f"Bearer {os.environ['VEIL_API_KEY']}",
        "x-upstream-key": os.environ["OPENAI_API_KEY"],
    },
)

response = client.chat.completions.create(
    model="gpt-4o-mini",
    messages=[
        {
            "role": "user",
            "content": "Summarize: Customer Jane Doe ([email protected]) called from 555-123-4567.",
        }
    ],
)

print(response.choices[0].message.content)

Quick Example: JavaScript

import OpenAI from 'openai';
import { createVeilOpenAIConfig } from '@a5omic/veil';

const client = new OpenAI(createVeilOpenAIConfig({
  veilApiKey: process.env.VEIL_API_KEY,
  upstreamApiKey: process.env.OPENAI_API_KEY,
}));

const response = await client.chat.completions.create({
  model: 'gpt-4o-mini',
  messages: [
    {
      role: 'user',
      content: 'Summarize: Customer Jane Doe ([email protected]) called from 555-123-4567.',
    },
  ],
});

console.log(response.choices[0].message.content);

Redact-Only Example: JavaScript

import { VeilClient } from '@a5omic/veil';

const veil = new VeilClient({
  apiKey: process.env.VEIL_API_KEY,
});

const result = await veil.redact({
  text: 'admit date: 03/15/2024, patient age: 92, MRN: AB123456',
  compliance: 'hipaa',
});

console.log(result);

Quick Example: cURL

curl -X POST https://veil-api.com/v1/chat/completions \
  -H "Authorization: Bearer $VEIL_API_KEY" \
  -H "x-upstream-key: $OPENAI_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{
    "model": "gpt-4o-mini",
    "messages": [
      {
        "role": "user",
        "content": "Summarize: Customer Jane Doe ([email protected]) called from 555-123-4567."
      }
    ]
  }'

Example Files

Compliance Modes

  • x-veil-compliance: hipaa and x-veil-compliance: coppa are available on Growth+ plans.
  • Compliance mode adds stricter redaction plus audit logging for regulated text workflows.
  • Compliance mode is intentionally text-only today and does not support streaming or multimodal image/audio requests.

Docs

Hosted Product

Veil is a hosted API product. This repo is examples-only and does not include the private backend, infrastructure, detection pipeline, or internal operations code.

If you want to use Veil in production, start here: