Skip to content
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
The table of contents is too big for display.
Diff view
Diff view
  •  
  •  
  •  
6 changes: 3 additions & 3 deletions sdk/automation/azure-mgmt-automation/_meta.json
Original file line number Diff line number Diff line change
@@ -1,11 +1,11 @@
{
"commit": "690a7656d65a03b134fa44fc7bb8013dc18a15b5",
"commit": "ce415ddc79aa454faab934c23e7ccef6bddfe3f4",
"repository_url": "https://github.com/Azure/azure-rest-api-specs",
"autorest": "3.10.2",
"use": [
"@autorest/python@6.19.0",
"@autorest/python@6.26.4",
"@autorest/[email protected]"
],
"autorest_command": "autorest specification/automation/resource-manager/readme.md --generate-sample=True --generate-test=True --include-x-ms-examples-original-file=True --python --python-sdks-folder=/mnt/vss/_work/1/azure-sdk-for-python/sdk --tag=package-2022-08-08 --use=@autorest/python@6.19.0 --use=@autorest/[email protected] --version=3.10.2 --version-tolerant=False",
"autorest_command": "autorest specification/automation/resource-manager/readme.md --generate-sample=True --generate-test=True --include-x-ms-examples-original-file=True --python --python-sdks-folder=/mnt/vss/_work/1/s/azure-sdk-for-python/sdk --use=@autorest/python@6.26.4 --use=@autorest/[email protected] --version=3.10.2 --version-tolerant=False",
"readme": "specification/automation/resource-manager/readme.md"
}
Original file line number Diff line number Diff line change
Expand Up @@ -5,22 +5,28 @@
# Code generated by Microsoft (R) AutoRest Code Generator.
# Changes may cause incorrect behavior and will be lost if the code is regenerated.
# --------------------------------------------------------------------------
# pylint: disable=wrong-import-position

from ._automation_client import AutomationClient
from typing import TYPE_CHECKING

if TYPE_CHECKING:
from ._patch import * # pylint: disable=unused-wildcard-import

from ._automation_client import AutomationClient # type: ignore
from ._version import VERSION

__version__ = VERSION

try:
from ._patch import __all__ as _patch_all
from ._patch import * # pylint: disable=unused-wildcard-import
from ._patch import *
except ImportError:
_patch_all = []
from ._patch import patch_sdk as _patch_sdk

__all__ = [
"AutomationClient",
]
__all__.extend([p for p in _patch_all if p not in __all__])
__all__.extend([p for p in _patch_all if p not in __all__]) # pyright: ignore

_patch_sdk()
Original file line number Diff line number Diff line change
Expand Up @@ -28,8 +28,6 @@
ConnectionTypeOperations,
CredentialOperations,
DeletedAutomationAccountsOperations,
DscCompilationJobOperations,
DscCompilationJobStreamOperations,
DscConfigurationOperations,
DscNodeConfigurationOperations,
DscNodeOperations,
Expand All @@ -46,12 +44,14 @@
NodeReportsOperations,
ObjectDataTypesOperations,
Operations,
PackageOperations,
PrivateEndpointConnectionsOperations,
PrivateLinkResourcesOperations,
Python2PackageOperations,
Python3PackageOperations,
RunbookDraftOperations,
RunbookOperations,
RuntimeEnvironmentsOperations,
ScheduleOperations,
SoftwareUpdateConfigurationMachineRunsOperations,
SoftwareUpdateConfigurationRunsOperations,
Expand All @@ -69,18 +69,21 @@
)

if TYPE_CHECKING:
# pylint: disable=unused-import,ungrouped-imports
from azure.core.credentials import TokenCredential


