h1. activetiger h2. Overview activetiger is a ruby library that allows interaction with Tiger Payment Processing. Using simple commands you can charge, authorize, capture, void, refund and update credit card transactions. Some simple examples are below, see the "wiki":http://wiki.github.com/inventables/activetiger for a more complete guide. h2. Simple example Authorize and capture a credit card: bc. # authorize the charge gateway = ActiveTiger::Gateway.new :username => "user", :password => "password" response = gateway.authorize :ccnumber => "4111111111111111", :ccexp => "1010", :amount => "1.00" bc. # capture gateway.charge(:transactionid => response.transaction_id) h2. Rails Integration activetiger works great with rails. When used in a rails project, active tiger looks for a directory called config/activetiger. Within this directory, it expects to find yaml configuration files for each environment in which you will be using activetiger. Tiger Payment Processing provides a dummy account with the username of "demo" and the password of "password". The standard configuration would normally be something like the example below: bc. # config/activetiger/development.yml username: demo password: password bc. # config/activetiger/test.yml username: demo password: password bc. # config/activetiger/production.yml username: realusername password: realpassword The above setup allows you to instantiate an ActiveTiger::Gateway without providing a username or password. It will be instantiated with the credentials specified in the yaml config files based on the environment. This allows you the test and develop against the sandbox account while run production with your account. Very handy for testing. h2. Note on Patches/Pull Requests * Fork the project. * Make your feature addition or bug fix. * Add tests for it. This is important so I don't break it in a future version unintentionally. * Commit, do not mess with rakefile, version, or history. (if you want to have your own version, that is fine but bump version in a commit by itself I can ignore when I pull) * Send me a pull request. Bonus points for topic branches. h2. Copyright Copyright (c) 2009 Inventables. See LICENSE for details.