NAME

Finance::Bitcoin::Yacuna - yacuna.com API connector

VERSION

0.1

SYNOPSIS

 use Finance::Bitcoin::Yacuna;

 my $yacuna = Finance::Bitcoin::Yacuna->new(
        tokenId => $apiTokenId, 
        secret => $apiSecret, 
        apiVersion => 1, # optional, default:1
        debug => 0, # optional, default:0
        skipSSL => 0, # optional, default:0
        sandbox => 0 # optional, default:0
 );

 $result = $yacuna->call($httpMethod, $restPath, ["param1=$param1", "param2=$param2", ..]);

 use Data::Dump qw(dump);
 use JSON;
 my $json = new JSON;
 dump $json->decode($result);

DESCRIPTION

The module to connect to the api of the bitcoin exchange Yacuna.

Please see Yacuna API documentation for a catalog of api methods.

METHODS

$yacuna = Finance::Bitcoin::Yacuna->new( tokenId => $apiTokenId, secret => $apiSecret, apiVersion => 1, # optional, default:1 debug => 0, # optional, default:0 skipSSL => 0, # optional, default:0 sandbox => 0 # optional, default:0 );

The constructor. Returns a Finance::Bitcoin::Yacuna object.

$result = $yacuna->call($httpMethod, $restPath, ["param1=$param1", "param2=$param2", ..]);

Calls the API method $restPath (with the given $params, where applicable) and returns either undef or a JSON string.

DEPENDENCIES

WWW::Mechanize
HTTP::Request
MIME::Base64
Digest::SHA
Data::Dump

AUTHOR and COPYRIGHT

Copyright Andrei Martchouk <andrei at yacuna dot com>