Class: Fastlane::Plugin::GitHubStatus::Client

Inherits:
Object
  • Object
show all
Defined in:
lib/fastlane/plugin/github_status/client.rb

Overview

Calls GitHub’s status API and returns model objects to represent the data

Constant Summary collapse

API_ENDPOINT =
'https://status.github.com/api'.freeze

Instance Method Summary collapse

Instance Method Details

#last_messageObject

Returns Message representing the last status update from GitHub.

Returns:

  • Message representing the last status update from GitHub



9
10
11
12
# File 'lib/fastlane/plugin/github_status/client.rb', line 9

def last_message
  message_json = JSON.parse(open("#{API_ENDPOINT}/last-message.json").read)
  Plugin::GitHubStatus::Message.new(message_json)
end