Skip to content

Commit e2e257a

Browse files
author
SDKAuto
committed
CodeGen from PR 14311 in Azure/azure-rest-api-specs
Merge 8d207d1abb9060ec7a8a8f698d27fd9cdeeb5be7 into 4b7dca5
1 parent 8dd26ca commit e2e257a

File tree

9 files changed

+48
-11
lines changed

9 files changed

+48
-11
lines changed

sdk/iothub/azure-mgmt-iotcentral/MANIFEST.in

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,4 @@
1+
include _meta.json
12
recursive-include tests *.py *.yaml
23
include *.md
34
include azure/__init__.py
Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,8 @@
1+
{
2+
"autorest": "V2",
3+
"use": "@microsoft.azure/autorest.python@~4.0.71",
4+
"commit": "801a3a8be463965161233bcd3ffda1b1e0871fcc",
5+
"repository_url": "https://github.com/Azure/azure-rest-api-specs",
6+
"autorest_command": "autorest specification/iotcentral/resource-manager/readme.md --keep-version-file --multiapi --no-async --python --python-mode=update --python-sdks-folder=/home/vsts/work/1/s/azure-sdk-for-python/sdk [email protected]/autorest.python@~4.0.71 --version=V2",
7+
"readme": "specification/iotcentral/resource-manager/readme.md"
8+
}

sdk/iothub/azure-mgmt-iotcentral/azure/mgmt/iotcentral/_iot_central_client.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -44,7 +44,7 @@ def __init__(
4444
super(IotCentralClient, self).__init__(self.config.credentials, self.config)
4545

4646
client_models = {k: v for k, v in models.__dict__.items() if isinstance(v, type)}
47-
self.api_version = '2018-09-01'
47+
self.api_version = '2021-06-01'
4848
self._serialize = Serializer(client_models)
4949
self._deserialize = Deserializer(client_models)
5050

sdk/iothub/azure-mgmt-iotcentral/azure/mgmt/iotcentral/models/__init__.py

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -37,6 +37,7 @@
3737
from ._paged_models import AppTemplatePaged
3838
from ._paged_models import OperationPaged
3939
from ._iot_central_client_enums import (
40+
AppState,
4041
AppSku,
4142
)
4243

@@ -55,5 +56,6 @@
5556
'AppPaged',
5657
'AppTemplatePaged',
5758
'OperationPaged',
59+
'AppState',
5860
'AppSku',
5961
]

sdk/iothub/azure-mgmt-iotcentral/azure/mgmt/iotcentral/models/_iot_central_client_enums.py

Lines changed: 7 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -12,10 +12,16 @@
1212
from enum import Enum
1313

1414

15+
class AppState(str, Enum):
16+
17+
created = "created"
18+
deleted = "deleted"
19+
suspended = "suspended"
20+
21+
1522
class AppSku(str, Enum):
1623

1724
f1 = "F1"
18-
s1 = "S1"
1925
st0 = "ST0"
2026
st1 = "ST1"
2127
st2 = "ST2"

sdk/iothub/azure-mgmt-iotcentral/azure/mgmt/iotcentral/models/_models.py

