Skip to content

Commit 9d6f782

Browse files
author
SDKAuto
committed
CodeGen from PR 25460 in Azure/azure-rest-api-specs
Merge 60c4df51a4f89db2f46b31aedd4cdb63e249fc32 into ad6484fee29013ab0b3619217970b106a1f44cf0
1 parent 11a6c8f commit 9d6f782

File tree

384 files changed

+36133
-4471
lines changed

Some content is hidden

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

384 files changed

+36133
-4471
lines changed
Lines changed: 23 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -1,11 +1,28 @@
11
{
2-
"commit": "396209531039d3e211cb1ec0982606dbbdf64ac2",
2+
"commit": "fa720d560a43fde8264d2a6d9d8407b1464e6c12",
33
"repository_url": "https://github.com/Azure/azure-rest-api-specs",
4-
"autorest": "3.9.2",
4+
"autorest": "3.9.7",
55
"use": [
6-
"@autorest/python@6.4.3",
7-
"@autorest/modelerfour@4.24.3"
6+
"@autorest/python@6.7.1",
7+
"@autorest/modelerfour@4.26.2"
88
],
9-
"autorest_command": "autorest specification/iothub/resource-manager/readme.md --generate-sample=True --include-x-ms-examples-original-file=True --python --python-sdks-folder=/home/vsts/work/1/azure-sdk-for-python/sdk --use=@autorest/python@6.4.3 --use=@autorest/modelerfour@4.24.3 --version=3.9.2 --version-tolerant=False",
10-
"readme": "specification/iothub/resource-manager/readme.md"
9+
"autorest_command": "autorest specification/iothub/resource-manager/readme.md --generate-sample=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.7.1 --use=@autorest/modelerfour@4.26.2 --version=3.9.7 --version-tolerant=False",
10+
"readme": "specification/iothub/resource-manager/readme.md",
11+
"package-2023-06": "2023-08-16 18:48:22 -0700 8fa9b5051129dd4808c9be1f5b753af226b044db Microsoft.Devices/stable/2023-06-30/iothub.json",
12+
"package-preview-2023-06": "2023-08-14 22:58:07 -0700 d99f18b18405cd446f7abc2c9e6b3884f5c549f8 Microsoft.Devices/preview/2023-06-30-preview/iothub.json",
13+
"package-preview-2022-11": "2023-03-14 21:37:19 -0700 7e5861ad01a796a72617080e89e42f428e66242e Microsoft.Devices/preview/2022-11-15-preview/iothub.json",
14+
"package-preview-2022-04-30": "2022-08-09 20:31:29 -0700 1f75c8b5d3f55387d6e07e7f2f879a88f529180d Microsoft.Devices/preview/2022-04-30-preview/iothub.json",
15+
"package-2021-07-02": "2023-01-27 19:16:47 -0800 0b0f8d5b088da606ffbb8b2828dc366982f106e5 Microsoft.Devices/stable/2021-07-02/iothub.json",
16+
"package-2021-07": "2023-01-27 19:16:47 -0800 0b0f8d5b088da606ffbb8b2828dc366982f106e5 Microsoft.Devices/stable/2021-07-02/iothub.json",
17+
"package-2021-03": "2021-05-07 19:43:30 -0700 4b7dca50a9a7559865803927a87a06ad0d73ff06 Microsoft.Devices/stable/2021-03-31/iothub.json",
18+
"package-preview-2021-03": "2021-04-05 22:04:32 -0700 2331a635ead0549b8c0f3891bf9bf2e5e5ad76bc Microsoft.Devices/preview/2021-03-03-preview/iothub.json",
19+
"package-2020-03": "2021-05-05 01:19:33 -0700 8c76ee1ab76c977e1bdd4abc5369704684576111 Microsoft.Devices/stable/2020-03-01/iothub.json",
20+
"package-2019-11": "2021-04-27 02:22:18 -0700 8873dabb56a800c037ca56beab11dd5a9ed988ad Microsoft.Devices/stable/2019-11-04/iothub.json",
21+
"package-preview-2019-07": "2021-04-27 02:22:18 -0700 8873dabb56a800c037ca56beab11dd5a9ed988ad Microsoft.Devices/preview/2019-07-01-preview/iothub.json",
22+
"package-2019-03": "2021-04-27 02:22:18 -0700 8873dabb56a800c037ca56beab11dd5a9ed988ad Microsoft.Devices/stable/2019-03-22/iothub.json",
23+
"package-2018-04": "2021-04-27 02:22:18 -0700 8873dabb56a800c037ca56beab11dd5a9ed988ad Microsoft.Devices/stable/2018-04-01/iothub.json",
24+
"package-2018-01": "2021-04-27 02:22:18 -0700 8873dabb56a800c037ca56beab11dd5a9ed988ad Microsoft.Devices/stable/2018-01-22/iothub.json",
25+
"package-2017-07": "2021-04-27 02:22:18 -0700 8873dabb56a800c037ca56beab11dd5a9ed988ad Microsoft.Devices/stable/2017-07-01/iothub.json",
26+
"package-2017-01": "2021-04-27 02:22:18 -0700 8873dabb56a800c037ca56beab11dd5a9ed988ad Microsoft.Devices/stable/2017-01-19/iothub.json",
27+
"package-2016-02": "2021-04-27 02:22:18 -0700 8873dabb56a800c037ca56beab11dd5a9ed988ad Microsoft.Devices/stable/2016-02-03/iothub.json"
1128
}

sdk/iothub/azure-mgmt-iothub/azure/mgmt/iothub/_iot_hub_client.py

Lines changed: 60 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -53,7 +53,7 @@ class IotHubClient(MultiApiClientMixin, _SDKClient):
5353
:keyword int polling_interval: Default waiting time between two polls for LRO operations if no Retry-After header is present.
5454
"""
5555

56-
DEFAULT_API_VERSION = '2021-07-02'
56+
DEFAULT_API_VERSION = '2023-06-30'
5757
_PROFILE_TAG = "azure.mgmt.iothub.IotHubClient"
5858
LATEST_PROFILE = ProfileDefinition({
5959
_PROFILE_TAG: {
@@ -71,6 +71,8 @@ def __init__(
7171
profile: KnownProfiles=KnownProfiles.default,
7272
**kwargs: Any
7373
):
74+
if api_version:
75+
kwargs.setdefault('api_version', api_version)
7476
self._config = IotHubClientConfiguration(credential, subscription_id, **kwargs)
7577
self._client = ARMPipelineClient(base_url=base_url, config=self._config, **kwargs)
7678
super(IotHubClient, self).__init__(
@@ -101,6 +103,8 @@ def models(cls, api_version=DEFAULT_API_VERSION):
101103
* 2021-07-02: :mod:`v2021_07_02.models<azure.mgmt.iothub.v2021_07_02.models>`
102104
* 2022-04-30-preview: :mod:`v2022_04_30_preview.models<azure.mgmt.iothub.v2022_04_30_preview.models>`
103105
* 2022-11-15-preview: :mod:`v2022_11_15_preview.models<azure.mgmt.iothub.v2022_11_15_preview.models>`
106+
* 2023-06-30: :mod:`v2023_06_30.models<azure.mgmt.iothub.v2023_06_30.models>`
107+
* 2023-06-30-preview: :mod:`v2023_06_30_preview.models<azure.mgmt.iothub.v2023_06_30_preview.models>`
104108
"""
105109
if api_version == '2016-02-03':
106110
from .v2016_02_03 import models
@@ -147,6 +151,12 @@ def models(cls, api_version=DEFAULT_API_VERSION):
147151
elif api_version == '2022-11-15-preview':
148152
from .v2022_11_15_preview import models
149153
return models
154+
elif api_version == '2023-06-30':
155+
from .v2023_06_30 import models
156+
return models
157+
elif api_version == '2023-06-30-preview':
158+
from .v2023_06_30_preview import models
159+
return models
150160
raise ValueError("API version {} is not available".format(api_version))
151161

