NodePing.Maintenance.update-exclamation-mark

You're seeing just the function update-exclamation-mark, go back to NodePing.Maintenance module for more information.
Link to this function

update!(token, id, duration, checklist, opts, customerid \\ nil)

View Source

Update a scheduled or ad-hoc maintenance.

Parameters

  • token - NodePing API token that is provided with account
  • id - ID for maintenance schedule that will be updated
  • duration - The duration that the maintenance will run
  • checklist - a list of check IDs that are a part of the maintenance
  • opts - Map of optional arguments for creating the maintenance
  • customerid - optional ID to access a subaccount

Opts

  • enabled - for scheduled maintenance. Whether it should be enabled or disabled on creation
  • name - the name for the maintenance
  • cron - cron string for when scheduled maintenance should start

Examples

iex> token = System.fetch_env!("TOKEN")
iex> checklist = ["201911191441YC6SJ-4S9OJ78G","201911191441YC6SJ-XB5HUTG6"]
iex> duration = 30
iex> id = "NZT101"
iex> opts = %{:name => "new maintenance name"}
iex> result = NodePing.Maintenance.update!(token, id, duration, checklist, opts)