Skip to content

Commit

Permalink
docs: regenerate package for alerts api
Browse files Browse the repository at this point in the history
  • Loading branch information
paigen11 committed May 15, 2024
1 parent 4503396 commit 69603b9
Show file tree
Hide file tree
Showing 20 changed files with 1,371 additions and 0 deletions.
15 changes: 15 additions & 0 deletions src/.openapi-generator/FILES
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,10 @@
.gitlab-ci.yml
.travis.yml
README.md
docs/Alert.md
docs/AlertApi.md
docs/AlertDataInner.md
docs/AlertNotificationsInner.md
docs/AuthorizationApi.md
docs/Aws.md
docs/Azure.md
Expand Down Expand Up @@ -31,6 +35,7 @@ docs/EventApi.md
docs/FirmwareApi.md
docs/FirmwareInfo.md
docs/Fleet.md
docs/GetAlerts200Response.md
docs/GetBillingAccounts200Response.md
docs/GetDeviceEnvironmentVariables200Response.md
docs/GetDeviceHealthLog200Response.md
Expand Down Expand Up @@ -90,6 +95,7 @@ docs/UserDbRoute.md
git_push.sh
notehub_py/__init__.py
notehub_py/api/__init__.py
notehub_py/api/alert_api.py
notehub_py/api/authorization_api.py
notehub_py/api/billing_account_api.py
notehub_py/api/device_api.py
Expand All @@ -103,6 +109,9 @@ notehub_py/api_response.py
notehub_py/configuration.py
notehub_py/exceptions.py
notehub_py/models/__init__.py
notehub_py/models/alert.py
notehub_py/models/alert_data_inner.py
notehub_py/models/alert_notifications_inner.py
notehub_py/models/aws.py
notehub_py/models/azure.py
notehub_py/models/billing_account.py
Expand All @@ -126,6 +135,7 @@ notehub_py/models/error.py
notehub_py/models/event.py
notehub_py/models/firmware_info.py
notehub_py/models/fleet.py
notehub_py/models/get_alerts200_response.py
notehub_py/models/get_billing_accounts200_response.py
notehub_py/models/get_device_environment_variables200_response.py
notehub_py/models/get_device_health_log200_response.py
Expand Down Expand Up @@ -187,4 +197,9 @@ setup.cfg
setup.py
test-requirements.txt
test/__init__.py
test/test_alert.py
test/test_alert_api.py
test/test_alert_data_inner.py
test/test_alert_notifications_inner.py
test/test_get_alerts200_response.py
tox.ini
5 changes: 5 additions & 0 deletions src/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -93,6 +93,7 @@ All URIs are relative to *https://api.notefile.net*

