invoice

package
v0.8.21 Latest Latest
Warning

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

Go to latest
Published: Jan 31, 2024 License: Apache-2.0 Imports: 7 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type CustomerService

type CustomerService interface {
	GetByID(ctx context.Context, id string) (customer.Customer, error)
}

type Filter

type Filter struct {
	CustomerID string
}

type Invoice

type Invoice struct {
	ID          string
	CustomerID  string
	ProviderID  string
	State       string
	Currency    string
	Amount      int64
	HostedURL   string
	DueDate     time.Time
	EffectiveAt time.Time
	CreatedAt   time.Time

	Metadata metadata.Metadata
}

type Service

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

func NewService

func NewService(stripeClient *client.API, customerService CustomerService) *Service

func (*Service) GetUpcoming

func (s *Service) GetUpcoming(ctx context.Context, customerID string) (Invoice, error)

func (*Service) List

func (s *Service) List(ctx context.Context, filter Filter) ([]Invoice, error)

Jump to

Keyboard shortcuts

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