Skip to main content
Coming soon. The @1stdigital/prism-http package is being updated for the latest x402 protocol. For Node.js applications today, please use the Express SDK.

Overview

The @1stdigital/prism-http package provides middleware for vanilla Node.js HTTP servers, without requiring any framework. Perfect for lightweight APIs or custom HTTP implementations.

Zero Dependencies

Works with raw http/https modules

Framework-Free

No Express, Fastify, or other framework needed

Lightweight

Minimal overhead, maximum performance

Installation


The canonical SDK config is identifyToken (PRISM_IDENTIFY_TOKEN env var) — formerly apiKey / PRISM_API_KEY. SDKs accept the legacy names as fallback during the migration window; new code should use the canonical names.

Quick Start


Configuration


Routing

URL-based Routing


Accessing Payment Info


Settlement Validation

HTTP middleware intercepts res.end() to validate settlement:

Testing

Last modified on May 15, 2026