Class | Method | HTTP request | Description
------------ | ------------- | ------------- | -------------
*AlertApi* | [**get_alerts**](docs/AlertApi.md#get_alerts) | **GET** /v1/projects/{projectUID}/alerts |
*AuthorizationApi* | [**login**](docs/AuthorizationApi.md#login) | **POST** /auth/login |
*BillingAccountApi* | [**get_billing_accounts**](docs/BillingAccountApi.md#get_billing_accounts) | **GET** /v1/billing-accounts |
*DeviceApi* | [**delete_device_environment_variable**](docs/DeviceApi.md#delete_device_environment_variable) | **DELETE** /v1/projects/{projectUID}/devices/{deviceUID}/environment_variables/{key} |
Expand Down Expand Up @@ -170,6 +171,9 @@ Class | Method | HTTP request | Description

## Documentation For Models

- [Alert](docs/Alert.md)
- [AlertDataInner](docs/AlertDataInner.md)
- [AlertNotificationsInner](docs/AlertNotificationsInner.md)
- [Aws](docs/Aws.md)
- [Azure](docs/Azure.md)
- [BillingAccount](docs/BillingAccount.md)
Expand All @@ -193,6 +197,7 @@ Class | Method | HTTP request | Description
- [Event](docs/Event.md)
- [FirmwareInfo](docs/FirmwareInfo.md)
- [Fleet](docs/Fleet.md)
- [GetAlerts200Response](docs/GetAlerts200Response.md)
- [GetBillingAccounts200Response](docs/GetBillingAccounts200Response.md)
- [GetDeviceEnvironmentVariables200Response](docs/GetDeviceEnvironmentVariables200Response.md)
- [GetDeviceHealthLog200Response](docs/GetDeviceHealthLog200Response.md)
Expand Down
39 changes: 39 additions & 0 deletions src/docs/Alert.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,39 @@
# Alert


## Properties

Name | Type | Description | Notes
------------ | ------------- | ------------- | -------------
**uid** | **str** | Alert UID | [optional]
**monitor_uid** | **str** | Monitor UID | [optional]
**device_uid** | **str** | Device UID | [optional]
**created_at** | **int** | The time the alert was created | [optional]
**value** | **float** | The value that triggered the alert | [optional]
**resolved** | **bool** | If true, the alert has been resolved | [optional]
**version** | **int** | The version of the alert | [optional]
**alert_source** | **str** | The source of the alert | [optional]
**source** | **str** | The UID of the source of the alert | [optional]
**data** | [**List[AlertDataInner]**](AlertDataInner.md) | | [optional]
**notifications** | [**List[AlertNotificationsInner]**](AlertNotificationsInner.md) | | [optional]

## Example

```python
from notehub_py.models.alert import Alert

# TODO update the JSON string below
json = "{}"
# create an instance of Alert from a JSON string
alert_instance = Alert.from_json(json)
# print the JSON string representation of the object
print(Alert.to_json())

# convert the object into a dict
alert_dict = alert_instance.to_dict()
# create an instance of Alert from a dict
alert_from_dict = Alert.from_dict(alert_dict)
```
[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md)


92 changes: 92 additions & 0 deletions src/docs/AlertApi.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,92 @@
# notehub_py.AlertApi

All URIs are relative to *https://api.notefile.net*

Method | HTTP request | Description
------------- | ------------- | -------------
[**get_alerts**](AlertApi.md#get_alerts) | **GET** /v1/projects/{projectUID}/alerts |


# **get_alerts**
> GetAlerts200Response get_alerts(project_uid, page_size=page_size, page_num=page_num)


Get list of defined Alerts

### Example

* Api Key Authentication (api_key):

```python
import notehub_py
from notehub_py.models.get_alerts200_response import GetAlerts200Response
from notehub_py.rest import ApiException
from pprint import pprint

# Defining the host is optional and defaults to https://api.notefile.net
# See configuration.py for a list of all supported configuration parameters.
configuration = notehub_py.Configuration(
host = "https://api.notefile.net"
)

# The client must configure the authentication and authorization parameters
# in accordance with the API server security policy.
# Examples for each auth method are provided below, use the example that
# satisfies your auth use case.

# Configure API key authorization: api_key
configuration.api_key['api_key'] = os.environ["API_KEY"]

# Uncomment below to setup prefix (e.g. Bearer) for API key, if needed
# configuration.api_key_prefix['api_key'] = 'Bearer'

# Enter a context with an instance of the API client
with notehub_py.ApiClient(configuration) as api_client:
# Create an instance of the API class
api_instance = notehub_py.AlertApi(api_client)
project_uid = 'app:2606f411-dea6-44a0-9743-1130f57d77d8' # str |
page_size = 50 # int | (optional) (default to 50)
page_num = 1 # int | (optional) (default to 1)

try:
api_response = api_instance.get_alerts(project_uid, page_size=page_size, page_num=page_num)
print("The response of AlertApi->get_alerts:\n")
pprint(api_response)
except Exception as e:
print("Exception when calling AlertApi->get_alerts: %s\n" % e)
```



### Parameters


Name | Type | Description | Notes
------------- | ------------- | ------------- | -------------
**project_uid** | **str**| |
**page_size** | **int**| | [optional] [default to 50]
**page_num** | **int**| | [optional] [default to 1]

### Return type

[**GetAlerts200Response**](GetAlerts200Response.md)

### Authorization

[api_key](../README.md#api_key)

### HTTP request headers

- **Content-Type**: Not defined
- **Accept**: application/json

### HTTP response details

| Status code | Description | Response headers |
|-------------|-------------|------------------|
**200** | The response body from GET /alerts | - |
**0** | The response body in case of an API error. | - |

[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md)

34 changes: 34 additions & 0 deletions src/docs/AlertDataInner.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,34 @@
# AlertDataInner


## Properties

Name | Type | Description | Notes
------------ | ------------- | ------------- | -------------
**alert_source** | **str** | The source of the alert | [optional]
**source** | **str** | The UID of the source of the alert | [optional]
**source_type** | **str** | The type of source. | [optional]
**value** | **float** | The value that triggered the alert | [optional]
**source_uid** | **str** | The UID of the source of the alert | [optional]
**when** | **str** | The time the alert was created | [optional]

## Example

```python
from notehub_py.models.alert_data_inner import AlertDataInner

# TODO update the JSON string below
json = "{}"
# create an instance of AlertDataInner from a JSON string
alert_data_inner_instance = AlertDataInner.from_json(json)
# print the JSON string representation of the object
print(AlertDataInner.to_json())

# convert the object into a dict
alert_data_inner_dict = alert_data_inner_instance.to_dict()
# create an instance of AlertDataInner from a dict
alert_data_inner_from_dict = AlertDataInner.from_dict(alert_data_inner_dict)
```
[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md)


31 changes: 31 additions & 0 deletions src/docs/AlertNotificationsInner.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,31 @@
# AlertNotificationsInner


## Properties

Name | Type | Description | Notes
------------ | ------------- | ------------- | -------------
**notification_type** | **str** | The type of notification | [optional]
**status** | **float** | The status of the notification | [optional]
**recipients** | **str** | The recipients of the notification | [optional]

## Example

```python
from notehub_py.models.alert_notifications_inner import AlertNotificationsInner

# TODO update the JSON string below
json = "{}"
# create an instance of AlertNotificationsInner from a JSON string
alert_notifications_inner_instance = AlertNotificationsInner.from_json(json)
# print the JSON string representation of the object
print(AlertNotificationsInner.to_json())

# convert the object into a dict
alert_notifications_inner_dict = alert_notifications_inner_instance.to_dict()
# create an instance of AlertNotificationsInner from a dict
alert_notifications_inner_from_dict = AlertNotificationsInner.from_dict(alert_notifications_inner_dict)
```
[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md)


30 changes: 30 additions & 0 deletions src/docs/GetAlerts200Response.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,30 @@
# GetAlerts200Response


## Properties

Name | Type | Description | Notes
------------ | ------------- | ------------- | -------------
**alerts** | [**List[Alert]**](Alert.md) | The list of alerts |
**has_more** | **bool** | True if there are more alerts |

## Example

```python
from notehub_py.models.get_alerts200_response import GetAlerts200Response

# TODO update the JSON string below
json = "{}"
# create an instance of GetAlerts200Response from a JSON string
get_alerts200_response_instance = GetAlerts200Response.from_json(json)
# print the JSON string representation of the object
print(GetAlerts200Response.to_json())

# convert the object into a dict
get_alerts200_response_dict = get_alerts200_response_instance.to_dict()
# create an instance of GetAlerts200Response from a dict
get_alerts200_response_from_dict = GetAlerts200Response.from_dict(get_alerts200_response_dict)
```
[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md)


5 changes: 5 additions & 0 deletions src/notehub_py/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -18,6 +18,7 @@
__version__ = "0.0.2"

# import apis into sdk package
from notehub_py.api.alert_api import AlertApi
from notehub_py.api.authorization_api import AuthorizationApi
from notehub_py.api.billing_account_api import BillingAccountApi
from notehub_py.api.device_api import DeviceApi
Expand All @@ -39,6 +40,9 @@
from notehub_py.exceptions import ApiException

# import models into sdk package
from notehub_py.models.alert import Alert
from notehub_py.models.alert_data_inner import AlertDataInner
from notehub_py.models.alert_notifications_inner import AlertNotificationsInner
from notehub_py.models.aws import Aws
from notehub_py.models.azure import Azure
from notehub_py.models.billing_account import BillingAccount
Expand All @@ -62,6 +66,7 @@
from notehub_py.models.event import Event
from notehub_py.models.firmware_info import FirmwareInfo
from notehub_py.models.fleet import Fleet
from notehub_py.models.get_alerts200_response import GetAlerts200Response
from notehub_py.models.get_billing_accounts200_response import GetBillingAccounts200Response
from notehub_py.models.get_device_environment_variables200_response import GetDeviceEnvironmentVariables200Response
from notehub_py.models.get_device_health_log200_response import GetDeviceHealthLog200Response
Expand Down
1 change: 1 addition & 0 deletions src/notehub_py/api/__init__.py
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
# flake8: noqa

# import apis into api package
from notehub_py.api.alert_api import AlertApi
from notehub_py.api.authorization_api import AuthorizationApi
from notehub_py.api.billing_account_api import BillingAccountApi
from notehub_py.api.device_api import DeviceApi
Expand Down
Loading

0 comments on commit 69603b9

Please sign in to comment.