docs: add POST support for self-hosted JWT callback endpoint#3611
docs: add POST support for self-hosted JWT callback endpoint#3611thesandlord merged 4 commits intomainfrom
Conversation
Co-Authored-By: Sandeep Dinesh <sandeep@buildwithfern.com>
🤖 Devin AI EngineerI'll be helping with this pull request! Here's what you should know: ✅ I will automatically:
Note: I can only respond to comments from users who have write access to this repository. ⚙️ Control Options:
|
|
🌿 Preview your docs: https://fern-preview-24b4c0bd-46fa-4eae-a7aa-338cc628112e.docs.buildwithfern.com/learn Here are the markdown pages you've updated: |
Co-Authored-By: Sandeep Dinesh <sandeep@buildwithfern.com>
| @@ -0,0 +1,5 @@ | |||
| ## POST support for self-hosted JWT callback | |||
|
|
|||
| The self-hosted JWT callback endpoint (`/api/fern-docs/auth/jwt/callback`) now accepts `POST` requests with `application/x-www-form-urlencoded` body in addition to `GET` requests with query parameters. POST avoids exposing JWT tokens in URLs and server logs. | |||
There was a problem hiding this comment.
remove "self-hosted", this callback endpoint works for all envs
There was a problem hiding this comment.
Removed "self-hosted" from both the changelog heading and body. Pushed in 133d641.
… envs Co-Authored-By: Sandeep Dinesh <sandeep@buildwithfern.com>
|
|
||
| The JWT callback endpoint (`/api/fern-docs/auth/jwt/callback`) now accepts `POST` requests with `application/x-www-form-urlencoded` body in addition to `GET` requests with query parameters. POST avoids exposing JWT tokens in URLs and server logs. | ||
|
|
||
| Learn more about [self-hosted authentication](/learn/docs/self-hosted/authentication#basic-token-verification). |
There was a problem hiding this comment.
add a link to the auth overview page instead of self hosted specific page
There was a problem hiding this comment.
Updated to link to the auth overview page instead. Pushed in 19b6301.
Co-Authored-By: Sandeep Dinesh <sandeep@buildwithfern.com>
docs: add POST support for self-hosted JWT callback endpoint
Summary
Updates the self-hosted authentication docs to reflect that the JWT callback endpoint (
/api/fern-docs/auth/jwt/callback) now supportsPOSTwithapplication/x-www-form-urlencodedbody, in addition to the existingGETquery parameter flow. This documents the feature added in fern-platform#7059.Changes:
<Tabs>with a new POST tab showing an auto-submitting HTML form patternUpdates since last revision
application/x-www-form-urlencoded" → "in anapplication/x-www-form-urlencoded" (line 45 of auth doc)Review & Testing Checklist for Human
/learn/docs/self-hosted/authentication#basic-token-verificationresolves to the correct page and anchor in the preview<Tabs>rendering in the preview — confirm both GET and POST tabs display and switch correctlyredirectUriandtokendirectly into HTML without escaping. Acceptable for a documentation example, but worth a conscious decision since users may copy-paste this into production codeSuggested test plan: Open the preview link, navigate to the self-hosted authentication page, and verify the tabbed code examples render correctly. Check the changelog page for the new entry.
Notes
base64url/createFernJWThelper code from the GET tab to keep each example self-containedLink to Devin run | Requested by @thesandlord