{
  "id": 1174864,
  "title": "Paywall Any API Endpoint With Two Prices: Sats or Compute",
  "url": "https://urgent.news/2026/08/16/paywall-any-api-endpoint-with-two-prices-sats-or-compute",
  "topic": "tech",
  "section": "Tech",
  "published": "2026-08-16T02:02:59.000Z",
  "source": {
    "name": "Dev.to",
    "slug": "dev-to",
    "url": "https://dev.to/zekebuilds/paywall-any-api-endpoint-with-two-prices-sats-or-compute-1jdh"
  },
  "original_language": "en",
  "account": "Pay-to-Compute API Endpoint: Two Pricing Options for Protection Against Scrapers\n\nAPI creators often face the challenge of unwanted scraping and bot traffic, leading to high compute costs and no return for their services. Traditional solutions involve setting up API keys, a signup flow, and a support system. However, this approach requires significant effort and can be cumbersome for users.\n\nA simpler alternative is to implement a pay-to-compute model, where every API request incurs a cost. Callers can either pay a small amount in satoshis (sats) via a Lightning invoice or solve a compute-intensive proof-of-work puzzle. This model eliminates the need for accounts, keys, or dashboards, as the payment itself serves as authorization.\n\nThe gate.powforge.dev server demonstrates this two-price idea. Callers can choose either path to access the gated response. The compute path requires solving a SHA-256 partial collision, with difficulty adjustable based on server resources. The solution cost for the caller is the electricity consumed and the time spent solving the puzzle. The sats path involves settling a Lightning invoice for a fixed amount (10 sats, which amounts to a tenth of a cent).\n\nBoth payment methods grant the same access to the gated response, ensuring that no free-riding occurs. The server-side verification process is straightforward and requires minimal resources. It simply checks the provided proof-of-work solution against the predefined difficulty.\n\nThe pay-to-compute API offers a straightforward solution to protect against scrapers and bots without the need for complex authentication systems. The server-side verification is minimal, while the cost of compute or sats falls on the caller, making it an effective and lightweight protective measure for API providers.",
  "summary": "You built an API. It works. Then the scrapers show up. Not paying customers. Bots hammering your endpoint a thousand times a minute, running up your compute bill, and giving you nothing back. The usual fix is API keys, a signup flow, a Stripe integration, a dashboard, and a support inbox for people who lost their key. That is a lot of plumbing to answer one question: did this caller give up…",
  "key_points": [
    "Pay-to-Compute model protects APIs against scrapers",
    "Callers pay in sats or solve compute-intensive proof-of-work",
    "Server-side verification is minimal and straightforward"
  ],
  "editors_take": "This pay-to-compute model shifts the cost of protecting against scrapers and bots from API providers to callers, allowing for a more straightforward and lightweight defensive strategy.",
  "illustration": null,
  "coverage": {
    "outlets": 1,
    "also_reported_by": []
  },
  "ai_generated": true,
  "disclaimer": "Summaries, key points and the editor’s take are written by software from other outlets’ reporting and may contain errors — always check the linked original."
}