SubscriptionsApi
All URIs are relative to http://admin.alertsense.com/api
| Method | HTTP request | Description |
|---|---|---|
| createSubscription | POST /v2/settings/subscriptions | |
| deleteSubscription | DELETE /v2/settings/subscriptions/{id} | |
| getEventTypes | GET /v2/settings/subscriptions/eventTypes | |
| getSubscription | GET /v2/settings/subscriptions/{id} | |
| getSubscriptionHistory | GET /v2/settings/subscriptions/{id}/history | |
| getSubscriptionTest | GET /v2/settings/subscriptions/{id}/test | |
| getSubscriptions | GET /v2/settings/subscriptions | |
| updateSubscription | PUT /v2/settings/subscriptions/{id} |
createSubscription
singleSubscriptionResponse createSubscription(createSubscriptionRequest)
Create a new `Subscription` object.
Parameters
| Name | Type | Description | Notes |
|---|---|---|---|
| createSubscriptionRequest | createSubscriptionRequest |
Return type
Authorization
No authorization required
HTTP request headers
- Content-Type: application/json
- Accept: application/json
deleteSubscription
deleteSubscription(id)
Delete an existing `Subscription` object.
Parameters
| Name | Type | Description | Notes |
|---|---|---|---|
| id | String | [default to null] |
Return type
null (empty response body)
Authorization
No authorization required
HTTP request headers
- Content-Type: Not defined
- Accept: application/json
getEventTypes
pagedEventTypesResponse getEventTypes(page, pageSize)
Gets a paged list of `EventType` objects.
Parameters
| Name | Type | Description | Notes |
|---|---|---|---|
| page | Integer | The page number of items to return. (1 by default) | [optional] [default to 1] |
| pageSize | Integer | The desired number of items per page. (25 by default) | [optional] [default to 25] |
Return type
Authorization
No authorization required
HTTP request headers
- Content-Type: Not defined
- Accept: application/json
getSubscription
singleSubscriptionResponse getSubscription(id)
Gets a single `Subscription` object.
Parameters
| Name | Type | Description | Notes |
|---|---|---|---|
| id | String | [default to null] |
Return type
Authorization
No authorization required
HTTP request headers
- Content-Type: Not defined
- Accept: application/json
getSubscriptionHistory
pagedSubscriptionHistoryResponse getSubscriptionHistory(id, eventIds, eventTypes, startDateTime, endDateTime, page, pageSize)
Gets a paged list of `SubscriptionHistory` objects. Subscription history is available for the previous 30 days.
Parameters
| Name | Type | Description | Notes |
|---|---|---|---|
| id | String | The Id of the Subscription for which to get the history. | [default to null] |
| eventIds | List | Filter by specific event Ids. | [optional] [default to null] |
| eventTypes | List | Filter by specific event types. | [optional] [default to null] |
| startDateTime | Date | Filter by history items newer than the specified datetime. | [optional] [default to null] |
| endDateTime | Date | Filter by history items older than the specified datetime. | [optional] [default to null] |
| page | Integer | The page number of items to return. (1 by default) | [optional] [default to 1] |
| pageSize | Integer | The desired number of items per page. (25 by default) | [optional] [default to 25] |
Return type
pagedSubscriptionHistoryResponse
Authorization
No authorization required
HTTP request headers
- Content-Type: Not defined
- Accept: application/json
getSubscriptionTest
getSubscriptionTest(id)
Request a test hook be sent to the specified `Subscription`.
Parameters
| Name | Type | Description | Notes |
|---|---|---|---|
| id | String | The Id of the Subscription to test. | [default to null] |
Return type
null (empty response body)
Authorization
No authorization required
HTTP request headers
- Content-Type: Not defined
- Accept: Not defined
getSubscriptions
pagedSubscriptionResponse getSubscriptions(page, pageSize)
Gets a paged list of `Subscription` objects.
Parameters
| Name | Type | Description | Notes |
|---|---|---|---|
| page | Integer | The page number of items to return. (1 by default) | [optional] [default to 1] |
| pageSize | Integer | The desired number of items per page. (25 by default) | [optional] [default to 25] |
Return type
Authorization
No authorization required
HTTP request headers
- Content-Type: Not defined
- Accept: application/json
updateSubscription
updateSubscription(id, updateSubscriptionRequest)
Update an existing `Subscription` object.
Parameters
| Name | Type | Description | Notes |
|---|---|---|---|
| id | String | [default to null] | |
| updateSubscriptionRequest | updateSubscriptionRequest |
Return type
null (empty response body)
Authorization
No authorization required
HTTP request headers
- Content-Type: application/json
- Accept: application/json