Introducing The Sweep: OX’s New Live Security Research Series
Register Now
Breaking: The 2026 Vulnpocalypse Hits PHP: Four Critical RCEs, but How Dangerous Are They?
Read the Report
Are you exposed? Connect your apps in minutes.
Scan your apps free

@capillarytech/cap-hydra-web-sdk

Latest version: v1.10.8

Overview

Last scanned
1 Dec 2026
Published
1 Dec 2026
npm package Publisher: capillary, yogeshgcapillary
3 Versions

Scan summary

@capillarytech/cap-hydra-web-sdk was last scanned on 1 Dec 2026 at version 1.10.8. Risk score 0 of 100. No malicious behavior was detected.

  • Releases: 3 versions, all published on 1 Dec 2026.
  • Findings: No rules fired in version 1.10.8.

Versions

3 versions published
Versions and the rules that fired in each
VersionPublishedStatus
1.10.8 LATEST 1 Dec 2026 No rules fired
1.10.8-beta.feat-pkg-migration-under-org.1 1 Dec 2026 No rules fired
0.0.0-stage 1 Dec 2026 Not shown

No rules fired in 1.10.8

Findings

Findings for v1.10.8. The score is a capped sum of the weights of the rules that fired — not CVSS, not exploitability, and not a probability. It is not comparable across packages with different scan coverage.

The score describes 1.10.8; other versions have their own rules, not their own score.

README

The publisher’s own README, as collected from the registry.

WebSDK Integration Guide

A comprehensive guide for integrating the Hydra WebSDK into your web application for event tracking, user identification, and analytics.


Basic WebSDK Integration

1. Installation

Choose the release channel that matches your environment:

Channel When to use npm tag
Production (@latest) Live / production apps — stable, fully tested (default)
Beta (@beta) Staging / pre-release testing — latest features before stable cut @beta

NPM (recommended):

# Production (stable)
npm install @capillarytech/cap-hydra-web-sdk

# Beta (pre-release / testing)
npm install @capillarytech/cap-hydra-web-sdk@beta

CDN / Script tag:

<!-- Production -->
<script src="https://cdn.jsdelivr.net/npm/@capillarytech/cap-hydra-web-sdk@latest/dist/index.umd.min.js"></script>

<!-- Beta -->
<script src="https://cdn.jsdelivr.net/npm/@capillarytech/cap-hydra-web-sdk@beta/dist/index.umd.min.js"></script>

Beta channel: Beta builds are published manually from feature/UAT branches and carry the branch name and a build number (e.g. 1.10.8-beta.feature-login.42). @beta always points at the most recent beta from any branch, so pin the exact version when testing a specific branch. Switch to production once the release is cut.

2. Importing the SDK

ES6 Modules (TypeScript / JavaScript):

import { HydraSDK } from '@capillarytech/cap-hydra-web-sdk';

CommonJS:

const { HydraSDK } = require('@capillarytech/cap-hydra-web-sdk');

When using the CDN script tag, HydraSDK is available as a global on the window object.

3. SDK Initialization

Call HydraSDK.initialize() once at application startup. The SDK uses Firebase Remote Config to fetch backend configuration (accountId, baseURL, debugLevel, etc.) automatically — you only need to provide Firebase credentials and the Remote Config key.

import { HydraSDK } from '@capillarytech/cap-hydra-web-sdk';

HydraSDK.initialize({
  firebaseConfig: {
    apiKey: 'YOUR_FIREBASE_API_KEY',
    authDomain: 'your-app.firebaseapp.com',
    databaseURL: 'https://your-app.firebaseio.com',
    projectId: 'your-project-id',
    storageBucket: 'your-app.appspot.com',
    messagingSenderId: '123456789',
    appId: 'your-firebase-app-id',
  },
  remoteConfigKey: 'your_app_config_key',
  appVersion: '1.0.0',
});

Important: Initialize the SDK at module load time — not inside React useEffect, Angular ngOnInit, or similar async lifecycle hooks. This ensures the SDK instance exists before any component attempts to use it. In a React app, wrap the call in a small service module (e.g. services/sdkService.ts) that calls HydraSDK.initialize() at the top level, then import that module wherever you need HydraSDK.

4. Basic Event Tracking
// Track a page view (auto-captures URL and title)
HydraSDK.pageView();

// Track a custom event
HydraSDK.track('page_view', {
  page: 'homepage',
});

