Skip to content

Commit 296f938

Browse files
author
SDKAuto
committed
CodeGen from PR 34322 in Azure/azure-rest-api-specs
Merge b1b37c8597d7d5369765ba595029ed402b65d28d into d6da37c3f230556d5edefd5cefccaeb9ecceaba3
1 parent be6af6e commit 296f938

File tree

54 files changed

+2378
-2458
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

54 files changed

+2378
-2458
lines changed

sdk/nginx/azure-mgmt-nginx/CHANGELOG.md

Lines changed: 79 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,84 @@
11
# Release History
22

3+
## 3.1.0b3 (2025-04-29)
4+
5+
### Features Added
6+
7+
- Model `NginxCertificate` added property `provisioning_state`
8+
- Model `NginxCertificate` added property `key_virtual_path`
9+
- Model `NginxCertificate` added property `certificate_virtual_path`
10+
- Model `NginxCertificate` added property `key_vault_secret_id`
11+
- Model `NginxCertificate` added property `sha1_thumbprint`
12+
- Model `NginxCertificate` added property `key_vault_secret_version`
13+
- Model `NginxCertificate` added property `key_vault_secret_created`
14+
- Model `NginxCertificate` added property `certificate_error`
15+
- Model `NginxConfigurationResponse` added property `provisioning_state`
16+
- Model `NginxConfigurationResponse` added property `files`
17+
- Model `NginxConfigurationResponse` added property `protected_files`
18+
- Model `NginxConfigurationResponse` added property `package`
19+
- Model `NginxConfigurationResponse` added property `root_file`
20+
- Model `NginxDeployment` added property `provisioning_state`
21+
- Model `NginxDeployment` added property `nginx_version`
22+
- Model `NginxDeployment` added property `network_profile`
23+
- Model `NginxDeployment` added property `ip_address`
24+
- Model `NginxDeployment` added property `enable_diagnostics_support`
25+
- Model `NginxDeployment` added property `logging`
26+
- Model `NginxDeployment` added property `scaling_properties`
27+
- Model `NginxDeployment` added property `auto_upgrade_profile`
28+
- Model `NginxDeployment` added property `user_profile`
29+
- Model `NginxDeployment` added property `nginx_app_protect`
30+
- Model `NginxDeployment` added property `dataplane_api_endpoint`
31+
- Model `NginxDeploymentApiKeyResponse` added property `hint`
32+
- Model `NginxDeploymentApiKeyResponse` added property `end_date_time`
33+
- Model `NginxDeploymentApiKeyResponse` added property `system_data`
34+
- Added enum `ActionType`
35+
- Added model `AzureResourceManagerArmResponseNginxDeployment`
36+
- Added model `AzureResourceManagerResourceSkuProperty`
37+
- Added model `Operation`
38+
- Added enum `Origin`
39+
- Added model `ProxyResource`
40+
- Added model `Resource`
41+
- Added model `Sku`
42+
- Added enum `SkuTier`
43+
- Added model `TrackedResource`
44+
- Method `ApiKeysOperations.create_or_update` has a new overload `def create_or_update(self: None, resource_group_name: str, deployment_name: str, api_key_name: str, body: NginxDeploymentApiKeyResponse, content_type: str)`
45+
- Method `ApiKeysOperations.create_or_update` has a new overload `def create_or_update(self: None, resource_group_name: str, deployment_name: str, api_key_name: str, body: IO[bytes], content_type: str)`
46+
- Method `CertificatesOperations.begin_create_or_update` has a new overload `def begin_create_or_update(self: None, resource_group_name: str, deployment_name: str, certificate_name: str, body: NginxCertificate, content_type: str)`
47+
- Method `CertificatesOperations.begin_create_or_update` has a new overload `def begin_create_or_update(self: None, resource_group_name: str, deployment_name: str, certificate_name: str, body: IO[bytes], content_type: str)`
48+
- Method `ConfigurationsOperations.begin_create_or_update` has a new overload `def begin_create_or_update(self: None, resource_group_name: str, deployment_name: str, configuration_name: str, body: NginxConfigurationResponse, content_type: str)`
49+
- Method `ConfigurationsOperations.begin_create_or_update` has a new overload `def begin_create_or_update(self: None, resource_group_name: str, deployment_name: str, configuration_name: str, body: IO[bytes], content_type: str)`
50+
- Method `DeploymentsOperations.begin_create_or_update` has a new overload `def begin_create_or_update(self: None, resource_group_name: str, deployment_name: str, body: NginxDeployment, content_type: str)`
51+
- Method `DeploymentsOperations.begin_create_or_update` has a new overload `def begin_create_or_update(self: None, resource_group_name: str, deployment_name: str, body: IO[bytes], content_type: str)`
52+
- Method `DeploymentsOperations.begin_update` has a new overload `def begin_update(self: None, resource_group_name: str, deployment_name: str, body: NginxDeploymentUpdateParameters, content_type: str)`
53+
- Method `DeploymentsOperations.begin_update` has a new overload `def begin_update(self: None, resource_group_name: str, deployment_name: str, body: IO[bytes], content_type: str)`
54+
55+
### Breaking Changes
56+
57+
- Model `NginxCertificate` deleted or renamed its instance variable `properties`
58+
- Method `NginxCertificateListResponse.__init__` removed default value `None` from its parameter `value`
59+
- Method `NginxConfigurationListResponse.__init__` removed default value `None` from its parameter `value`
60+
- Model `NginxConfigurationResponse` deleted or renamed its instance variable `properties`
61+
- Model `NginxDeployment` deleted or renamed its instance variable `properties`
62+
- Method `NginxDeployment.__init__` removed default value `None` from its parameter `location`
63+
- Method `NginxDeploymentApiKeyListResponse.__init__` removed default value `None` from its parameter `value`
64+
- Model `NginxDeploymentApiKeyResponse` deleted or renamed its instance variable `properties`
65+
- Method `NginxDeploymentListResponse.__init__` removed default value `None` from its parameter `value`
66+
- Deleted or renamed model `NginxCertificateProperties`
67+
- Deleted or renamed model `NginxConfigurationRequest`
68+
- Deleted or renamed model `NginxConfigurationRequestProperties`
69+
- Deleted or renamed model `NginxConfigurationResponseProperties`
70+
- Deleted or renamed model `NginxDeploymentApiKeyRequest`
71+
- Deleted or renamed model `NginxDeploymentApiKeyRequestProperties`
72+
- Deleted or renamed model `NginxDeploymentApiKeyResponseProperties`
73+
- Deleted or renamed model `NginxDeploymentProperties`
74+
- Deleted or renamed model `OperationResult`
75+
- Deleted or renamed model `ResourceSku`
76+
- Method `ApiKeysOperations.create_or_update` removed default value `None` from its parameter `body`
77+
- Method `CertificatesOperations.begin_create_or_update` removed default value `None` from its parameter `body`
78+
- Method `ConfigurationsOperations.begin_create_or_update` removed default value `None` from its parameter `body`
79+
- Method `DeploymentsOperations.begin_create_or_update` removed default value `None` from its parameter `body`
80+
- Method `DeploymentsOperations.begin_update` removed default value `None` from its parameter `body`
81+
382
## 3.1.0b2 (2025-02-23)
483

