account

package
v0.19.1069 Latest Latest
Warning

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

Go to latest
Published: Jul 17, 2026 License: AGPL-3.0 Imports: 14 Imported by: 0 modules, 0 packages

The first number is the count of modules that contain a package that imports this one. The module count is a better indicator of popularity than the package count. A module with 100 importing packages is counted only once instead of 100 times, reflecting the fact that the choice to use the package was likely made only once, not 100 times.
A '?' means that the value hasn't been computed yet.

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func DefaultEvaluationJourney

func DefaultEvaluationJourney(completionSource string) app.UserJourneys

DefaultEvaluationJourney returns the evaluation journey for self-signup users This is the 6-step journey: account_created, org_created, cli_installed, app_created, app_synced, install_created

func DefaultEvaluationJourneyWithAttribution

func DefaultEvaluationJourneyWithAttribution(attribution map[string]interface{}, completionSource string) app.UserJourneys

DefaultEvaluationJourneyWithAttribution returns the evaluation journey with attribution data stored in the account_created step's metadata. This enables tracking marketing source for ROI analysis.

func NoUserJourneys

func NoUserJourneys() app.UserJourneys

NoUserJourneys returns an empty journey slice for invited/support users

func ServiceAccountEmail

func ServiceAccountEmail(id string) string

Types

type Client

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

func New

func New(params Params) *Client

func (*Client) CreateAccount

func (m *Client) CreateAccount(ctx context.Context, email, subject string, userJourneys app.UserJourneys) (*app.Account, error)

func (*Client) CreateAuthAccount

func (m *Client) CreateAuthAccount(ctx context.Context, email, subject string, userJourneys app.UserJourneys) (*app.Account, error)

func (*Client) CreateServiceAccount

func (c *Client) CreateServiceAccount(ctx context.Context, svcAcctID string) (*app.Account, error)

func (*Client) CreateToken

func (c *Client) CreateToken(ctx context.Context, subjectOrEmail string, dur time.Duration) (*app.Token, error)

func (*Client) ExtendToken

func (c *Client) ExtendToken(ctx context.Context, subjectOrEmail string, dur time.Duration) error

func (*Client) FetchAccount

func (m *Client) FetchAccount(ctx context.Context, acctID string) (*app.Account, error)

TODO(jm): this entire file should probably live in `pkg/account`

func (*Client) FindAccount

func (c *Client) FindAccount(ctx context.Context, emailOrSubjectOrID string) (*app.Account, error)

func (*Client) InvalidateOldTokens added in v0.19.770

func (c *Client) InvalidateOldTokens(ctx context.Context, subjectOrEmail string) (int64, error)

func (*Client) InvalidateTokens

func (c *Client) InvalidateTokens(ctx context.Context, subjectOrEmail string) error

type Params

type Params struct {
	fx.In

	Cfg             *internal.Config
	AnalyticsClient analytics.Writer
	DB              *gorm.DB `name:"psql"`
	V               *validator.Validate
	AuthzClient     *authz.Client
}

Jump to

Keyboard shortcuts

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