Class: GithubAPI
- Inherits:
-
Object
- Object
- GithubAPI
- Defined in:
- lib/githabit/github_api.rb
Instance Method Summary collapse
- #get_user_events(username) ⇒ Object
-
#initialize(username, password) ⇒ GithubAPI
constructor
A new instance of GithubAPI.
Constructor Details
#initialize(username, password) ⇒ GithubAPI
Returns a new instance of GithubAPI.
5 6 7 8 9 |
# File 'lib/githabit/github_api.rb', line 5 def initialize(username, password) @github = Github.new( :basic_auth => "#{username}:#{password}" ) end |
Instance Method Details
#get_user_events(username) ⇒ Object
11 12 13 |
# File 'lib/githabit/github_api.rb', line 11 def get_user_events(username) @github.activity.events.performed(username).body end |