584
### Features Added

sdk/nginx/azure-mgmt-nginx/README.md

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
# Microsoft Azure SDK for Python
22

33
This is the Microsoft Azure Nginx Management Client Library.
4-
This package has been tested with Python 3.8+.
4+
This package has been tested with Python 3.9+.
55
For a more complete view of Azure libraries, see the [azure sdk python release](https://aka.ms/azsdk/python/all).
66

77
## _Disclaimer_
@@ -12,7 +12,7 @@ _Azure SDK Python packages support for Python 2.7 has ended 01 January 2022. For
1212

1313
### Prerequisites
1414

15-
- Python 3.8+ is required to use this package.
15+
- Python 3.9+ is required to use this package.
1616
- [Azure subscription](https://azure.microsoft.com/free/)
1717

1818
### Install the package
@@ -24,7 +24,7 @@ pip install azure-identity
2424

2525
### Authentication
2626

27-
By default, [Azure Active Directory](https://aka.ms/awps/aad) token authentication depends on correct configure of following environment variables.
27+
By default, [Azure Active Directory](https://aka.ms/awps/aad) token authentication depends on correct configuration of the following environment variables.
2828

2929
- `AZURE_CLIENT_ID` for Azure client ID.
3030
- `AZURE_TENANT_ID` for Azure tenant ID.
Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,11 +1,11 @@
11
{
2-
"commit": "198ffdb2b788b49be283a388ad9735b0cfad1be1",
2+
"commit": "e34f731fc59195cf22bbe1923ec4ed35f65f0bb2",
33
"repository_url": "https://github.com/Azure/azure-rest-api-specs",
44
"autorest": "3.10.2",
55
"use": [
6-
"@autorest/python@6.27.4",
6+
"@autorest/python@6.34.1",
77
"@autorest/[email protected]"
88
],
9-
"autorest_command": "autorest specification/nginx/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 --use=@autorest/python@6.27.4 --use=@autorest/[email protected] --version=3.10.2 --version-tolerant=False",
9+
"autorest_command": "autorest specification/nginx/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.34.1 --use=@autorest/[email protected] --version=3.10.2 --version-tolerant=False",
1010
"readme": "specification/nginx/resource-manager/readme.md"
1111
}

sdk/nginx/azure-mgmt-nginx/azure/mgmt/nginx/_nginx_management_client.py

Lines changed: 21 additions & 17 deletions
Original file line numberDiff line numberDiff line change
@@ -7,17 +7,19 @@
77
# --------------------------------------------------------------------------
88

99
from copy import deepcopy
10-
from typing import Any, TYPE_CHECKING
10+
from typing import Any, Optional, TYPE_CHECKING, cast
1111
from typing_extensions import Self
1212

1313
from azure.core.pipeline import policies
1414
from azure.core.rest import HttpRequest, HttpResponse
15+
from azure.core.settings import settings
1516
from azure.mgmt.core import ARMPipelineClient
1617
from azure.mgmt.core.policies import ARMAutoResourceProviderRegistrationPolicy
18+
from azure.mgmt.core.tools import get_arm_endpoints
1719

1820
from . import models as _models
1921
from ._configuration import NginxManagementClientConfiguration
20-
from ._serialization import Deserializer, Serializer
22+
from ._utils.serialization import Deserializer, Serializer
2123
from .operations import (
2224
ApiKeysOperations,
2325
CertificatesOperations,
@@ -31,23 +33,23 @@
3133

3234

3335
class NginxManagementClient:
34-
"""NginxManagementClient.
36+
"""// FIXME: (missing-service-description) Add service description.
3537
38+
:ivar operations: Operations operations
39+
:vartype operations: azure.mgmt.nginx.operations.Operations
40+
:ivar deployments: DeploymentsOperations operations
41+
:vartype deployments: azure.mgmt.nginx.operations.DeploymentsOperations
3642
:ivar api_keys: ApiKeysOperations operations
3743
:vartype api_keys: azure.mgmt.nginx.operations.ApiKeysOperations
3844
:ivar certificates: CertificatesOperations operations
3945
:vartype certificates: azure.mgmt.nginx.operations.CertificatesOperations
4046
:ivar configurations: ConfigurationsOperations operations
4147
:vartype configurations: azure.mgmt.nginx.operations.ConfigurationsOperations
42-
:ivar deployments: DeploymentsOperations operations
43-
:vartype deployments: azure.mgmt.nginx.operations.DeploymentsOperations
44-
:ivar operations: Operations operations
45-
:vartype operations: azure.mgmt.nginx.operations.Operations
4648
:param credential: Credential needed for the client to connect to Azure. Required.
4749
:type credential: ~azure.core.credentials.TokenCredential
4850
:param subscription_id: The ID of the target subscription. The value must be an UUID. Required.
4951
:type subscription_id: str
50-
:param base_url: Service URL. Default value is "https://management.azure.com".
52+
:param base_url: Service URL. Default value is None.
5153
:type base_url: str
5254
:keyword api_version: Api Version. Default value is "2024-11-01-preview". Note that overriding
5355
this default value may result in unsupported behavior.
@@ -57,15 +59,17 @@ class NginxManagementClient:
5759
"""
5860

5961
def __init__(
60-
self,
61-
credential: "TokenCredential",
62-
subscription_id: str,
63-
base_url: str = "https://management.azure.com",
64-
**kwargs: Any
62+
self, credential: "TokenCredential", subscription_id: str, base_url: Optional[str] = None, **kwargs: Any
6563
) -> None:
64+
_cloud = kwargs.pop("cloud_setting", None) or settings.current.azure_cloud # type: ignore
65+
_endpoints = get_arm_endpoints(_cloud)
66+
if not base_url:
67+
base_url = _endpoints["resource_manager"]
68+
credential_scopes = kwargs.pop("credential_scopes", _endpoints["credential_scopes"])
6669
self._config = NginxManagementClientConfiguration(
67-
credential=credential, subscription_id=subscription_id, **kwargs
70+
credential=credential, subscription_id=subscription_id, credential_scopes=credential_scopes, **kwargs
6871
)
72+
6973
_policies = kwargs.pop("policies", None)
7074
if _policies is None:
7175
_policies = [
@@ -84,17 +88,17 @@ def __init__(
8488
policies.SensitiveHeaderCleanupPolicy(**kwargs) if self._config.redirect_policy else None,
8589
self._config.http_logging_policy,
8690
]
87-
self._client: ARMPipelineClient = ARMPipelineClient(base_url=base_url, policies=_policies, **kwargs)
91+
self._client: ARMPipelineClient = ARMPipelineClient(base_url=cast(str, base_url), policies=_policies, **kwargs)
8892

8993
client_models = {k: v for k, v in _models.__dict__.items() if isinstance(v, type)}
9094
self._serialize = Serializer(client_models)
9195
self._deserialize = Deserializer(client_models)
9296
self._serialize.client_side_validation = False
97+
self.operations = Operations(self._client, self._config, self._serialize, self._deserialize)
98+
self.deployments = DeploymentsOperations(self._client, self._config, self._serialize, self._deserialize)
9399
self.api_keys = ApiKeysOperations(self._client, self._config, self._serialize, self._deserialize)
94100
self.certificates = CertificatesOperations(self._client, self._config, self._serialize, self._deserialize)
95101
self.configurations = ConfigurationsOperations(self._client, self._config, self._serialize, self._deserialize)
96-
self.deployments = DeploymentsOperations(self._client, self._config, self._serialize, self._deserialize)
97-
self.operations = Operations(self._client, self._config, self._serialize, self._deserialize)
98102

99103
def _send_request(self, request: HttpRequest, *, stream: bool = False, **kwargs: Any) -> HttpResponse:
100104
"""Runs the network request through the client's chained policies.
Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,6 @@
1+
# --------------------------------------------------------------------------
2+
# Copyright (c) Microsoft Corporation. All rights reserved.
3+
# Licensed under the MIT License. See License.txt in the project root for license information.
4+
# Code generated by Microsoft (R) AutoRest Code Generator.
5+
# Changes may cause incorrect behavior and will be lost if the code is regenerated.
6+
# --------------------------------------------------------------------------

0 commit comments

Comments
 (0)