152162
@property
@@ -166,6 +176,8 @@ def certificates(self):
166176
* 2021-07-02: :class:`CertificatesOperations<azure.mgmt.iothub.v2021_07_02.operations.CertificatesOperations>`
167177
* 2022-04-30-preview: :class:`CertificatesOperations<azure.mgmt.iothub.v2022_04_30_preview.operations.CertificatesOperations>`
168178
* 2022-11-15-preview: :class:`CertificatesOperations<azure.mgmt.iothub.v2022_11_15_preview.operations.CertificatesOperations>`
179+
* 2023-06-30: :class:`CertificatesOperations<azure.mgmt.iothub.v2023_06_30.operations.CertificatesOperations>`
180+
* 2023-06-30-preview: :class:`CertificatesOperations<azure.mgmt.iothub.v2023_06_30_preview.operations.CertificatesOperations>`
169181
"""
170182
api_version = self._get_api_version('certificates')
171183
if api_version == '2017-07-01':
@@ -194,10 +206,14 @@ def certificates(self):
194206
from .v2022_04_30_preview.operations import CertificatesOperations as OperationClass
195207
elif api_version == '2022-11-15-preview':
196208
from .v2022_11_15_preview.operations import CertificatesOperations as OperationClass
209+
elif api_version == '2023-06-30':
210+
from .v2023_06_30.operations import CertificatesOperations as OperationClass
211+
elif api_version == '2023-06-30-preview':
212+
from .v2023_06_30_preview.operations import CertificatesOperations as OperationClass
197213
else:
198214
raise ValueError("API version {} does not have operation group 'certificates'".format(api_version))
199215
self._config.api_version = api_version
200-
return OperationClass(self._client, self._config, Serializer(self._models_dict(api_version)), Deserializer(self._models_dict(api_version)))
216+
return OperationClass(self._client, self._config, Serializer(self._models_dict(api_version)), Deserializer(self._models_dict(api_version)), api_version)
201217

202218
@property
203219
def iot_hub(self):
@@ -213,6 +229,8 @@ def iot_hub(self):
213229
* 2021-07-02: :class:`IotHubOperations<azure.mgmt.iothub.v2021_07_02.operations.IotHubOperations>`
214230
* 2022-04-30-preview: :class:`IotHubOperations<azure.mgmt.iothub.v2022_04_30_preview.operations.IotHubOperations>`
215231
* 2022-11-15-preview: :class:`IotHubOperations<azure.mgmt.iothub.v2022_11_15_preview.operations.IotHubOperations>`
232+
* 2023-06-30: :class:`IotHubOperations<azure.mgmt.iothub.v2023_06_30.operations.IotHubOperations>`
233+
* 2023-06-30-preview: :class:`IotHubOperations<azure.mgmt.iothub.v2023_06_30_preview.operations.IotHubOperations>`
216234
"""
217235
api_version = self._get_api_version('iot_hub')
218236
if api_version == '2019-03-22':
@@ -235,10 +253,14 @@ def iot_hub(self):
235253
from .v2022_04_30_preview.operations import IotHubOperations as OperationClass
236254
elif api_version == '2022-11-15-preview':
237255
from .v2022_11_15_preview.operations import IotHubOperations as OperationClass
256+
elif api_version == '2023-06-30':
257+
from .v2023_06_30.operations import IotHubOperations as OperationClass
258+
elif api_version == '2023-06-30-preview':
259+
from .v2023_06_30_preview.operations import IotHubOperations as OperationClass
238260
else:
239261
raise ValueError("API version {} does not have operation group 'iot_hub'".format(api_version))
240262
self._config.api_version = api_version
241-
return OperationClass(self._client, self._config, Serializer(self._models_dict(api_version)), Deserializer(self._models_dict(api_version)))
263+
return OperationClass(self._client, self._config, Serializer(self._models_dict(api_version)), Deserializer(self._models_dict(api_version)), api_version)
242264

