Project

funds

0.0
No commit activity in last 3 years
No release in over 3 years
An Open Financial Exchange client.
2005
2006
2007
2008
2009
2010
2011
2012
2013
2014
2015
2016
2017
2018
2019
2020
2021
2022
2023
2024
2025
 Dependencies

Runtime

= 2.7.1
= 1.6.7.2
 Project Readme

funds (alpha)

An Open Financial Exchange (OFX) client in Ruby

Installation

gem install nokogiri -v 1.6.7.2
gem install httpclient -v 2.7.1
gem install funds

RubyGem: https://rubygems.org/gems/funds

Usage

Query ofxhome.com API for ofxhome.com institution IDs

OFXClient::search_institutions("Fidelity")

=> {"Fidelity Investments"=>449, "Fidelity NetBenefits"=>558}

NOTE: ofxhome.com institution IDs are unique to the ofxhome.com database. These IDs are independent of the OFX FID tied to a given institution. You will use ofxhome.com institution IDs to retrieve an institution's FID.

Retrieve FinancialInstitution by institution ID

fi = OFXClient::get_institution(449)
unless fi.nil?
  puts fi.fid
  puts fi.name
  puts fi.org
  puts fi.url
end
```
=> 7776  
=> Fidelity Investments  
=> fidelity.com  
=> https://ofx.fidelity.com/ftgw/OFX/clients/download

### Retrieve all institution IDs

```Ruby
OFXClient::all_institutions
```
=> {"121 Financial Credit Union"=>666, "1st Advantage FCU"=>542, ... , "Zions Bank"=>630, "zWachovia"=>452}

### Get a credit card statement

```Ruby
# Retrieve a FinancialInstitution
fi = OFXClient::get_institution(449)
# Create an Account by with your account number and an AccountType (CHECKING, SAVINGS, MONEYMRKT, CREDITCARD)
account = Account.new("1234567890123456", AccountType::CREDITCARD)
# fetch the OFX statement(s) in date range (yyyymmdd) from the institution
# currently, this call returns the raw OFX body response
puts OFXClient::get_statement(fi, account, "myOnlineUsername", "myPassword", "20151201", "20160115")
```
Response:
```
OFXHEADER:100
DATA:OFXSGML
VERSION:102
SECURITY:NONE
ENCODING:USASCII
CHARSET:1252
COMPRESSION:NONE
OLDFILEUID:NONE
NEWFILEUID:NONE

<OFX>
<SIGNONMSGSRSV1>
<SONRS>
<STATUS>
<CODE>0
<SEVERITY>INFO
</STATUS>...
```
### Get a checking statement
```Ruby
# Retrieve a FinancialInstitution
fi = OFXClient::get_institution(449)
# Create an Account by with your account number and an AccountType (CHECKING, SAVINGS, MONEYMRKT, CREDITCARD)
account = Account.new("1234567890123456", AccountType::CHECKING)
# CHECKING/SAVINGS accounts require a routing number
account.routingNumber = "0010020032"
# fetch the OFX statement(s) in date range (yyyymmdd) from the institution
# currently, this call returns the raw OFX body response
puts OFXClient::get_statement(fi, account, "myOnlineUsername", "myPassword", "20151201", "20160115")
```