NAME

Finance::Bank::Wachovia - access account info from Perl

  • Account numbers

  • Account names

  • Account balances (posted and available)

  • Account transaction data (in all their detailed glory)

Does not (yet) provide any means to transfer money or pay bills.

SYNOPSIS

Since this version uses the website to get account info, it will need the information to login: There are two ways to login via the wachovia website, and depending on which login method you use, that decides which parameters you'll provide to the new() method. If you use the Customer access number method (left form on the website) then provide "customer_access_number", "pin", and "code_word". If you use the user id method (right form on the website) then provide "user_id" and "password".

use Finance::Bank::Wachovia;

# Two different types of login information,
# if you login using can/pin/codeword:
my $wachovia  = Finance::Bank::Wachovia->new(
    customer_access_number => '123456789',
    pin                    => '1234',
    code_word              => 'blah'
) or die Finance::Bank::Wachovia->ErrStr();

# OR if you login using user_id/password:
$wachovia = Finance::Bank::Wachovia->new(
    user_id  => 'foo',
    password => 'bar'  
) or die Finance::Bank::Wachovia->ErrStr();

my @account_numbers		= $wachovia->account_numbers();
my @account_names		= $wachovia->account_names();
my @account_balances	= $wachovia->account_balances();

my $account = $wachovia->account( $account_numbers[0] )
	or die $wachovia->ErrStr();;
print "Number: ", $account->number, "\n";
print "Name: ", $account->name, "\n";
print "Type: ", $account->type, "\n";
print "Avail. Bal.: ", $account->available_balance, "\n";
print "Posted.Bal.: ", $account->posted_balance, "\n";

my $transactions = $account->transactions
	or die $account->ErrStr;

foreach my $t ( @$transactions ){
	print "Date: ",     $t->date,              "\n",
	      "Action: ",   $t->action,            "\n",
	      "Desc: ",     $t->description,       "\n",
	      "Withdrawal", $t->withdrawal_amount, "\n",
	      "Deposit",    $t->deposit_amount,    "\n",
	      "Balance",    $t->balance,           "\n",
	      "seq_no",     $t->seq_no,            "\n",
	      "trans_code", $t->trans_code,        "\n",
	      "check_num",  $t->check_num,         "\n";
} 

DESCRIPTION

Internally uses WWW::Mechanize to scrape the bank's website. The idea was to keep the interface as logical as possible. The user is completely abstracted from how the data is obtained, and to a large degree so is the module itself. In case wachovia ever offers an XML interface, or soap, or DBI (right) this should be an easy module to add to/modify, but the application interface will not change, so YOUR code won't have to either.

METHODS

new

Returns object Finance::Bank::Wachovia object. This is when you should define your login information. There are currently two login methods, the 3 argument "can/pin/codeword" method, and the two argument "user_id/password" method. Which one you need to use depends on how you login to your account via the wachovia website.

If you use the can/pin/codeword method, then:

my $wachovia = Finance::Bank::Wachovia->new(
    customer_access_number => '123456789',
    pin                    => '1234',
    code_word              => 'blah'
);

And if you use the user_id/password method, then:

my $wachovia = Finance::Bank::Wachovia->new(
    user_id  => 'foo',
    password => 'bar'
);

On wachovia's website they say that eventually everyone will be migrated to the userid/password method.

account_numbers

Returns a list of account numbers (from the Relationship Summary Page).

my @numbers = $wachovia->account_numbers();

account_names

Returns (in lowercase) a list of account names (ie: "exp access") (from the Relationship Summary Page).

my @names = $wachovia->account_names;

account_balances

Returns a list of account balances (from Relationship Summary page ).

my @balances = $wachovia->account_balances;

account

Returns a Finance::Bank::Wachovia::Account object. This object can be used to get any info available about an account, including posted/available balances, it's name, type, number, and a list of all it's transactions. See the perldocs for Finance::Bank::Wachovia::Account for info on what to do with the object. (or just look at the code example in the "How to use" section of this perldoc.

my $account = $wachovia->account( $account_num );

WORTH MENTIONING

Doug Feuerbach had the idea for storing login information in an encrypted file to be accessed via a password (like apple's keychain). Then he gave me the code to implement it. He thinks it's silly to thank him for something "so trivial", but he should know that it's not an official perl module without a "thanks" going out to someone by name. The program included with the module makes use of his contribution. Thanks Doug.

Also, thanks to the Giants that authored all the modules that made the conception and creation of this module so easy. Your shoulder's are awesome.

Where would we all be without Perl? Checking our account balances over the phone, that's where. Thanks to Larry Wall.

Thanks to Jason Marcell for helping me test/debug the user_id/password login in a pretty short amount of time.

TODO

  • finish documentation

  • add in fancy stuff like transfers and billpay -- maybe

AUTHOR

Jim Garvin <jg.perl@thegarvin.com>

Copyright 2004 by Jim Garvin

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

SEE ALSO

Finance::Bank::Wachovia::Account Finance::Bank::Wachovia::Transaction

1 POD Error

The following errors were encountered while parsing the POD:

Around line 113:

=begin without a target?