Overview
Error Handling

Methods

API Documentation (API Version v1)

Notifications/

DESCRIPTION

Sometimes we want to notify the user about a particular incident, such as service monitoring alerts, load monitoring alerts, background process progress, etc. This section of the API gives access to those alerts.

all

URL:

https://api.stormondemand.com/v1/Notifications/all

Description:

Get a list of all notifications for an account or server. More information about the data structure can be found in the storm/alerts/details method.

Parameters:

ParameterTypeNotes
categoryA string of text, containing no newlines or other control characters.
page_numA positive integer value (i.e. 1 and up).* Optional
  • Defaults to: 1
page_sizeA positive integer value (i.e. 1 and up).* Optional
  • Defaults to: 25
resolvedA boolean value (0 or 1).
systemA string consisting of only letters, digits, hyphens, spaces, and underscores.
uniq_idA six-character identifier, containing only capital letters and digits.

Returns:

FieldType
item_countA non-negative integer value (i.e. 0 and up).
item_totalA non-negative integer value (i.e. 0 and up).
itemsAn array of associative arrays containing
 
categoryA string of text, containing no newlines or other control characters.* Optional
descriptionA string permitting tabs, carriage returns and newlines
enddateA valid date and time in YYYY-MM-DD HH:MM:SS format.* Optional
idA positive integer value (i.e. 1 and up).
last_alertA string permitting tabs, carriage returns and newlines* Optional
modifieddateA valid date and time in YYYY-MM-DD HH:MM:SS format.
resolvedA boolean value (0 or 1).
severityA single word, consisting of only letters and digits.
startdateA valid date and time in YYYY-MM-DD HH:MM:SS format.
systemA string consisting of only letters, digits, hyphens, spaces, and underscores.
system_identifierA positive integer value (i.e. 1 and up).* Optional
uniq_idA six-character identifier, containing only capital letters and digits.* Optional
page_numA positive integer value (i.e. 1 and up).
page_sizeA positive integer value (i.e. 1 and up).
page_totalA positive integer value (i.e. 1 and up).

Possible Errors:

Refer to the Error Handling documentation for the list of exception types

current

URL:

https://api.stormondemand.com/v1/Notifications/current

Description:

Get a list of unresolved notifications for an account or server. More information about the data structure can be found in the storm/alerts/details method.

Parameters:

ParameterTypeNotes
categoryA string of text, containing no newlines or other control characters.
page_numA positive integer value (i.e. 1 and up).* Optional
  • Defaults to: 1
page_sizeA positive integer value (i.e. 1 and up).* Optional
  • Defaults to: 25
severityA single word, consisting of only letters and digits.
systemA string consisting of only letters, digits, hyphens, spaces, and underscores.
uniq_idA six-character identifier, containing only capital letters and digits.

Returns:

FieldType
item_countA non-negative integer value (i.e. 0 and up).
item_totalA non-negative integer value (i.e. 0 and up).
itemsAn array of associative arrays containing
 
categoryA string of text, containing no newlines or other control characters.* Optional
descriptionA string permitting tabs, carriage returns and newlines
enddateA valid date and time in YYYY-MM-DD HH:MM:SS format.* Optional
idA positive integer value (i.e. 1 and up).
last_alertA string permitting tabs, carriage returns and newlines* Optional
modifieddateA valid date and time in YYYY-MM-DD HH:MM:SS format.
resolvedA boolean value (0 or 1).
severityA single word, consisting of only letters and digits.
startdateA valid date and time in YYYY-MM-DD HH:MM:SS format.
systemA string consisting of only letters, digits, hyphens, spaces, and underscores.
system_identifierA positive integer value (i.e. 1 and up).* Optional
uniq_idA six-character identifier, containing only capital letters and digits.* Optional
page_numA positive integer value (i.e. 1 and up).
page_sizeA positive integer value (i.e. 1 and up).
page_totalA positive integer value (i.e. 1 and up).

Possible Errors:

Refer to the Error Handling documentation for the list of exception types

details

URL:

https://api.stormondemand.com/v1/Notifications/details

Description:

Gets information about a specific notification, including a history of all the alerts related to that notification. You can limit the number of historical alerts by specifying a 'limit'.

