Azure management core library defines extensions to Azure Core that are specific to ARM (Azure Resource Management) needed when you use client libraries
—
Quality
Pending
Does it follow best practices?
Impact
Pending
No eval scenarios have been run
Azure Management Core provides essential ARM (Azure Resource Management) extensions and utilities that are shared across Azure management client libraries. It offers base classes for ARM-specific pipeline clients, custom exception handling, ARM-specific policies for authentication and request processing, specialized polling mechanisms for long-running operations, and utility functions for ARM resource operations.
pip install azure-mgmt-corefrom azure.mgmt.core import ARMPipelineClient, AsyncARMPipelineClient, VERSION, __version__For specific functionality:
from azure.mgmt.core.exceptions import TypedErrorInfo, ARMErrorFormat
from azure.mgmt.core.tools import parse_resource_id, resource_id, is_valid_resource_id
from azure.mgmt.core.policies import (
ARMAutoResourceProviderRegistrationPolicy,
ARMChallengeAuthenticationPolicy,
ARMHttpLoggingPolicy
)
from azure.mgmt.core.polling.arm_polling import ARMPolling, AzureAsyncOperationPolling, BodyContentPolling
from azure.mgmt.core.polling.async_arm_polling import AsyncARMPollingfrom azure.mgmt.core import ARMPipelineClient
from azure.core.credentials import DefaultAzureCredential
# Create an ARM pipeline client
credential = DefaultAzureCredential()
base_url = "https://management.azure.com"
# Initialize with configuration
from azure.core.configuration import Configuration
config = Configuration()
client = ARMPipelineClient(
base_url=base_url,
config=config
)
# The client automatically includes ARM-specific policies:
# - Resource provider auto-registration
# - ARM-specific HTTP logging
# - Authentication challenge handlingAzure Management Core implements the Azure SDK's pipeline architecture with ARM-specific enhancements:
This design provides maximum reusability across Azure management SDKs while maintaining consistency with Azure's authentication systems, continuous access evaluation (CAE), and ARM's asynchronous operation patterns.
ARM-specific pipeline clients for synchronous and asynchronous HTTP operations, with built-in support for ARM policies, authentication, and request processing.
# Version information
VERSION: str # Package version string
__version__: str # Package version alias
class ARMPipelineClient(PipelineClient):
def __init__(self, base_url: str, **kwargs) -> None: ...
class AsyncARMPipelineClient(AsyncPipelineClient):
def __init__(self, base_url: str, **kwargs) -> None: ...Specialized HTTP pipeline policies for Azure Resource Manager operations, including automatic resource provider registration, authentication challenge handling, and ARM-specific logging.
class ARMAutoResourceProviderRegistrationPolicy(HTTPPolicy): ...
class ARMChallengeAuthenticationPolicy(BearerTokenCredentialPolicy): ...
class ARMHttpLoggingPolicy(HttpLoggingPolicy): ...ARM-specific polling strategies for managing long-running operations, supporting Azure-AsyncOperation headers, location headers, and body content polling patterns.
class ARMPolling(LROBasePolling): ...
class AsyncARMPolling(AsyncLROBasePolling): ...
class AzureAsyncOperationPolling(OperationResourcePolling): ...
class BodyContentPolling(LongRunningOperation): ...Utilities for parsing Azure resource identifiers, constructing resource IDs, and validating resource names according to ARM specifications.
def parse_resource_id(rid: str) -> Mapping[str, Union[str, int]]: ...
def resource_id(**kwargs: Optional[str]) -> str: ...
def is_valid_resource_id(rid: str, exception_type: Optional[Type[BaseException]] = None) -> bool: ...
def is_valid_resource_name(rname: str, exception_type: Optional[Type[BaseException]] = None) -> bool: ...
def get_arm_endpoints(cloud_setting: AzureClouds) -> Dict[str, Any]: ...ARM-specific error formatting and exception handling that extends Azure Core's OData v4 error format with additional ARM-specific error information.
class TypedErrorInfo:
def __init__(self, type: str, info: Mapping[str, Any]) -> None: ...
class ARMErrorFormat(ODataV4Format):
def __init__(self, json_object: Mapping[str, Any]) -> None: ...# Type aliases for HTTP request/response handling
HTTPResponseType = TypeVar("HTTPResponseType")
HTTPRequestType = TypeVar("HTTPRequestType")
AllHttpResponseType = Union[LegacyHttpResponse, HttpResponse, LegacyAsyncHttpResponse, AsyncHttpResponse]Install with Tessl CLI
npx tessl i tessl/pypi-azure-mgmt-core