v1.0972

Introduction

Reddit::Client is a wrapper for the Reddit API written in Perl. Its source can be found at its home on CPAN and on Bitbucket. This is the official documentation.

Reddit::Client uses Oauth for all communication with Reddit; the cookie-based methods from older versions (pre-1.0) are no longer available. For help setting up your first app, see Oauth Setup.

Example

use Reddit::Client;

my $reddit = new Reddit::Client(
    user_agent      => "Reddit::Client test 1.0 by /u/earth-tone",
    client_id       => "DFhtrhBgfhhRTd",
    secret          => "KrDNsbeffdbILOdgbgSvSBsbfFs",
    username        => "reddit_username",
    password        => "reddit_password"               
);

my $me = $reddit->me();

print "You've got mail!" if $me->{has_mail};

For the list of methods, see Main Methods.

For some example scripts and snippets, see Examples.

Installation

For Linux, Unix, OSX, and Windows with Strawberry Perl, open a console window and enter

cpan Reddit::Client

License

Reddit::Client is available under the BSD license.

Author

earthtone.rc@gmail.com