adminsubscriptions

package
v1.0.21 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Aug 11, 2026 License: AGPL-3.0 Imports: 5 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Service

type Service struct {
	// contains filtered or unexported fields
}

func New

func (*Service) GetUserSubscription

func (s *Service) GetUserSubscription(
	ctx context.Context, userUuid uuid.UUID,
) (domain.Subscription, domain.EffectiveSubscription, error)

func (*Service) ListPlans

func (s *Service) ListPlans(ctx context.Context) ([]domain.SubscriptionPlan, error)

func (*Service) UpdateUserSubscription

func (s *Service) UpdateUserSubscription(
	ctx context.Context, sub domain.Subscription,
) (domain.EffectiveSubscription, error)

UpdateUserSubscription writes the admin-supplied active flag, plan assignment, and overrides in place — the two writes aren't transactional, but they're both idempotent full-replace upserts on the same row, so a failure between them just leaves the next admin save to retry.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL