Skip to main content

Microsoft Azure Alertsmanagement Management Client Library for Python

Project description

Microsoft Azure SDK for Python

This is the Microsoft Azure Alerts Management Client Library. This package has been tested with Python 3.10+. For a more complete view of Azure libraries, see the azure sdk python release.

Disclaimer

Azure SDK Python packages support for Python 2.7 has ended 01 January 2022. For more information and questions, please refer to https://github.com/Azure/azure-sdk-for-python/issues/20691

Getting started

Prerequisites

Install the package

pip install azure-mgmt-alertsmanagement
pip install azure-identity

Authentication

By default, Azure Active Directory token authentication depends on correct configuration of the following environment variables.

  • AZURE_CLIENT_ID for Azure client ID.
  • AZURE_TENANT_ID for Azure tenant ID.
  • AZURE_CLIENT_SECRET for Azure client secret.

With above configuration, client can be authenticated by following code:

from azure.identity import DefaultAzureCredential
from azure.mgmt.alertsmanagement import AlertsManagementClient

client = AlertsManagementClient(credential=DefaultAzureCredential())

Examples

Code samples for this package can be found at:

Troubleshooting

Next steps

Provide Feedback

If you encounter any bugs or have suggestions, please file an issue in the Issues section of the project.

Release History

2.0.0b3 (2026-05-27)

Features Added

  • Client AlertsManagementClient added parameter cloud_setting in method __init__
  • Client AlertsManagementClient added method send_request
  • Enum ActionType added member INTERNAL
  • Model Alert added property system_data
  • Model AlertModificationItem added property details
  • Model AlertProperties added property custom_properties
  • Enum MonitorService added member RESOURCE_HEALTH
  • Model Operation added property is_data_action
  • Model Operation added property action_type
  • Model Resource added property system_data
  • Added model ActionSuppressedDetails
  • Added model ActionTriggeredDetails
  • Added model AlertEnrichmentItem
  • Added model AlertEnrichmentProperties
  • Added model AlertEnrichmentResponse
  • Added enum AlertModificationType
  • Added model AlertsManagementErrorResponse
  • Added model BaseDetails
  • Added model NotificationResult
  • Added enum Origin
  • Added model PrometheusEnrichmentItem
  • Added model PrometheusInstantQuery
  • Added model PrometheusRangeQuery
  • Added model PropertyChangeDetails
  • Added model ProxyResource
  • Added model ProxyResourceAutoGenerated
  • Added enum ResultStatus
  • Added enum RuleType
  • Added enum Status
  • Added model TriggeredRule
  • Added enum Type
  • Operation group AlertsOperations added method change_state_tenant
  • Operation group AlertsOperations added method get_all_tenant
  • Operation group AlertsOperations added method get_by_id_tenant
  • Operation group AlertsOperations added method get_enrichments
  • Operation group AlertsOperations added method get_history_tenant

Breaking Changes

  • This version introduces new hybrid models which have dual dictionary and model nature. And please follow https://aka.ms/azsdk/python/migrate/hybrid-models for migration.
  • For the method breakings, please refer to https://aka.ms/azsdk/python/migrate/operations for migration.
  • Deleted or renamed client operation group AlertsManagementClient.alert_processing_rules
  • Deleted or renamed client operation group AlertsManagementClient.prometheus_rule_groups
  • Deleted or renamed client operation group AlertsManagementClient.smart_groups
  • Method AlertsManagementClient.__init__ deleted or renamed its parameter subscription_id of kind positional_or_keyword
  • Deleted or renamed enum value ActionType.ADD_ACTION_GROUPS
  • Deleted or renamed enum value ActionType.REMOVE_ALL_ACTION_GROUPS
  • Deleted or renamed enum value AlertModificationEvent.ACTIONS_FAILED
  • Deleted or renamed enum value AlertModificationEvent.ACTION_RULE_SUPPRESSED
  • Deleted or renamed enum value AlertModificationEvent.ACTION_RULE_TRIGGERED
  • Model AlertsSummaryGroup renamed its instance variable values to values_property
  • Model AlertsSummaryGroupItem renamed its instance variable values to values_property
  • Method AlertsOperations.change_state changed its parameter new_state from positional_or_keyword to keyword_only
  • Method AlertsOperations.change_state inserted a positional_or_keyword parameter scope
  • Method AlertsOperations.get_all changed its parameter target_resource/target_resource_type/target_resource_group/monitor_service/monitor_condition/severity/alert_state/alert_rule/smart_group_id/include_context/include_egress_config/page_count/sort_by/sort_order/select/time_range/custom_time_range from positional_or_keyword to keyword_only
  • Method AlertsOperations.get_all inserted a positional_or_keyword parameter scope
  • Method AlertsOperations.get_by_id inserted a positional_or_keyword parameter scope
  • Method AlertsOperations.get_history inserted a positional_or_keyword parameter scope
  • Method AlertsOperations.get_summary changed its parameter groupby/include_smart_groups_count/target_resource/target_resource_type/target_resource_group/monitor_service/monitor_condition/severity/alert_state/alert_rule/time_range/custom_time_range from positional_or_keyword to keyword_only
  • Method AlertsOperations.get_summary inserted a positional_or_keyword parameter scope
  • Method AlertsOperations.meta_data changed its parameter identifier from positional_or_keyword to keyword_only
  • Deleted or renamed operation group AlertProcessingRulesOperations
  • Deleted or renamed operation group PrometheusRuleGroupsOperations
  • Deleted or renamed operation group SmartGroupsOperations

Other Changes

  • Deleted model AlertProcessingRulesList/AlertsList/OperationsList/PrometheusRuleGroupResourceCollection/SmartGroupsList which actually were not used by SDK users
  • Deleted model Action/AddActionGroups/AlertProcessingRule/AlertProcessingRuleProperties/Condition/DailyRecurrence/ErrorResponseAutoGenerated/ErrorResponseAutoGenerated2/ErrorResponseAutoGenerated3/ErrorResponseBodyAutoGenerated/ErrorResponseBodyAutoGenerated2/ManagedResource/MonthlyRecurrence/PatchObject/PrometheusRule/PrometheusRuleGroupAction/PrometheusRuleGroupResource/PrometheusRuleGroupResourcePatch/PrometheusRuleGroupResourcePatchProperties/PrometheusRuleResolveConfiguration/Recurrence/RemoveAllActionGroups/ResourceAutoGenerated/Schedule/SmartGroup/SmartGroupAggregatedProperty/SmartGroupModification/SmartGroupModificationItem/SmartGroupModificationProperties/TrackedResource/WeeklyRecurrence which actually were not used by SDK users
  • Deleted enum DaysOfWeek/Field/Operator/RecurrenceType/SmartGroupModificationEvent/SmartGroupsSortByFields/State which actually were not used by SDK users

1.0.1 (2026-05-13)

Other Changes

  • Regenerated with latest code generator tool

2.0.0b2 (2022-12-26)

Features Added

  • Added operation group PrometheusRuleGroupsOperations

2.0.0b1 (2022-08-22)

Features Added

  • Added operation group AlertProcessingRulesOperations
  • Model Condition has a new parameter field
  • Model Essentials has a new parameter action_status
  • Model Essentials has a new parameter description
  • Model Operation has a new parameter origin
  • Model PatchObject has a new parameter enabled

Breaking Changes

  • Model PatchObject no longer has parameter status
  • Operation AlertsOperations.change_state has a new parameter comment
  • Removed operation group ActionRulesOperations
  • Removed operation group SmartDetectorAlertRulesOperations

1.0.0 (2021-03-16)

  • GA release

1.0.0b1 (2020-11-20)

This is beta preview version.

This version uses a next-generation code generator that introduces important breaking changes, but also important new features (like unified authentication and async programming).

