FazBrowse GitHub Viewer | Trending |
URL:
| Home
Tools: [Download Repo ZIP]   [Original HTTPS Page]

feat: zero-cost payment gate and balance-based rate limits · Issue #244 · JavaScriptSolidServer/JavaScriptSolidServer · GitHub

Repository navigation

feat: zero-cost payment gate and balance-based rate limits #244

Closed

Description

Summary

Two related enhancements to the payment system:

1. Zero-cost PaymentCondition (membership gate)

A PaymentCondition with "amount": "0" should grant access if the user has a balance — without deducting anything. This acts as a membership check: "prove you have funds."

Currently amount: 0 skips the balance check and always returns 402. Fix: check that a balance entry exists and grant access.

{
  "acl:condition": {
    "@type": "PaymentCondition",
    "amount": "0",
    "currency": "sats"
  }
}

2. Balance-based rate limits

Users with a balance get relaxed rate limits. Spammers won't deposit real sats to abuse the API.

  • No balance — default rate limits (strict)
  • Has balance — relaxed (e.g. 2x)
  • Higher balance — more relaxed (e.g. 10x)

This makes the payment system double as an anti-spam / trust layer.

Design question

For the zero-cost gate: should balance >= 0 (has an account) or balance > 0 (has actual funds) be the requirement?

Activity

  1. added a commit that references this issue on Apr 2, 2026
    48ae891
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions


      Back | FazBrowse Home | New Git URL