billing

package
v0.28.0 Latest Latest
Warning

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

Go to latest
Published: Sep 5, 2025 License: Apache-2.0 Imports: 8 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type OverageService

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

func (*OverageService) CheckOverage

func (s *OverageService) CheckOverage(tenantID string, usedBytes, limitBytes int64) string

func (*OverageService) ShouldAutoUpgrade

func (s *OverageService) ShouldAutoUpgrade(tenantID string, graceDuration time.Duration) bool

type StripeService

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

func NewStripeService

func NewStripeService(apiKey string) *StripeService

func (*StripeService) CreateCheckoutSession

func (s *StripeService) CreateCheckoutSession(customerID, successURL, cancelURL string) (string, error)

CreateCheckoutSession creates a Stripe Checkout session for $6.69/month subscription

func (*StripeService) CreateCustomer

func (s *StripeService) CreateCustomer(email, tenantID string) (string, error)

type WebhookHandler

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

func NewWebhookHandler

func NewWebhookHandler(secret string) *WebhookHandler

func (*WebhookHandler) ServeHTTP

func (h *WebhookHandler) ServeHTTP(w http.ResponseWriter, r *http.Request)

Jump to

Keyboard shortcuts

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