Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
branch: master

Fetching latest commit…

Cannot retrieve the latest commit at this time

Failed to load latest commit information.
lib
.gitignore
CONTRIBUTORS
Gemfile
Gemfile.lock
Guardfile
LICENSE
README.md
Rakefile
balanced.gemspec
x.rb

README.md

Balanced

Online Marketplace Payments

Build Status

Installation

Add this line to your application's Gemfile:

gem 'balanced-ach'

And then execute:

$ bundle

Or install it yourself as:

$ gem install balanced-ach

Usage

Create a Bank Account

require 'balanced_ach'

# create a bank account
ba = Balanced::BankAccount.new(
    :name => "Gottfried Leibniz",
    :account_number => "3819372930",
:routing_number => "121042882",
    :type => "checking"
).save

# credit this bank account $1.00 USD
ba.credit(:amount => 100)

# debit this bank account $1.00 USD
ba.debit(:amount => 100)

# retrieve this bank account at a later date
Balanced::BankAccount.find(ba.uri)

# delete this bank account
ba.unstore

Debit a Bank Account

require 'balanced_ach'

# debit this bank account $1.00 USD
Balanced::Debit.new(
:bank_account => {
        :name => "Gottfried Leibniz",
    :account_number => "3819372930",
        :routing_number => "121042882",
    :type => "checking"
}, :amount => 100
).save

Credit a Bank Account

require 'balanced_ach'

# credit this bank account $1.00 USD
Balanced::Credit.new(
    :bank_account => {
        :name => "Gottfried Leibniz",
        :account_number => "3819372930",
        :routing_number => "121042882",
        :type => "checking"
    }, :amount => 100
).save
Something went wrong with that request. Please try again.