Author image Dmytro Nikolayev

NAME

Ukrmoney::API - Perl extension for UkrMoney.com Payment System

SYNOPSIS

  use UkrMoney::API;
  my $um = new UkrMoney::API;
  
  #login in.. login fucntion returns your session_id, but this is not needed to remember it,
  #cause UkrMoney::API module remembers it for you, so all operations below go with this session_id param. 
  $um->login({login => 'your@email.com', password => 'yourpassword'});
  
  #making new transaction
  $um->trans({'payee_purse'     => '1',
              'amount'          => '200',
              'description'     => 'payment for product id#3274823',
              'benef_email'     => 'receiver_email',
              'mode'            => 'test'});
  
  #getting the last 10 transactions on purse #1 on you account:
  my $transactions = $um->trans_list({purse => '1', offset => -10, limit => 10});
  
  #checking the time of last transaction
  my $time = $transactions->[scalar(@{$transactions})-1]->{'transaction'}->{'time'};
  
  

DESCRIPTION

UkrMoney::API is needed to work with UkrMoney payment system from your scripts (like automated payments scripts, etc..)

Main methods

  • $um->login({params..}) - Logining to system via automated API, needed params:

    login

    login is your email in the system

    password

    password is your password in the system

  • $um->trans({params..}); - making new transaction, params needed:

    payee_purse

    payee_purse is the purse-source number

    benef_email

    benef_email is the receiver id(email) in the system

    benef_purse

    benef_purse is the receiver's purse number, if you know it,.. not needed param

    amount

    amount is the sum you want to transfer

    description

    description is the description (comment) of transfer

    mode

    mode if this is set to 'test', than transfer will be made in test mode(just check if this transfer is possible)

  • $um->trans_info({params..}); - Get information about needed transaction, params:

    trans_id

    trans_id is the transaction ID you want to check

  • $um->trans_list({params..}); - Logining to system via automated API

    purse

    purse is the purse you want to check transactions of

    offset

    offset is the offset in the list of all transactions, can be <0 then offset is counting from the end of list

    limit

    limit is the number of transactions you want to get.

  • $um->my_info(); - Getting info about current user.

  • $um->check_user({params..}); - Checking if the user you want to transfer to exists

    payee_purse

    payee_purse is the purse, from what test transaction will be made

    email

    email is the person's email you want to check

SEE ALSO

UkrMoney Online Payment System site: http://ukrmoney.com

AUTHOR

Dmitry Nikolayev <dmitry@cpan.org>, http://perl.dp.ua/resume.html

THANKS

Thanks to UkrMoney.com Support team for their help in creating of this module.

Also, thanks for DotHost Hosting Provider: http://dothost.ru for their Tech. support.

COPYRIGHT AND LICENSE

Copyright (C) 2006 by Dmitry Nikolayev

This library is free software; you can redistribute it and/or modify it under the same terms as Perl itself.