Skip to content

maximilianromer/ContactYourRepresentatives

Repository files navigation

Contact Your Representatives AI Letter Generator

License: MIT

Remix on Replit

This project provides a web application designed to help constituents easily draft professional letters to their elected officials using the power of AI. By providing basic information about themselves, the representative, and the issue at hand, users can generate well-structured, persuasive letters ready to be sent.

🚀 Try It Out

Try the application live:

Screenshot 2025-04-05 133146

🌟 Features

  • AI-Powered Drafting: Leverages the Perplexity AI API to generate formal, researched, and persuasive letter content.
  • Simple Interface: User-friendly form to input necessary details (user info, representative info, issue, custom instructions).
  • Customizable Output: Option to add custom instructions to guide the AI's tone, style, or specific points to include.
  • Multiple Export Options:
    • Copy the generated letter text to the clipboard.
    • Download the letter as a formatted .docx file.
    • Initiate sending the letter via the default email client, Gmail, or Outlook.
  • Theming: Supports both Light and Dark modes, respecting system preferences and allowing manual toggling.
  • Responsive Design: Adapts to various screen sizes for accessibility on desktop and mobile devices.
  • Built with Modern Tech: Utilizes React, TypeScript, Node.js, Express, and shadcn/ui components.

🛠️ Technology Stack

  • Frontend:
    • React
    • Vite
    • TypeScript
    • Wouter (Routing)
    • TanStack Query (Data Fetching/Caching)
    • shadcn/ui (Component Library)
    • Tailwind CSS (Styling)
    • docx (for .docx generation)
    • file-saver (for file downloads)
  • Backend:
    • Node.js
    • Express
    • TypeScript
    • Perplexity AI API (via Axios)
  • Shared:
    • TypeScript (for shared types/schemas)
    • Zod (Schema validation)
  • Development/Build:
    • tsx (TypeScript execution)
    • esbuild (Bundling for production)
  • Deployment:
    • Replit (Hosting & Autoscale)

🤝 Contributing

Contributions are welcome! If you'd like to contribute, please send me a message!

📄 License

This project is licensed under the MIT License. Use it as you wish.

🙏 Acknowledgements

  • Replit: For the seamless development and deployment platform.
  • Perplexity API: For providing the powerful AI model used for letter generation.
  • shadcn/ui: For the excellent collection of reusable UI components.

About

AI website to create compelling letters to government in seconds!

Topics

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages