Add Neon Auth Phone Number plugin documentation#4788
Closed
Conversation
- Add new plugin page at content/docs/auth/guides/plugins/phone-number.md - Add Phone Number row to plugins index and roadmap (moved out of "On the roadmap") - Add /plugins/phone_number endpoint to manage-auth-api reference - Add phone_number.verified event and note SMS delivery_preference on send.otp in webhooks guide - Link nextjs-phone-login example from overview and plugins pages - Add Phone Number entry to docs navigation under Plugins Do not merge until the backend switches /plugins/phone_number from PUT to PATCH on staging, neon-js publishes a version with phoneNumberClient (#74) plus bugfixes (#76, #78), and the Console feature flag rolls out.
|
The latest updates on your projects. Learn more about Vercel for GitHub.
|
…erence The send.otp webhook event_data does not include a phone_number field; the phone number is available via user.phone_number. Removed the non-existent fallback from the SMS handler example and rewrote the accompanying admonition to describe the real behavior (minimal user object on first OTPs, where profile fields beyond phone_number are not populated). Also dropped the "and Magic Link" comparison since the Magic Link plugin page is not yet merged on main.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Adds Neon Auth docs for the upcoming Phone Number plugin (LKB-11605), mirroring the scope of the Magic Link PR (#4750).
content/docs/auth/guides/plugins/phone-number.mdcovering intro, prerequisites, how users link a phone to an existing account, Console + API enablement, SMS provider webhook integration (required), the two-step SDK sign-in flow, integration withAuthView, webhook events, and limitations.content/docs/auth/guides/plugins.md): adds Phone Number row and links thenextjs-phone-loginexample.content/docs/auth/roadmap.md): moves Phone Number from "On the roadmap" to Supported.content/docs/auth/guides/manage-auth-api.md): adds/plugins/phone_numberrow.content/docs/auth/guides/webhooks.md): addsphone_number.verifiedevent (non-blocking), documents the SMSdelivery_preferenceonsend.otp, and updates theenabled_eventslist and example payload.content/docs/auth/overview.md): links thenextjs-phone-loginexample.content/docs/navigation.yaml): adds Phone Number under Plugins (alphabetical).Two things the page makes unmistakable:
send.otpwebhook that forwards the code to your SMS provider is a hard requirement.Related PRs
[neon-auth/be] feat: support partial phone number plugin config updates(LKB-11605) -- initial endpoint + partial-update (PUT -> PATCH)[lakebase/web] feat: Add phone number plugin UI with feature flag(LKB-11605) -- Console card behind a feature flagfeat: add phoneNumber client plugin for phone OTP sign-inmisc: add phone number login example app--examples/nextjs-phone-login[auth] fix: refresh session_data cookie cache on mutation responsesfix(auth): normalize adapter errors to AuthApiError (.status + .code)Do not merge until
/projects/{project_id}/branches/{branch_id}/auth/plugins/phone_numbershowsPATCH(notPUT) with a partial-update body schema. Staging currently exposesPUTwith the full-object body.neon-jsversion includesphoneNumberClient()(feat: add redirectFrom field in the frontmatter #74) and the two bugfixes (Mention the default Postgres schema in docs #76, Add release notes #78).public/docs/auth/neon_auth_plugins_phone_number.pngwith a real Console capture (the page references this path but the asset is not committed yet).Test plan
npm run devand visually review the new plugin page under/docs/auth/guides/plugins/phone-number.examples/nextjs-phone-loginend-to-end against a flag-enabled project with asend.otpwebhook wired to Twilio (or similar) and confirm the docs match the observed flow.Follow-ups
@neondatabase/neon-js/auth/react/uito match the existing convention inemail-otp.mdand the Magic Link PR (Add Neon Auth Magic Link plugin documentation #4750). Theexamples/nextjs-phone-loginapp inneondatabase/neon-jsimports from@neondatabase/auth/react/ui. These should be reconciled before GA — either update the example to use the documented path, or switch the Neon Auth plugin pages over to@neondatabase/auth/react/uifor consistency with the shipping SDK.