Learn about the Closeio API at http://developer.close.io.
Add this line to your application's Gemfile:
# in your Gemfile
gem 'closeio'
# then...
bundle install
# Add your Close.io api key as an ENV variable
ENV['CLOSEIO_API_KEY']='xxxxxxxx'
# Find a specific lead
lead = Closeio::Lead.find 'lead_xxxxxxxxxxxx'
# See some data about the lead
lead.addresses
lead.contacts
lead.opportunities
# Find leads that match fields
Closeio::Lead.where query: 'custom.current_system:[Simple Donation]'
# Create a lead
Closeio::Lead.create name: "Bluth Company", contacts: [{name: "Buster Bluth", emails: [{email: "cartographer@bluthcompany.com"}]}]
# Saved Search (SmartView)
saved_search = Closeio::SavedSearch.all.first
saved_search.leads
- Fork it
- Create your feature branch (
git checkout -b my-new-feature
) - Commit your changes (
git commit -am 'Add some feature'
) - Push to the branch (
git push origin my-new-feature
) - Create new Pull Request
Copyright (c) 2013 Taylor Brooks. See LICENSE for details.