New Research: Supply Chain Attack on Axios Pulls Malicious Dependency from npm.Details
Socket
Book a DemoSign in
Socket

@xhrdev/sdk

Package Overview
Dependencies
Maintainers
1
Versions
2
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@xhrdev/sdk

latest
npmnpm
Version
1.0.8
Version published
Maintainers
1
Created
Source

@xhrdev/sdk

sdk

TypeScript SDK for the xhr.dev API

docs

Installation

npm install --save-dev @xhrdev/sdk

Usage

Basic Type Imports

import {
  DatadomeCaptchaRequest,
  DatadomeCaptchaResponse,
  DatadomeInterstitialRequest,
  DatadomeInterstitialResponse,
  DatadomeTagsRequest,
  DatadomeTagsResponse
} from '@xhrdev/sdk';

OpenAPI Specification

Access the complete OpenAPI 3.0.3 specification:

import { openApiSpec, getOpenApiSpec } from '@xhrdev/sdk';

// Get the spec as a YAML string
console.log(openApiSpec);

// Get the spec (currently returns the string, but could be parsed)
const spec = getOpenApiSpec();

Raw OpenAPI Types

Access the full OpenAPI type definitions:

import { sdk } from '@xhrdev/sdk';

// Access all paths, operations, and components
type ApiPaths = sdk.paths;
type ApiOperations = sdk.operations;
type ApiComponents = sdk.components;

// Access specific operations
type CaptchaOperation = sdk.operations['getDatadomeCaptcha'];
type InterstitialOperation = sdk.operations['postDatadomeInterstitial'];
type TagsOperation = sdk.operations['postDatadomeTags'];

API Endpoints

DataDome Interstitial

  • POST /datadome/interstitial - Process interstitial challenges
  • GET /datadome/captcha - Retrieve captcha challenges
  • POST /datadome/tags - Process DataDome tags

Authentication

All endpoints require an API key passed in the x-xhr-api-key header.

FAQs

Package last updated on 19 Sep 2025

Did you know?

Socket

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts