A simple Ruby client library for KOSapi RESTful service.
Add this line to your application's Gemfile:
gem 'kosapi_client', github: 'flexik/kosapi_client'
And then execute:
$ bundle
# Creates a new instance of client with OAuth2 credentials
client = KOSapiClient.new(OAUTH_CLIENT_ID, OAUTH_SECRET)
# Retrieves first page of all course events
course_events_page = client.course_events
course_events_page.each { |event| do_stuff_with_event(event) }
# Fetches page of parallels according to API parameters
parallels_page = client.parallels(offset: 0, limit: 50, query: 'course.department=18*')
- 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