243265
@property
244266
def iot_hub_resource(self):
@@ -259,6 +281,8 @@ def iot_hub_resource(self):
259281
* 2021-07-02: :class:`IotHubResourceOperations<azure.mgmt.iothub.v2021_07_02.operations.IotHubResourceOperations>`
260282
* 2022-04-30-preview: :class:`IotHubResourceOperations<azure.mgmt.iothub.v2022_04_30_preview.operations.IotHubResourceOperations>`
261283
* 2022-11-15-preview: :class:`IotHubResourceOperations<azure.mgmt.iothub.v2022_11_15_preview.operations.IotHubResourceOperations>`
284+
* 2023-06-30: :class:`IotHubResourceOperations<azure.mgmt.iothub.v2023_06_30.operations.IotHubResourceOperations>`
285+
* 2023-06-30-preview: :class:`IotHubResourceOperations<azure.mgmt.iothub.v2023_06_30_preview.operations.IotHubResourceOperations>`
262286
"""
263287
api_version = self._get_api_version('iot_hub_resource')
264288
if api_version == '2016-02-03':
@@ -291,10 +315,14 @@ def iot_hub_resource(self):
291315
from .v2022_04_30_preview.operations import IotHubResourceOperations as OperationClass
292316
elif api_version == '2022-11-15-preview':
293317
from .v2022_11_15_preview.operations import IotHubResourceOperations as OperationClass
318+
elif api_version == '2023-06-30':
319+
from .v2023_06_30.operations import IotHubResourceOperations as OperationClass
320+
elif api_version == '2023-06-30-preview':
321+
from .v2023_06_30_preview.operations import IotHubResourceOperations as OperationClass
294322
else:
295323
raise ValueError("API version {} does not have operation group 'iot_hub_resource'".format(api_version))
296324
self._config.api_version = api_version
297-
return OperationClass(self._client, self._config, Serializer(self._models_dict(api_version)), Deserializer(self._models_dict(api_version)))
325+
return OperationClass(self._client, self._config, Serializer(self._models_dict(api_version)), Deserializer(self._models_dict(api_version)), api_version)
298326

299327
@property
300328
def operations(self):
@@ -313,6 +341,8 @@ def operations(self):
313341
* 2021-07-02: :class:`Operations<azure.mgmt.iothub.v2021_07_02.operations.Operations>`
314342
* 2022-04-30-preview: :class:`Operations<azure.mgmt.iothub.v2022_04_30_preview.operations.Operations>`
315343
* 2022-11-15-preview: :class:`Operations<azure.mgmt.iothub.v2022_11_15_preview.operations.Operations>`
344+
* 2023-06-30: :class:`Operations<azure.mgmt.iothub.v2023_06_30.operations.Operations>`
345+
* 2023-06-30-preview: :class:`Operations<azure.mgmt.iothub.v2023_06_30_preview.operations.Operations>`
316346
"""
317347
api_version = self._get_api_version('operations')
318348
if api_version == '2017-07-01':
@@ -341,10 +371,14 @@ def operations(self):
341371
from .v2022_04_30_preview.operations import Operations as OperationClass
342372
elif api_version == '2022-11-15-preview':
343373
from .v2022_11_15_preview.operations import Operations as OperationClass
374+
elif api_version == '2023-06-30':
375+
from .v2023_06_30.operations import Operations as OperationClass
376+
elif api_version == '2023-06-30-preview':
377+
from .v2023_06_30_preview.operations import Operations as OperationClass
344378
else:
345379
raise ValueError("API version {} does not have operation group 'operations'".format(api_version))
346380
self._config.api_version = api_version
347-
return OperationClass(self._client, self._config, Serializer(self._models_dict(api_version)), Deserializer(self._models_dict(api_version)))
381+
return OperationClass(self._client, self._config, Serializer(self._models_dict(api_version)), Deserializer(self._models_dict(api_version)), api_version)
348382

349383
@property
350384
def private_endpoint_connections(self):
@@ -357,6 +391,8 @@ def private_endpoint_connections(self):
357391
* 2021-07-02: :class:`PrivateEndpointConnectionsOperations<azure.mgmt.iothub.v2021_07_02.operations.PrivateEndpointConnectionsOperations>`
358392
* 2022-04-30-preview: :class:`PrivateEndpointConnectionsOperations<azure.mgmt.iothub.v2022_04_30_preview.operations.PrivateEndpointConnectionsOperations>`
359393
* 2022-11-15-preview: :class:`PrivateEndpointConnectionsOperations<azure.mgmt.iothub.v2022_11_15_preview.operations.PrivateEndpointConnectionsOperations>`
394+
* 2023-06-30: :class:`PrivateEndpointConnectionsOperations<azure.mgmt.iothub.v2023_06_30.operations.PrivateEndpointConnectionsOperations>`
395+
* 2023-06-30-preview: :class:`PrivateEndpointConnectionsOperations<azure.mgmt.iothub.v2023_06_30_preview.operations.PrivateEndpointConnectionsOperations>`
360396
"""
361397
api_version = self._get_api_version('private_endpoint_connections')
362398
if api_version == '2020-03-01':
@@ -373,10 +409,14 @@ def private_endpoint_connections(self):
373409
from .v2022_04_30_preview.operations import PrivateEndpointConnectionsOperations as OperationClass
374410
elif api_version == '2022-11-15-preview':
375411
from .v2022_11_15_preview.operations import PrivateEndpointConnectionsOperations as OperationClass
412+
elif api_version == '2023-06-30':
413+
from .v2023_06_30.operations import PrivateEndpointConnectionsOperations as OperationClass
414+
elif api_version == '2023-06-30-preview':
415+
from .v2023_06_30_preview.operations import PrivateEndpointConnectionsOperations as OperationClass
376416
else:
377417
raise ValueError("API version {} does not have operation group 'private_endpoint_connections'".format(api_version))
378418
self._config.api_version = api_version
379-
return OperationClass(self._client, self._config, Serializer(self._models_dict(api_version)), Deserializer(self._models_dict(api_version)))
419+
return OperationClass(self._client, self._config, Serializer(self._models_dict(api_version)), Deserializer(self._models_dict(api_version)), api_version)
380420

381421
@property
382422
def private_link_resources(self):
@@ -389,6 +429,8 @@ def private_link_resources(self):
389429
* 2021-07-02: :class:`PrivateLinkResourcesOperations<azure.mgmt.iothub.v2021_07_02.operations.PrivateLinkResourcesOperations>`
390430
* 2022-04-30-preview: :class:`PrivateLinkResourcesOperations<azure.mgmt.iothub.v2022_04_30_preview.operations.PrivateLinkResourcesOperations>`
391431
* 2022-11-15-preview: :class:`PrivateLinkResourcesOperations<azure.mgmt.iothub.v2022_11_15_preview.operations.PrivateLinkResourcesOperations>`
432+
* 2023-06-30: :class:`PrivateLinkResourcesOperations<azure.mgmt.iothub.v2023_06_30.operations.PrivateLinkResourcesOperations>`
433+
* 2023-06-30-preview: :class:`PrivateLinkResourcesOperations<azure.mgmt.iothub.v2023_06_30_preview.operations.PrivateLinkResourcesOperations>`
392434
"""
393435
api_version = self._get_api_version('private_link_resources')
394436
if api_version == '2020-03-01':
@@ -405,10 +447,14 @@ def private_link_resources(self):
405447
from .v2022_04_30_preview.operations import PrivateLinkResourcesOperations as OperationClass
406448
elif api_version == '2022-11-15-preview':
407449
from .v2022_11_15_preview.operations import PrivateLinkResourcesOperations as OperationClass
450+
elif api_version == '2023-06-30':
451+
from .v2023_06_30.operations import PrivateLinkResourcesOperations as OperationClass
452+
elif api_version == '2023-06-30-preview':
453+
from .v2023_06_30_preview.operations import PrivateLinkResourcesOperations as OperationClass
408454
else:
409455
raise ValueError("API version {} does not have operation group 'private_link_resources'".format(api_version))
410456
self._config.api_version = api_version
411-
return OperationClass(self._client, self._config, Serializer(self._models_dict(api_version)), Deserializer(self._models_dict(api_version)))
457+
return OperationClass(self._client, self._config, Serializer(self._models_dict(api_version)), Deserializer(self._models_dict(api_version)), api_version)
412458

