Adk2

Code Climate Test Coverage Circle CI

A ruby wrapper for accessing the ADK2 API.

Installation

Add this line to your application's Gemfile:

gem 'adk2'

And then execute:

$ bundle

Or install it yourself as:

$ gem install adk2

Usage

To instantiate the client:

client = Adk2::Client.new(network_name, username: '[email protected]', password: '123456')

Alternatively, you can use an API token:

client = Adk2::Client.new(network_name, api_token: 'tokentokentoken')

In case the API token expires (TODO: when does this happen?), with the first version the client automatically will fetch a new one. With the second version it won't.

Use the client to generate a report:

client.report(
  'network',
  'networkanalyticsbydate',
  '2015-02-01',
  '2015-02-04'
)

Contributing

  1. Fork it (https://github.com/ad2games/adk2/fork)
  2. Create your feature branch (git checkout -b my-new-feature)
  3. Commit your changes (git commit -am 'Add some feature')
  4. Push to the branch (git push origin my-new-feature)
  5. Create a new Pull Request