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

credlibkit

v1.0.0

Published

The Web Analytics SDK enables comprehensive collection of browser telemetry, device information, and fraud detection metrics from web applications while maintaining user privacy and compliance.

Readme

CredLibKit: MobileGator Web Analytics SDK

The Web Analytics SDK enables comprehensive collection of browser telemetry, device information, and fraud detection metrics from web applications while maintaining user privacy and compliance.

Requirements

The Web SDK works on Google Chrome, Safari, Firefox, Opera and other popular modern browsers.

Adding Dependency

Add the SDK to your application using one of the following methods.

NPM/Yarn

Fetch using npm -

npm install credlibkit

Fetch using yarn -

yarn add credlibkit

Import the sync functions from fetched module -

import { syncWebData } from "credlibkit";

Implement data fetch by importing the syncWebData function in your JavaScript code -

import { syncWebData } from "credlibkit";
import { useEffect } from "react";

const App = () => {
	useEffect(() => {
		const fetchData = async () => {
			try {
				const result = await syncWebData("<user_id>", "<client_id>", "<secret_key>");

				if (result) {
					// Data collection successful
					console.log("Sync successful:", result);
				} else {
					// Data collection failed
					console.log("Sync failed");
				}
			} catch (error) {
				// Handle errors
				console.error("SDK Error:", error);
			}
		};

		fetchData();
	}, []);

	return <div>App</div>;
};

export default App;

CDN Integration

Import the SDK from NPM CDN -

<script src="https://cdn.jsdelivr.net/npm/credlibkit@1/dist/web-sdk.min.js"></script>

Implement data fetch by embedding CDN in HTML -

<!DOCTYPE html>
<html lang="en">
	<head>
		<meta charset="UTF-8" />
		<meta name="viewport" content="width=device-width, initial-scale=1.0" />
		<title>Web SDK Data Display</title>
	</head>
	<body>
		<script src="https://cdn.jsdelivr.net/npm/credlibkit@1/dist/web-sdk.min.js"></script>

		<script>
			const fetchData = async () => {
				try {
					const response = await credLibKit.syncWebData("<user_id>", "<client_id>", "<secret_key>");
					console.log("In HTML Client File-Fetched data:", response);
				} catch (error) {
					console.error("In HTML Client File-Error fetching data:", error);
				}
			};

			fetchData();
		</script>
	</body>
</html>

Note:

Following credentials will be shared by the Credeau team at the time of integration -

  • CLIENT_ID
  • SECRET_KEY

Function Reference

Sync Web Data

To collect and synchronize comprehensive browser and device data, call the syncWebData method with the following -

syncWebData(user_id, client_id, secret_key,​base_url)

Parameters

| Parameter | Type | Required | Description | | ---------- | ------ | -------- | ------------------------------------------------------------- | | user_id | string | Yes | Unique identifier for the user | | client_id | string | Yes | Your application's client identifier | | secret_key | string | Yes | Authentication key for API access | | base_url | string | No | Custom API endpoint (default: https://devicesync.credeau.com) |

Note:

user_id must be -

  • Alphanumeric (no special characters)
  • Should not exceed 64 characters
  • A non-empty / non-null value

Returns

Returns a Promise that resolves to an object containing all collected data, or null if an error occurs.

Response schema -

{
    user_id: "user123",
    client_id: "client456",
    app_device_id: "unique_device_id",
    sync_id: "sync_identifier",
    sdk_version: "1.0.0",
    sync_request_id: "uuid",

    // Location
    latitude: 37.7749,
    longitude: -122.4194,
    accuracy: 10,
    timezone: "America/Los_Angeles",

    // Browser
    browserName: "Chrome",
    os: "Windows 10",
    language: "en-US",
    platform: "Win32",
    vendor: "Google Inc.",
    browser_fingerprint: "hash_value",

    // Hardware
    screenResolution: "1920x1080",
    deviceMemory: 8,
    logicalProcessors: 8,
    maxTouchPoints: 0, touchSupport: false,
    batteryLevel: 0.85,
    batteryCharging: true,

    // Performance
    uptimeMs: 1234567,

    // Storage
    storageUsed: 1024000,
    storageTotal: 2048000,
    localStorageAvailable: true,
    sessionStorageAvailable: true,
    indexedDBAvailable: true,

    // Media
    audioInputs: 1,
    videoInputs: 1,
    videoCard: "NVIDIA GeForce GTX 1060",

    // Security
    incognito: false,
    hasAutomationTools: false,
    isHeadless: false,
    resistFingerprinting: false,
    hasPrivacyExtensions: false,
    doNotTrack: false,
    clipboardSupport: true
}

Response Handling

The response to this method (success or failure) can be captured using async/await or promises.

try {
	const result = await syncWebData(
		"USER_ID", // User identifier
		"CLIENT_ID", // Your client identifier
		"SECRET_KEY", // Authentication key
		"https://api.yourserver.com" // Optional: Custom API endpoint
	);

	if (result) {
		// Data collection successful console.log("Sync successful:", result);
	} else {
		// Data collection failed console.log("Sync failed");
	}
} catch (error) {
	// Handle errors
	console.error("SDK Error:", error);
}

Error Handling

Common error scenarios and their handling -

// Handle permission denials gracefully
if (!result.latitude) {
	console.log("Location access denied by user");
}
// Network connectivity issues
if (!result) {
	console.log("Network error - sync failed");
}

Privacy Consideration

  • Respects user privacy settings and browser limitations
  • Handles incognito/private browsing modes appropriately
  • Complies with Do Not Track preferences
  • No sensitive personal data collected without explicit permission