Class: CIRunner::Client::CircleCI
- Defined in:
- lib/ci_runner/client/circle_ci.rb
Constant Summary collapse
- API_ENDPOINT =
"circleci.com"
Instance Method Summary collapse
- #job(repository, build_number) ⇒ Object
-
#me ⇒ Hash
Make an API request to get the authenticated user.
Methods inherited from Base
Constructor Details
This class inherits a constructor from CIRunner::Client::Base
Instance Method Details
#job(repository, build_number) ⇒ Object
24 25 26 27 28 |
# File 'lib/ci_runner/client/circle_ci.rb', line 24 def job(repository, build_number) get("/api/v1.1/project/github/#{repository}/#{build_number}") rescue Error => e reraise_with_reason(e) end |
#me ⇒ Hash
Make an API request to get the authenticated user. Used to verify if the access token the user has stored in its config is valid.
16 17 18 |
# File 'lib/ci_runner/client/circle_ci.rb', line 16 def me get("/api/v1.1/me") end |