// Track with detailed properties
HydraSDK.track('add_to_cart', {
  product_id: 'shoe-123',
  product_name: 'Nike Air Max',
  quantity: 1,
  price: 129.99,
  currency: 'USD',
});
5. User Identification

When a user logs in, call identify() to link their activity to a known identity:

HydraSDK.identify({
  identifier: { type: 'email', cuid: 'user@example.com' },
  actionType: 'USER_REGISTER',
  traits: {
    firstName: 'John',
    lastName: 'Doe',
  },
});

Supported identifier types: 'email', 'mobile', 'externalId'.

When the user logs out, call reset() to return to anonymous tracking:

HydraSDK.reset();

Configuration

The SDK supports two bootstrap modes, selected by whether remoteConfigKey is present in the config passed to initialize():

  • Remote Config bootstrap (below): supply firebaseConfig + remoteConfigKey. Values like accountId, baseURL, debugLevel, etc. are fetched automatically from Firebase Remote Config.
  • Direct-config bootstrap (see Direct-Config Bootstrap (No Firebase) below): omit firebaseConfig and remoteConfigKey entirely and pass accountId, baseURL, and orgId directly instead. No Firebase project is required in this mode unless notifications (push) is also configured.
Required Fields (Remote Config bootstrap)
Field Type Description
firebaseConfig FirebaseConfig Firebase project configuration
remoteConfigKey string Key to fetch SDK config from Remote Config
Fields
Field Type Default Description
appVersion string — Host application version (populates app_version in events)
retryDelays number[] [60000, 120000, 240000, 480000, 900000] Custom retry delays in milliseconds
notifications NotificationConfig — Push notification configuration
Auto-populated Fields (from Remote Config)

The following fields are fetched from Firebase Remote Config. Do not set them manually.

Field Required Default Description
accountId Yes — Organization account identifier
baseURL Yes — API base URL for all SDK requests
orgId Yes — Organization ID for API authentication
brandId No — Brand identifier for namespaced database names
applicationId No — Application identifier for namespaced database names
source No WEBPUSH Source identifier for visitor profiles
channelType No web Communication channel type
sessionTimeoutMinutes No 30 Session inactivity timeout in minutes
batchSize No 50 Max events per batch request
debugLevel No NONE Logging level (NONE / ERROR / WARN / INFO / DEBUG / VERBOSE)
gamificationWriteKey Yes* — Gamification write key; gamification auto-initializes on user signin once this and gamificationBaseUrl are set. Required to enable gamification.
gamificationBaseUrl Yes* — Gamification API base URL. Required to enable gamification — there is no built-in default endpoint.

* gamificationWriteKey and gamificationBaseUrl are both required to enable gamification. Omit both if gamification is not being used.

Example Remote Config JSON (stored as the value of your remoteConfigKey in Firebase Console):

{
  "accountId": "100458",
  "baseURL": "https://api.example.capillarytech.com",
  "orgId": "100458",
  "brandId": "1",
  "applicationId": "2",
  "source": "WEBPUSH",
  "channelType": "web",
  "sessionTimeoutMinutes": 30,
  "batchSize": 50,
  "debugLevel": "NONE",
  "gamificationWriteKey": "wk_live_xxxxxxxxxx",
  "gamificationBaseUrl": "https://gamification.example.capillarytech.com"
}

Gamification is opt-in. With both fields above configured, campaigns and entry points are fetched and rendered automatically after identify() — no other host-app code is required beyond placing a <div id="{hookId}"></div> for EMBEDDED/NATIVE_BANNER container types. Once a user explicitly closes a campaign, it won't reopen again until a new session starts, by default — no configuration needed. See DEVELOPER_GUIDE.md §14 for the full container/content-type reference, the session-dismissal rules, and the 7 engagement-tracking events sent automatically alongside track()/pageView().

Direct-Config Bootstrap (No Firebase)

If you don't want to depend on Firebase at all, omit firebaseConfig and remoteConfigKey from initialize() and pass the config directly instead:

