{"id":25002192,"url":"https://github.com/evrendev/office365-mailing","last_synced_at":"2025-07-09T09:35:28.355Z","repository":{"id":274979321,"uuid":"924689340","full_name":"evrendev/office365-mailing","owner":"evrendev","description":"A .NET Core service for sending bulk emails through Office 365 with rate limiting and tracking capabilities. Built using Clean Architecture principles.","archived":false,"fork":false,"pushed_at":"2025-01-30T13:29:40.000Z","size":8,"stargazers_count":0,"open_issues_count":0,"forks_count":0,"subscribers_count":1,"default_branch":"main","last_synced_at":"2025-01-30T14:30:09.637Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":null,"language":"C#","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/evrendev.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":null,"code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2025-01-30T13:27:18.000Z","updated_at":"2025-01-30T13:29:44.000Z","dependencies_parsed_at":"2025-02-03T02:15:14.461Z","dependency_job_id":null,"html_url":"https://github.com/evrendev/office365-mailing","commit_stats":null,"previous_names":["evrendev/office365-mailing"],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/evrendev%2Foffice365-mailing","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/evrendev%2Foffice365-mailing/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/evrendev%2Foffice365-mailing/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/evrendev%2Foffice365-mailing/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/evrendev","download_url":"https://codeload.github.com/evrendev/office365-mailing/tar.gz/refs/heads/main","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":246243567,"owners_count":20746307,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":[],"created_at":"2025-02-04T21:39:15.058Z","updated_at":"2025-03-29T20:44:14.183Z","avatar_url":"https://github.com/evrendev.png","language":"C#","funding_links":[],"categories":[],"sub_categories":[],"readme":"# Office 365 Mailing Service\n\nA .NET Core service for sending bulk emails through Office 365 with rate limiting and tracking capabilities. Built using Clean Architecture principles.\n\n## Features\n\n- Office 365 SMTP integration\n- Daily email rate limiting (configurable, default 3600/day)\n- Email tracking to prevent duplicate sends\n- CSV-based recipient management\n- HTML email template support with personalization\n- Swagger API documentation\n- Clean Architecture implementation\n- Entity Framework Core for data persistence\n\n## Prerequisites\n\n- .NET 7.0 SDK\n- SQL Server (or LocalDB)\n- Office 365 account with SMTP access\n- Visual Studio 2022 or VS Code\n\n## Project Structure\n\n```\nMailingService/\n├── src/\n│   ├── MailingService.Domain/        # Enterprise business rules\n│   ├── MailingService.Application/   # Application business rules\n│   ├── MailingService.Infrastructure/# Data and external concerns\n│   └── MailingService.Api/           # API endpoints and configuration\n```\n\n## Configuration\n\n1. Update `appsettings.json` with your settings:\n\n```json\n{\n  \"ConnectionStrings\": {\n    \"DefaultConnection\": \"Your-DB-Connection-String\"\n  },\n  \"MailSettings\": {\n    \"Office365Username\": \"your-email@yourdomain.com\",\n    \"Office365Password\": \"your-password\",\n    \"FromEmail\": \"your-email@yourdomain.com\",\n    \"FromName\": \"Your Name\",\n    \"HtmlTemplatePath\": \"Templates/email-template.html\",\n    \"CsvFilePath\": \"Data/recipients.csv\",\n    \"DailyEmailLimit\": 3600\n  }\n}\n```\n\n2. Create required directories and files:\n   - `Templates/email-template.html` - Your email template\n   - `Data/recipients.csv` - CSV file with recipients (format: Email,Name)\n\n## Getting Started\n\n1. Clone the repository:\n\n```bash\ngit clone https://github.com/yourusername/MailingService.git\n```\n\n2. Navigate to the project directory:\n\n```bash\ncd MailingService\n```\n\n3. Restore dependencies:\n\n```bash\ndotnet restore\n```\n\n4. Update the database:\n\n```bash\ndotnet ef database update\n```\n\n5. Run the application:\n\n```bash\ndotnet run --project src/MailingService.Api\n```\n\n## API Endpoints\n\n### Send Batch Emails\n\n```http\nPOST /api/email/send-batch\n```\n\nReads recipients from CSV file and sends personalized emails.\n\n### Check Daily Count\n\n```http\nGET /api/email/daily-count\n```\n\nReturns current daily email statistics.\n\n## CSV File Format\n\nThe recipients CSV file should follow this format:\n\n```csv\nEmail,Name\nrecipient1@example.com,John Doe\nrecipient2@example.com,Jane Smith\n```\n\n## HTML Template\n\nThe HTML template supports personalization using placeholders:\n\n```html\n\u003chtml\u003e\n  \u003cbody\u003e\n    \u003ch1\u003eHello {{Name}}\u003c/h1\u003e\n    \u003cp\u003eYour email content here.\u003c/p\u003e\n  \u003c/body\u003e\n\u003c/html\u003e\n```\n\n## Development\n\n- Follow Clean Architecture principles\n- Use Entity Framework Core migrations for database changes\n- Keep services stateless\n- Handle exceptions appropriately\n- Use async/await for I/O operations\n\n## Security Considerations\n\n- Store sensitive data (passwords, connection strings) in user secrets during development\n- Use appropriate authentication/authorization in production\n- Implement rate limiting per client if needed\n- Monitor for abuse\n\n## Contributing\n\n1. Fork the repository\n2. Create your feature branch\n3. Commit your changes\n4. Push to the branch\n5. Create a new Pull Request\n\n## License\n\nThis project is licensed under the MIT License - see the LICENSE file for details.\n# office365-mailing\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fevrendev%2Foffice365-mailing","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fevrendev%2Foffice365-mailing","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fevrendev%2Foffice365-mailing/lists"}