Here's a rundown of what those fields mean:

	accnt: your account number

	category: the category of alert, if any.  Examples are (list likely to grow):

		Provisioning - an alert from our provisioning system, which handles long-
		running background processes like creating servers, rebooting, etc

		Monitoring:* - our service monitoring system creates alerts in various
		categories based on which server was having issues.  Monitoring: host
		indicates that the primary service on the server was having issues.
		Other examples are Monitoring: http, Monitoring: mysql, etc.

		Bandwidth Overage Warning - you have exceeded or are within a certain
		percentage of your bandwidth quota on a server

	description: the original description of the alert

	enddate: the date and time the alert was closed, if it is closed

	id: the id for this alert

	modifieddate: the date and time the alert was last updated

	severity:  the class of alert

		Notification: this alert is just to let you know that something has
		happened or is happening.

		Warning: indicates that something may be wrong, but is not yet serious.

		Error: something is wrong, like a service is not responding at all.

		Critical: something is seriously wrong and requires user acknowledgement
		to be closed.  Failed background processes from the provisioning system
		are the primary example here.

	system: the system reporting the alert

		Provisioning: alerts from our provisioning system, which handle
		long-running background tasks, like building servers, rebooting, etc

		Service Monitoring: alerts from our service monitoring system

		Storm: alerts related to Storm downtime or maintenance

		Billing: alerts from our billing system.  Things like bandwidth overage
		notifications.

	system_indentifier: some of the systems maintain their own unique identifiers
	for each ongoing alert.  This is that identifier, if it exists.

	uniq_id: the unique server identifier, made of 6 letters and numbers

	alerts: if an alert is repeated or has progress updates, each individual
	alert is kept and returns as a list here.  Other methods like list and open
	do not return this bit of information

Parameters:

ParameterTypeNotes
idA positive integer value (i.e. 1 and up).
limitA non-negative integer value (i.e. 0 and up).
systemA string consisting of only letters, digits, hyphens, spaces, and underscores.* Required if:
  • id is not given
system_identifierA non-negative integer value (i.e. 0 and up).* Required if:
  • id is not given

Returns:

FieldTypeNotes
alertsAn array of associative arrays containing
 
alertdateA valid date and time in YYYY-MM-DD HH:MM:SS format.
descriptionA string.
categoryA string of text, containing no newlines or other control characters.* Optional
descriptionA string permitting tabs, carriage returns and newlines
enddateA valid date and time in YYYY-MM-DD HH:MM:SS format.* Optional
idA positive integer value (i.e. 1 and up).
last_alertA string permitting tabs, carriage returns and newlines* Optional
modifieddateA valid date and time in YYYY-MM-DD HH:MM:SS format.
resolvedA boolean value (0 or 1).
severityA single word, consisting of only letters and digits.
startdateA valid date and time in YYYY-MM-DD HH:MM:SS format.
systemA string consisting of only letters, digits, hyphens, spaces, and underscores.
system_identifierA positive integer value (i.e. 1 and up).* Optional
uniq_idA six-character identifier, containing only capital letters and digits.* Optional

Possible Errors:

Refer to the Error Handling documentation for the list of exception types

resolve

URL:

https://api.stormondemand.com/v1/Notifications/resolve

Description:

Resolve an existing open notification. It will be marked as 'resolved' and no longer be returned by the 'current' method.

Parameters:

ParameterTypeNotes
idA positive integer value (i.e. 1 and up).
systemA string consisting of only letters, digits, hyphens, spaces, and underscores.* Required if:
  • id is not given
system_identifierA non-negative integer value (i.e. 0 and up).* Required if:
  • id is not given

Returns:

FieldTypeNotes
categoryA string of text, containing no newlines or other control characters.* Optional
descriptionA string permitting tabs, carriage returns and newlines
enddateA valid date and time in YYYY-MM-DD HH:MM:SS format.* Optional
idA positive integer value (i.e. 1 and up).
last_alertA string permitting tabs, carriage returns and newlines* Optional
modifieddateA valid date and time in YYYY-MM-DD HH:MM:SS format.
resolvedA boolean value (0 or 1).
severityA single word, consisting of only letters and digits.
startdateA valid date and time in YYYY-MM-DD HH:MM:SS format.
systemA string consisting of only letters, digits, hyphens, spaces, and underscores.
system_identifierA positive integer value (i.e. 1 and up).* Optional
uniq_idA six-character identifier, containing only capital letters and digits.* Optional

Possible Errors:

Refer to the Error Handling documentation for the list of exception types