fix(unsubscribe): add one-click unsubscribe#2467
Merged
waleedlatif1 merged 2 commits intostagingfrom Dec 19, 2025
Merged
Conversation
|
The latest updates on your projects. Learn more about Vercel for GitHub. |
Contributor
Greptile SummaryThis PR adds RFC 8058 compliant one-click unsubscribe support for marketing emails. The changes enable email clients to display a native "Unsubscribe" button by adding proper
Confidence Score: 5/5
Important Files Changed
Sequence DiagramsequenceDiagram
participant EC as Email Client
participant API as Unsubscribe API
participant DB as Database
Note over EC,DB: One-Click Unsubscribe Flow (RFC 8058)
EC->>API: POST /unsubscribe (form-urlencoded)<br/>with email and token in URL
API->>API: Detect form-urlencoded content type
API->>API: Parse email and token from URL params
API->>API: Verify unsubscribe token
API->>DB: Update email preferences
DB-->>API: Success
API-->>EC: 200 OK
Note over EC,DB: Traditional Unsubscribe Flow
EC->>API: POST /unsubscribe (JSON body)
API->>API: Parse JSON body with email, token, type
API->>API: Verify unsubscribe token
API->>DB: Update email preferences
DB-->>API: Success
API-->>EC: 200 OK with message
|
Collaborator
Author
|
@greptile |
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
Type of Change
Testing
Tested manually
Checklist