Hacktoberfest 2026:メンテナが10月に向けて印を付けた、オープンで初心者向けの issue。 Hacktoberfest の issue を見る

feat(payments): subscription data model and plan settings

クローズ
#848 コメント 0 件 リアクション 0 件 担当者 1 名 GitHub で見る

メンテナーはふだん 1 日以内に返信

@Priyanshubhartistm がすでに取り組んでいます。

2026年10月16日 から。

  • #849 @Priyanshubhartistm による — オープン

評価

この issue はまだ評価されていません。

説明

enhancement

Is your feature request related to a problem? Please describe.
Admission is a one-time boolean (users.is_admitted). There is nowhere to record a paid period, a plan, or when access ends, so recurring billing and tiered access (#673) cannot be built. This is the first, behaviour-neutral step.

Describe the solution you'd like

  • A user_subscriptions table (pubkey, plan id, status, period start/end, grace end, cancel-at-period-end) and the invoices columns plan_id, period_start, period_end, via a migration. A subscription is keyed by pubkey, so no separate subscription id is needed.
  • payments.subscriptionPlans[] in settings (id, price, interval, grace period, per-plan limits), with types, defaults (empty list), validation in validateSettings, and CONFIGURATION.md docs.
  • IUserSubscriptionRepository (find by pubkey, upsert, list due for renewal/expiry) and the invoice repository/Invoice type changes, with unit tests.
  • The migration grandfathers every existing is_admitted user onto a non-expiring plan so enabling plans later never locks anyone out.
  • No change to runtime behaviour: with no plans configured the relay behaves exactly as today.

Additional context

  • Design: #673. Earlier groundwork for the same layer.
主要言語
TypeScript
スター
829
フォーク
234
平均マージ
18時間 43分
マージ済み PR(30日)
67

環境構築

はじめの一歩

  1. issue を最後まで読み、次にプロジェクトのコントリビューションガイドを読みます。
  2. 着手することを issue にコメントします — 二人が同じ作業をするのを防げます。
  3. リポジトリをフォークし、ブランチを切って変更します。
  4. issue 番号を参照したプルリクエストを送ります。

cameri/nostream のほかの issue

cameri/nostream の issue をすべて見る

似ている issue

TypeScript の issue をもっと見る

新しい issue をメールで受け取る

初心者向けの GitHub issue を短くまとめたダイジェスト。