API Reference

REST API endpoints, authentication, and SDK installation options for Sublyzer integrations.

SDK installation

Pick one path: download a ready-made SDK (or use the Windows installer), use an NPM package for JavaScript/React, or generate tailored code for other languages.

Installer (.exe)

Windows app — selects your stack, writes SDK files into your project. Download installer

SDK Customizer

Browser tool — generate & download SDK for JS, Python, PHP, Go, C++, and more. Open SDK Customizer

Option A: Download SDK or Installer

Installer: run sublyzer-installer.exe, enter your integration code, choose your language/framework. Files are copied into your project automatically.

SDK Customizer: open https://www.sublyzer.com/sdk-customizer, configure features, then Download the generated sublyzer.js (or language-specific files). Place them in your repo (e.g. public/sdks/ for web apps).

Option A (web): Script tag

Fastest for static sites — no build step:

<script
  src="https://www.sublyzer.com/sublyzer.js"
  data-integration-code="YOUR_INTEGRATION_CODE"
  defer
></script>

Option B: NPM Package

npm install @sublyzer/browser

Then initialize in your app:

import { Sublyzer } from '@sublyzer/browser';

Sublyzer.init({
  code: 'YOUR_INTEGRATION_CODE',
  // Optional: customize what data is collected
  performance: true,
  errors: true,
  sessions: true,
});

Option C: React / Next.js

npm install @sublyzer/react

In your _app.tsx or root layout:

import { SublyzerProvider } from '@sublyzer/react';

export default function App({ Component, pageProps }) {
  return (
    <SublyzerProvider code="YOUR_INTEGRATION_CODE">
      <Component {...pageProps} />
    </SublyzerProvider>
  );
}

Need a different language? Use the SDK Customizer to generate code for Python, PHP, Rust, Go, C++, and more. Full per-language docs: SDK Reference.

Auth

Most dashboard and integration endpoints require a Bearer token from login or OAuth:

Authorization: Bearer YOUR_JWT_TOKEN

The browser SDK uses your public integration code only — never embed JWT secrets in client code.

Data collection (SDK)

SDKs send batched events to the collect endpoint. On www.sublyzer.com this is proxied as /api/accelerate; direct backend URL:

POST /data-collection/collect-batch
Content-Type: application/json

{
  "integrationCode": "YOUR_24_CHAR_CODE",
  "events": [ /* error, performance, pageview, ... */ ]
}
Integrations
POST   /integrations          # create (auth required)
GET    /integrations/:id      # details
PATCH  /integrations/:id      # update settings
DELETE /integrations/:id      # remove
TestingAI

Start a headless TestingAI run (PRO):

POST /ai/swarm/run
Content-Type: application/json
Authorization: Bearer YOUR_TOKEN

{
  "integrationId": "INTEGRATION_ID",
  "agents": 8,
  "targetUrl": "https://www.example.com",
  "maxPages": 3,
  "maxClicks": 10
}
Webhooks

Configure outbound webhooks per integration in the dashboard. See the Webhooks guide for events, signatures, and retry policy.

# Your server receives POST JSON from Sublyzer
POST https://your-app.com/webhooks/sublyzer
X-Sublyzer-Signature: sha256=...
Admin (internal)

Admin-only endpoints (demo links, storage, test users) require isAdmin on the JWT.

GET  /users/admin/demo-dashboard-link
GET  /users/admin/storage/stats
POST /users/admin/storage/cleanup-cache

Need help? Join our Discord.