Skip to content
Ruby wrapper for the ChannelAdvisor API
Latest commit 6df358b May 28, 2013 @dnunez24 Merge pull request #13 from sheetmusicplus/fix-broken-specs
Fix Broken Specs With Updated Spec Support Credentials

ChannelAdvisor Build Status

Ruby wrapper for the SOAP API provided by ChannelAdvisor.


Install the gem:

$ gem install channeladvisor


Setup the ChannelAdvisor client:

require 'channeladvisor'

ChannelAdvisor.configure do |config|
  config.developer_key = YOUR_DEVELOPER_KEY
  config.password      = YOUR_PASSWORD
  config.account_id    = YOUR_ACCOUNT_ID

Make a request to the service:

date_range =,05,01),06,01)

orders = ChannelAdvisor::Order.list(:created_between => date_range)
# => [#<ChannelAdvisor::Order>, #<ChannelAdvisor::Order>, ...]
# => 1234567


The API wrapper is organized into two distinct segments. The ChannelAdvisor::Services module directly corresponds to the services and methods in the ChannelAdvisor API. Utilizing this interface ensures consistency with the actual ChannelAdvisor interface and will also allow you to handle errors and response data your own way, i.e. making a minimal amount of assumptions about how to handle the data returned from the web service request. A second, simpler interface is designed for ease-of-use and makes some assumptions about how best to handle the data and errors in the API response. For example, the simple interface would work like this:

ChannelAdvisor::Order.list(:state => "Active")
# => [#<ChannelAdvisor::Order>, #<ChannelAdvisor::Order>, ...]

While the Services interface would work like this:

ChannelAdvisor::Services::OrderService.get_order_list(:state => "Active")
# => #<Savon::SOAP::Response>
# ... do some neat stuff with the SOAP response
Something went wrong with that request. Please try again.