Lines changed: 11 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -86,6 +86,9 @@ class App(Resource):
8686
Optional; if not specified, defaults to a blank blueprint and allows the
8787
application to be defined from scratch.
8888
:type template: str
89+
:param state: The current state of the application. Possible values
90+
include: 'created', 'deleted', 'suspended'
91+
:type state: str or ~azure.mgmt.iotcentral.models.AppState
8992
:param sku: Required. A valid instance SKU.
9093
:type sku: ~azure.mgmt.iotcentral.models.AppSkuInfo
9194
"""
@@ -109,6 +112,7 @@ class App(Resource):
109112
'display_name': {'key': 'properties.displayName', 'type': 'str'},
110113
'subdomain': {'key': 'properties.subdomain', 'type': 'str'},
111114
'template': {'key': 'properties.template', 'type': 'str'},
115+
'state': {'key': 'properties.state', 'type': 'str'},
112116
'sku': {'key': 'sku', 'type': 'AppSkuInfo'},
113117
}
114118

@@ -118,6 +122,7 @@ def __init__(self, **kwargs):
118122
self.display_name = kwargs.get('display_name', None)
119123
self.subdomain = kwargs.get('subdomain', None)
120124
self.template = kwargs.get('template', None)
125+
self.state = kwargs.get('state', None)
121126
self.sku = kwargs.get('sku', None)
122127

123128

@@ -177,6 +182,9 @@ class AppPatch(Model):
177182
Optional; if not specified, defaults to a blank blueprint and allows the
178183
application to be defined from scratch.
179184
:type template: str
185+
:param state: The current state of the application. Possible values
186+
include: 'created', 'deleted', 'suspended'
187+
:type state: str or ~azure.mgmt.iotcentral.models.AppState
180188
"""
181189

182190
_validation = {
@@ -190,6 +198,7 @@ class AppPatch(Model):
190198
'display_name': {'key': 'properties.displayName', 'type': 'str'},
191199
'subdomain': {'key': 'properties.subdomain', 'type': 'str'},
192200
'template': {'key': 'properties.template', 'type': 'str'},
201+
'state': {'key': 'properties.state', 'type': 'str'},
193202
}
194203

195204
def __init__(self, **kwargs):
@@ -200,6 +209,7 @@ def __init__(self, **kwargs):
200209
self.display_name = kwargs.get('display_name', None)
201210
self.subdomain = kwargs.get('subdomain', None)
202211
self.template = kwargs.get('template', None)
212+
self.state = kwargs.get('state', None)
203213

204214

205215
class AppSkuInfo(Model):
@@ -208,7 +218,7 @@ class AppSkuInfo(Model):
208218
All required parameters must be populated in order to send to Azure.
209219
210220
:param name: Required. The name of the SKU. Possible values include: 'F1',
211-
'S1', 'ST0', 'ST1', 'ST2'
221+
'ST0', 'ST1', 'ST2'
212222
:type name: str or ~azure.mgmt.iotcentral.models.AppSku
213223
"""
214224

sdk/iothub/azure-mgmt-iotcentral/azure/mgmt/iotcentral/models/_models_py3.py

Lines changed: 13 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -86,6 +86,9 @@ class App(Resource):
8686
Optional; if not specified, defaults to a blank blueprint and allows the
8787
application to be defined from scratch.
8888
:type template: str
89+
:param state: The current state of the application. Possible values
90+
include: 'created', 'deleted', 'suspended'
91+
:type state: str or ~azure.mgmt.iotcentral.models.AppState
8992
:param sku: Required. A valid instance SKU.
9093
:type sku: ~azure.mgmt.iotcentral.models.AppSkuInfo
9194
"""
@@ -109,15 +112,17 @@ class App(Resource):
109112
'display_name': {'key': 'properties.displayName', 'type': 'str'},
110113
'subdomain': {'key': 'properties.subdomain', 'type': 'str'},
111114
'template': {'key': 'properties.template', 'type': 'str'},
115+
'state': {'key': 'properties.state', 'type': 'str'},
112116
'sku': {'key': 'sku', 'type': 'AppSkuInfo'},
113117
}
114118

115-
def __init__(self, *, location: str, sku, tags=None, display_name: str=None, subdomain: str=None, template: str=None, **kwargs) -> None:
119+
def __init__(self, *, location: str, sku, tags=None, display_name: str=None, subdomain: str=None, template: str=None, state=None, **kwargs) -> None:
116120
super(App, self).__init__(location=location, tags=tags, **kwargs)
117121
self.application_id = None
118122
self.display_name = display_name
119123
self.subdomain = subdomain
120124
self.template = template
125+
self.state = state
121126
self.sku = sku
122127

