Service hub client
Add this line to your application's Gemfile:
gem 'hub_client'
And then execute:
$ bundle
Or install it yourself as:
$ gem install hub_client
First let's create initializer file and configure the client:
HubClient.configure do |config|
config.env = "IL" # Optional
config.endpoint_url = "http://user:pass@hub.com" # scheme://host:port
config.access_token = "token" # Optional
endTo publish any message to the hub:
HubClient.publish('message', { pay: "load" })You can set the service hub api version by change the HUB_VERSION const
- Fork it ( http://github.com//hub_client/fork )
- 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