curl -H "Accept: text/plain" http://localhost:8080/serverinfo
curl -H "Accept: application/json" http://localhost:8080/serverinfo
=head1 DESCRIPTION
The WWW::Suffit Plugin for show Server and
# Json
my %json = ();
foreach my $r (@o) {
next unless ref($r) eq 'HASH';
my $key = $r->{key}; # key - Key
my $val = $r->{val}; # val - Value
$json{$key
@html, $r;
}
}
# Render
return $self->respond_to(
json => {
json => \%json,
},
text => {
text => join("", @text),