The Trolley Ruby SDK provides integration access to the Trolley API.
Ruby version >= 2.4 is required. Bundler is required.
gem install trolley
git clone https://github.com/Trolley/ruby-sdk.git
cd ruby-sdk
bundler install
gem build trolley.gemspec
gem install trolley-[version].gem
// set keys as environment variables
export SANDBOX_ACCESS_KEY="your_access_key"
export SANDBOX_SECRET_KEY="your_secret_key"
// run a single test file, for example:
bundle exec ruby test/integration/RecipientTest.rb
require 'trolley'
client = Trolley.client('ACCESS-KEY', 'SECRET-KEY')
recipient = client.recipient.find('R-1234567abcdefg')
print recipient.id
client = Trolley.client('ACCESS-KEY', 'SECRET-KEY', proxy_uri: 'peter_the_proxy.com')
client = Trolley.client('key', 'secret', api_base: 'https://api.railz.io')
All URIs are available at http://docs.trolley.com/