Last Update: Tue Apr 15 12:45:44 -0400 2008

Welcome to QuickBooks for Ruby

The purpose of this gem is to perform connectivity and communication with Quickbooks, providing the user with access to quickbooks data as everyday ruby objects. This could be understood to be somewhat like an ORM, but it is different in that its models are predefined by the Quickbooks API.

In releases prior to 0.1.0, some knowledge of the Quickbooks API may be required. In releases beyond 0.1.0, the Quickbooks API should be fully hidden from your view.

Enjoy and PLEASE contribute either by suggestion or by submitting patches, etc. Or if development seems slow, please feel free to join! My work on this project has been solely for my own use of the gem, while opening up its achievements for others to use as well. Development may slow down considerably when I find it is at a stable and usable point for my needs. You‘ve been warned! ;)



This library is a work in progress. This package is separated into two distinct components: Qbxml and Quickbooks (models). The Qbxml represents most of the work of complying to the Quickbooks SDK, and is useful separate from the Quickbooks portion, for use with the QB Web Connector or QB Online Edition (as this gem does not support these connection types yet). For now, The Web Connector is NOT in plans to be supported as it requires additional logic of a different kind in asynchronous network communication.

Furthermore, as of version 0.1.0, the Customer model is the only model fleshed out and in working condition. It is rather stable, but please report any bugs you find. I have attempted to make the Quickbooks family of models to work much like DataMapper models, with their finder methods and such. It may be possible to make this gem into a DataMapper adapter.


Simply include this gem in your project:

  require 'rubygems'
  gem 'quickbooks'

Without any configuration, you should be able to talk to Quickbooks immediately if it and a company file is open on the same computer:

  c = Quickbooks::Customer.first = '(123) 456-7890'
  c.first_name = 'Joey'
  c.last_name = 'Smith'

Read further in Qbxml::Request and Qbxml::Response in order to get a better understanding of the kinds of options you can use. The Quickbooks::Base - inherited models also hold a lot of logic that is specific to each data type.

Again, until a later version, you will need to be running Quickbooks on the same computer _and have quickbooks open_ to the company file you need. The first time you run your script, you will need to authorize access to your script when Quickbooks asks you to.


This library is released under the terms of the MIT License.


  • Initial import of a new rewrite at version 0.0.3
  • 0.0.5 includes support for ordered qbxml attributes, as well as better error-handling and smarter saving.
  • 0.0.7 includes support for nested finder options, with aliases for easy access. Outdated by bugfixes in the next version.
  • 0.1.0 Bugfixes, a little more docs, and connection is a little more robust.