feat: integrate social sharing UI and add GitHub auto-publisher#183
Open
Unnati1007 wants to merge 3 commits into
Open
feat: integrate social sharing UI and add GitHub auto-publisher#183Unnati1007 wants to merge 3 commits into
Unnati1007 wants to merge 3 commits into
Conversation
Exposes existing Twitter/X backend integration safely in the React settings UI. Implements a new backend module to push LeetCode solutions directly to user GitHub repositories automatically via GitHub REST API.
Owner
|
Please resolve merge conflict and check for pipeline |
Author
|
@vanshaggarwal27 done do review it |
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.
Description
This PR implements the requested "Social Integrations" feature, fulfilling the "Future Scope" goals of LeetLog AI by enabling a truly 100% automated workflow from "Solving the Code" to "Social Media Promotion."
Key Changes:
Exposed Existing Social Sharing: Integrated the twitter_api_key, twitter_api_secret, twitter_access_token, and twitter_access_secret inputs into the React Settings UI. This seamlessly bridges the gap so the existing social.py logic can now successfully auto-tweet URLs without disturbing the current implementation!
GitHub Auto-Publisher Integration: Built a brand new backend module (github_integration.py) that uses the GitHub REST API to automatically commit code.
Background Execution: Wired the GitHub publisher into the /generate-blog FastAPI route so it runs silently in the background (using run_in_threadpool) immediately after a blog is generated.
Frontend Sync: Expanded the IntegrationSettings MongoDB schema and added a "GitHub Auto-Publisher" card to the React dashboard where users can securely paste their GitHub Personal Access Token and target Repository Name.
Related Issue
Fixes #162
Type of Change
Bug fix
New feature
Documentation update
Checklist
My code follows project guidelines
I have tested my changes
Documentation updated if needed