HydraSDK.initialize({
  accountId: '100458',
  baseURL: 'https://api.example.capillarytech.com',
  orgId: '100458',
  // Everything below is optional (same fields, same defaults as Remote Config bootstrap) —
  // except the gamification pair, which is required together only if you want gamification.
  brandId: '1',
  applicationId: '2',
  sessionTimeoutMinutes: 30,
  batchSize: 50,
  debugLevel: 'NONE',
  gamificationWriteKey: 'wk_live_xxxxxxxxxx',
  gamificationBaseUrl: 'https://gamification.example.capillarytech.com',
});
Field Required? Notes
accountId Yes Same field as the Remote Config JSON's accountId
baseURL Yes Same field as the Remote Config JSON's baseURL
orgId Yes Same field as the Remote Config JSON's orgId
Everything else No Same fields and requirements as the "Auto-populated Fields" table above (gamification's 3 fields are still required together if enabling gamification)

No Firebase project is required in this mode, except for push notifications — see Push Notifications below.

This is also how to use a different config source than this SDK's built-in Remote Config fetch. Fetch your config however you like and pass the values in directly; there's nothing Firebase-specific about this mode.


Public API Reference

All 15 public methods are static and accessed via HydraSDK.*. All methods (except initialize) internally wait for SDK initialization to complete before executing.

1. initialize(config)

Creates and initializes the SDK singleton. Must be called once before any other method. Safe to call multiple times — subsequent calls return the existing instance.

const sdk = HydraSDK.initialize({
  firebaseConfig: {/* ... */},
  remoteConfigKey: 'your_app_config_key',
  appVersion: '1.0.0',
});
Parameter Type Required Description
config WebSDKConfig Yes SDK configuration object

2. track(eventName, properties?)

Tracks a custom behavioral event.

HydraSDK.track('button_click', {
  button_id: 'checkout',
  page: 'cart',
  value: 99.99,
});
Parameter Type Required Description
eventName string Yes Name of the event
properties Record<string, unknown> No Custom event properties

If gamification is configured and a gamification entry point is set up with triggerType: "ACTION_EVENT" for this eventName, this same track() call also evaluates and, if its display conditions pass, opens that entry point — no separate call is needed. Unlike screen-triggered campaigns, an ACTION_EVENT entry point isn't rationed by a frequency cap and isn't blocked once its campaign is marked completed — it keeps responding to every occurrence of its event.

Overlay campaigns queue, they don't stack. If a matching entry point is a pop-up, bottom sheet, or chat box and another overlay campaign is already open, it waits in a priority-ordered queue and shows automatically once the current one closes — you never see two overlay campaigns on screen at once. Icon buttons, banners, and embeds are unaffected and open immediately. See DEVELOPER_GUIDE.md's Campaign Queue section for the full ordering/persistence rules.


3. pageView(options?)

Tracks a page view event. If called with no arguments, automatically captures the current URL and page title.

// Automatic capture
HydraSDK.pageView();

// With custom options
HydraSDK.pageView({
  page_url: 'https://example.com/products/123',
  page_title: 'Product Detail',
  page_category: 'product',
  properties: { productId: 'SKU-123' },
});
Parameter Type Required Description
options PageViewOptions No Page view metadata

PageViewOptions fields:

Field Type Description
page_url string Override the current page URL
page_title string Override the current page title
referrer string Override the page referrer
page_category string Page category (e.g., 'blog', 'product', 'checkout')
properties Record<string, unknown> Custom properties

These same keys (page_url, page_title, referrer, page_category) are what's sent as the page_view event's attributes. See DEVELOPER_GUIDE.md § Automatic Event Attributes for the full schema, including the automatic scroll_depth event.

OX Radar and Response Center

Find threats in your stack.

OX Radar can check high-priority threats, like critical package CVEs, against your context.

Each incident is marked Detected or Not Detected with a remediation plan and proof all tracked in the Response Center.

Where it’s listed

The probe returned only these fields for this server — auth requirement, protocol and tool list weren’t observed, so they’re not shown (never guessed).

  • npm @capillarytech/cap-hydra-web-sdk

References

The publisher’s own links, as the registry reports them. These are not sources for the assessment on this page.

Powered by Read the latest findings

Scan your whole stack

Group 1261154050 1
Group 1261154050
 

From OX Research Newsroom

Ethersphere Hijacked With Crypto Stealing Malware (1)
npm

Ethersphere Hijacked With Crypto Stealing Malware Via Github & npm

Critical Apache HTTP Server Flaw Exposes Web Servers to RCE (1)
CVE

CVE-2026-119618: Critical Apache HTTP Server Flaw Exposes Web Servers to Remote Code Execution

Plug and Pray: Your AI Agents Are Taking Orders From Strangers
Research

Plug and Pray: Your AI Agents Are Taking Orders From Strangers

Frame 2085668439 (1)
Group 1261154229