H

Heinrichstech · CDP Regex Test

by Heinrichstech

POSTBaseXRP Ledgerstellar:pubneteip155:1440000

$0.0001

per call · USD Coin on Base

BitBooth Regex Test: pay 0.001 USDC, safely compile and run a regex against a corpus. Returns structured matches with capture groups, indices, and lengths. JS engine flags (g, i, m, s, u, y, d). Hard CPU deadline guards against catastrophic backtracking (ReDoS) — `regex_timeout` is reported instead of stalling. Stateless, no API key.

Endpoint

POST https://app.heinrichstech.com/v1/cdp/regex-test

1

Calls / 30d

1

Unique payers / 30d

Sep 1

Last called

exact

Payment scheme

Call this service

TypeScript · @x402/fetch
import { wrapFetchWithPayment } from "@x402/fetch";
import { privateKeyToAccount } from "viem/accounts";

const account = privateKeyToAccount(process.env.PRIVATE_KEY);
const fetchWithPay = wrapFetchWithPayment(fetch, account);

const res = await fetchWithPay("https://app.heinrichstech.com/v1/cdp/regex-test", {
  method: "POST",
  headers: { "Content-Type": "application/json" },
  body: JSON.stringify({
    "captureLimit": 100,
    "flags": "g",
    "input": "a1 b22 c333",
    "pattern": "\\d+"
  }),
});
const data = await res.json();
cURL
curl -X POST \
  "https://app.heinrichstech.com/v1/cdp/regex-test" \
  -H "Content-Type: application/json" \
  -d '{"captureLimit":100,"flags":"g","input":"a1 b22 c333","pattern":"\\d+"}' \
  -H "X-PAYMENT: <signed x402 payment>"

Example response

{
  "flags": "g",
  "fullCount": 3,
  "matchCount": 3,
  "matches": [
    {
      "groups": [],
      "index": 1,
      "length": 1,
      "match": "1"
    },
    {
      "groups": [],
      "index": 4,
      "length": 2,
      "match": "22"
    },
    {
      "groups": [],
      "index": 8,
      "length": 3,
      "match": "333"
    }
  ],
  "ok": true,
  "pattern": "\\d+",
  "payment": {
    "network": "eip155:8453",
    "payer": "0xbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbb",
    "transaction": "0xaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa"
  },
  "service": "BitBooth /v1/cdp/regex-test",
  "truncated": false
}

Payment details

Pay to0xda2f35d283c42dd60b965322394bc658a5c1769f
AssetUSD Coin · 0x833589fcd6edb6e08f4c7c32d4f71b54bda02913
NetworksBase, XRP Ledger, stellar:pubnet, eip155:1440000
Schemesexact, onchain

Is this your API?

Pin it to the top of Other and the homepage with a featured placement.

Get featured →

More from Heinrichstech & similar services