Skip to content

feat(auth): Update ActionCodeSettings to support link_domain and deprecate dynamic_link_domain #884

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged

Conversation

huwmartin
Copy link
Contributor

@huwmartin huwmartin commented Jun 3, 2025

Discussion

Firebase Dynamic Links will stop working August 25th 2025.

Migration instructions indicate that to use a custom domain one should update usage of ActionCodeSettings to use linkDomain, see also in the Firebase Admin docs.

We currently depend upon generate_sign_in_with_email_link to generate email links, firebase-admin-python hasn't been updated with link_domain and currently only supports dynamic_link_domain, firebase-admin-node has been updated with support for linkDomain so I assume this should be officially supported, please let me know if this is not the case.

See #883.

This PR updates ActionCodeSettings to accept link_domain and updates encode_action_code_settings to handle link_domain when constructing request payload. I have also added definition for new InvalidHostingLinkDomainError error.

@huwmartin
Copy link
Contributor Author

@lahirumaramba @pashanka see here re: #883. In my org we're currently relying on this via a fork and would be great to get into main release.

Copy link

@Xiaoshouzi-gh Xiaoshouzi-gh left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks for putting this together!

Copy link

@Xiaoshouzi-gh Xiaoshouzi-gh left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thank you for putting this together!

Copy link

@Xiaoshouzi-gh Xiaoshouzi-gh left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@huwmartin huwmartin force-pushed the action-code-settings-link-domain branch from 1d9d933 to dfce7c1 Compare July 7, 2025 17:33
@lahirumaramba lahirumaramba self-assigned this Jul 8, 2025
@jonathanedey jonathanedey self-requested a review July 14, 2025 14:14
Copy link
Contributor

@jonathanedey jonathanedey left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks @huwmartin for putting this together! Overall LGTM with one minor change below.

@jonathanedey jonathanedey requested review from egilmorez and removed request for OrlandriaH-G July 23, 2025 15:12
Copy link
Contributor

@jonathanedey jonathanedey left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM! Please address the lint error and update the branch, Thanks!

Copy link

@egilmorez egilmorez left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LG, thanks!

@huwmartin
Copy link
Contributor Author

@jonathanedey thanks, lots of other issues when running ./lint.sh all locally, CI appears to only lint touched lines(?), so difficult to tell what will snag 😄 I've updated all of ActionCodeSettings.__init__ for consistency.

@jonathanedey
Copy link
Contributor

jonathanedey commented Jul 23, 2025

@huwmartin, no worries, those were mainly because the branch was out of date. We made some lint changes in or last release and the CI here are using those settings. Thanks again for you contribution!

@jonathanedey jonathanedey changed the title Update ActionCodeSettings to support link_domain feat(auth) Update ActionCodeSettings to support link_domain and deprecate dynamic_link_domain Jul 23, 2025
@jonathanedey jonathanedey merged commit 4fa2918 into firebase:master Jul 23, 2025
10 checks passed
@jonathanedey jonathanedey changed the title feat(auth) Update ActionCodeSettings to support link_domain and deprecate dynamic_link_domain feat(auth): Update ActionCodeSettings to support link_domain and deprecate dynamic_link_domain Jul 23, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

6 participants