Ruby SDK

Getting started with the People Data Labs Ruby Helper Library, which is our open-source SDK that lets you write Ruby code to make HTTP requests to the People Data Labs API

The People Data Labs Ruby Helper Library

The People Data Labs Ruby Helper Library makes it easy to interact with the People Data Labs API from your Ruby application. You can find the most recent version of the library on RubyGems.

Install the library

This library is available as a Ruby gem, and you can install it by doing the following:

gem install peopledatalabs

Using the library

require 'peopledatalabs'
require 'json'

Peopledatalabs.api_key = 'api_key'

result = Peopledatalabs::Enrichment.person(params: { phone: '4155688415' })

if result['status'] == 200
    puts JSON.pretty_generate(result['data'])
else
    puts "Status: #{result['status']};"\
       "\nReason: #{result['error']['type']};"\
       "\nMessage: #{result['error']['message']};"
end

More Information, Pull Requests, Feature Suggestions and Bug Reports

We've open-sourced the library, which is available on GitHub. Head there to view more information and submit pull requests, feature suggestions or bug reports.


Did this page help you?