firebase-admin-node
firebase-admin-node copied to clipboard
[firebase-admin] dynamic custom link suffix not added in email verification links in auth admin
- Operating System version: -
- Firebase SDK version: -
- Firebase Product: firebase-admin
- Node.js version: 15.9.0
- NPM version: 7.5.3
[REQUIRED] Step 3:
Steps to reproduce:
link-suffix is not added in the generatePasswordResetLink and generateEmailVerificationLink of auth admin (firebase-admin/lib/auth) like https://firebase.google.com/docs/dynamic-links/custom-domains
it should be automatically added or ActionCodeSettings should include such param, for instance if you have example.com/link dynamic link, example.com/?link=... is generated instead of example.com/link/?link=...
Relevant Code:
const link: string = await admin.auth().generateEmailVerificationLink(someEmail, {url: '...', dynamicLinkDomain: '...'});
const link: string = await admin.auth().generatePasswordResetLink(someEmail, {url: '...', dynamicLinkDomain: '...'});
I found a few problems with this issue:
- I couldn't figure out how to label this issue, so I've labeled it for a human to triage. Hang tight.
- This issue does not seem to follow the issue template. Make sure you provide all the required information.
- Operating System version: -
- Firebase SDK version: -
- Firebase Product: firebase-admin
- Node.js version: 15.9.0
- NPM version: 7.5.3
[REQUIRED] Step 3:
Steps to reproduce:
link-suffix is not added in the generatePasswordResetLink and generateEmailVerificationLink of auth admin (firebase-admin/lib/auth) like https://firebase.google.com/docs/dynamic-links/custom-domains
it should be automatically added or ActionCodeSettings should include such param, for instance if you have example.com/link dynamic link, example.com/?link=... is generated instead of example.com/link/?link=...
Relevant Code:
const link: string = await admin.auth().generateEmailVerificationLink(someEmail, {url: '...', dynamicLinkDomain: '...'}); const link: string = await admin.auth().generatePasswordResetLink(someEmail, {url: '...', dynamicLinkDomain: '...'});
Were you ever able to find a solution to this? Running into the same problem.
Can you share what you are passing in as the "dynamicLinkDomain" parameter in the admin SDK/rest API call?
Passing in should throw a INVALID_DYNAMIC_LINK_DOMAIN error, since we only accept domain names registered in Firebase Dynamic links.
cc @renkelvin