Class: Github::Client
Constant Summary
Constants included from Request
Request::METHODS, Request::METHODS_WITH_BODIES
Constants included from Connection
Github::Connection::ALLOWED_OPTIONS
Constants included from Constants
Github::Constants::ACCEPT, Github::Constants::ACCEPTED_OAUTH_SCOPES, Github::Constants::ACCEPT_CHARSET, Github::Constants::CACHE_CONTROL, Github::Constants::CONTENT_LENGTH, Github::Constants::CONTENT_TYPE, Github::Constants::DATE, Github::Constants::ETAG, Github::Constants::HEADER_LAST, Github::Constants::HEADER_LINK, Github::Constants::HEADER_NEXT, Github::Constants::LOCATION, Github::Constants::META_FIRST, Github::Constants::META_LAST, Github::Constants::META_NEXT, Github::Constants::META_PREV, Github::Constants::META_REL, Github::Constants::OAUTH_SCOPES, Github::Constants::PARAM_PAGE, Github::Constants::PARAM_PER_PAGE, Github::Constants::PARAM_START_PAGE, Github::Constants::RATELIMIT_LIMIT, Github::Constants::RATELIMIT_REMAINING, Github::Constants::SERVER, Github::Constants::USER_AGENT
Constants included from MimeType
Instance Attribute Summary
Attributes inherited from API
Instance Method Summary collapse
-
#activity(options = {}, &block) ⇒ Object
Serving up the ‘social’ in Social Coding™, the Activity APIs provide access to notifications, subscriptions, and timelines.
- #emojis(options = {}, &block) ⇒ Object
- #gists(options = {}, &block) ⇒ Object
-
#git_data(options = {}, &block) ⇒ Object
(also: #git)
The Git Database API gives you access to read and write raw Git objects to your Git database on GitHub and to list and update your references (branch heads and tags).
- #gitignore(options = {}, &block) ⇒ Object (also: #git_ignore)
- #issues(options = {}, &block) ⇒ Object
- #markdown(options = {}, &block) ⇒ Object
- #meta(options = {}, &block) ⇒ Object
-
#oauth(options = {}, &block) ⇒ Object
(also: #authorizations)
An API for users to manage their own tokens.
- #octocat(options = {}, &block) ⇒ Object
- #orgs(options = {}, &block) ⇒ Object (also: #organizations)
- #pull_requests(options = {}, &block) ⇒ Object (also: #pulls)
- #repos(options = {}, &block) ⇒ Object (also: #repositories)
- #scopes(options = {}, &block) ⇒ Object
- #search(options = {}, &block) ⇒ Object
-
#users(options = {}, &block) ⇒ Object
Many of the resources on the users API provide a shortcut for getting information about the currently authenticated user.
Methods inherited from API
#api_methods_in, #append_arguments, #arguments, inherited, #initialize, #method_missing, #process_basic_auth, #set, #setup, #with, #yield_or_eval
Methods included from RateLimit
#ratelimit, #ratelimit_remaining
Methods included from Request
#delete_request, #get_request, #patch_request, #post_request, #put_request, #request
Methods included from Connection
#caching?, #clear_cache, #connection, #default_middleware, #default_options, #stack
Methods included from MimeType
Methods included from Authorization
#auth_code, #authenticated?, #authentication, #authorize_url, #basic_authed?, #client, #get_token
Constructor Details
This class inherits a constructor from Github::API
Dynamic Method Handling
This class handles dynamic methods through the method_missing method in the class Github::API
Instance Method Details
#activity(options = {}, &block) ⇒ Object
Serving up the ‘social’ in Social Coding™, the Activity APIs provide access to notifications, subscriptions, and timelines.
9 10 11 |
# File 'lib/github_api/client.rb', line 9 def activity(={}, &block) @activity ||= ApiFactory.new('Activity', .merge(), &block) end |
#emojis(options = {}, &block) ⇒ Object
13 14 15 |
# File 'lib/github_api/client.rb', line 13 def emojis(={}, &block) @emojis ||= ApiFactory.new('Emojis', .merge(), &block) end |
#gists(options = {}, &block) ⇒ Object
17 18 19 |
# File 'lib/github_api/client.rb', line 17 def gists(={}, &block) @gists ||= ApiFactory.new('Gists', .merge(), &block) end |
#git_data(options = {}, &block) ⇒ Object Also known as: git
The Git Database API gives you access to read and write raw Git objects to your Git database on GitHub and to list and update your references (branch heads and tags).
29 30 31 |
# File 'lib/github_api/client.rb', line 29 def git_data(={}, &block) @git_data ||= ApiFactory.new('GitData', .merge(), &block) end |
#gitignore(options = {}, &block) ⇒ Object Also known as: git_ignore
21 22 23 |
# File 'lib/github_api/client.rb', line 21 def gitignore(={}, &block) @gitignore ||= ApiFactory.new('Gitignore', .merge(), &block) end |
#issues(options = {}, &block) ⇒ Object
34 35 36 |
# File 'lib/github_api/client.rb', line 34 def issues(={}, &block) @issues ||= ApiFactory.new('Issues', .merge(), &block) end |
#markdown(options = {}, &block) ⇒ Object
38 39 40 |
# File 'lib/github_api/client.rb', line 38 def markdown(={}, &block) @markdown ||= ApiFactory.new('Markdown', .merge(), &block) end |
#meta(options = {}, &block) ⇒ Object
42 43 44 |
# File 'lib/github_api/client.rb', line 42 def (={}, &block) @meta ||= ApiFactory.new('Meta', .merge(), &block) end |
#oauth(options = {}, &block) ⇒ Object Also known as:
An API for users to manage their own tokens. You can only access your own tokens, and only through Basic Authentication.
48 49 50 |
# File 'lib/github_api/client.rb', line 48 def oauth(={}, &block) @oauth ||= ApiFactory.new('Authorizations', .merge(), &block) end |
#octocat(options = {}, &block) ⇒ Object
68 69 70 |
# File 'lib/github_api/client.rb', line 68 def octocat(={}, &block) @octocat ||= ApiFactory.new('Say', .merge(), &block) end |
#orgs(options = {}, &block) ⇒ Object Also known as: organizations
53 54 55 |
# File 'lib/github_api/client.rb', line 53 def orgs(={}, &block) @orgs ||= ApiFactory.new('Orgs', .merge(), &block) end |
#pull_requests(options = {}, &block) ⇒ Object Also known as: pulls
58 59 60 |
# File 'lib/github_api/client.rb', line 58 def pull_requests(={}, &block) @pull_requests ||= ApiFactory.new('PullRequests', .merge(), &block) end |
#repos(options = {}, &block) ⇒ Object Also known as: repositories
63 64 65 |
# File 'lib/github_api/client.rb', line 63 def repos(={}, &block) @repos ||= ApiFactory.new('Repos', .merge(), &block) end |
#scopes(options = {}, &block) ⇒ Object
72 73 74 |
# File 'lib/github_api/client.rb', line 72 def scopes(={}, &block) @scopes ||= ApiFactory.new('Scopes', .merge(), &block) end |
#search(options = {}, &block) ⇒ Object
76 77 78 |
# File 'lib/github_api/client.rb', line 76 def search(={}, &block) @search ||= ApiFactory.new('Search', .merge(), &block) end |
#users(options = {}, &block) ⇒ Object
Many of the resources on the users API provide a shortcut for getting information about the currently authenticated user.
83 84 85 |
# File 'lib/github_api/client.rb', line 83 def users(={}, &block) @users ||= ApiFactory.new('Users', .merge(), &block) end |