BuildersUtility 22
Seller SDK
Drop-in middleware for Hono, Express and Next.js, with pricing, receipts and payouts handled.
Ship a paid endpoint in the framework you already use. The Seller SDK is the code behind Nous Gate: pricing, receipts and payouts in one middleware. Planned package name: @nouspay/gate.
Hono
import { gate } from "@nouspay/gate";
app.get("/forecast", gate({ price: "<price in ETH>", payTo: "<your wallet>" }), handler);Express
import { gate } from "@nouspay/gate/express";
app.get("/forecast", gate({ price: "<price in ETH>", payTo: "<your wallet>" }), handler);Next.js route handler
import { withGate } from "@nouspay/gate/next";
export const GET = withGate({ price: "<price in ETH>", payTo: "<your wallet>" }, async () => {
return Response.json(await runForecast());
});Options
| Option | Meaning |
|---|---|
price | Price per call in ETH |
payTo | Wallet that receives payment |
description | Shown to buyers and in the Agent Shop |
split | Upstream sellers and their shares; see Revenue Split |
facilitator | Hosted by default; self-hosting is planned |
Buyer side
The matching client, planned as @nouspay/fetch, wraps fetch and handles 402 responses. See Quickstart for agents.