Skip to content

fix(hooks): send_email payload site_url should use GOTRUE_SITE_URL (fixes #2558) - #2715

Open
deepshekhardas wants to merge 3 commits into
supabase:masterfrom
deepshekhardas:fix/2558-hook-site-url
Open

fix(hooks): send_email payload site_url should use GOTRUE_SITE_URL (fixes #2558)#2715
deepshekhardas wants to merge 3 commits into
supabase:masterfrom
deepshekhardas:fix/2558-hook-site-url

Conversation

@deepshekhardas

Copy link
Copy Markdown

fix(hooks): send_email payload site_url should use GOTRUE_SITE_URL (fixes #2558)

The send_email hook payload's email_data.site_url was populated from
API_EXTERNAL_URL (e.g. https://<ref>.supabase.co/auth/v1) instead of
GOTRUE_SITE_URL (e.g. https://myapp.com), unlike the SMTP template
path ({{ .SiteURL }}m.cfg.SiteURL). Hooks building confirmation
links from site_url pointed at the auth server instead of the app.

Use config.SiteURL for the hook payload, matching the templates.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

send_email hook payload site_url uses API_EXTERNAL_URL instead of GOTRUE_SITE_URL

1 participant