{"id":24760019,"url":"https://github.com/Dhanya-Abhirami/GoMail","last_synced_at":"2025-10-11T06:31:37.329Z","repository":{"id":103343696,"uuid":"473729510","full_name":"Dhanya-Abhirami/GoMail","owner":"Dhanya-Abhirami","description":"A simple client to send and receive emails.","archived":false,"fork":false,"pushed_at":"2022-10-17T07:54:12.000Z","size":28,"stargazers_count":1,"open_issues_count":1,"forks_count":0,"subscribers_count":1,"default_branch":"main","last_synced_at":"2025-03-20T19:09:31.530Z","etag":null,"topics":["dotenv","go-gin","golang","jwt","kafka","middleware","mongodb","postman-collection","restful-api","swagger-ui"],"latest_commit_sha":null,"homepage":"","language":"Go","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/Dhanya-Abhirami.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}},"created_at":"2022-03-24T18:34:24.000Z","updated_at":"2023-03-04T09:38:41.000Z","dependencies_parsed_at":"2024-01-20T04:31:26.886Z","dependency_job_id":null,"html_url":"https://github.com/Dhanya-Abhirami/GoMail","commit_stats":null,"previous_names":["dhanya-abhirami/go-gin-microservices-pg"],"tags_count":0,"template":false,"template_full_name":null,"purl":"pkg:github/Dhanya-Abhirami/GoMail","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Dhanya-Abhirami%2FGoMail","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Dhanya-Abhirami%2FGoMail/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Dhanya-Abhirami%2FGoMail/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Dhanya-Abhirami%2FGoMail/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/Dhanya-Abhirami","download_url":"https://codeload.github.com/Dhanya-Abhirami/GoMail/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Dhanya-Abhirami%2FGoMail/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":279006456,"owners_count":26084108,"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","status":"online","status_checked_at":"2025-10-11T02:00:06.511Z","response_time":55,"last_error":null,"robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":true,"can_crawl_api":true,"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":["dotenv","go-gin","golang","jwt","kafka","middleware","mongodb","postman-collection","restful-api","swagger-ui"],"created_at":"2025-01-28T17:17:55.240Z","updated_at":"2025-10-11T06:31:37.040Z","avatar_url":"https://github.com/Dhanya-Abhirami.png","language":"Go","funding_links":[],"categories":[],"sub_categories":[],"readme":"# GoMail\r\nA simple client to send and receive emails.\r\n\r\n![Alt text](assets/GoMail.drawio.svg?raw=true \"Title\")\r\n\r\n## Backend\r\n* Golang with gin\r\n* MongoDB (remote DB based in mLab)\r\n* Kafka\r\n\r\n## Setting up\r\n```bash\r\ncd email-client/src\r\nmake build\r\nmake run\r\n```\r\n\r\n## File Structure\r\n```\r\nModel - For modelling entities\r\nRoutes - Controller\r\nHandler - Service\r\nMiddleware - interceptor\r\nHelper - Utils\r\n```\r\n\r\n## Requirements\r\n### Fetch Inbox\r\n\r\nThe user should be able to fetch their inbox emails. The task is to create an endpoint “localhost:8080/user/mail/inbox” to fetch the inbox.\r\n\r\n \r\n\r\na. Choose appropriate HTTP methods (GET,POST,PUT,DELETE) to hit this URL.\r\n\r\n \r\n\r\nb. There should be a key-value pair of “Authorization: \u003cJWT_TOKEN\u003e” \u0026 if it's incorrect or not present, the API should throw a Bad Request Exception with 401 Unauthorized code.\r\n\r\nThe username can be identified from the JWT_TOKEN.\r\n\r\n \r\n\r\nc. In case the user name exists in the database we should fetch the inbox details sorted by date (descending order of date), as a response with appropriate HTTP status.\r\n\r\n### Send Email API\r\n\r\nThe user should be able to send an email to another user.The task is to create an endpoint localhost:8080/user/mail/send to send an email to a user\r\n\r\n \r\n\r\na. Choose appropriate HTTP methods (GET,POST,PUT,DELETE) to hit this URL.\r\n\r\nb. The user needs to provide the details of the email like (sender email address, list of receiver’s email address, subject line, email body) in the request body.\r\n\r\n \r\n\r\nBasic validation on the attributes of the email needs to be performed with the following rules :\r\n\r\n• Receiver Email address: It should be a valid email ID format\r\n• Subject: It should be a minimum of 2 characters and a maximum of 100 characters\r\n• Email Body: It should be a minimum of 10 chars and a maximum of 1500 characters\r\n• Date: It should be sent as the current date\r\n \r\n\r\nc. In case a user provides wrong input, they should get a message saying “Invalid Details” with the appropriate HTTP status.\r\n\r\n \r\n\r\nd. In case the user provides the right set of inputs, the data should get stored in the database and we should get a response with a message “ Email sent successfully” with appropriate HTTP status.\r\n\r\n### Fetch Outbox\r\n\r\nThe task is to create an endpoint “localhost:8080/user/mail/outbox” to fetch the outbox of a user.\r\n\r\n \r\n\r\na. Choose appropriate HTTP methods (GET, POST, PUT, DELETE) to hit this URL.\r\n\r\n \r\n\r\nb. There should be a key-value pair of “Authorization: \u003cJWT_TOKEN\u003e” \u0026 if it's incorrect or not present, the API should throw a Bad Request Exception with 401 Unauthorized code.\r\n\r\n \r\n\r\nc. The username of the user can be identified from the JWT_TOKEN.\r\n\r\n \r\n\r\nd. In case the user name exists in the database we should fetch the outbox details sorted by date (descending order of date), as a response with appropriate HTTP status.","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2FDhanya-Abhirami%2FGoMail","html_url":"https://awesome.ecosyste.ms/projects/github.com%2FDhanya-Abhirami%2FGoMail","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2FDhanya-Abhirami%2FGoMail/lists"}