use Moo;
use WWW::Mechanize;
use Method::Signatures 20121201;
use WebService::HabitRPG::Task;
use JSON::MaybeXS;
use Data::Dumper;
use Carp qw(croak);
our $DEBUG = $ENV{HRPG_DEBUG} || 0;
our $TAG_PRE
);
has 'api_base' => (is => 'ro', default => sub { 'https://habitica.com/api/v3' });
has '_last_json' => (is => 'rw'); # For debugging
has 'tags' => (is => 'rw');
has 'tag_prefix' => (is => 'r
= 1,
:$down = 1,
:$extend = {},
) {
# Magical boolification for JSONification.
# TODO: These work with JSON::XS. Do they work with other backends?
$up = $up ? \1 : \0;
$d