GitHub - ParallaxAPIs/parallaxapis-sdk-ts · GitHub
Skip to content

Latest commit

 

History

101 Commits

Folders and files

Repository files navigation

Parallax Logo ParallaxAPIs SDK - TypeScript Library for Bot Protection Bypass (Datadome & PerimeterX)

license MIT Node.js version downloads

Discord

TypeScript SDK for bypassing DataDome and PerimeterX anti-bot protection.

📖 Overview

ParallaxAPIs provides a request-based solution for bypassing DataDome and PerimeterX anti-bot systems. Instead of relying on slow, resource-heavy browser automation, our API generates valid cookies and tokens in 200-400ms through direct HTTP requests.

What We Solve:

  • ✅ DataDome - Slider captchas, interstitial pages, cookie generation, tags payload
  • ✅ PerimeterX - Cookie generation (_px3), challenge solver, vid & cts tokens

Key Benefits:

  • ⚡ Lightning Fast - 200-400ms response times vs 5-10+ seconds for browsers
  • 🔧 Simple Integration - Clean API with comprehensive documentation, no browser management required
  • 🚀 Highly Scalable - Handle thousands of concurrent requests with minimal resources
  • ⚙️ Flexible Configuration - Custom timeouts, HTTP clients, and proxy settings
  • 💰 Cost Effective - Lightweight infrastructure, minimal proxy usage
  • 🔄 Always Updated - We handle all reverse engineering and updates for you

🚀 Quick Start

Get started with ParallaxAPIs SDK's in under 5 minutes:

  1. Join our Discord - Connect with our community
  2. Get your free trial - Start testing immediately
  3. Install the SDK - Choose your preferred language
  4. Solve all antibots in seconds - Start bypassing DataDome, PerimeterX & more

📦 Installation

npm install parallaxapis-sdk-ts

NPM Install Demo


🧑‍💻 Datadome Usage

⚡ SDK Initialization

import { DatadomeSDK } from "parallaxapis-sdk-ts";

// Basic initialization with API key
const sdk = new DatadomeSDK({ apiKey: "Key" });

// Custom host
const sdk = new DatadomeSDK({ apiKey: "Key", apiHost: "example.host.com" });

// Advanced configuration with timeouts and custom dispatcher
import { ProxyAgent } from "undici";

const sdk = new DatadomeSDK({
  apiKey: "Key",
  timeout: 30000, // Request timeout in milliseconds (default: none) (optional)
  bodyTimeout: 10000, // Body timeout in milliseconds (default: none) (optional)
  dispatcher: new ProxyAgent("http://proxy:port", {
    requestTls: { rejectUnauthorized: false }
  }) // Custom undici dispatcher (optional)
});

const usedRequests = await sdk.checkUsage("site")
console.log(usedRequests);

🕵️‍♂️ Generate New User Agent

import { DatadomeSDK } from "parallaxapis-sdk-ts";

const sdk = new DatadomeSDK({ apiKey: "Key" });

const userAgent = await sdk.generateUserAgent({
  region: "com",
  site: "site",
});

console.log(userAgent);

🔍 Get Task Data

import { DatadomeSDK } from "parallaxapis-sdk-ts";

const sdk = new DatadomeSDK({ apiKey: "Key" });

const [taskData, productType] = sdk.parseChallengeUrl(
  "https://www.example.com/captcha/?initialCid=initialCid&cid=cid&referer=referer&hash=hash&t=t&s=s&e=e",
  "cookie_value",
);

console.log(taskData, productType);

📄 Parse HTML Challenge

import { DatadomeSDK } from "parallaxapis-sdk-ts";

const sdk = new DatadomeSDK({ apiKey: "Key" });

const htmlBody = "<html><script>dd={example:1}</script></html>";
const prevCookie = "cookie_value";

const [taskData, productType] = sdk.parseChallengeHtml(htmlBody, prevCookie);

console.log(taskData, productType);

🍪 Generate Cookie

import { DatadomeSDK } from "parallaxapis-sdk-ts";

const sdk = new DatadomeSDK({ apiKey: "Key" });

const [taskData, productType] = sdk.parseChallengeUrl(
  "https://www.example.com/captcha/?initialCid=initialCid&cid=cid&referer=referer&hash=hash&t=t&s=s&e=e",
  "cookie_value",
);

const cookie = await sdk.generateCookie({
  site: "site",
  region: "com",
  data: taskData,
  pd: productType,
  proxy: "http://user:pas@addr:port",
  proxyregion: "eu",
});

console.log(cookie);

🏷️ Generate Tags Cookie

import { DatadomeSDK } from "parallaxapis-sdk-ts";

const sdk = new DatadomeSDK({ apiKey: "Key" });

const cookie = await sdk.generateDatadomeTagsCookie({
  site: "site",
  region: "com",
  data: {
    cid: "null",
  },
  proxy: "http://user:pas@addr:port",
  proxyregion: "eu",
});

console.log(cookie);

🔎 Detect and Parse Challenge

import { DatadomeSDK } from "parallaxapis-sdk-ts";

const sdk = new DatadomeSDK({ apiKey: "Key" });

const responseBody = "<html>...</html>"; // Response body from website
const prevCookie = "cookie_value";

const [isBlocked, taskData, productType] = sdk.detectChallengeAndParse(
  responseBody,
  prevCookie,
);

console.log(isBlocked, taskData, productType);

🛡️ Perimeterx Usage

⚡ SDK Initialization

import { PerimeterxSDK } from "parallaxapis-sdk-ts";

// Basic initialization with API key
const sdk = new PerimeterxSDK({ apiKey: "Key" });

// Custom host
const sdk = new PerimeterxSDK({ apiKey: "Key", apiHost: "example.host.com" });

// Advanced configuration with timeouts and custom dispatcher
import { ProxyAgent } from "undici";

const sdk = new PerimeterxSDK({
  apiKey: "Key",
  timeout: 30000, // Request timeout in milliseconds (default: none)
  bodyTimeout: 10000, // Body timeout in milliseconds (default: none)
  dispatcher: new ProxyAgent("http://proxy:port", {
    requestTls: { rejectUnauthorized: false }
  }) // Custom undici dispatcher (optional)
});

const usedRequests = await sdk.checkUsage("site")
console.log(usedRequests);

🍪 Generate PX Cookie

import { PerimeterxSDK } from "parallaxapis-sdk-ts";
import type { TaskGenerateHoldCaptcha, TaskGeneratePXCookies } from "parallaxapis-sdk-ts";

const sdk = new PerimeterxSDK({
    apiKey: "Key",
});

const result = await sdk.generateCookies({
    proxy: "http://user:pas@addr:port",
    proxyregion: "eu",
    region: "com",
    site: "site"
} satisfies TaskGeneratePXCookies);

console.log(JSON.stringify(result))


const holdCaptchaResult = await sdk.generateHoldCaptcha({
    proxy: "http://user:pas@addr:port",
    proxyregion: "eu",
    region: "com",
    site: "site",
    data: result.data,
} satisfies TaskGenerateHoldCaptcha);

console.log(JSON.stringify(holdCaptchaResult))

📚 Documentation & Help

🌟 Contributing

Got feedback or found a bug? Feel free to open an issue or send us a pull request!

🏢 Enterprise

Unlock enterprise-grade performance with custom solutions, expanded limits, and expert support. Contact us to learn more.

📝 License

MIT


🔑 Keywords

DataDome bypass • PerimeterX bypass • Anti-bot bypass • Bot detection bypass • CAPTCHA solver • Cookie generator • TypeScript web scraping • JavaScript bot automation • Node.js anti-bot • DataDome TypeScript SDK • PerimeterX TypeScript SDK • Headless browser alternative • Request-based bypass • TypeScript automation • Web scraping TypeScript • Bot mitigation bypass • Sensor data generation • Challenge solver • npm anti-bot