Help for this page

Select Code to Download


  1. or download this
    #!/usr/bin/env perl
    use Mojolicious::Lite;
    ...
    get '/_live' => sub { shift->render( json => { alive_since => (time - 
    +$startup) } ) };
    
    app->start;
    
  2. or download this
    #!/usr/bin/env perl
    
    ...
        ->json_is({success => 1, code => 200, message => 'OK'});
    
    done_testing();