class AutomationClient(
AutomationClientOperationsMixin
): # pylint: disable=client-accepts-api-version-keyword,too-many-instance-attributes
class AutomationClient(AutomationClientOperationsMixin): # pylint: disable=too-many-instance-attributes
"""Automation Client.

:ivar private_endpoint_connections: PrivateEndpointConnectionsOperations operations
:vartype private_endpoint_connections:
azure.mgmt.automation.operations.PrivateEndpointConnectionsOperations
:ivar node_count_information: NodeCountInformationOperations operations
:vartype node_count_information:
azure.mgmt.automation.operations.NodeCountInformationOperations
:ivar software_update_configurations: SoftwareUpdateConfigurationsOperations operations
:vartype software_update_configurations:
azure.mgmt.automation.operations.SoftwareUpdateConfigurationsOperations
:ivar deleted_automation_accounts: DeletedAutomationAccountsOperations operations
:vartype deleted_automation_accounts:
azure.mgmt.automation.operations.DeletedAutomationAccountsOperations
:ivar private_link_resources: PrivateLinkResourcesOperations operations
:vartype private_link_resources:
azure.mgmt.automation.operations.PrivateLinkResourcesOperations
Expand All @@ -91,24 +94,6 @@ class AutomationClient(
:vartype dsc_node: azure.mgmt.automation.operations.DscNodeOperations
:ivar node_reports: NodeReportsOperations operations
:vartype node_reports: azure.mgmt.automation.operations.NodeReportsOperations
:ivar dsc_compilation_job: DscCompilationJobOperations operations
:vartype dsc_compilation_job: azure.mgmt.automation.operations.DscCompilationJobOperations
:ivar dsc_compilation_job_stream: DscCompilationJobStreamOperations operations
:vartype dsc_compilation_job_stream:
azure.mgmt.automation.operations.DscCompilationJobStreamOperations
:ivar node_count_information: NodeCountInformationOperations operations
:vartype node_count_information:
azure.mgmt.automation.operations.NodeCountInformationOperations
:ivar watcher: WatcherOperations operations
:vartype watcher: azure.mgmt.automation.operations.WatcherOperations
:ivar software_update_configurations: SoftwareUpdateConfigurationsOperations operations
:vartype software_update_configurations:
azure.mgmt.automation.operations.SoftwareUpdateConfigurationsOperations
:ivar webhook: WebhookOperations operations
:vartype webhook: azure.mgmt.automation.operations.WebhookOperations
:ivar deleted_automation_accounts: DeletedAutomationAccountsOperations operations
:vartype deleted_automation_accounts:
azure.mgmt.automation.operations.DeletedAutomationAccountsOperations
:ivar automation_account: AutomationAccountOperations operations
:vartype automation_account: azure.mgmt.automation.operations.AutomationAccountOperations
:ivar statistics: StatisticsOperations operations
Expand Down Expand Up @@ -154,6 +139,11 @@ class AutomationClient(
:vartype fields: azure.mgmt.automation.operations.FieldsOperations
:ivar operations: Operations operations
:vartype operations: azure.mgmt.automation.operations.Operations
:ivar package: PackageOperations operations
:vartype package: azure.mgmt.automation.operations.PackageOperations
:ivar private_endpoint_connections: PrivateEndpointConnectionsOperations operations
:vartype private_endpoint_connections:
azure.mgmt.automation.operations.PrivateEndpointConnectionsOperations
:ivar python2_package: Python2PackageOperations operations
:vartype python2_package: azure.mgmt.automation.operations.Python2PackageOperations
:ivar python3_package: Python3PackageOperations operations
Expand All @@ -166,6 +156,8 @@ class AutomationClient(
:vartype test_job_streams: azure.mgmt.automation.operations.TestJobStreamsOperations
:ivar test_job: TestJobOperations operations
:vartype test_job: azure.mgmt.automation.operations.TestJobOperations
:ivar runtime_environments: RuntimeEnvironmentsOperations operations
:vartype runtime_environments: azure.mgmt.automation.operations.RuntimeEnvironmentsOperations
:ivar schedule: ScheduleOperations operations
:vartype schedule: azure.mgmt.automation.operations.ScheduleOperations
:ivar software_update_configuration_machine_runs:
Expand All @@ -185,13 +177,20 @@ class AutomationClient(
azure.mgmt.automation.operations.SourceControlSyncJobStreamsOperations
:ivar variable: VariableOperations operations
:vartype variable: azure.mgmt.automation.operations.VariableOperations
:ivar watcher: WatcherOperations operations
:vartype watcher: azure.mgmt.automation.operations.WatcherOperations
:ivar webhook: WebhookOperations operations
:vartype webhook: azure.mgmt.automation.operations.WebhookOperations
:param credential: Credential needed for the client to connect to Azure. Required.
:type credential: ~azure.core.credentials.TokenCredential
:param subscription_id: Gets subscription credentials which uniquely identify Microsoft Azure
subscription. The subscription ID forms part of the URI for every service call. Required.
:type subscription_id: str
:param base_url: Service URL. Default value is "https://management.azure.com".
:type base_url: str
:keyword api_version: Api Version. Default value is "2024-10-23". Note that overriding this
default value may result in unsupported behavior.
:paramtype api_version: str
:keyword int polling_interval: Default waiting time between two polls for LRO operations if no
Retry-After header is present.
"""
Expand Down Expand Up @@ -228,34 +227,23 @@ def __init__(
self._serialize = Serializer(client_models)
self._deserialize = Deserializer(client_models)
self._serialize.client_side_validation = False
self.private_endpoint_connections = PrivateEndpointConnectionsOperations(
self._client, self._config, self._serialize, self._deserialize
)
self.private_link_resources = PrivateLinkResourcesOperations(
self._client, self._config, self._serialize, self._deserialize
)
self.agent_registration_information = AgentRegistrationInformationOperations(
self._client, self._config, self._serialize, self._deserialize
)
self.dsc_node = DscNodeOperations(self._client, self._config, self._serialize, self._deserialize)
self.node_reports = NodeReportsOperations(self._client, self._config, self._serialize, self._deserialize)
self.dsc_compilation_job = DscCompilationJobOperations(
self.node_count_information = NodeCountInformationOperations(
self._client, self._config, self._serialize, self._deserialize
)
self.dsc_compilation_job_stream = DscCompilationJobStreamOperations(
self.software_update_configurations = SoftwareUpdateConfigurationsOperations(
self._client, self._config, self._serialize, self._deserialize
)
self.node_count_information = NodeCountInformationOperations(
self.deleted_automation_accounts = DeletedAutomationAccountsOperations(
self._client, self._config, self._serialize, self._deserialize
)
self.watcher = WatcherOperations(self._client, self._config, self._serialize, self._deserialize)
self.software_update_configurations = SoftwareUpdateConfigurationsOperations(
self.private_link_resources = PrivateLinkResourcesOperations(
self._client, self._config, self._serialize, self._deserialize
)
self.webhook = WebhookOperations(self._client, self._config, self._serialize, self._deserialize)
self.deleted_automation_accounts = DeletedAutomationAccountsOperations(
self.agent_registration_information = AgentRegistrationInformationOperations(
self._client, self._config, self._serialize, self._deserialize
)
self.dsc_node = DscNodeOperations(self._client, self._config, self._serialize, self._deserialize)
self.node_reports = NodeReportsOperations(self._client, self._config, self._serialize, self._deserialize)
self.automation_account = AutomationAccountOperations(
self._client, self._config, self._serialize, self._deserialize
)
Expand Down Expand Up @@ -291,12 +279,19 @@ def __init__(
)
self.fields = FieldsOperations(self._client, self._config, self._serialize, self._deserialize)
self.operations = Operations(self._client, self._config, self._serialize, self._deserialize)
self.package = PackageOperations(self._client, self._config, self._serialize, self._deserialize)
self.private_endpoint_connections = PrivateEndpointConnectionsOperations(
self._client, self._config, self._serialize, self._deserialize
)
self.python2_package = Python2PackageOperations(self._client, self._config, self._serialize, self._deserialize)
self.python3_package = Python3PackageOperations(self._client, self._config, self._serialize, self._deserialize)
self.runbook_draft = RunbookDraftOperations(self._client, self._config, self._serialize, self._deserialize)
self.runbook = RunbookOperations(self._client, self._config, self._serialize, self._deserialize)
self.test_job_streams = TestJobStreamsOperations(self._client, self._config, self._serialize, self._deserialize)
self.test_job = TestJobOperations(self._client, self._config, self._serialize, self._deserialize)
self.runtime_environments = RuntimeEnvironmentsOperations(
self._client, self._config, self._serialize, self._deserialize
)
self.schedule = ScheduleOperations(self._client, self._config, self._serialize, self._deserialize)
self.software_update_configuration_machine_runs = SoftwareUpdateConfigurationMachineRunsOperations(
self._client, self._config, self._serialize, self._deserialize
Expand All @@ -312,6 +307,8 @@ def __init__(
self._client, self._config, self._serialize, self._deserialize
)
self.variable = VariableOperations(self._client, self._config, self._serialize, self._deserialize)
self.watcher = WatcherOperations(self._client, self._config, self._serialize, self._deserialize)
self.webhook = WebhookOperations(self._client, self._config, self._serialize, self._deserialize)

def _send_request(self, request: HttpRequest, *, stream: bool = False, **kwargs: Any) -> HttpResponse:
"""Runs the network request through the client's chained policies.
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -14,11 +14,10 @@
from ._version import VERSION

if TYPE_CHECKING:
# pylint: disable=unused-import,ungrouped-imports
from azure.core.credentials import TokenCredential


class AutomationClientConfiguration: # pylint: disable=too-many-instance-attributes,name-too-long
class AutomationClientConfiguration: # pylint: disable=too-many-instance-attributes
"""Configuration for AutomationClient.

Note that all parameters used to create this instance are saved as instance
Expand All @@ -29,16 +28,22 @@ class AutomationClientConfiguration: # pylint: disable=too-many-instance-attrib
:param subscription_id: Gets subscription credentials which uniquely identify Microsoft Azure
subscription. The subscription ID forms part of the URI for every service call. Required.
:type subscription_id: str
:keyword api_version: Api Version. Default value is "2024-10-23". Note that overriding this
default value may result in unsupported behavior.
:paramtype api_version: str
"""

def __init__(self, credential: "TokenCredential", subscription_id: str, **kwargs: Any) -> None:
api_version: str = kwargs.pop("api_version", "2024-10-23")

if credential is None:
raise ValueError("Parameter 'credential' must not be None.")
if subscription_id is None:
raise ValueError("Parameter 'subscription_id' must not be None.")

self.credential = credential
self.subscription_id = subscription_id
self.api_version = api_version
self.credential_scopes = kwargs.pop("credential_scopes", ["https://management.azure.com/.default"])
kwargs.setdefault("sdk_moniker", "mgmt-automation/{}".format(VERSION))
self.polling_interval = kwargs.get("polling_interval", 30)
Expand Down
Loading
Loading