MCPcopy Index your code
hub / github.com/supabase/auth / triggerBeforeUserCreated

Method triggerBeforeUserCreated

internal/api/hooks.go:35–50  ·  view source on GitHub ↗
(
	r *http.Request,
	db *storage.Connection,
	user *models.User,
)

Source from the content-addressed store, hash-verified

33}
34
35func (a *API) triggerBeforeUserCreated(
36 r *http.Request,
37 db *storage.Connection,
38 user *models.User,
39) error {
40 if !a.hooksMgr.Enabled(v0hooks.BeforeUserCreated) {
41 return nil
42 }
43 if err := checkTX(db); err != nil {
44 return err
45 }
46
47 req := v0hooks.NewBeforeUserCreatedInput(r, user)
48 res := new(v0hooks.BeforeUserCreatedOutput)
49 return a.hooksMgr.InvokeHook(db, r, req, res)
50}
51
52func (a *API) triggerBeforeUserCreatedExternal(
53 r *http.Request,

Callers 5

SignupAnonymouslyMethod · 0.95
InviteMethod · 0.95
SignupMethod · 0.95
adminGenerateLinkMethod · 0.95

Calls 4

checkTXFunction · 0.85
EnabledMethod · 0.80
InvokeHookMethod · 0.65

Tested by

no test coverage detected