123128

@@ -177,6 +182,9 @@ class AppPatch(Model):
177182
Optional; if not specified, defaults to a blank blueprint and allows the
178183
application to be defined from scratch.
179184
:type template: str
185+
:param state: The current state of the application. Possible values
186+
include: 'created', 'deleted', 'suspended'
187+
:type state: str or ~azure.mgmt.iotcentral.models.AppState
180188
"""
181189

182190
_validation = {
@@ -190,16 +198,18 @@ class AppPatch(Model):
190198
'display_name': {'key': 'properties.displayName', 'type': 'str'},
191199
'subdomain': {'key': 'properties.subdomain', 'type': 'str'},
192200
'template': {'key': 'properties.template', 'type': 'str'},
201+
'state': {'key': 'properties.state', 'type': 'str'},
193202
}
194203

195-
def __init__(self, *, tags=None, sku=None, display_name: str=None, subdomain: str=None, template: str=None, **kwargs) -> None:
204+
def __init__(self, *, tags=None, sku=None, display_name: str=None, subdomain: str=None, template: str=None, state=None, **kwargs) -> None:
196205
super(AppPatch, self).__init__(**kwargs)
197206
self.tags = tags
198207
self.sku = sku
199208
self.application_id = None
200209
self.display_name = display_name
201210
self.subdomain = subdomain
202211
self.template = template
212+
self.state = state
203213

204214

205215
class AppSkuInfo(Model):
@@ -208,7 +218,7 @@ class AppSkuInfo(Model):
208218
All required parameters must be populated in order to send to Azure.
209219
210220
:param name: Required. The name of the SKU. Possible values include: 'F1',
211-
'S1', 'ST0', 'ST1', 'ST2'
221+
'ST0', 'ST1', 'ST2'
212222
:type name: str or ~azure.mgmt.iotcentral.models.AppSku
213223
"""
214224

sdk/iothub/azure-mgmt-iotcentral/azure/mgmt/iotcentral/operations/_apps_operations.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -27,7 +27,7 @@ class AppsOperations(object):
2727
:param config: Configuration of service client.
2828
:param serializer: An object model serializer.
2929
:param deserializer: An object model deserializer.
30-
:ivar api_version: The version of the API. Constant value: "2018-09-01".
30+
:ivar api_version: The version of the API. Constant value: "2021-06-01".
3131
"""
3232

3333
models = models
@@ -37,7 +37,7 @@ def __init__(self, client, config, serializer, deserializer):
3737
self._client = client
3838
self._serialize = serializer
3939
self._deserialize = deserializer
40-
self.api_version = "2018-09-01"
40+
self.api_version = "2021-06-01"
4141

4242
self.config = config
4343

sdk/iothub/azure-mgmt-iotcentral/azure/mgmt/iotcentral/operations/_operations.py

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -25,7 +25,7 @@ class Operations(object):
2525
:param config: Configuration of service client.
2626
:param serializer: An object model serializer.
2727
:param deserializer: An object model deserializer.
28-
:ivar api_version: The version of the API. Constant value: "2018-09-01".
28+
:ivar api_version: The version of the API. Constant value: "2021-06-01".
2929
"""
3030

3131
models = models
@@ -35,13 +35,13 @@ def __init__(self, client, config, serializer, deserializer):
3535
self._client = client
3636
self._serialize = serializer
3737
self._deserialize = deserializer
38-
self.api_version = "2018-09-01"
38+
self.api_version = "2021-06-01"
3939

4040
self.config = config
4141

4242
def list(
4343
self, custom_headers=None, raw=False, **operation_config):
44-
"""Lists all of the available IoT Central application REST API operations.
44+
"""Lists all of the available IoT Central Resource Provider operations.
4545
4646
:param dict custom_headers: headers that will be added to the request
4747
:param bool raw: returns the direct response alongside the

0 commit comments

Comments
 (0)