{"id":19373853,"url":"https://github.com/cutelyst/simple-mail","last_synced_at":"2025-04-12T06:19:23.879Z","repository":{"id":43401095,"uuid":"45946860","full_name":"cutelyst/simple-mail","owner":"cutelyst","description":"An SMTP library written in C++ for Qt. Allows applications to send emails (MIME with text, html, attachments, inline files, etc.) via SMTP. Supports SSL and SMTP authentication.","archived":false,"fork":false,"pushed_at":"2025-03-17T22:21:12.000Z","size":366,"stargazers_count":220,"open_issues_count":8,"forks_count":64,"subscribers_count":11,"default_branch":"master","last_synced_at":"2025-04-12T06:19:14.144Z","etag":null,"topics":["attachment","c-plus-plus","c-plus-plus-11","inline-files","mime","qt","qt5","recipients","simplemail","smtp","smtp-authentication"],"latest_commit_sha":null,"homepage":"","language":"C++","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"lgpl-2.1","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/cutelyst.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":".github/FUNDING.yml","license":"LICENSE","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},"funding":{"github":null,"patreon":"dantti","open_collective":null,"ko_fi":null,"tidelift":null,"community_bridge":null,"liberapay":null,"issuehunt":null,"otechie":null,"custom":null}},"created_at":"2015-11-10T23:19:04.000Z","updated_at":"2025-04-09T20:21:01.000Z","dependencies_parsed_at":"2024-03-13T02:41:13.633Z","dependency_job_id":"5d264e7a-e4c3-45e9-82cf-80eb3ee387d4","html_url":"https://github.com/cutelyst/simple-mail","commit_stats":null,"previous_names":[],"tags_count":9,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/cutelyst%2Fsimple-mail","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/cutelyst%2Fsimple-mail/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/cutelyst%2Fsimple-mail/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/cutelyst%2Fsimple-mail/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/cutelyst","download_url":"https://codeload.github.com/cutelyst/simple-mail/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":248525141,"owners_count":21118620,"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":["attachment","c-plus-plus","c-plus-plus-11","inline-files","mime","qt","qt5","recipients","simplemail","smtp","smtp-authentication"],"created_at":"2024-11-10T08:32:23.419Z","updated_at":"2025-04-12T06:19:23.845Z","avatar_url":"https://github.com/cutelyst.png","language":"C++","funding_links":["https://patreon.com/dantti"],"categories":[],"sub_categories":[],"readme":"SimpleMail\n=============================================\n\nThe SimpleMail is small library writen for Qt 5 or 6 (C++14) that allows applications to send complex emails (plain text, html, attachments, inline files, etc.) using the Simple Mail Transfer Protocol (SMTP).\n\n## Features:\n\n- Asyncronous operation\n- SMTP pipelining\n- TCP and SSL connections to SMTP servers (STARTTLS included)\n- SMTP authentication (PLAIN, LOGIN, CRAM-MD5 methods)\n- sending MIME emails (to multiple recipients)\n- plain text and HTML (with inline files) content in emails\n- nested mime emails (mixed/alternative, mixed/related)\n- multiple attachments and inline files (used in HTML)\n- different character sets (ascii, utf-8, etc) and encoding methods (7bit, 8bit, base64)\n- multiple types of recipients (to, cc, bcc)\n- error handling (including RESET command)\n- output compilant with RFC2045\n\n## Examples\n\n```c++\n#include \u003cQCoreApplication\u003e\n#include \u003cSimpleMail/SimpleMail\u003e\n\nint main(int argc, char *argv[])\n{\n    QCoreApplication app(argc, argv);\n\n    // First we need to create an Server object\n    auto server = new SimpleMail::Server;\n\n    // We will use the Gmail's smtp server (smtp.gmail.com, port 465, ssl)\n    server-\u003esetHost(\"smtp.gmail.com\");\n    server-\u003esetPort(465);\n    server-\u003esetConnectionType(SimpleMail::Server::SslConnection);\n\n    // We need to set the username (your email address) and the password for smtp authentification.\n    server-\u003esetUsername(\"your_email_address@gmail.com\");\n    server-\u003esetPassword(\"your_password\");\n\n    // Now we create a MimeMessage object. This will be the email.\n    SimpleMail::MimeMessage message;\n    message.setSender(SimpleMail::EmailAddress(\"your_email_address@gmail.com\", \"Your Name\"));\n    message.addTo(SimpleMail::EmailAddress(\"Recipient's Name \u003crecipient@host.com\u003e\"));\n    message.setSubject(\"Testing Subject\");\n\n    // First we create a MimeText object.\n    auto text = std::make_shared\u003cMimeText\u003e();\n\n    // Now add some text to the email.\n    text-\u003esetText(\"Hi,\\nThis is a simple email message.\\n\");\n\n    // Now add it to the mail\n    message.addPart(text);\n\n    // Now we can send the mail\n    SimpleMail::ServerReply *reply = server-\u003esendMail(message);\n    QObject::connect(reply, \u0026SimpleMail::ServerReply::finished, [reply] {\n        qDebug() \u003c\u003c \"ServerReply finished\" \u003c\u003c reply-\u003eerror() \u003c\u003c reply-\u003eresponseText();\n        reply-\u003edeleteLater();// Don't forget to delete it\n\n        qApp-\u003equit();\n    });\n\n    app.exec();\n}\n```\n\n## License\n\nThis project (all files including the demos/examples) is licensed under the GNU LGPL, version 2.1+.\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fcutelyst%2Fsimple-mail","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fcutelyst%2Fsimple-mail","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fcutelyst%2Fsimple-mail/lists"}