Skip to content

Conversation

@apoorvajainrp21
Copy link

@apoorvajainrp21 apoorvajainrp21 commented Dec 25, 2025

Description

This PR implements the backend controller and API endpoints required for the LiveJournal Auto-Poster. It handles the XML-RPC communication with LiveJournal, manages scheduled posts via MongoDB, and integrates Cloudinary for hosting images embedded in posts.
Implements # (LiveJournal Auto-Poster API)

Related PRS (if any):

This backend PR is related to the #4624 frontend PR.

Main changes explained:

  • Create liveJournalPostController.js: Implemented the postToLiveJournal logic using the XML-RPC protocol.
  • Update liveJournalPostController.js: Added Cloudinary integration to upload and host images before embedding them in post HTML.
  • Update liveJournalPostController.js: Implemented schedulePost, updateScheduledPost, and deleteScheduledPost to manage delayed publications in the database.
  • Update liveJournalPostController.js: Added logic to handle alt text and image title attributes for accessibility and hover effects.
  • Update package.json: Added cloudinary and streamifier dependencies.

How to test:

  • check into current branch feature/livejournal-backend-api
  • do npm install to install cloudinary and streamifier.
  • Ensure your .env file has valid CLOUDINARY_CLOUD_NAME, CLOUDINARY_API_KEY, and CLOUDINARY_API_SECRET values.
  • Start the server (npm start).
  • Schedule a post and verify it is being posted.

Screenshots or videos of changes:

Note:

Reviewers must run npm install to pull in the new Cloudinary dependencies. Ensure environment variables are set up locally for testing.

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.

2 participants