Skip to content

armando-mio/RomS

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

6 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

RomS

Repost on my Socials
RomS is a Node.js tool to download content from social platforms (Instagram, TikTok, YouTube, generic media) and re-upload it to multiple destinations (Instagram, TikTok, YouTube, Telegram channels/groups).


🏗️ Architecture & Design Patterns

RomS is designed for modularity and extensibility, leveraging several classic software design patterns:

1. Strategy Pattern

  • Where:
  • Why:
    Allows dynamic selection of the download/upload strategy at runtime based on the platform (Instagram, TikTok, YouTube, etc.).
  • How:
    Each platform has its own strategy class implementing a common interface (download(url) or upload(url, data)).

2. Factory Pattern

  • Where:
  • Why:
    Centralizes the creation of uploader instances for different platforms.
  • How:
    The factory returns the correct uploader strategy based on a string identifier.

3. Composite Pattern

  • Where:
  • Why:
    Enables uploading to multiple platforms in parallel as a single operation.
  • How:
    The composite uploader aggregates multiple platform uploaders and manages their execution and result aggregation.

4. Template Method Pattern

  • Where:
  • Why:
    Provides a base class with a default workflow for uploaders, allowing subclasses to override specific steps.

📦 Main Components


🚀 Usage

  1. Install dependencies:

    npm install
  2. Configure environment variables:
    Copy .env.example to .env and fill in your API keys and credentials.

  3. Run the main script:

    node main.js
  4. Telegram Integration:
    The bot listens for messages and can forward media or links to Instagram and other platforms.


🧩 Extending

  • Add a new platform:

    • Implement a new strategy class in the appropriate folder.
    • Register it in the factory/context.
  • Change workflow:

    • Modify the context or composite classes to adjust how downloads/uploads are orchestrated.

📚 References


📝 License

MIT License

About

Repost on my Socials - Bot that reposts every video you send from other socials into your own socials.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors