Skip to content

Commit 6b14c88

Browse files
author
SDKAuto
committed
CodeGen from PR 12585 in Azure/azure-rest-api-specs
Merge 78796c54400d85a197d34909ca8c460aa4e34b8c into d2d049f
1 parent 7477eac commit 6b14c88

File tree

23 files changed

+996
-73
lines changed

23 files changed

+996
-73
lines changed

sdk/applicationinsights/azure-mgmt-applicationinsights/azure/mgmt/applicationinsights/v2015_05_01/_application_insights_management_client.py

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -29,6 +29,7 @@
2929
from .operations import WebTestsOperations
3030
from .operations import AnalyticsItemsOperations
3131
from .operations import WorkbooksOperations
32+
from .operations import MyWorkbooksOperations
3233
from . import models
3334

3435

@@ -70,6 +71,8 @@ class ApplicationInsightsManagementClient(SDKClient):
7071
:vartype analytics_items: azure.mgmt.applicationinsights.v2015_05_01.operations.AnalyticsItemsOperations
7172
:ivar workbooks: Workbooks operations
7273
:vartype workbooks: azure.mgmt.applicationinsights.v2015_05_01.operations.WorkbooksOperations
74+
:ivar my_workbooks: MyWorkbooks operations
75+
:vartype my_workbooks: azure.mgmt.applicationinsights.v2015_05_01.operations.MyWorkbooksOperations
7376
7477
:param credentials: Credentials needed for the client to connect to Azure.
7578
:type credentials: :mod:`A msrestazure Credentials
@@ -122,3 +125,5 @@ def __init__(
122125
self._client, self.config, self._serialize, self._deserialize)
123126
self.workbooks = WorkbooksOperations(
124127
self._client, self.config, self._serialize, self._deserialize)
128+
self.my_workbooks = MyWorkbooksOperations(
129+
self._client, self.config, self._serialize, self._deserialize)

sdk/applicationinsights/azure-mgmt-applicationinsights/azure/mgmt/applicationinsights/v2015_05_01/models/__init__.py

Lines changed: 13 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -39,6 +39,9 @@
3939
from ._models_py3 import ErrorResponse, ErrorResponseException
4040
from ._models_py3 import InnerError
4141
from ._models_py3 import LinkProperties
42+
from ._models_py3 import MyWorkbook
43+
from ._models_py3 import MyWorkbookError, MyWorkbookErrorException
44+
from ._models_py3 import MyWorkbookResource
4245
from ._models_py3 import Operation
4346
from ._models_py3 import OperationDisplay
4447
from ._models_py3 import PrivateLinkScopedResource
@@ -83,6 +86,9 @@
8386
from ._models import ErrorResponse, ErrorResponseException
8487
from ._models import InnerError
8588
from ._models import LinkProperties
89+
from ._models import MyWorkbook
90+
from ._models import MyWorkbookError, MyWorkbookErrorException
91+
from ._models import MyWorkbookResource
8692
from ._models import Operation
8793
from ._models import OperationDisplay
8894
from ._models import PrivateLinkScopedResource
@@ -101,6 +107,7 @@
101107
from ._paged_models import ApplicationInsightsComponentAPIKeyPaged
102108
from ._paged_models import ApplicationInsightsComponentPaged
103109
from ._paged_models import ApplicationInsightsComponentWebTestLocationPaged
110+
from ._paged_models import MyWorkbookPaged
104111
from ._paged_models import OperationPaged
105112
from ._paged_models import WebTestPaged
106113
from ._paged_models import WorkbookPaged
@@ -109,6 +116,7 @@
109116
ApplicationType,
110117
FlowType,
111118
RequestSource,
119+
IngestionMode,
112120
PurgeState,
113121
FavoriteType,
114122
WebTestKind,
@@ -151,6 +159,9 @@
151159
'ErrorResponse', 'ErrorResponseException',
152160
'InnerError',
153161
'LinkProperties',
162+
'MyWorkbook',
163+
'MyWorkbookError', 'MyWorkbookErrorException',
164+
'MyWorkbookResource',
154165
'Operation',
155166
'OperationDisplay',
156167
'PrivateLinkScopedResource',
@@ -173,9 +184,11 @@
173184
'ApplicationInsightsComponentWebTestLocationPaged',
174185
'WebTestPaged',
175186
'WorkbookPaged',
187+
'MyWorkbookPaged',
176188
'ApplicationType',
177189
'FlowType',
178190
'RequestSource',
191+
'IngestionMode',
179192
'PurgeState',
180193
'FavoriteType',
181194
'WebTestKind',

sdk/applicationinsights/azure-mgmt-applicationinsights/azure/mgmt/applicationinsights/v2015_05_01/models/_application_insights_management_client_enums.py

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -28,6 +28,13 @@ class RequestSource(str, Enum):
2828
rest = "rest"
2929

3030

31+
class IngestionMode(str, Enum):
32+
33+
application_insights = "ApplicationInsights"
34+
application_insights_with_diagnostic_settings = "ApplicationInsightsWithDiagnosticSettings"
35+
log_analytics = "LogAnalytics"
36+
37+
3138
class PurgeState(str, Enum):
3239

3340
pending = "pending"

sdk/applicationinsights/azure-mgmt-applicationinsights/azure/mgmt/applicationinsights/v2015_05_01/models/_models.py

Lines changed: 164 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -236,6 +236,12 @@ class ApplicationInsightsComponent(ComponentsResource):
236236
resources.
237237
:vartype private_link_scoped_resources:
238238
list[~azure.mgmt.applicationinsights.v2015_05_01.models.PrivateLinkScopedResource]
239+
:param ingestion_mode: Indicates the flow of the ingestion. Possible
240+
values include: 'ApplicationInsights',
241+
'ApplicationInsightsWithDiagnosticSettings', 'LogAnalytics'. Default
242+
value: "ApplicationInsights" .
243+
:type ingestion_mode: str or
244+
~azure.mgmt.applicationinsights.v2015_05_01.models.IngestionMode
239245
"""
240246

241247
_validation = {
@@ -280,6 +286,7 @@ class ApplicationInsightsComponent(ComponentsResource):
280286
'disable_ip_masking': {'key': 'properties.DisableIpMasking', 'type': 'bool'},
281287
'immediate_purge_data_on30_days': {'key': 'properties.ImmediatePurgeDataOn30Days', 'type': 'bool'},
282288
'private_link_scoped_resources': {'key': 'properties.PrivateLinkScopedResources', 'type': '[PrivateLinkScopedResource]'},
289+
'ingestion_mode': {'key': 'properties.IngestionMode', 'type': 'str'},
283290
}
284291

285292
def __init__(self, **kwargs):
@@ -302,6 +309,7 @@ def __init__(self, **kwargs):
302309
self.disable_ip_masking = kwargs.get('disable_ip_masking', None)
303310
self.immediate_purge_data_on30_days = kwargs.get('immediate_purge_data_on30_days', None)
304311
self.private_link_scoped_resources = None
312+
self.ingestion_mode = kwargs.get('ingestion_mode', "ApplicationInsights")
305313

306314

307315
class ApplicationInsightsComponentAnalyticsItem(Model):
@@ -1381,6 +1389,162 @@ def __init__(self, **kwargs):
13811389
self.category = kwargs.get('category', None)
13821390

13831391

1392+
class MyWorkbookResource(Model):
1393+
"""An azure resource object.
1394+
1395+
:param id: Azure resource Id
1396+
:type id: str
1397+
:param name: Azure resource name
1398+
:type name: str
1399+
:param type: Azure resource type
1400+
:type type: str
1401+
:param location: Resource location
1402+
:type location: str
1403+
:param tags: Resource tags
1404+
:type tags: dict[str, str]
1405+
"""
1406+
1407+
_attribute_map = {
1408+
'id': {'key': 'id', 'type': 'str'},
1409+
'name': {'key': 'name', 'type': 'str'},
1410+
'type': {'key': 'type', 'type': 'str'},
1411+
'location': {'key': 'location', 'type': 'str'},
1412+
'tags': {'key': 'tags', 'type': '{str}'},
1413+
}
1414+
1415+
def __init__(self, **kwargs):
1416+
super(MyWorkbookResource, self).__init__(**kwargs)
1417+
self.id = kwargs.get('id', None)
1418+
self.name = kwargs.get('name', None)
1419+
self.type = kwargs.get('type', None)
1420+
self.location = kwargs.get('location', None)
1421+
self.tags = kwargs.get('tags', None)
1422+
1423+
1424+
class MyWorkbook(MyWorkbookResource):
1425+
"""An Application Insights private workbook definition.
1426+
1427+
Variables are only populated by the server, and will be ignored when
1428+
sending a request.
1429+
1430+
All required parameters must be populated in order to send to Azure.
1431+
1432+
:param id: Azure resource Id
1433+
:type id: str
1434+
:param name: Azure resource name
1435+
:type name: str
1436+
:param type: Azure resource type
1437+
:type type: str
1438+
:param location: Resource location
1439+
:type location: str
1440+
:param tags: Resource tags
1441+
:type tags: dict[str, str]
1442+
:param kind: The kind of workbook. Choices are user and shared. Possible
1443+
values include: 'user', 'shared'
1444+
:type kind: str or
1445+
~azure.mgmt.applicationinsights.v2015_05_01.models.SharedTypeKind
1446+
:param display_name: Required. The user-defined name of the private
1447+
workbook.
1448+
:type display_name: str
1449+
:param serialized_data: Required. Configuration of this particular private
1450+
workbook. Configuration data is a string containing valid JSON
1451+
:type serialized_data: str
1452+
:param version: This instance's version of the data model. This can change
1453+
as new features are added that can be marked private workbook.
1454+
:type version: str
1455+
:ivar time_modified: Date and time in UTC of the last modification that
1456+
was made to this private workbook definition.
1457+
:vartype time_modified: str
1458+
:param category: Required. Workbook category, as defined by the user at
1459+
creation time.
1460+
:type category: str
1461+
:param my_workbook_tags: A list of 0 or more tags that are associated with
1462+
this private workbook definition
1463+
:type my_workbook_tags: list[str]
1464+
:ivar user_id: Unique user id of the specific user that owns this private
1465+
workbook.
1466+
:vartype user_id: str
1467+
:param source_id: Optional resourceId for a source resource.
1468+
:type source_id: str
1469+
"""
1470+
1471+
_validation = {
1472+
'display_name': {'required': True},
1473+
'serialized_data': {'required': True},
1474+
'time_modified': {'readonly': True},
1475+
'category': {'required': True},
1476+
'user_id': {'readonly': True},
1477+
}
1478+
1479+
_attribute_map = {
1480+
'id': {'key': 'id', 'type': 'str'},
1481+
'name': {'key': 'name', 'type': 'str'},
1482+
'type': {'key': 'type', 'type': 'str'},
1483+
'location': {'key': 'location', 'type': 'str'},
1484+
'tags': {'key': 'tags', 'type': '{str}'},
1485+
'kind': {'key': 'kind', 'type': 'str'},
1486+
'display_name': {'key': 'properties.displayName', 'type': 'str'},
1487+
'serialized_data': {'key': 'properties.serializedData', 'type': 'str'},
1488+
'version': {'key': 'properties.version', 'type': 'str'},
1489+
'time_modified': {'key': 'properties.timeModified', 'type': 'str'},
1490+
'category': {'key': 'properties.category', 'type': 'str'},
1491+
'my_workbook_tags': {'key': 'properties.tags', 'type': '[str]'},
1492+
'user_id': {'key': 'properties.userId', 'type': 'str'},
1493+
'source_id': {'key': 'properties.sourceId', 'type': 'str'},
1494+
}
1495+
1496+
def __init__(self, **kwargs):
1497+
super(MyWorkbook, self).__init__(**kwargs)
1498+
self.kind = kwargs.get('kind', None)
1499+
self.display_name = kwargs.get('display_name', None)
1500+
self.serialized_data = kwargs.get('serialized_data', None)
1501+
self.version = kwargs.get('version', None)
1502+
self.time_modified = None
1503+
self.category = kwargs.get('category', None)
1504+
self.my_workbook_tags = kwargs.get('my_workbook_tags', None)
1505+
self.user_id = None
1506+
self.source_id = kwargs.get('source_id', None)
1507+
1508+
1509+
class MyWorkbookError(Model):
1510+
"""Error message body that will indicate why the operation failed.
1511+
1512+
:param code: Service-defined error code. This code serves as a sub-status
1513+
for the HTTP error code specified in the response.
1514+
:type code: str
1515+
:param message: Human-readable representation of the error.
1516+
:type message: str
1517+
:param details: The list of invalid fields send in request, in case of
1518+
validation error.
1519+
:type details:
1520+
list[~azure.mgmt.applicationinsights.v2015_05_01.models.ErrorFieldContract]
1521+
"""
1522+
1523+
_attribute_map = {
1524+
'code': {'key': 'code', 'type': 'str'},
1525+
'message': {'key': 'message', 'type': 'str'},
1526+
'details': {'key': 'details', 'type': '[ErrorFieldContract]'},
1527+
}
1528+
1529+
def __init__(self, **kwargs):
1530+
super(MyWorkbookError, self).__init__(**kwargs)
1531+
self.code = kwargs.get('code', None)
1532+
self.message = kwargs.get('message', None)
1533+
self.details = kwargs.get('details', None)
1534+
1535+
1536+
class MyWorkbookErrorException(HttpOperationError):
1537+
"""Server responsed with exception of type: 'MyWorkbookError'.
1538+
1539+
:param deserialize: A deserializer
1540+
:param response: Server response to be deserialized.
1541+
"""
1542+
1543+
def __init__(self, deserialize, response, *args):
1544+
1545+
super(MyWorkbookErrorException, self).__init__(deserialize, response, 'MyWorkbookError', *args)
1546+
1547+
13841548
class Operation(Model):
13851549
"""CDN REST API operation.
13861550

0 commit comments

Comments
 (0)