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

Method triggerAfterUserCreated

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

Source from the content-addressed store, hash-verified

13)
14
15func (a *API) triggerAfterUserCreated(
16 r *http.Request,
17 conn *storage.Connection,
18 user *models.User,
19) error {
20 if !a.hooksMgr.Enabled(v0hooks.AfterUserCreated) {
21 return nil
22 }
23
24 // We still check tx because we want to make sure we aren't calling this
25 // trigger in code paths that haven't actually created the user yet.
26 if err := checkTX(conn); err != nil {
27 return err
28 }
29
30 req := v0hooks.NewAfterUserCreatedInput(r, user)
31 res := new(v0hooks.AfterUserCreatedOutput)
32 return a.hooksMgr.InvokeHook(conn, r, req, res)
33}
34
35func (a *API) triggerBeforeUserCreated(
36 r *http.Request,

Callers 9

web3GrantSolanaMethod · 0.95
web3GrantEthereumMethod · 0.95
handleSamlAcsMethod · 0.95
SignupAnonymouslyMethod · 0.95
InviteMethod · 0.95
SignupMethod · 0.95
adminGenerateLinkMethod · 0.95
IdTokenGrantMethod · 0.95

Calls 4

NewAfterUserCreatedInputFunction · 0.92
checkTXFunction · 0.85
EnabledMethod · 0.80
InvokeHookMethod · 0.65

Tested by

no test coverage detected