Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/sticksnleaves/status-ku
Elixir client for the Heroku status API
https://github.com/sticksnleaves/status-ku
Last synced: about 1 month ago
JSON representation
Elixir client for the Heroku status API
- Host: GitHub
- URL: https://github.com/sticksnleaves/status-ku
- Owner: sticksnleaves
- License: mit
- Created: 2016-11-03T23:59:24.000Z (about 8 years ago)
- Default Branch: master
- Last Pushed: 2016-11-11T04:24:55.000Z (about 8 years ago)
- Last Synced: 2024-10-28T22:13:01.433Z (about 2 months ago)
- Language: Elixir
- Size: 27.3 KB
- Stars: 0
- Watchers: 2
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# StatusKu
[![Build Status](https://travis-ci.org/sticksnleaves/status-ku.svg?branch=master)](https://travis-ci.org/sticksnleaves/status-ku)
Elixir client for the Heroku status API
## Installation
1. Add `status_ku` to your list of dependencies in `mix.exs`:
```elixir
def deps do
[{:status_ku, "~> 1.0.0"}]
end
```2. Ensure `status_ku` is started before your application:
```elixir
def application do
[applications: [:status_ku]]
end
```## Usage
```elixir
iex> StatusKu.current_status
{:ok, %StatusKu.Model.Status{
production: "green",
development: "green",
issues: []
}}iex> StatusKu.issue(604)
{:ok, %StatusKu.Model.Issue{
created_at: "2014-04-01T17:16:00Z",
full_url: "https://status.heroku.com/incidents/604",
href: "https://status.heroku.com/api/v3/issues/604",
id: 604,
resolved: true,
status_dev: "green",
status_prod: "green",
title: "Error when deploying certain apps",
upcoming: false,
updated_at: "2014-04-02T06:03:49Z",
updates: [
%StatusKu.Model.Update{
contents: "This change was reverted at 7:26 PM PDT (02:26 UTC).",
created_at: "2014-04-01T19:26:00Z",
id: 1961,
incident_id: 604,
status_dev: "green",
status_prod: "green",
title: "Error when deploying certain apps",
update_type: "resolved",
updated_at: "2014-04-02T06:03:55Z"
}
]
}}iex> StatusKu.issues(limit: 1, page: 1)
{:ok, %StatusKu.Model.Issue{
created_at: "2014-04-01T17:16:00Z",
full_url: "https://status.heroku.com/incidents/604",
href: "https://status.heroku.com/api/v3/issues/604",
id: 604,
resolved: true,
status_dev: "green",
status_prod: "green",
title: "Error when deploying certain apps",
upcoming: false,
updated_at: "2014-04-02T06:03:49Z",
updates: [
%StatusKu.Model.Update{
contents: "This change was reverted at 7:26 PM PDT (02:26 UTC).",
created_at: "2014-04-01T19:26:00Z",
id: 1961,
incident_id: 604,
status_dev: "green",
status_prod: "green",
title: "Error when deploying certain apps",
update_type: "resolved",
updated_at: "2014-04-02T06:03:55Z"
}
]
}}
```