# OEHClient ONE Engagement Hub (OEH) is the premier customer engagement platform offered by Thunderhead, Inc. The OEHClient ('oeh-client') gem is a series of wrapper classes that allow your ruby/rails applicaitons to easily support integration with the platform. ## Feature Description OEHClient exposes the key features of the ONE Engagement Hub (OEH) system through some simplified classes. The client interface allows you to: * Register multiple spaces (OEH Configurations) to allow a single application to interact with each of your company configurations * Post customer and anoymous interactions to the ONE Engagement Hub (OEH) server * Manage and expose personalized assets and response handlers for optimized interactions * Fetch structure data from the ONE Engagement Hub (OEH) in realtime ## Installation Add this line to your application's Gemfile: ```ruby gem 'oeh-client' ``` And then execute: $ bundle install Or install it yourself as: $ gem install oeh-client ## Usage Each OEH instance can contain one ore more 'spaces', which contain separate application configurations. Each space is provided a unique key that identifies it within the existing SaaS environment. To access the space, you first need to register the space details with the space manager singleton as follows: ```ruby space_parameters = { :site_key => "YOUR_SITE_KEY", :host => "YOUR_THINSTANCE_SERVER_NAME" :api_key => "YOUR_API_KEY", :shared_secret => "YOUR_SHARED_SECRET_KEY", :username => "CONFIGURED_USERNAME", :meta_password => "LOGIN_PASSWORD_FOR_USERNAME" } OEHClient::Config::SpaceManager.instance.register_space(space_parameters) ``` As needed, you can register multiple spaces for the same instances to support integration with a number of spaces within your application. ### Interactions Interactions are the key elements of the customer experience. Interactions represent the back-and-forth between the customer and your organization. You can post an interaction simply: ```ruby customer_interaction = OEHClient::Realtime::Interaction.post("YOUR_TARGET_SITE_KEY", "TOUCHPOINT_INTERACTION_URI") ``` The post method will return an instance of the OE ## Contributing Bug reports and pull requests are welcome on GitHub at https://github.com/[USERNAME]/oeh-client. This project is intended to be a safe, welcoming space for collaboration, and contributors are expected to adhere to the [Contributor Covenant](contributor-covenant.org) code of conduct. ## License The gem is available as open source under the terms of the [MIT License](http://opensource.org/licenses/MIT).