AlertsOperations Class
Warning
DO NOT instantiate this class directly.
Instead, you should access the following operations through
AuthorizationManagementClient's
<xref:alerts> attribute.
Constructor
AlertsOperations(*args, **kwargs)
Methods
| begin_refresh |
Refresh an alert. |
| begin_refresh_all |
Refresh all alerts for a resource scope. |
| get |
Get the specified alert. |
| list_for_scope |
Gets alerts for a resource scope. |
| update |
Update an alert. |
begin_refresh
Refresh an alert.
async begin_refresh(scope: str, alert_id: str, **kwargs: Any) -> AsyncLROPoller[AlertOperationResult]
Parameters
| Name | Description |
|---|---|
|
scope
Required
|
The scope of the alert. Required. |
|
alert_id
Required
|
The name of the alert to refresh. Required. |
Keyword-Only Parameters
| Name | Description |
|---|---|
|
cls
|
A custom type or function that will be passed the direct response |
|
continuation_token
|
A continuation token to restart a poller from a saved state. |
|
polling
|
By default, your polling method will be AsyncARMPolling. Pass in False for this operation to not poll, or pass in your own initialized polling object for a personal polling strategy. |
|
polling_interval
|
Default waiting time between two polls for LRO operations if no Retry-After header is present. |
Returns
| Type | Description |
|---|---|
|
An instance of AsyncLROPoller that returns either AlertOperationResult or the result of cls(response) |
Exceptions
| Type | Description |
|---|---|
begin_refresh_all
Refresh all alerts for a resource scope.
async begin_refresh_all(scope: str, **kwargs: Any) -> AsyncLROPoller[AlertOperationResult]
Parameters
| Name | Description |
|---|---|
|
scope
Required
|
The scope of the alert. Required. |
Keyword-Only Parameters
| Name | Description |
|---|---|
|
cls
|
A custom type or function that will be passed the direct response |
|
continuation_token
|
A continuation token to restart a poller from a saved state. |
|
polling
|
By default, your polling method will be AsyncARMPolling. Pass in False for this operation to not poll, or pass in your own initialized polling object for a personal polling strategy. |
|
polling_interval
|
Default waiting time between two polls for LRO operations if no Retry-After header is present. |
Returns
| Type | Description |
|---|---|
|
An instance of AsyncLROPoller that returns either AlertOperationResult or the result of cls(response) |
Exceptions
| Type | Description |
|---|---|
get
Get the specified alert.
async get(scope: str, alert_id: str, **kwargs: Any) -> Alert
Parameters
| Name | Description |
|---|---|
|
scope
Required
|
The scope of the alert. The scope can be any REST resource instance. For example, use '/providers/Microsoft.Subscription/subscriptions/{subscription-id}/' for a subscription, '/providers/Microsoft.Subscription/subscriptions/{subscription-id}/resourceGroups/{resource-group-name}' for a resource group, and '/providers/Microsoft.Subscription/subscriptions/{subscription-id}/resourceGroups/{resource-group-name}/providers/{resource-provider}/{resource-type}/{resource-name}' for a resource. Required. |
|
alert_id
Required
|
The name of the alert to get. Required. |
Keyword-Only Parameters
| Name | Description |
|---|---|
|
cls
|
A custom type or function that will be passed the direct response |
Returns
| Type | Description |
|---|---|
|
Alert or the result of cls(response) |
Exceptions
| Type | Description |
|---|---|
list_for_scope
Gets alerts for a resource scope.
list_for_scope(scope: str, **kwargs: Any) -> AsyncIterable[Alert]
Parameters
| Name | Description |
|---|---|
|
scope
Required
|
The scope of the alert. Required. |
Keyword-Only Parameters
| Name | Description |
|---|---|
|
cls
|
A custom type or function that will be passed the direct response |
Returns
| Type | Description |
|---|---|
|
An iterator like instance of either Alert or the result of cls(response) |
Exceptions
| Type | Description |
|---|---|
update
Update an alert.
async update(scope: str, alert_id: str, parameters: _models.Alert, *, content_type: str = 'application/json', **kwargs: Any) -> None
Parameters
| Name | Description |
|---|---|
|
scope
Required
|
The scope of the alert. Required. |
|
alert_id
Required
|
The name of the alert to dismiss. Required. |
|
parameters
Required
|
Parameters for the alert. Is either a Alert type or a IO type. Required. |
Keyword-Only Parameters
| Name | Description |
|---|---|
|
content_type
|
Body Parameter content-type. Known values are: 'application/json'. Default value is None. |
|
cls
|
A custom type or function that will be passed the direct response |
Returns
| Type | Description |
|---|---|
|
None or the result of cls(response) |
Exceptions
| Type | Description |
|---|---|
Attributes
models
models = <module 'azure.mgmt.authorization.v2022_08_01_preview.models' from 'C:\\ToolCache\\Python\\3.11.9\\x64\\Lib\\site-packages\\py2docfx\\venv\\venv71\\Lib\\site-packages\\azure\\mgmt\\authorization\\v2022_08_01_preview\\models\\__init__.py'>