413459
@property
414460
def resource_provider_common(self):
@@ -425,6 +471,8 @@ def resource_provider_common(self):
425471
* 2021-07-02: :class:`ResourceProviderCommonOperations<azure.mgmt.iothub.v2021_07_02.operations.ResourceProviderCommonOperations>`
426472
* 2022-04-30-preview: :class:`ResourceProviderCommonOperations<azure.mgmt.iothub.v2022_04_30_preview.operations.ResourceProviderCommonOperations>`
427473
* 2022-11-15-preview: :class:`ResourceProviderCommonOperations<azure.mgmt.iothub.v2022_11_15_preview.operations.ResourceProviderCommonOperations>`
474+
* 2023-06-30: :class:`ResourceProviderCommonOperations<azure.mgmt.iothub.v2023_06_30.operations.ResourceProviderCommonOperations>`
475+
* 2023-06-30-preview: :class:`ResourceProviderCommonOperations<azure.mgmt.iothub.v2023_06_30_preview.operations.ResourceProviderCommonOperations>`
428476
"""
429477
api_version = self._get_api_version('resource_provider_common')
430478
if api_version == '2018-04-01':
@@ -449,10 +497,14 @@ def resource_provider_common(self):
449497
from .v2022_04_30_preview.operations import ResourceProviderCommonOperations as OperationClass
450498
elif api_version == '2022-11-15-preview':
451499
from .v2022_11_15_preview.operations import ResourceProviderCommonOperations as OperationClass
500+
elif api_version == '2023-06-30':
501+
from .v2023_06_30.operations import ResourceProviderCommonOperations as OperationClass
502+
elif api_version == '2023-06-30-preview':
503+
from .v2023_06_30_preview.operations import ResourceProviderCommonOperations as OperationClass
452504
else:
453505
raise ValueError("API version {} does not have operation group 'resource_provider_common'".format(api_version))
454506
self._config.api_version = api_version
455-
return OperationClass(self._client, self._config, Serializer(self._models_dict(api_version)), Deserializer(self._models_dict(api_version)))
507+
return OperationClass(self._client, self._config, Serializer(self._models_dict(api_version)), Deserializer(self._models_dict(api_version)), api_version)
456508

457509
def close(self):
458510
self._client.close()

0 commit comments

Comments
 (0)