Hacktoberfest 2026: as issues que os mantenedores marcaram para outubro, abertas e boas para iniciantes. Ver issues do Hacktoberfest

feat(payments): per-plan event rate limits and retention

Aberta
#921 0 comentários 0 reações 1 responsável Ver no GitHub

Mantenedores costumam responder em até 1 dia

@Priyanshubhartistm já está trabalhando nisso.

Desde 21/10/2026.

  • #922 de @Priyanshubhartistm — aberto

Avaliação

Esta issue ainda não foi avaliada.

Descrição

enhancement

Is your feature request related to a problem? Please describe.
Rate limits (limits.event.rateLimits) and retention (limits.event.retention) are global, so a paying subscriber on a premium plan gets the same limits as everyone else. Tiered access (#673) needs these to depend on the sender's active plan.

Describe the solution you'd like

  • Plans can define their own event rate limits; EventMessageHandler.isRateLimited uses the plan's set for a subscriber and the global set otherwise, keyed the same way as today.
  • Plans can define their own retention (maxDays); the maintenance purge applies it per subscriber instead of one global value, keeping the existing kind/pubkey whitelists.
  • The plan lookup reuses the admission cache so no extra database read happens per event.
  • Documentation in CONFIGURATION.md and tests for both limit paths, including expiry falling back to the global limits.

Additional context

  • Design: #673. Per-plan connection/subscription-count limits are more invasive (adapter level) and left for a follow-up unless maintainers want them here.
Linguagem predominante
TypeScript
Estrelas
829
Forks
234
Merge médio
16h 13min
PRs com merge (30d)
74

Preparar o ambiente

Primeiros passos

  1. Leia a issue inteira e depois o guia de contribuição do projeto.
  2. Comente na issue dizendo que vai assumir — evita que duas pessoas façam o mesmo trabalho.
  3. Faça um fork do repositório e trabalhe em uma branch.
  4. Abra um pull request que referencie o número da issue.

Mais de cameri/nostream

Todas as issues de cameri/nostream

Issues semelhantes

Mais issues de TypeScript

Receba novas issues na sua caixa de entrada

Um resumo curto de issues do GitHub para quem está começando.