NAME
Finance::Bank::DE::NetBank - Check your NetBank Bank Accounts with Perl
SYNOPSIS
use Finance::Bank::DE::NetBank;
my $account = Finance::Bank::DE::NetBank->new(
CUSTOMER_ID => "12345678",
ACCOUNT_ID => "12345678",
PASSWORD => "ROUTE66",
);
$account->connect();
$account->login();
print $account->saldo();
$account->logout();
DESCRIPTION
This module extends the Finance::Bank::DE::SpardaBank module for usage with the online banking service provided by the german NetBank (www.netbank.de).
All methods are included from Finance::Bank::DE::SpardaBank - only the constructor is modified to fit with the NetBank Website.
It uses OOD and doesn't export anything.
WARNING! This module is neither offical nor is it tested to be 100% save! Because of the nature of web-robots, everything may break from one day to the other when the underlaying web interface changes.
This is code for online banking, and that means your money, and that means BE CAREFUL. You are encouraged, nay, expected, to audit the source of this module yourself to reassure yourself that I am not doing anything untoward with your banking data. This software is useful to me, but is provided under NO GUARANTEE, explicit or implied.
METHODS
new(%values)
This constructor will set the default values and/or user provided values for connection and authentication.
my $account = Finance::Bank::DE::NetBank->new ( CUSTOMER_ID => "demo", PASSWORD => "", ACCOUNT => "2777770", , @_);
If you don't provide any values the module will automatically use the demo account.
CUSTOMER_ID is your "Kundennummer" and ACCOUNT is the "Kontonummer" (if you have only one account you can skip that)
connect()
This method will create the user agent and connect to the online banking website. Also this (done by WWW::Mechanize) automagically handles the session-id handling.
$account->connect();
login(%values)
This method will try to log in with the provided authentication details. If nothing is specified the values from the constructor or the defaults will be used.
$account->login(ACCOUNT => "1234");
saldo(%values)
This method will return the current account balance called "Saldo". The method uses the account number if previously set.
You can override/set it:
$account->saldo(ACCOUNT => "5555555");
statement(%values)
This method will retrieve an Account Statement (Kontoauszug). You can specify the timeframe of the statement by passing different arguments.
The value of TIMEFRAME can be "1" (last day only), "30" (last 30 days only), "alle" (all possible) or "variable" (between START_DATE and END_DATE only).
$account->statement(
TIMEFRAME => "variabel",
START_DATE => "10.04.2003",
END_DATE => "02.05.2003",
);
logout()
This method will just log out the website and it's only existent to keep the module logic clean ;-)
USAGE
use Finance::Bank::DE::NetBank;
use Data::Dumper;
my $account = Finance::Bank::DE::NetBank->new(
CUSTOMER_ID => "xxxxxxx",
ACCOUNT => "yyyyyyy",
PASSWORD => "zzzzzz",
);
$account->connect();
$account->login();
print Dumper($account->statement(
TIMEFRAME => "variabel",
START_DATE => "10.04.2003",
END_DATE => "02.05.2003",
)
);
$account->logout();
BUGS
Please report bugs via http://rt.cpan.org/NoAuth/Bugs.html?Dist=Finance-Bank-DE-NetBank
SUPPORT
Support currently available via eMail to the author.
HISTORY
0.02 Sun May 04 15:45:00 2003 - documentation fixes
0.01 Sun May 04 03:00:00 2003 - original version;
AUTHOR
Roland Moriz
rmoriz@cpan.org && roland@moriz.de
http://www.roland-moriz.de/
Disclaimer stolen from Simon Cozens' Finance::Bank::LloydsTSB without asking for permission %-)
COPYRIGHT
This program is free software; you can redistribute it and/or modify it under the same terms as Perl itself.
The full text of the license can be found in the LICENSE file included with this module.
SEE ALSO
Finance::Bank::DE::SpardaBank, WWW::Mechanize, Finance::Bank::LloydsTSB