NAME
Mackerel::Webhook::Receiver::Declare - DSL interface of Mackerel::Webhook::Receiver
SYNOPSIS
use Mackerel::Webhook::Receiver::Declare;
my $receiver = receiver {
on alert => sub {
my ($event, $req) = @_;
warn $event->event;
my $payload = $event->payload;
};
};
$receiver->to_app;
DESCRIPTION
Mackerel::Webhook::Receiver::Declare provides DSL interface of Mackerel::Webhook::Receiver.
LICENSE
Copyright (C) Songmu.
This library is free software; you can redistribute it and/or modify it under the same terms as Perl itself.
AUTHOR
Songmu <y.songmu@gmail.com>