General breaking changes

  • Credential system has been completly revamped:

    • azure.common.credentials or msrestazure.azure_active_directory instances are no longer supported, use the azure-identity classes instead: https://pypi.org/project/azure-identity/
    • credentials parameter has been renamed credential
  • The config attribute no longer exists on a client, configuration should be passed as kwarg. Example: MyClient(credential, subscription_id, enable_logging=True). For a complete set of supported options, see the parameters accept in init documentation of azure-core

  • You can't import a version module anymore, use __version__ instead

  • Operations that used to return a msrest.polling.LROPoller now returns a azure.core.polling.LROPoller and are prefixed with begin_.

  • Exceptions tree have been simplified and most exceptions are now azure.core.exceptions.HttpResponseError (CloudError has been removed).

  • Most of the operation kwarg have changed. Some of the most noticeable:

General new features

  • Type annotations support using typing. SDKs are mypy ready.
  • This client has now stable and official support for async. Check the aio namespace of your package to find the async client.
  • This client now support natively tracing library like OpenCensus or OpenTelemetry. See this tracing quickstart for an overview.

0.2.0rc2 (2019-07-31)

Bugfix

  • Fixed autogenerated code problems

0.2.0rc1 (2019-07-29)

Features

  • Added operation AlertsOperations.meta_data
  • Added operation group SmartDetectorAlertRulesOperations
  • Added operation group ActionRulesOperations

General breaking changes

This version uses a next-generation code generator that might introduce breaking changes if from some import. In summary, some modules were incorrectly visible/importable and have been renamed. This fixed several issues caused by usage of classes that were not supposed to be used in the first place.

  • AlertsManagementClient cannot be imported from azure.mgmt.alertsmanagement.alerts_management_client anymore (import from azure.mgmt.alertsmanagement works like before)
  • AlertsManagementClientConfiguration import has been moved from azure.mgmt.alertsmanagement.alerts_management_client to azure.mgmt.alertsmanagement
  • A model MyClass from a "models" sub-module cannot be imported anymore using azure.mgmt.alertsmanagement.models.my_class (import from azure.mgmt.alertsmanagement.models works like before)
  • An operation class MyClassOperations from an operations sub-module cannot be imported anymore using azure.mgmt.alertsmanagement.operations.my_class_operations (import from azure.mgmt.alertsmanagement.operations works like before)

Last but not least, HTTP connection pooling is now enabled by default. You should always use a client as a context manager, or call close(), or use no more than one client per process.

0.1.0 (2018-09-17)

  • Initial Release

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

azure_mgmt_alertsmanagement-2.0.0b3.tar.gz (75.1 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

azure_mgmt_alertsmanagement-2.0.0b3-py3-none-any.whl (80.1 kB view details)

Uploaded Python 3

File details

Details for the file azure_mgmt_alertsmanagement-2.0.0b3.tar.gz.

File metadata

File hashes

Hashes for azure_mgmt_alertsmanagement-2.0.0b3.tar.gz
Algorithm Hash digest
SHA256 c4985a6c822df1065d469bfa0ae098fa683119aefd9243c5b8bfc03d7c4d9d89
MD5 3fe3ee51a0d0f28b6d3af8959668c249
BLAKE2b-256 edec3326f145367ed4a042f8163f4d709a9f0a2b567d3f624e8b49ec72ac1950

See more details on using hashes here.

File details

Details for the file azure_mgmt_alertsmanagement-2.0.0b3-py3-none-any.whl.

File metadata

File hashes

Hashes for azure_mgmt_alertsmanagement-2.0.0b3-py3-none-any.whl
Algorithm Hash digest
SHA256 465d87807ef9c3b3a8541af91119df1d8214000fdecfc24751f81e4a6b0993a3
MD5 5290e49bf252007b3965851d64b70a9e
BLAKE2b-256 ef7c2d0f380f0458e7b8aea7a8a634bf06316c5696958d94c734d5b9628765c1

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page