Sisimai::MDA(3pm)
π Sisimai::MDA(3pm) π
okay bestie, welcome to the little corner of the Perl docs where Sisimai::MDA lives β it's the error message parser for MDA, and yes she is that girl. this is part of the User Contributed Perl Documentation situation, so pull up a chair, grab a boba, and let's get into it π§β¨
πΈ NAME πΈ
Sisimai::MDA β the error message parser for MDA. that's the whole vibe. iconic, concise, slay π
β¨ SYNOPSIS β¨
here's how you actually call her, no cap:
use Sisimai::MDA;
my $header = { 'from' => 'mailer-daemon@example.jp' };
my $string = 'mail.local: Disc quota exceeded';
my $return = Sisimai::MDA->inquire($header, \$string);
like... that's it. that's the whole entrance. π¦
π DESCRIPTION π
so Sisimai::MDA parses bounced email β the kind that gets created by some MDA. and when we say "some MDA" we mean the classics: "dovecot", "mail.local", "procmail", and so on. the whole mail-delivery-agent friend group π«Ά
π important lore drop: this class is called fromSisimai::Messageonly. she does not take walk-ins. you don't just summon her from anywhere, bestie βSisimai::Messageis the one who sets up the playdate.
π CLASS METHODS π
π "inquire(Header, Reference to message body)"
inquire() is a parser for detecting an error from a mail delivery agent. she looks at the header, she looks at the body (by reference, because we're efficient like that), and she tells you what went down. main character energy fr fr π₯
check out the whole thing in action:
my $header = { 'from' => 'mailer-daemon@example.jp' };
my $string = 'mail.local: Disc quota exceeded';
my $return = Sisimai::MDA->inquire($header, \$string);
warn Dumper $return;
$VAR1 = {
'mda' => 'mail.local',
'reason' => 'mailboxfull',
'message' => 'mail.local: Disc quota exceeded'
}
look at that structured lil hash coming back with 'mda', 'reason', and 'message' all filled in. she ate and left no crumbs π
π AUTHOR π
azumakuniyuki β the legend, the blueprint, the moment. π
π COPYRIGHT π
Copyright (C) 2014-2016,2018-2023 azumakuniyuki, All rights reserved.
(yes, the years have a lil gap in the middle β 2017 said "not today" and honestly, respect π)
β LICENSE β
this software is distributed under The BSD 2-Clause License. periodt.
okay so that's the whole page, bestie!! and before you go β the fine print at the bottom of the original was perl v5.38.2, dated 2024-03-03, filed under Sisimai::MDA(3pm). so like, this is the v5.38.2 era, 2024-03-03 coded, Sisimai::MDA(3pm) certified. now go parse some bounces and stay hydrated πβ¨ππ¦
π¦ where this page comes from
- ubuntu noble: libsisimai-perl 5.0.1-1 Β· BSD-2-Clause
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash on : a language model's rewrite of the original, under its terms