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

@visionfi/server-sdk

v1.4.0

Published

Server-side SDK for VisionFI API access using Google Service Account authentication

Readme

@visionfi/server

Server-side SDK for VisionFI API access using Google Service Account authentication.

Installation

npm install @visionfi/server

Quick Start

import { VisionFi } from '@visionfi/server';

// Initialize with service account
const client = new VisionFi({
  serviceAccountPath: './service-account.json'
});

// Or use Application Default Credentials
const client = new VisionFi();

// Verify authentication
const auth = await client.verifyAuth();

// Create a package
const pkg = await client.createPackage({
  productType: 'consumer_loan_vehicle',
  description: 'Vehicle loan application'
});

// Analyze a document
const job = await client.analyzeDocument(fileBuffer, {
  fileName: 'document.pdf',
  analysisType: 'auto_loan_abstract'
});

// Get results
const results = await client.getResults(job.uuid);

Authentication

This package supports three authentication methods:

  1. Service Account File: Provide path to JSON key file
  2. Service Account JSON: Pass JSON object directly
  3. Application Default Credentials: Automatic in GCP environments

Features

  • Document analysis and processing
  • Package management
  • Package sharing with role-based permissions
  • DocuSign integration
  • Workflow management
  • Processing history and results
  • Per-request custom headers for B2B2C scenarios

Package Sharing

The SDK supports sharing packages with other users with role-based permissions.

Share a Package

// Share with specific users
await client.packages.sharing.addShares('package-uuid', [
  { target: '[email protected]', role: 'editor' },
  { target: '[email protected]', role: 'viewer' }
]);

// Share with all users in your organization
await client.packages.sharing.addShares('package-uuid', [
  { target: 'AllUsers', role: 'viewer' }
]);

Update Share Role

await client.packages.sharing.updateRole('package-uuid', '[email protected]', 'viewer');

Remove a Share

await client.packages.sharing.remove('package-uuid', '[email protected]');

Get Sharing Info (Owner Only)

const info = await client.packages.sharing.getInfo('package-uuid');
// { packageId, owner, shares: [{ target, role }] }

List Packages Shared With Me

const shared = await client.packages.listShared();
// { packages: [{ packageId, owner, myRole, sharedVia, ... }], total }

List All Accessible Packages

// List only owned packages (default)
const owned = await client.packages.list();

// List only shared packages
const shared = await client.packages.list({ include: 'shared' });

// List all accessible packages (owned + shared)
const all = await client.packages.list({ include: 'all' });

Per-Request Custom Headers

All SDK methods support an optional requestOptions parameter that allows you to pass custom headers on a per-request basis. This is useful for B2B2C scenarios where you need to identify the end-user making the request.

Example: Passing End-User Identity

import { VisionFi } from '@visionfi/server';

const client = new VisionFi();

// Pass end-user identity via VF-On-Behalf-Of header
const packages = await client.packages.list(
  { productTypes: 'consumer_loan_vehicle' },
  { headers: { 'VF-On-Behalf-Of': '[email protected]' } }
);

// Works with all SDK methods
const pkg = await client.packages.get(
  'package-uuid',
  { headers: { 'VF-On-Behalf-Of': '[email protected]' } }
);

// Create package on behalf of user
const newPkg = await client.packages.create(
  { productType: 'consumer_loan_vehicle' },
  { headers: { 'VF-On-Behalf-Of': '[email protected]' } }
);

// Execute processing on behalf of user
const result = await client.packages.processing.execute(
  'package-uuid',
  { workflow: 'auto_loan_abstract' },
  { headers: { 'VF-On-Behalf-Of': '[email protected]' } }
);

Protected Headers

For security, the following headers cannot be overridden per-request and will be stripped:

  • authorization - Managed by SDK authentication
  • host - Managed by axios
  • x-api-key - Managed by SDK configuration

License

Copyright (c) 2024-2025 VisionFI. All Rights Reserved.

See LICENSE file for details.