This package is no longer maintained and we do not recommend using it.
A simple elixir client for the PagerDuty v2 API.
Install by adding mixduty
to your list of dependencies in mix.exs
:
def deps do
[
{:mixduty, "~> 0.1.1"}
]
end
$ mix deps.get
Initialize a new client with a valid auth token:
$ iex -S mix
iex(1)> client = Mixduty.Client.new("MY_TOKEN")
%Mixduty.Client{
headers: [
{"Accept", "application/vnd.pagerduty+json;version=2"},
{"Authorization", "Token token=y_NbAkKc66ryYTWUXYEu"},
{"Content-type", "application/json"}
]
}
Pass client to function calls described in documentation:
iex(2)> Mixduty.Users.list(client)
The following configuration options are available:
config :mixduty,
base_url: "https://api.pagerduty.com/"
- Fork it ( https://github.com/PagerDuty/mixduty/fork )
- Create your feature branch (
git checkout -b my-new-feature
) - Commit your changes (
git commit -am 'Add some feature'
) - Push to the branch (
git push origin my-new-feature
) - Create a new Pull Request