[PR #6136] [CLOSED] fix(device-authorization): make verificationUri a required option #6471

Closed
opened 2026-03-13 13:00:26 -05:00 by GiteaMirror · 0 comments
Owner

📋 Pull Request Information

Original PR: https://github.com/better-auth/better-auth/pull/6136
Author: @bytaesu
Created: 11/20/2025
Status: Closed

Base: canaryHead: 2025-11-21/fix/device-verification-required


📝 Commits (3)

  • 0c0ef81 fix: make verificationUri in deviceAuthorization required
  • 10ac66d docs: update verificationUri related content
  • 6f0f110 test: missing option in e2e

📊 Changes

5 files changed (+35 additions, -25 deletions)

View changed files

📝 demo/nextjs/lib/auth.ts (+1 -0)
📝 docs/content/docs/plugins/device-authorization.mdx (+6 -9)
📝 e2e/smoke/test/fixtures/tsconfig-declaration/src/demo.ts (+1 -0)
📝 packages/better-auth/src/plugins/device-authorization/device-authorization.test.ts (+17 -3)
📝 packages/better-auth/src/plugins/device-authorization/index.ts (+10 -13)

📄 Description

This PR introduces a breaking change in the device-authorization plugin by making verificationUri a required option.

According to RFC 8628 Section 3.2, verification_uri is required, but we also need to allow it to be customized. We are changing it from an internally defaulted value to a required option.


Summary by cubic

Makes verificationUri a required option in the device-authorization plugin to comply with RFC 8628. Removes the internal default; you must provide the verification URL.

  • Migration
    • Pass verificationUri in deviceAuthorization({ verificationUri: "/device" }) or use an absolute URL.
    • verification_uri and verification_uri_complete are derived from the provided value (user_code is appended to the complete URI).

Written for commit 6f0f110fd1. Summary will update automatically on new commits.


🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.

## 📋 Pull Request Information **Original PR:** https://github.com/better-auth/better-auth/pull/6136 **Author:** [@bytaesu](https://github.com/bytaesu) **Created:** 11/20/2025 **Status:** ❌ Closed **Base:** `canary` ← **Head:** `2025-11-21/fix/device-verification-required` --- ### 📝 Commits (3) - [`0c0ef81`](https://github.com/better-auth/better-auth/commit/0c0ef81f83f4c967265b8f40df679232668a5c7c) fix: make verificationUri in deviceAuthorization required - [`10ac66d`](https://github.com/better-auth/better-auth/commit/10ac66d14c4021ac0c11618ff2d075481951e7a6) docs: update verificationUri related content - [`6f0f110`](https://github.com/better-auth/better-auth/commit/6f0f110fd163b8d306bd3d2e83756148c9c80132) test: missing option in e2e ### 📊 Changes **5 files changed** (+35 additions, -25 deletions) <details> <summary>View changed files</summary> 📝 `demo/nextjs/lib/auth.ts` (+1 -0) 📝 `docs/content/docs/plugins/device-authorization.mdx` (+6 -9) 📝 `e2e/smoke/test/fixtures/tsconfig-declaration/src/demo.ts` (+1 -0) 📝 `packages/better-auth/src/plugins/device-authorization/device-authorization.test.ts` (+17 -3) 📝 `packages/better-auth/src/plugins/device-authorization/index.ts` (+10 -13) </details> ### 📄 Description This PR introduces a breaking change in the device-authorization plugin by making verificationUri a required option. According to [RFC 8628 Section 3.2](https://datatracker.ietf.org/doc/html/rfc8628#section-3.2), `verification_uri` is required, but we also need to allow it to be customized. We are changing it from an internally defaulted value to a required option. <!-- This is an auto-generated description by cubic. --> --- ## Summary by cubic Makes verificationUri a required option in the device-authorization plugin to comply with RFC 8628. Removes the internal default; you must provide the verification URL. - **Migration** - Pass verificationUri in deviceAuthorization({ verificationUri: "/device" }) or use an absolute URL. - verification_uri and verification_uri_complete are derived from the provided value (user_code is appended to the complete URI). <sup>Written for commit 6f0f110fd163b8d306bd3d2e83756148c9c80132. Summary will update automatically on new commits.</sup> <!-- End of auto-generated description by cubic. --> --- <sub>🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.</sub>
GiteaMirror added the pull-request label 2026-03-13 13:00:26 -05:00
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: github-starred/better-auth#6471