{
    "content": [
        {
            "type": "text",
            "text": "# Mail::Send (perldoc)\n\n## NAME\n\nMail::Send - Simple electronic mail interface\n\n## SYNOPSIS\n\nrequire Mail::Send;\n$msg = Mail::Send->new;\n$msg = Mail::Send->new(Subject => 'example', To => 'timbo');\n$msg->to('user@host');\n$msg->to('user@host', 'user2@example.com');\n$msg->subject('example subject');\n$msg->cc('user@host');\n$msg->bcc('someone@else');\n$msg->set($header, @values);\n$msg->add($header, @values);\n$msg->delete($header);\n# Launch mailer and set headers. The filehandle returned\n# by open() is an instance of the Mail::Mailer class.\n# Arguments to the open() method are passed to the Mail::Mailer\n# constructor.\n$fh = $msg->open;   # some default mailer\n$fh = $msg->open('sendmail'); # explicit\nprint $fh \"Body of message\";\n$fh->close          # complete the message and send it\nor die \"couldn't send whole message: $!\\n\";\n\n## DESCRIPTION\n\nMail::Send creates e-mail messages without using the Mail::Header knowledge, which means that\nall escaping and folding must be done by you! Also: do not forget to escape leading dots.\nSimplicity has its price.\n\n## Sections\n\n- **NAME**\n- **SYNOPSIS**\n- **DESCRIPTION**\n- **METHODS** (3 subsections)\n- **SEE ALSO**\n- **AUTHORS**\n- **LICENSE**\n\nUse structuredContent.sections for detailed options, examples, and full documentation.\n"
        }
    ],
    "structuredContent": {
        "command": "Mail::Send",
        "section": "",
        "mode": "perldoc",
        "summary": "Mail::Send - Simple electronic mail interface",
        "synopsis": "require Mail::Send;\n$msg = Mail::Send->new;\n$msg = Mail::Send->new(Subject => 'example', To => 'timbo');\n$msg->to('user@host');\n$msg->to('user@host', 'user2@example.com');\n$msg->subject('example subject');\n$msg->cc('user@host');\n$msg->bcc('someone@else');\n$msg->set($header, @values);\n$msg->add($header, @values);\n$msg->delete($header);\n# Launch mailer and set headers. The filehandle returned\n# by open() is an instance of the Mail::Mailer class.\n# Arguments to the open() method are passed to the Mail::Mailer\n# constructor.\n$fh = $msg->open;   # some default mailer\n$fh = $msg->open('sendmail'); # explicit\nprint $fh \"Body of message\";\n$fh->close          # complete the message and send it\nor die \"couldn't send whole message: $!\\n\";",
        "tldr_summary": null,
        "tldr_examples": [],
        "tldr_source": null,
        "flags": [],
        "examples": [],
        "see_also": [],
        "section_outline": [
            {
                "name": "NAME",
                "lines": 2,
                "subsections": []
            },
            {
                "name": "SYNOPSIS",
                "lines": 26,
                "subsections": []
            },
            {
                "name": "DESCRIPTION",
                "lines": 6,
                "subsections": []
            },
            {
                "name": "METHODS",
                "lines": 1,
                "subsections": [
                    {
                        "name": "Constructors",
                        "lines": 5
                    },
                    {
                        "name": "Header fields",
                        "lines": 13
                    },
                    {
                        "name": "Sending",
                        "lines": 7
                    }
                ]
            },
            {
                "name": "SEE ALSO",
                "lines": 2,
                "subsections": []
            },
            {
                "name": "AUTHORS",
                "lines": 7,
                "subsections": []
            },
            {
                "name": "LICENSE",
                "lines": 6,
                "subsections": []
            }
        ],
        "sections": {
            "NAME": {
                "content": "Mail::Send - Simple electronic mail interface\n",
                "subsections": []
            },
            "SYNOPSIS": {
                "content": "require Mail::Send;\n\n$msg = Mail::Send->new;\n$msg = Mail::Send->new(Subject => 'example', To => 'timbo');\n\n$msg->to('user@host');\n$msg->to('user@host', 'user2@example.com');\n$msg->subject('example subject');\n$msg->cc('user@host');\n$msg->bcc('someone@else');\n\n$msg->set($header, @values);\n$msg->add($header, @values);\n$msg->delete($header);\n\n# Launch mailer and set headers. The filehandle returned\n# by open() is an instance of the Mail::Mailer class.\n# Arguments to the open() method are passed to the Mail::Mailer\n# constructor.\n\n$fh = $msg->open;   # some default mailer\n$fh = $msg->open('sendmail'); # explicit\nprint $fh \"Body of message\";\n$fh->close          # complete the message and send it\nor die \"couldn't send whole message: $!\\n\";\n",
                "subsections": []
            },
            "DESCRIPTION": {
                "content": "Mail::Send creates e-mail messages without using the Mail::Header knowledge, which means that\nall escaping and folding must be done by you! Also: do not forget to escape leading dots.\nSimplicity has its price.\n\nWhen you have time, take a look at Mail::Transport which is part of the MailBox suite.\n",
                "subsections": []
            },
            "METHODS": {
                "content": "",
                "subsections": [
                    {
                        "name": "Constructors",
                        "content": "Mail::Send->new(PAIRS)\nA list of header fields (provided as key-value PAIRS) can be used to initialize the object,\nlimited to the few provided as method: \"to\", \"subject\", \"cc\", and \"bcc\". For other header\nfields, use add().\n"
                    },
                    {
                        "name": "Header fields",
                        "content": "$obj->add($fieldname, @values)\nAdd values to the list of defined values for the $fieldname.\n\n$obj->bcc(@values)\n$obj->cc(@values)\n$obj->delete($fieldname)\n$obj->set($fieldname, @values)\nThe @values will replace the old values for the $fieldname. Returned is the LIST of values\nafter modification.\n\n$obj->subject(@values)\n$obj->to(@values)\n"
                    },
                    {
                        "name": "Sending",
                        "content": "$obj->open(%options)\nThe %options are used to initiate a mailer object via Mail::Mailer::new(). Then\nMail::Mailer::open() is called with the knowledge collected in this \"Mail::Send\" object.\n\nBe warned: this module implements raw smtp, which means that you have to escape lines which\nstart with a dot, by adding one in front.\n"
                    }
                ]
            },
            "SEE ALSO": {
                "content": "This module is part of the MailTools distribution, http://perl.overmeer.net/mailtools/.\n",
                "subsections": []
            },
            "AUTHORS": {
                "content": "The MailTools bundle was developed by Graham Barr. Later, Mark Overmeer took over maintenance\nwithout commitment to further development.\n\nMail::Cap by Gisle Aas <aas@oslonett.no>. Mail::Field::AddrList by Peter Orbaek <poe@cit.dk>.\nMail::Mailer and Mail::Send by Tim Bunce <Tim.Bunce@ig.co.uk>. For other contributors see\nChangeLog.\n",
                "subsections": []
            },
            "LICENSE": {
                "content": "Copyrights 1995-2000 Graham Barr <gbarr@pobox.com> and 2001-2017 Mark Overmeer\n<perl@overmeer.net>.\n\nThis program is free software; you can redistribute it and/or modify it under the same terms as\nPerl itself. See http://www.perl.com/perl/misc/Artistic.html\n",
                "subsections": []
            }
        }
    }
}