Skip to content

feature/md-2696-add-withjwtexpiredhandler-for-expired-authenticated-user - #36

Draft
filipe-boleto wants to merge 1 commit into
mainfrom
feature/md-2696-add-withjwtexpiredhandler-for-expired-authenticated-user
Draft

filipe-boleto wants to merge 1 commit into
mainfrom
feature/md-2696-add-withjwtexpiredhandler-for-expired-authenticated-user

Conversation

@filipe-boleto

Copy link
Copy Markdown
Contributor

Summary

Add MOSProxyBuilder.withJwtExpiredHandler so a proxy can react when the authenticated-user JWT cookie is past exp. The check runs before the origin fetch and any MonetizationOS API call.

  • Return a Response to take over the reply. The README example reloads the document once (Refresh to ?reloaded=1) so the follow-up request is proxied instead of reloading forever.
  • Return nothing to keep proxying. The expired JWT is still forwarded to the MonetizationOS API.
  • With no handler registered, behavior is unchanged.

@changeset-bot

changeset-bot Bot commented Oct 1, 2026

Copy link
Copy Markdown

🦋 Changeset detected

Latest commit: 5732242

The changes in this PR will be included in the next version bump.

This PR includes changesets to release 1 package
Name Type
@monetizationos/proxy Minor

Not sure what this means? Click here to learn what changesets are.

Click here if you're a maintainer who wants to add another changeset to this PR

@filipe-boleto
filipe-boleto requested a review from benney October 1, 2026 21:36
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant