Created
December 2, 2018 19:22
-
-
Save Downes/467aaf0cf15b047267b35fe577dbb923 to your computer and use it in GitHub Desktop.
Create Badge Object in Perl
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
package gRSShopper::Badgr; | |
use strict; | |
use warnings; | |
use HTTP::Request::Common qw(POST); | |
use LWP::UserAgent; | |
use JSON qw(encode_json decode_json); | |
our $VERSION = "1.00"; | |
sub new { | |
my($class, $args) = @_; | |
my $self = bless({}, $class); | |
while (my ($ax,$ay) = each %$args) {$self->{$ax} = $ay;} | |
$self->generate_access_token(); | |
return $self; | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment