diff --git a/azure-applicationinsights-query/HISTORY.rst b/azure-applicationinsights-query/HISTORY.rst new file mode 100644 index 000000000000..8924d5d6c445 --- /dev/null +++ b/azure-applicationinsights-query/HISTORY.rst @@ -0,0 +1,9 @@ +.. :changelog: + +Release History +=============== + +0.1.0 (1970-01-01) +++++++++++++++++++ + +* Initial Release diff --git a/azure-applicationinsights-query/MANIFEST.in b/azure-applicationinsights-query/MANIFEST.in new file mode 100644 index 000000000000..bf1103e6811a --- /dev/null +++ b/azure-applicationinsights-query/MANIFEST.in @@ -0,0 +1,5 @@ +recursive-include tests *.py *.yaml +include *.rst +include azure/__init__.py +include azure/applicationinsights/__init__.py + diff --git a/azure-applicationinsights-query/README.rst b/azure-applicationinsights-query/README.rst new file mode 100644 index 000000000000..d0429ebc7565 --- /dev/null +++ b/azure-applicationinsights-query/README.rst @@ -0,0 +1,30 @@ +Microsoft Azure SDK for Python +============================== + +This is the Microsoft Azure MyService Management Client Library. + +Azure Resource Manager (ARM) is the next generation of management APIs that +replace the old Azure Service Management (ASM). + +This package has been tested with Python 2.7, 3.4, 3.5, 3.6 and 3.7. + +For the older Azure Service Management (ASM) libraries, see +`azure-servicemanagement-legacy `__ library. + +For a more complete set of Azure libraries, see the `azure `__ bundle package. + + +Usage +===== + +For code examples, see `MyService Management +`__ +on docs.microsoft.com. + + +Provide Feedback +================ + +If you encounter any bugs or have suggestions, please file an issue in the +`Issues `__ +section of the project. diff --git a/azure-applicationinsights-query/__init__.py b/azure-applicationinsights-query/__init__.py new file mode 100644 index 000000000000..11d0b47e08e0 --- /dev/null +++ b/azure-applicationinsights-query/__init__.py @@ -0,0 +1,18 @@ +# coding=utf-8 +# -------------------------------------------------------------------------- +# Copyright (c) Microsoft Corporation. All rights reserved. +# Licensed under the MIT License. See License.txt in the project root for +# license information. +# +# Code generated by Microsoft (R) AutoRest Code Generator. +# Changes may cause incorrect behavior and will be lost if the code is +# regenerated. +# -------------------------------------------------------------------------- + +from .application_insights_data_client import ApplicationInsightsDataClient +from .version import VERSION + +__all__ = ['ApplicationInsightsDataClient'] + +__version__ = VERSION + diff --git a/azure-applicationinsights-query/application_insights_data_client.py b/azure-applicationinsights-query/application_insights_data_client.py new file mode 100644 index 000000000000..27c449d23c94 --- /dev/null +++ b/azure-applicationinsights-query/application_insights_data_client.py @@ -0,0 +1,82 @@ +# coding=utf-8 +# -------------------------------------------------------------------------- +# Copyright (c) Microsoft Corporation. All rights reserved. +# Licensed under the MIT License. See License.txt in the project root for +# license information. +# +# Code generated by Microsoft (R) AutoRest Code Generator. +# Changes may cause incorrect behavior and will be lost if the code is +# regenerated. +# -------------------------------------------------------------------------- + +from msrest.service_client import SDKClient +from msrest import Configuration, Serializer, Deserializer +from .version import VERSION +from .operations.metrics_operations import MetricsOperations +from .operations.events_operations import EventsOperations +from .operations.query_operations import QueryOperations +from . import models + + +class ApplicationInsightsDataClientConfiguration(Configuration): + """Configuration for ApplicationInsightsDataClient + Note that all parameters used to create this instance are saved as instance + attributes. + + :param credentials: Subscription credentials which uniquely identify + client subscription. + :type credentials: None + :param str base_url: Service URL + """ + + def __init__( + self, credentials, base_url=None): + + if credentials is None: + raise ValueError("Parameter 'credentials' must not be None.") + if not base_url: + base_url = 'https://api.applicationinsights.io/v1' + + super(ApplicationInsightsDataClientConfiguration, self).__init__(base_url) + + self.add_user_agent('azure-applicationinsights-query/{}'.format(VERSION)) + + self.credentials = credentials + + +class ApplicationInsightsDataClient(SDKClient): + """Composite Swagger for Application Insights Data Client + + :ivar config: Configuration for client. + :vartype config: ApplicationInsightsDataClientConfiguration + + :ivar metrics: Metrics operations + :vartype metrics: azure.applicationinsights.query.operations.MetricsOperations + :ivar events: Events operations + :vartype events: azure.applicationinsights.query.operations.EventsOperations + :ivar query: Query operations + :vartype query: azure.applicationinsights.query.operations.QueryOperations + + :param credentials: Subscription credentials which uniquely identify + client subscription. + :type credentials: None + :param str base_url: Service URL + """ + + def __init__( + self, credentials, base_url=None): + + self.config = ApplicationInsightsDataClientConfiguration(credentials, base_url) + super(ApplicationInsightsDataClient, self).__init__(self.config.credentials, self.config) + + client_models = {k: v for k, v in models.__dict__.items() if isinstance(v, type)} + self.api_version = 'v1' + self._serialize = Serializer(client_models) + self._deserialize = Deserializer(client_models) + + self.metrics = MetricsOperations( + self._client, self.config, self._serialize, self._deserialize) + self.events = EventsOperations( + self._client, self.config, self._serialize, self._deserialize) + self.query = QueryOperations( + self._client, self.config, self._serialize, self._deserialize) diff --git a/azure-applicationinsights-query/azure/__init__.py b/azure-applicationinsights-query/azure/__init__.py new file mode 100644 index 000000000000..0260537a02bb --- /dev/null +++ b/azure-applicationinsights-query/azure/__init__.py @@ -0,0 +1 @@ +__path__ = __import__('pkgutil').extend_path(__path__, __name__) \ No newline at end of file diff --git a/azure-applicationinsights-query/azure/applicationinsights/__init__.py b/azure-applicationinsights-query/azure/applicationinsights/__init__.py new file mode 100644 index 000000000000..0260537a02bb --- /dev/null +++ b/azure-applicationinsights-query/azure/applicationinsights/__init__.py @@ -0,0 +1 @@ +__path__ = __import__('pkgutil').extend_path(__path__, __name__) \ No newline at end of file diff --git a/azure-applicationinsights-query/azure/applicationinsights/query/__init__.py b/azure-applicationinsights-query/azure/applicationinsights/query/__init__.py new file mode 100644 index 000000000000..11d0b47e08e0 --- /dev/null +++ b/azure-applicationinsights-query/azure/applicationinsights/query/__init__.py @@ -0,0 +1,18 @@ +# coding=utf-8 +# -------------------------------------------------------------------------- +# Copyright (c) Microsoft Corporation. All rights reserved. +# Licensed under the MIT License. See License.txt in the project root for +# license information. +# +# Code generated by Microsoft (R) AutoRest Code Generator. +# Changes may cause incorrect behavior and will be lost if the code is +# regenerated. +# -------------------------------------------------------------------------- + +from .application_insights_data_client import ApplicationInsightsDataClient +from .version import VERSION + +__all__ = ['ApplicationInsightsDataClient'] + +__version__ = VERSION + diff --git a/azure-applicationinsights-query/azure/applicationinsights/query/application_insights_data_client.py b/azure-applicationinsights-query/azure/applicationinsights/query/application_insights_data_client.py new file mode 100644 index 000000000000..27c449d23c94 --- /dev/null +++ b/azure-applicationinsights-query/azure/applicationinsights/query/application_insights_data_client.py @@ -0,0 +1,82 @@ +# coding=utf-8 +# -------------------------------------------------------------------------- +# Copyright (c) Microsoft Corporation. All rights reserved. +# Licensed under the MIT License. See License.txt in the project root for +# license information. +# +# Code generated by Microsoft (R) AutoRest Code Generator. +# Changes may cause incorrect behavior and will be lost if the code is +# regenerated. +# -------------------------------------------------------------------------- + +from msrest.service_client import SDKClient +from msrest import Configuration, Serializer, Deserializer +from .version import VERSION +from .operations.metrics_operations import MetricsOperations +from .operations.events_operations import EventsOperations +from .operations.query_operations import QueryOperations +from . import models + + +class ApplicationInsightsDataClientConfiguration(Configuration): + """Configuration for ApplicationInsightsDataClient + Note that all parameters used to create this instance are saved as instance + attributes. + + :param credentials: Subscription credentials which uniquely identify + client subscription. + :type credentials: None + :param str base_url: Service URL + """ + + def __init__( + self, credentials, base_url=None): + + if credentials is None: + raise ValueError("Parameter 'credentials' must not be None.") + if not base_url: + base_url = 'https://api.applicationinsights.io/v1' + + super(ApplicationInsightsDataClientConfiguration, self).__init__(base_url) + + self.add_user_agent('azure-applicationinsights-query/{}'.format(VERSION)) + + self.credentials = credentials + + +class ApplicationInsightsDataClient(SDKClient): + """Composite Swagger for Application Insights Data Client + + :ivar config: Configuration for client. + :vartype config: ApplicationInsightsDataClientConfiguration + + :ivar metrics: Metrics operations + :vartype metrics: azure.applicationinsights.query.operations.MetricsOperations + :ivar events: Events operations + :vartype events: azure.applicationinsights.query.operations.EventsOperations + :ivar query: Query operations + :vartype query: azure.applicationinsights.query.operations.QueryOperations + + :param credentials: Subscription credentials which uniquely identify + client subscription. + :type credentials: None + :param str base_url: Service URL + """ + + def __init__( + self, credentials, base_url=None): + + self.config = ApplicationInsightsDataClientConfiguration(credentials, base_url) + super(ApplicationInsightsDataClient, self).__init__(self.config.credentials, self.config) + + client_models = {k: v for k, v in models.__dict__.items() if isinstance(v, type)} + self.api_version = 'v1' + self._serialize = Serializer(client_models) + self._deserialize = Deserializer(client_models) + + self.metrics = MetricsOperations( + self._client, self.config, self._serialize, self._deserialize) + self.events = EventsOperations( + self._client, self.config, self._serialize, self._deserialize) + self.query = QueryOperations( + self._client, self.config, self._serialize, self._deserialize) diff --git a/azure-applicationinsights-query/azure/applicationinsights/query/models/__init__.py b/azure-applicationinsights-query/azure/applicationinsights/query/models/__init__.py new file mode 100644 index 000000000000..0fb0a6c567d4 --- /dev/null +++ b/azure-applicationinsights-query/azure/applicationinsights/query/models/__init__.py @@ -0,0 +1,170 @@ +# coding=utf-8 +# -------------------------------------------------------------------------- +# Copyright (c) Microsoft Corporation. All rights reserved. +# Licensed under the MIT License. See License.txt in the project root for +# license information. +# +# Code generated by Microsoft (R) AutoRest Code Generator. +# Changes may cause incorrect behavior and will be lost if the code is +# regenerated. +# -------------------------------------------------------------------------- + +try: + from .metrics_post_body_schema_parameters_py3 import MetricsPostBodySchemaParameters + from .metrics_post_body_schema_py3 import MetricsPostBodySchema + from .metrics_segment_info_py3 import MetricsSegmentInfo + from .metrics_result_info_py3 import MetricsResultInfo + from .metrics_result_py3 import MetricsResult + from .metrics_results_item_py3 import MetricsResultsItem + from .error_detail_py3 import ErrorDetail + from .error_info_py3 import ErrorInfo + from .events_result_data_custom_dimensions_py3 import EventsResultDataCustomDimensions + from .events_result_data_custom_measurements_py3 import EventsResultDataCustomMeasurements + from .events_operation_info_py3 import EventsOperationInfo + from .events_session_info_py3 import EventsSessionInfo + from .events_user_info_py3 import EventsUserInfo + from .events_cloud_info_py3 import EventsCloudInfo + from .events_ai_info_py3 import EventsAiInfo + from .events_application_info_py3 import EventsApplicationInfo + from .events_client_info_py3 import EventsClientInfo + from .events_result_data_py3 import EventsResultData + from .events_results_py3 import EventsResults + from .events_result_py3 import EventsResult + from .events_trace_info_py3 import EventsTraceInfo + from .events_trace_result_py3 import EventsTraceResult + from .events_custom_event_info_py3 import EventsCustomEventInfo + from .events_custom_event_result_py3 import EventsCustomEventResult + from .events_page_view_info_py3 import EventsPageViewInfo + from .events_page_view_result_py3 import EventsPageViewResult + from .events_browser_timing_info_py3 import EventsBrowserTimingInfo + from .events_client_performance_info_py3 import EventsClientPerformanceInfo + from .events_browser_timing_result_py3 import EventsBrowserTimingResult + from .events_request_info_py3 import EventsRequestInfo + from .events_request_result_py3 import EventsRequestResult + from .events_dependency_info_py3 import EventsDependencyInfo + from .events_dependency_result_py3 import EventsDependencyResult + from .events_exception_details_parsed_stack_py3 import EventsExceptionDetailsParsedStack + from .events_exception_detail_py3 import EventsExceptionDetail + from .events_exception_info_py3 import EventsExceptionInfo + from .events_exception_result_py3 import EventsExceptionResult + from .events_availability_result_info_py3 import EventsAvailabilityResultInfo + from .events_availability_result_result_py3 import EventsAvailabilityResultResult + from .events_performance_counter_info_py3 import EventsPerformanceCounterInfo + from .events_performance_counter_result_py3 import EventsPerformanceCounterResult + from .events_custom_metric_info_py3 import EventsCustomMetricInfo + from .events_custom_metric_result_py3 import EventsCustomMetricResult + from .query_body_py3 import QueryBody + from .column_py3 import Column + from .table_py3 import Table + from .query_results_py3 import QueryResults + from .error_response_py3 import ErrorResponse, ErrorResponseException +except (SyntaxError, ImportError): + from .metrics_post_body_schema_parameters import MetricsPostBodySchemaParameters + from .metrics_post_body_schema import MetricsPostBodySchema + from .metrics_segment_info import MetricsSegmentInfo + from .metrics_result_info import MetricsResultInfo + from .metrics_result import MetricsResult + from .metrics_results_item import MetricsResultsItem + from .error_detail import ErrorDetail + from .error_info import ErrorInfo + from .events_result_data_custom_dimensions import EventsResultDataCustomDimensions + from .events_result_data_custom_measurements import EventsResultDataCustomMeasurements + from .events_operation_info import EventsOperationInfo + from .events_session_info import EventsSessionInfo + from .events_user_info import EventsUserInfo + from .events_cloud_info import EventsCloudInfo + from .events_ai_info import EventsAiInfo + from .events_application_info import EventsApplicationInfo + from .events_client_info import EventsClientInfo + from .events_result_data import EventsResultData + from .events_results import EventsResults + from .events_result import EventsResult + from .events_trace_info import EventsTraceInfo + from .events_trace_result import EventsTraceResult + from .events_custom_event_info import EventsCustomEventInfo + from .events_custom_event_result import EventsCustomEventResult + from .events_page_view_info import EventsPageViewInfo + from .events_page_view_result import EventsPageViewResult + from .events_browser_timing_info import EventsBrowserTimingInfo + from .events_client_performance_info import EventsClientPerformanceInfo + from .events_browser_timing_result import EventsBrowserTimingResult + from .events_request_info import EventsRequestInfo + from .events_request_result import EventsRequestResult + from .events_dependency_info import EventsDependencyInfo + from .events_dependency_result import EventsDependencyResult + from .events_exception_details_parsed_stack import EventsExceptionDetailsParsedStack + from .events_exception_detail import EventsExceptionDetail + from .events_exception_info import EventsExceptionInfo + from .events_exception_result import EventsExceptionResult + from .events_availability_result_info import EventsAvailabilityResultInfo + from .events_availability_result_result import EventsAvailabilityResultResult + from .events_performance_counter_info import EventsPerformanceCounterInfo + from .events_performance_counter_result import EventsPerformanceCounterResult + from .events_custom_metric_info import EventsCustomMetricInfo + from .events_custom_metric_result import EventsCustomMetricResult + from .query_body import QueryBody + from .column import Column + from .table import Table + from .query_results import QueryResults + from .error_response import ErrorResponse, ErrorResponseException +from .application_insights_data_client_enums import ( + MetricId, + MetricsAggregation, + MetricsSegment, + EventType, +) + +__all__ = [ + 'MetricsPostBodySchemaParameters', + 'MetricsPostBodySchema', + 'MetricsSegmentInfo', + 'MetricsResultInfo', + 'MetricsResult', + 'MetricsResultsItem', + 'ErrorDetail', + 'ErrorInfo', + 'EventsResultDataCustomDimensions', + 'EventsResultDataCustomMeasurements', + 'EventsOperationInfo', + 'EventsSessionInfo', + 'EventsUserInfo', + 'EventsCloudInfo', + 'EventsAiInfo', + 'EventsApplicationInfo', + 'EventsClientInfo', + 'EventsResultData', + 'EventsResults', + 'EventsResult', + 'EventsTraceInfo', + 'EventsTraceResult', + 'EventsCustomEventInfo', + 'EventsCustomEventResult', + 'EventsPageViewInfo', + 'EventsPageViewResult', + 'EventsBrowserTimingInfo', + 'EventsClientPerformanceInfo', + 'EventsBrowserTimingResult', + 'EventsRequestInfo', + 'EventsRequestResult', + 'EventsDependencyInfo', + 'EventsDependencyResult', + 'EventsExceptionDetailsParsedStack', + 'EventsExceptionDetail', + 'EventsExceptionInfo', + 'EventsExceptionResult', + 'EventsAvailabilityResultInfo', + 'EventsAvailabilityResultResult', + 'EventsPerformanceCounterInfo', + 'EventsPerformanceCounterResult', + 'EventsCustomMetricInfo', + 'EventsCustomMetricResult', + 'QueryBody', + 'Column', + 'Table', + 'QueryResults', + 'ErrorResponse', 'ErrorResponseException', + 'MetricId', + 'MetricsAggregation', + 'MetricsSegment', + 'EventType', +] diff --git a/azure-applicationinsights-query/azure/applicationinsights/query/models/application_insights_data_client_enums.py b/azure-applicationinsights-query/azure/applicationinsights/query/models/application_insights_data_client_enums.py new file mode 100644 index 000000000000..f81da2b46d59 --- /dev/null +++ b/azure-applicationinsights-query/azure/applicationinsights/query/models/application_insights_data_client_enums.py @@ -0,0 +1,93 @@ +# coding=utf-8 +# -------------------------------------------------------------------------- +# Copyright (c) Microsoft Corporation. All rights reserved. +# Licensed under the MIT License. See License.txt in the project root for +# license information. +# +# Code generated by Microsoft (R) AutoRest Code Generator. +# Changes may cause incorrect behavior and will be lost if the code is +# regenerated. +# -------------------------------------------------------------------------- + +from enum import Enum + + +class MetricId(str, Enum): + + requestscount = "requests/count" + requestsduration = "requests/duration" + requestsfailed = "requests/failed" + userscount = "users/count" + usersauthenticated = "users/authenticated" + page_viewscount = "pageViews/count" + page_viewsduration = "pageViews/duration" + clientprocessing_duration = "client/processingDuration" + clientreceive_duration = "client/receiveDuration" + clientnetwork_duration = "client/networkDuration" + clientsend_duration = "client/sendDuration" + clienttotal_duration = "client/totalDuration" + dependenciescount = "dependencies/count" + dependenciesfailed = "dependencies/failed" + dependenciesduration = "dependencies/duration" + exceptionscount = "exceptions/count" + exceptionsbrowser = "exceptions/browser" + exceptionsserver = "exceptions/server" + sessionscount = "sessions/count" + performance_countersrequest_execution_time = "performanceCounters/requestExecutionTime" + performance_countersrequests_per_second = "performanceCounters/requestsPerSecond" + performance_countersrequests_in_queue = "performanceCounters/requestsInQueue" + performance_countersmemory_available_bytes = "performanceCounters/memoryAvailableBytes" + performance_countersexceptions_per_second = "performanceCounters/exceptionsPerSecond" + performance_countersprocess_cpu_percentage = "performanceCounters/processCpuPercentage" + performance_countersprocess_io_bytes_per_second = "performanceCounters/processIOBytesPerSecond" + performance_countersprocess_private_bytes = "performanceCounters/processPrivateBytes" + performance_countersprocessor_cpu_percentage = "performanceCounters/processorCpuPercentage" + availability_resultsavailability_percentage = "availabilityResults/availabilityPercentage" + availability_resultsduration = "availabilityResults/duration" + billingtelemetry_count = "billing/telemetryCount" + custom_eventscount = "customEvents/count" + + +class MetricsAggregation(str, Enum): + + min = "min" + max = "max" + avg = "avg" + sum = "sum" + count = "count" + unique = "unique" + + +class MetricsSegment(str, Enum): + + application_build = "applicationBuild" + application_version = "applicationVersion" + authenticated_or_anonymous_traffic = "authenticatedOrAnonymousTraffic" + browser = "browser" + browser_version = "browserVersion" + city = "city" + cloud_role_name = "cloudRoleName" + cloud_service_name = "cloudServiceName" + continent = "continent" + country_or_region = "countryOrRegion" + deployment_id = "deploymentId" + deployment_unit = "deploymentUnit" + device_type = "deviceType" + environment = "environment" + hosting_location = "hostingLocation" + instance_name = "instanceName" + + +class EventType(str, Enum): + + all = "$all" + traces = "traces" + custom_events = "customEvents" + page_views = "pageViews" + browser_timings = "browserTimings" + requests = "requests" + dependencies = "dependencies" + exceptions = "exceptions" + availability_results = "availabilityResults" + performance_counters = "performanceCounters" + custom_metrics = "customMetrics" diff --git a/azure-applicationinsights-query/azure/applicationinsights/query/models/column.py b/azure-applicationinsights-query/azure/applicationinsights/query/models/column.py new file mode 100644 index 000000000000..fde9b294d351 --- /dev/null +++ b/azure-applicationinsights-query/azure/applicationinsights/query/models/column.py @@ -0,0 +1,34 @@ +# coding=utf-8 +# -------------------------------------------------------------------------- +# Copyright (c) Microsoft Corporation. All rights reserved. +# Licensed under the MIT License. See License.txt in the project root for +# license information. +# +# Code generated by Microsoft (R) AutoRest Code Generator. +# Changes may cause incorrect behavior and will be lost if the code is +# regenerated. +# -------------------------------------------------------------------------- + +from msrest.serialization import Model + + +class Column(Model): + """A table column. + + A column in a table. + + :param name: The name of this column. + :type name: str + :param type: The data type of this column. + :type type: str + """ + + _attribute_map = { + 'name': {'key': 'name', 'type': 'str'}, + 'type': {'key': 'type', 'type': 'str'}, + } + + def __init__(self, **kwargs): + super(Column, self).__init__(**kwargs) + self.name = kwargs.get('name', None) + self.type = kwargs.get('type', None) diff --git a/azure-applicationinsights-query/azure/applicationinsights/query/models/column_py3.py b/azure-applicationinsights-query/azure/applicationinsights/query/models/column_py3.py new file mode 100644 index 000000000000..4df2ac58398f --- /dev/null +++ b/azure-applicationinsights-query/azure/applicationinsights/query/models/column_py3.py @@ -0,0 +1,34 @@ +# coding=utf-8 +# -------------------------------------------------------------------------- +# Copyright (c) Microsoft Corporation. All rights reserved. +# Licensed under the MIT License. See License.txt in the project root for +# license information. +# +# Code generated by Microsoft (R) AutoRest Code Generator. +# Changes may cause incorrect behavior and will be lost if the code is +# regenerated. +# -------------------------------------------------------------------------- + +from msrest.serialization import Model + + +class Column(Model): + """A table column. + + A column in a table. + + :param name: The name of this column. + :type name: str + :param type: The data type of this column. + :type type: str + """ + + _attribute_map = { + 'name': {'key': 'name', 'type': 'str'}, + 'type': {'key': 'type', 'type': 'str'}, + } + + def __init__(self, *, name: str=None, type: str=None, **kwargs) -> None: + super(Column, self).__init__(**kwargs) + self.name = name + self.type = type diff --git a/azure-applicationinsights-query/azure/applicationinsights/query/models/error_detail.py b/azure-applicationinsights-query/azure/applicationinsights/query/models/error_detail.py new file mode 100644 index 000000000000..3fd620dffa45 --- /dev/null +++ b/azure-applicationinsights-query/azure/applicationinsights/query/models/error_detail.py @@ -0,0 +1,58 @@ +# coding=utf-8 +# -------------------------------------------------------------------------- +# Copyright (c) Microsoft Corporation. All rights reserved. +# Licensed under the MIT License. See License.txt in the project root for +# license information. +# +# Code generated by Microsoft (R) AutoRest Code Generator. +# Changes may cause incorrect behavior and will be lost if the code is +# regenerated. +# -------------------------------------------------------------------------- + +from msrest.serialization import Model + + +class ErrorDetail(Model): + """Error details. + + All required parameters must be populated in order to send to Azure. + + :param code: Required. The error's code. + :type code: str + :param message: Required. A human readable error message. + :type message: str + :param target: Indicates which property in the request is responsible for + the error. + :type target: str + :param value: Indicates which value in 'target' is responsible for the + error. + :type value: str + :param resources: Indicates resources which were responsible for the + error. + :type resources: list[str] + :param additional_properties: + :type additional_properties: object + """ + + _validation = { + 'code': {'required': True}, + 'message': {'required': True}, + } + + _attribute_map = { + 'code': {'key': 'code', 'type': 'str'}, + 'message': {'key': 'message', 'type': 'str'}, + 'target': {'key': 'target', 'type': 'str'}, + 'value': {'key': 'value', 'type': 'str'}, + 'resources': {'key': 'resources', 'type': '[str]'}, + 'additional_properties': {'key': 'additionalProperties', 'type': 'object'}, + } + + def __init__(self, **kwargs): + super(ErrorDetail, self).__init__(**kwargs) + self.code = kwargs.get('code', None) + self.message = kwargs.get('message', None) + self.target = kwargs.get('target', None) + self.value = kwargs.get('value', None) + self.resources = kwargs.get('resources', None) + self.additional_properties = kwargs.get('additional_properties', None) diff --git a/azure-applicationinsights-query/azure/applicationinsights/query/models/error_detail_py3.py b/azure-applicationinsights-query/azure/applicationinsights/query/models/error_detail_py3.py new file mode 100644 index 000000000000..8c714de89d18 --- /dev/null +++ b/azure-applicationinsights-query/azure/applicationinsights/query/models/error_detail_py3.py @@ -0,0 +1,58 @@ +# coding=utf-8 +# -------------------------------------------------------------------------- +# Copyright (c) Microsoft Corporation. All rights reserved. +# Licensed under the MIT License. See License.txt in the project root for +# license information. +# +# Code generated by Microsoft (R) AutoRest Code Generator. +# Changes may cause incorrect behavior and will be lost if the code is +# regenerated. +# -------------------------------------------------------------------------- + +from msrest.serialization import Model + + +class ErrorDetail(Model): + """Error details. + + All required parameters must be populated in order to send to Azure. + + :param code: Required. The error's code. + :type code: str + :param message: Required. A human readable error message. + :type message: str + :param target: Indicates which property in the request is responsible for + the error. + :type target: str + :param value: Indicates which value in 'target' is responsible for the + error. + :type value: str + :param resources: Indicates resources which were responsible for the + error. + :type resources: list[str] + :param additional_properties: + :type additional_properties: object + """ + + _validation = { + 'code': {'required': True}, + 'message': {'required': True}, + } + + _attribute_map = { + 'code': {'key': 'code', 'type': 'str'}, + 'message': {'key': 'message', 'type': 'str'}, + 'target': {'key': 'target', 'type': 'str'}, + 'value': {'key': 'value', 'type': 'str'}, + 'resources': {'key': 'resources', 'type': '[str]'}, + 'additional_properties': {'key': 'additionalProperties', 'type': 'object'}, + } + + def __init__(self, *, code: str, message: str, target: str=None, value: str=None, resources=None, additional_properties=None, **kwargs) -> None: + super(ErrorDetail, self).__init__(**kwargs) + self.code = code + self.message = message + self.target = target + self.value = value + self.resources = resources + self.additional_properties = additional_properties diff --git a/azure-applicationinsights-query/azure/applicationinsights/query/models/error_info.py b/azure-applicationinsights-query/azure/applicationinsights/query/models/error_info.py new file mode 100644 index 000000000000..14f34f097774 --- /dev/null +++ b/azure-applicationinsights-query/azure/applicationinsights/query/models/error_info.py @@ -0,0 +1,51 @@ +# coding=utf-8 +# -------------------------------------------------------------------------- +# Copyright (c) Microsoft Corporation. All rights reserved. +# Licensed under the MIT License. See License.txt in the project root for +# license information. +# +# Code generated by Microsoft (R) AutoRest Code Generator. +# Changes may cause incorrect behavior and will be lost if the code is +# regenerated. +# -------------------------------------------------------------------------- + +from msrest.serialization import Model + + +class ErrorInfo(Model): + """The code and message for an error. + + All required parameters must be populated in order to send to Azure. + + :param code: Required. A machine readable error code. + :type code: str + :param message: Required. A human readable error message. + :type message: str + :param details: error details. + :type details: list[~azure.applicationinsights.query.models.ErrorDetail] + :param innererror: Inner error details if they exist. + :type innererror: ~azure.applicationinsights.query.models.ErrorInfo + :param additional_properties: + :type additional_properties: object + """ + + _validation = { + 'code': {'required': True}, + 'message': {'required': True}, + } + + _attribute_map = { + 'code': {'key': 'code', 'type': 'str'}, + 'message': {'key': 'message', 'type': 'str'}, + 'details': {'key': 'details', 'type': '[ErrorDetail]'}, + 'innererror': {'key': 'innererror', 'type': 'ErrorInfo'}, + 'additional_properties': {'key': 'additionalProperties', 'type': 'object'}, + } + + def __init__(self, **kwargs): + super(ErrorInfo, self).__init__(**kwargs) + self.code = kwargs.get('code', None) + self.message = kwargs.get('message', None) + self.details = kwargs.get('details', None) + self.innererror = kwargs.get('innererror', None) + self.additional_properties = kwargs.get('additional_properties', None) diff --git a/azure-applicationinsights-query/azure/applicationinsights/query/models/error_info_py3.py b/azure-applicationinsights-query/azure/applicationinsights/query/models/error_info_py3.py new file mode 100644 index 000000000000..8d01ca19f1b8 --- /dev/null +++ b/azure-applicationinsights-query/azure/applicationinsights/query/models/error_info_py3.py @@ -0,0 +1,51 @@ +# coding=utf-8 +# -------------------------------------------------------------------------- +# Copyright (c) Microsoft Corporation. All rights reserved. +# Licensed under the MIT License. See License.txt in the project root for +# license information. +# +# Code generated by Microsoft (R) AutoRest Code Generator. +# Changes may cause incorrect behavior and will be lost if the code is +# regenerated. +# -------------------------------------------------------------------------- + +from msrest.serialization import Model + + +class ErrorInfo(Model): + """The code and message for an error. + + All required parameters must be populated in order to send to Azure. + + :param code: Required. A machine readable error code. + :type code: str + :param message: Required. A human readable error message. + :type message: str + :param details: error details. + :type details: list[~azure.applicationinsights.query.models.ErrorDetail] + :param innererror: Inner error details if they exist. + :type innererror: ~azure.applicationinsights.query.models.ErrorInfo + :param additional_properties: + :type additional_properties: object + """ + + _validation = { + 'code': {'required': True}, + 'message': {'required': True}, + } + + _attribute_map = { + 'code': {'key': 'code', 'type': 'str'}, + 'message': {'key': 'message', 'type': 'str'}, + 'details': {'key': 'details', 'type': '[ErrorDetail]'}, + 'innererror': {'key': 'innererror', 'type': 'ErrorInfo'}, + 'additional_properties': {'key': 'additionalProperties', 'type': 'object'}, + } + + def __init__(self, *, code: str, message: str, details=None, innererror=None, additional_properties=None, **kwargs) -> None: + super(ErrorInfo, self).__init__(**kwargs) + self.code = code + self.message = message + self.details = details + self.innererror = innererror + self.additional_properties = additional_properties diff --git a/azure-applicationinsights-query/azure/applicationinsights/query/models/error_response.py b/azure-applicationinsights-query/azure/applicationinsights/query/models/error_response.py new file mode 100644 index 000000000000..4461869de892 --- /dev/null +++ b/azure-applicationinsights-query/azure/applicationinsights/query/models/error_response.py @@ -0,0 +1,49 @@ +# coding=utf-8 +# -------------------------------------------------------------------------- +# Copyright (c) Microsoft Corporation. All rights reserved. +# Licensed under the MIT License. See License.txt in the project root for +# license information. +# +# Code generated by Microsoft (R) AutoRest Code Generator. +# Changes may cause incorrect behavior and will be lost if the code is +# regenerated. +# -------------------------------------------------------------------------- + +from msrest.serialization import Model +from msrest.exceptions import HttpOperationError + + +class ErrorResponse(Model): + """Error details. + + Contains details when the response code indicates an error. + + All required parameters must be populated in order to send to Azure. + + :param error: Required. The error details. + :type error: ~azure.applicationinsights.query.models.ErrorInfo + """ + + _validation = { + 'error': {'required': True}, + } + + _attribute_map = { + 'error': {'key': 'error', 'type': 'ErrorInfo'}, + } + + def __init__(self, **kwargs): + super(ErrorResponse, self).__init__(**kwargs) + self.error = kwargs.get('error', None) + + +class ErrorResponseException(HttpOperationError): + """Server responsed with exception of type: 'ErrorResponse'. + + :param deserialize: A deserializer + :param response: Server response to be deserialized. + """ + + def __init__(self, deserialize, response, *args): + + super(ErrorResponseException, self).__init__(deserialize, response, 'ErrorResponse', *args) diff --git a/azure-applicationinsights-query/azure/applicationinsights/query/models/error_response_py3.py b/azure-applicationinsights-query/azure/applicationinsights/query/models/error_response_py3.py new file mode 100644 index 000000000000..af501a2f5965 --- /dev/null +++ b/azure-applicationinsights-query/azure/applicationinsights/query/models/error_response_py3.py @@ -0,0 +1,49 @@ +# coding=utf-8 +# -------------------------------------------------------------------------- +# Copyright (c) Microsoft Corporation. All rights reserved. +# Licensed under the MIT License. See License.txt in the project root for +# license information. +# +# Code generated by Microsoft (R) AutoRest Code Generator. +# Changes may cause incorrect behavior and will be lost if the code is +# regenerated. +# -------------------------------------------------------------------------- + +from msrest.serialization import Model +from msrest.exceptions import HttpOperationError + + +class ErrorResponse(Model): + """Error details. + + Contains details when the response code indicates an error. + + All required parameters must be populated in order to send to Azure. + + :param error: Required. The error details. + :type error: ~azure.applicationinsights.query.models.ErrorInfo + """ + + _validation = { + 'error': {'required': True}, + } + + _attribute_map = { + 'error': {'key': 'error', 'type': 'ErrorInfo'}, + } + + def __init__(self, *, error, **kwargs) -> None: + super(ErrorResponse, self).__init__(**kwargs) + self.error = error + + +class ErrorResponseException(HttpOperationError): + """Server responsed with exception of type: 'ErrorResponse'. + + :param deserialize: A deserializer + :param response: Server response to be deserialized. + """ + + def __init__(self, deserialize, response, *args): + + super(ErrorResponseException, self).__init__(deserialize, response, 'ErrorResponse', *args) diff --git a/azure-applicationinsights-query/azure/applicationinsights/query/models/events_ai_info.py b/azure-applicationinsights-query/azure/applicationinsights/query/models/events_ai_info.py new file mode 100644 index 000000000000..61f01cdf44a7 --- /dev/null +++ b/azure-applicationinsights-query/azure/applicationinsights/query/models/events_ai_info.py @@ -0,0 +1,40 @@ +# coding=utf-8 +# -------------------------------------------------------------------------- +# Copyright (c) Microsoft Corporation. All rights reserved. +# Licensed under the MIT License. See License.txt in the project root for +# license information. +# +# Code generated by Microsoft (R) AutoRest Code Generator. +# Changes may cause incorrect behavior and will be lost if the code is +# regenerated. +# -------------------------------------------------------------------------- + +from msrest.serialization import Model + + +class EventsAiInfo(Model): + """AI related application info for an event result. + + :param i_key: iKey of the app + :type i_key: str + :param app_name: Name of the application + :type app_name: str + :param app_id: ID of the application + :type app_id: str + :param sdk_version: SDK version of the application + :type sdk_version: str + """ + + _attribute_map = { + 'i_key': {'key': 'iKey', 'type': 'str'}, + 'app_name': {'key': 'appName', 'type': 'str'}, + 'app_id': {'key': 'appId', 'type': 'str'}, + 'sdk_version': {'key': 'sdkVersion', 'type': 'str'}, + } + + def __init__(self, **kwargs): + super(EventsAiInfo, self).__init__(**kwargs) + self.i_key = kwargs.get('i_key', None) + self.app_name = kwargs.get('app_name', None) + self.app_id = kwargs.get('app_id', None) + self.sdk_version = kwargs.get('sdk_version', None) diff --git a/azure-applicationinsights-query/azure/applicationinsights/query/models/events_ai_info_py3.py b/azure-applicationinsights-query/azure/applicationinsights/query/models/events_ai_info_py3.py new file mode 100644 index 000000000000..ab903f4b09e3 --- /dev/null +++ b/azure-applicationinsights-query/azure/applicationinsights/query/models/events_ai_info_py3.py @@ -0,0 +1,40 @@ +# coding=utf-8 +# -------------------------------------------------------------------------- +# Copyright (c) Microsoft Corporation. All rights reserved. +# Licensed under the MIT License. See License.txt in the project root for +# license information. +# +# Code generated by Microsoft (R) AutoRest Code Generator. +# Changes may cause incorrect behavior and will be lost if the code is +# regenerated. +# -------------------------------------------------------------------------- + +from msrest.serialization import Model + + +class EventsAiInfo(Model): + """AI related application info for an event result. + + :param i_key: iKey of the app + :type i_key: str + :param app_name: Name of the application + :type app_name: str + :param app_id: ID of the application + :type app_id: str + :param sdk_version: SDK version of the application + :type sdk_version: str + """ + + _attribute_map = { + 'i_key': {'key': 'iKey', 'type': 'str'}, + 'app_name': {'key': 'appName', 'type': 'str'}, + 'app_id': {'key': 'appId', 'type': 'str'}, + 'sdk_version': {'key': 'sdkVersion', 'type': 'str'}, + } + + def __init__(self, *, i_key: str=None, app_name: str=None, app_id: str=None, sdk_version: str=None, **kwargs) -> None: + super(EventsAiInfo, self).__init__(**kwargs) + self.i_key = i_key + self.app_name = app_name + self.app_id = app_id + self.sdk_version = sdk_version diff --git a/azure-applicationinsights-query/azure/applicationinsights/query/models/events_application_info.py b/azure-applicationinsights-query/azure/applicationinsights/query/models/events_application_info.py new file mode 100644 index 000000000000..5ed98e5c8b19 --- /dev/null +++ b/azure-applicationinsights-query/azure/applicationinsights/query/models/events_application_info.py @@ -0,0 +1,28 @@ +# coding=utf-8 +# -------------------------------------------------------------------------- +# Copyright (c) Microsoft Corporation. All rights reserved. +# Licensed under the MIT License. See License.txt in the project root for +# license information. +# +# Code generated by Microsoft (R) AutoRest Code Generator. +# Changes may cause incorrect behavior and will be lost if the code is +# regenerated. +# -------------------------------------------------------------------------- + +from msrest.serialization import Model + + +class EventsApplicationInfo(Model): + """Application info for an event result. + + :param version: Version of the application + :type version: str + """ + + _attribute_map = { + 'version': {'key': 'version', 'type': 'str'}, + } + + def __init__(self, **kwargs): + super(EventsApplicationInfo, self).__init__(**kwargs) + self.version = kwargs.get('version', None) diff --git a/azure-applicationinsights-query/azure/applicationinsights/query/models/events_application_info_py3.py b/azure-applicationinsights-query/azure/applicationinsights/query/models/events_application_info_py3.py new file mode 100644 index 000000000000..03ede06633b7 --- /dev/null +++ b/azure-applicationinsights-query/azure/applicationinsights/query/models/events_application_info_py3.py @@ -0,0 +1,28 @@ +# coding=utf-8 +# -------------------------------------------------------------------------- +# Copyright (c) Microsoft Corporation. All rights reserved. +# Licensed under the MIT License. See License.txt in the project root for +# license information. +# +# Code generated by Microsoft (R) AutoRest Code Generator. +# Changes may cause incorrect behavior and will be lost if the code is +# regenerated. +# -------------------------------------------------------------------------- + +from msrest.serialization import Model + + +class EventsApplicationInfo(Model): + """Application info for an event result. + + :param version: Version of the application + :type version: str + """ + + _attribute_map = { + 'version': {'key': 'version', 'type': 'str'}, + } + + def __init__(self, *, version: str=None, **kwargs) -> None: + super(EventsApplicationInfo, self).__init__(**kwargs) + self.version = version diff --git a/azure-applicationinsights-query/azure/applicationinsights/query/models/events_availability_result_info.py b/azure-applicationinsights-query/azure/applicationinsights/query/models/events_availability_result_info.py new file mode 100644 index 000000000000..3daaca0578a2 --- /dev/null +++ b/azure-applicationinsights-query/azure/applicationinsights/query/models/events_availability_result_info.py @@ -0,0 +1,57 @@ +# coding=utf-8 +# -------------------------------------------------------------------------- +# Copyright (c) Microsoft Corporation. All rights reserved. +# Licensed under the MIT License. See License.txt in the project root for +# license information. +# +# Code generated by Microsoft (R) AutoRest Code Generator. +# Changes may cause incorrect behavior and will be lost if the code is +# regenerated. +# -------------------------------------------------------------------------- + +from msrest.serialization import Model + + +class EventsAvailabilityResultInfo(Model): + """The availability result info. + + :param name: The name of the availability result + :type name: str + :param success: Indicates if the availability result was successful + :type success: str + :param duration: The duration of the availability result + :type duration: long + :param performance_bucket: The performance bucket of the availability + result + :type performance_bucket: str + :param message: The message of the availability result + :type message: str + :param location: The location of the availability result + :type location: str + :param id: The ID of the availability result + :type id: str + :param size: The size of the availability result + :type size: str + """ + + _attribute_map = { + 'name': {'key': 'name', 'type': 'str'}, + 'success': {'key': 'success', 'type': 'str'}, + 'duration': {'key': 'duration', 'type': 'long'}, + 'performance_bucket': {'key': 'performanceBucket', 'type': 'str'}, + 'message': {'key': 'message', 'type': 'str'}, + 'location': {'key': 'location', 'type': 'str'}, + 'id': {'key': 'id', 'type': 'str'}, + 'size': {'key': 'size', 'type': 'str'}, + } + + def __init__(self, **kwargs): + super(EventsAvailabilityResultInfo, self).__init__(**kwargs) + self.name = kwargs.get('name', None) + self.success = kwargs.get('success', None) + self.duration = kwargs.get('duration', None) + self.performance_bucket = kwargs.get('performance_bucket', None) + self.message = kwargs.get('message', None) + self.location = kwargs.get('location', None) + self.id = kwargs.get('id', None) + self.size = kwargs.get('size', None) diff --git a/azure-applicationinsights-query/azure/applicationinsights/query/models/events_availability_result_info_py3.py b/azure-applicationinsights-query/azure/applicationinsights/query/models/events_availability_result_info_py3.py new file mode 100644 index 000000000000..90bd69d03aa9 --- /dev/null +++ b/azure-applicationinsights-query/azure/applicationinsights/query/models/events_availability_result_info_py3.py @@ -0,0 +1,57 @@ +# coding=utf-8 +# -------------------------------------------------------------------------- +# Copyright (c) Microsoft Corporation. All rights reserved. +# Licensed under the MIT License. See License.txt in the project root for +# license information. +# +# Code generated by Microsoft (R) AutoRest Code Generator. +# Changes may cause incorrect behavior and will be lost if the code is +# regenerated. +# -------------------------------------------------------------------------- + +from msrest.serialization import Model + + +class EventsAvailabilityResultInfo(Model): + """The availability result info. + + :param name: The name of the availability result + :type name: str + :param success: Indicates if the availability result was successful + :type success: str + :param duration: The duration of the availability result + :type duration: long + :param performance_bucket: The performance bucket of the availability + result + :type performance_bucket: str + :param message: The message of the availability result + :type message: str + :param location: The location of the availability result + :type location: str + :param id: The ID of the availability result + :type id: str + :param size: The size of the availability result + :type size: str + """ + + _attribute_map = { + 'name': {'key': 'name', 'type': 'str'}, + 'success': {'key': 'success', 'type': 'str'}, + 'duration': {'key': 'duration', 'type': 'long'}, + 'performance_bucket': {'key': 'performanceBucket', 'type': 'str'}, + 'message': {'key': 'message', 'type': 'str'}, + 'location': {'key': 'location', 'type': 'str'}, + 'id': {'key': 'id', 'type': 'str'}, + 'size': {'key': 'size', 'type': 'str'}, + } + + def __init__(self, *, name: str=None, success: str=None, duration: int=None, performance_bucket: str=None, message: str=None, location: str=None, id: str=None, size: str=None, **kwargs) -> None: + super(EventsAvailabilityResultInfo, self).__init__(**kwargs) + self.name = name + self.success = success + self.duration = duration + self.performance_bucket = performance_bucket + self.message = message + self.location = location + self.id = id + self.size = size diff --git a/azure-applicationinsights-query/azure/applicationinsights/query/models/events_availability_result_result.py b/azure-applicationinsights-query/azure/applicationinsights/query/models/events_availability_result_result.py new file mode 100644 index 000000000000..729504b268e8 --- /dev/null +++ b/azure-applicationinsights-query/azure/applicationinsights/query/models/events_availability_result_result.py @@ -0,0 +1,79 @@ +# coding=utf-8 +# -------------------------------------------------------------------------- +# Copyright (c) Microsoft Corporation. All rights reserved. +# Licensed under the MIT License. See License.txt in the project root for +# license information. +# +# Code generated by Microsoft (R) AutoRest Code Generator. +# Changes may cause incorrect behavior and will be lost if the code is +# regenerated. +# -------------------------------------------------------------------------- + +from .events_result_data import EventsResultData + + +class EventsAvailabilityResultResult(EventsResultData): + """An availability result result. + + All required parameters must be populated in order to send to Azure. + + :param id: The unique ID for this event. + :type id: str + :param count: Count of the event + :type count: long + :param timestamp: Timestamp of the event + :type timestamp: datetime + :param custom_dimensions: Custom dimensions of the event + :type custom_dimensions: + ~azure.applicationinsights.query.models.EventsResultDataCustomDimensions + :param custom_measurements: Custom measurements of the event + :type custom_measurements: + ~azure.applicationinsights.query.models.EventsResultDataCustomMeasurements + :param operation: Operation info of the event + :type operation: + ~azure.applicationinsights.query.models.EventsOperationInfo + :param session: Session info of the event + :type session: ~azure.applicationinsights.query.models.EventsSessionInfo + :param user: User info of the event + :type user: ~azure.applicationinsights.query.models.EventsUserInfo + :param cloud: Cloud info of the event + :type cloud: ~azure.applicationinsights.query.models.EventsCloudInfo + :param ai: AI info of the event + :type ai: ~azure.applicationinsights.query.models.EventsAiInfo + :param application: Application info of the event + :type application: + ~azure.applicationinsights.query.models.EventsApplicationInfo + :param client: Client info of the event + :type client: ~azure.applicationinsights.query.models.EventsClientInfo + :param type: Required. Constant filled by server. + :type type: str + :param availability_result: + :type availability_result: + ~azure.applicationinsights.query.models.EventsAvailabilityResultInfo + """ + + _validation = { + 'type': {'required': True}, + } + + _attribute_map = { + 'id': {'key': 'id', 'type': 'str'}, + 'count': {'key': 'count', 'type': 'long'}, + 'timestamp': {'key': 'timestamp', 'type': 'iso-8601'}, + 'custom_dimensions': {'key': 'customDimensions', 'type': 'EventsResultDataCustomDimensions'}, + 'custom_measurements': {'key': 'customMeasurements', 'type': 'EventsResultDataCustomMeasurements'}, + 'operation': {'key': 'operation', 'type': 'EventsOperationInfo'}, + 'session': {'key': 'session', 'type': 'EventsSessionInfo'}, + 'user': {'key': 'user', 'type': 'EventsUserInfo'}, + 'cloud': {'key': 'cloud', 'type': 'EventsCloudInfo'}, + 'ai': {'key': 'ai', 'type': 'EventsAiInfo'}, + 'application': {'key': 'application', 'type': 'EventsApplicationInfo'}, + 'client': {'key': 'client', 'type': 'EventsClientInfo'}, + 'type': {'key': 'type', 'type': 'str'}, + 'availability_result': {'key': 'availabilityResult', 'type': 'EventsAvailabilityResultInfo'}, + } + + def __init__(self, **kwargs): + super(EventsAvailabilityResultResult, self).__init__(**kwargs) + self.availability_result = kwargs.get('availability_result', None) + self.type = 'availabilityResult' diff --git a/azure-applicationinsights-query/azure/applicationinsights/query/models/events_availability_result_result_py3.py b/azure-applicationinsights-query/azure/applicationinsights/query/models/events_availability_result_result_py3.py new file mode 100644 index 000000000000..9a6da5a4488d --- /dev/null +++ b/azure-applicationinsights-query/azure/applicationinsights/query/models/events_availability_result_result_py3.py @@ -0,0 +1,79 @@ +# coding=utf-8 +# -------------------------------------------------------------------------- +# Copyright (c) Microsoft Corporation. All rights reserved. +# Licensed under the MIT License. See License.txt in the project root for +# license information. +# +# Code generated by Microsoft (R) AutoRest Code Generator. +# Changes may cause incorrect behavior and will be lost if the code is +# regenerated. +# -------------------------------------------------------------------------- + +from .events_result_data_py3 import EventsResultData + + +class EventsAvailabilityResultResult(EventsResultData): + """An availability result result. + + All required parameters must be populated in order to send to Azure. + + :param id: The unique ID for this event. + :type id: str + :param count: Count of the event + :type count: long + :param timestamp: Timestamp of the event + :type timestamp: datetime + :param custom_dimensions: Custom dimensions of the event + :type custom_dimensions: + ~azure.applicationinsights.query.models.EventsResultDataCustomDimensions + :param custom_measurements: Custom measurements of the event + :type custom_measurements: + ~azure.applicationinsights.query.models.EventsResultDataCustomMeasurements + :param operation: Operation info of the event + :type operation: + ~azure.applicationinsights.query.models.EventsOperationInfo + :param session: Session info of the event + :type session: ~azure.applicationinsights.query.models.EventsSessionInfo + :param user: User info of the event + :type user: ~azure.applicationinsights.query.models.EventsUserInfo + :param cloud: Cloud info of the event + :type cloud: ~azure.applicationinsights.query.models.EventsCloudInfo + :param ai: AI info of the event + :type ai: ~azure.applicationinsights.query.models.EventsAiInfo + :param application: Application info of the event + :type application: + ~azure.applicationinsights.query.models.EventsApplicationInfo + :param client: Client info of the event + :type client: ~azure.applicationinsights.query.models.EventsClientInfo + :param type: Required. Constant filled by server. + :type type: str + :param availability_result: + :type availability_result: + ~azure.applicationinsights.query.models.EventsAvailabilityResultInfo + """ + + _validation = { + 'type': {'required': True}, + } + + _attribute_map = { + 'id': {'key': 'id', 'type': 'str'}, + 'count': {'key': 'count', 'type': 'long'}, + 'timestamp': {'key': 'timestamp', 'type': 'iso-8601'}, + 'custom_dimensions': {'key': 'customDimensions', 'type': 'EventsResultDataCustomDimensions'}, + 'custom_measurements': {'key': 'customMeasurements', 'type': 'EventsResultDataCustomMeasurements'}, + 'operation': {'key': 'operation', 'type': 'EventsOperationInfo'}, + 'session': {'key': 'session', 'type': 'EventsSessionInfo'}, + 'user': {'key': 'user', 'type': 'EventsUserInfo'}, + 'cloud': {'key': 'cloud', 'type': 'EventsCloudInfo'}, + 'ai': {'key': 'ai', 'type': 'EventsAiInfo'}, + 'application': {'key': 'application', 'type': 'EventsApplicationInfo'}, + 'client': {'key': 'client', 'type': 'EventsClientInfo'}, + 'type': {'key': 'type', 'type': 'str'}, + 'availability_result': {'key': 'availabilityResult', 'type': 'EventsAvailabilityResultInfo'}, + } + + def __init__(self, *, id: str=None, count: int=None, timestamp=None, custom_dimensions=None, custom_measurements=None, operation=None, session=None, user=None, cloud=None, ai=None, application=None, client=None, availability_result=None, **kwargs) -> None: + super(EventsAvailabilityResultResult, self).__init__(id=id, count=count, timestamp=timestamp, custom_dimensions=custom_dimensions, custom_measurements=custom_measurements, operation=operation, session=session, user=user, cloud=cloud, ai=ai, application=application, client=client, **kwargs) + self.availability_result = availability_result + self.type = 'availabilityResult' diff --git a/azure-applicationinsights-query/azure/applicationinsights/query/models/events_browser_timing_info.py b/azure-applicationinsights-query/azure/applicationinsights/query/models/events_browser_timing_info.py new file mode 100644 index 000000000000..1686e263cfbf --- /dev/null +++ b/azure-applicationinsights-query/azure/applicationinsights/query/models/events_browser_timing_info.py @@ -0,0 +1,64 @@ +# coding=utf-8 +# -------------------------------------------------------------------------- +# Copyright (c) Microsoft Corporation. All rights reserved. +# Licensed under the MIT License. See License.txt in the project root for +# license information. +# +# Code generated by Microsoft (R) AutoRest Code Generator. +# Changes may cause incorrect behavior and will be lost if the code is +# regenerated. +# -------------------------------------------------------------------------- + +from msrest.serialization import Model + + +class EventsBrowserTimingInfo(Model): + """The browser timing information. + + :param url_path: The path of the URL + :type url_path: str + :param url_host: The host of the URL + :type url_host: str + :param name: The name of the page + :type name: str + :param url: The url of the page + :type url: str + :param total_duration: The total duration of the load + :type total_duration: long + :param performance_bucket: The performance bucket of the load + :type performance_bucket: str + :param network_duration: The network duration of the load + :type network_duration: long + :param send_duration: The send duration of the load + :type send_duration: long + :param receive_duration: The receive duration of the load + :type receive_duration: long + :param processing_duration: The processing duration of the load + :type processing_duration: long + """ + + _attribute_map = { + 'url_path': {'key': 'urlPath', 'type': 'str'}, + 'url_host': {'key': 'urlHost', 'type': 'str'}, + 'name': {'key': 'name', 'type': 'str'}, + 'url': {'key': 'url', 'type': 'str'}, + 'total_duration': {'key': 'totalDuration', 'type': 'long'}, + 'performance_bucket': {'key': 'performanceBucket', 'type': 'str'}, + 'network_duration': {'key': 'networkDuration', 'type': 'long'}, + 'send_duration': {'key': 'sendDuration', 'type': 'long'}, + 'receive_duration': {'key': 'receiveDuration', 'type': 'long'}, + 'processing_duration': {'key': 'processingDuration', 'type': 'long'}, + } + + def __init__(self, **kwargs): + super(EventsBrowserTimingInfo, self).__init__(**kwargs) + self.url_path = kwargs.get('url_path', None) + self.url_host = kwargs.get('url_host', None) + self.name = kwargs.get('name', None) + self.url = kwargs.get('url', None) + self.total_duration = kwargs.get('total_duration', None) + self.performance_bucket = kwargs.get('performance_bucket', None) + self.network_duration = kwargs.get('network_duration', None) + self.send_duration = kwargs.get('send_duration', None) + self.receive_duration = kwargs.get('receive_duration', None) + self.processing_duration = kwargs.get('processing_duration', None) diff --git a/azure-applicationinsights-query/azure/applicationinsights/query/models/events_browser_timing_info_py3.py b/azure-applicationinsights-query/azure/applicationinsights/query/models/events_browser_timing_info_py3.py new file mode 100644 index 000000000000..f32fabc2b31c --- /dev/null +++ b/azure-applicationinsights-query/azure/applicationinsights/query/models/events_browser_timing_info_py3.py @@ -0,0 +1,64 @@ +# coding=utf-8 +# -------------------------------------------------------------------------- +# Copyright (c) Microsoft Corporation. All rights reserved. +# Licensed under the MIT License. See License.txt in the project root for +# license information. +# +# Code generated by Microsoft (R) AutoRest Code Generator. +# Changes may cause incorrect behavior and will be lost if the code is +# regenerated. +# -------------------------------------------------------------------------- + +from msrest.serialization import Model + + +class EventsBrowserTimingInfo(Model): + """The browser timing information. + + :param url_path: The path of the URL + :type url_path: str + :param url_host: The host of the URL + :type url_host: str + :param name: The name of the page + :type name: str + :param url: The url of the page + :type url: str + :param total_duration: The total duration of the load + :type total_duration: long + :param performance_bucket: The performance bucket of the load + :type performance_bucket: str + :param network_duration: The network duration of the load + :type network_duration: long + :param send_duration: The send duration of the load + :type send_duration: long + :param receive_duration: The receive duration of the load + :type receive_duration: long + :param processing_duration: The processing duration of the load + :type processing_duration: long + """ + + _attribute_map = { + 'url_path': {'key': 'urlPath', 'type': 'str'}, + 'url_host': {'key': 'urlHost', 'type': 'str'}, + 'name': {'key': 'name', 'type': 'str'}, + 'url': {'key': 'url', 'type': 'str'}, + 'total_duration': {'key': 'totalDuration', 'type': 'long'}, + 'performance_bucket': {'key': 'performanceBucket', 'type': 'str'}, + 'network_duration': {'key': 'networkDuration', 'type': 'long'}, + 'send_duration': {'key': 'sendDuration', 'type': 'long'}, + 'receive_duration': {'key': 'receiveDuration', 'type': 'long'}, + 'processing_duration': {'key': 'processingDuration', 'type': 'long'}, + } + + def __init__(self, *, url_path: str=None, url_host: str=None, name: str=None, url: str=None, total_duration: int=None, performance_bucket: str=None, network_duration: int=None, send_duration: int=None, receive_duration: int=None, processing_duration: int=None, **kwargs) -> None: + super(EventsBrowserTimingInfo, self).__init__(**kwargs) + self.url_path = url_path + self.url_host = url_host + self.name = name + self.url = url + self.total_duration = total_duration + self.performance_bucket = performance_bucket + self.network_duration = network_duration + self.send_duration = send_duration + self.receive_duration = receive_duration + self.processing_duration = processing_duration diff --git a/azure-applicationinsights-query/azure/applicationinsights/query/models/events_browser_timing_result.py b/azure-applicationinsights-query/azure/applicationinsights/query/models/events_browser_timing_result.py new file mode 100644 index 000000000000..15bada46f728 --- /dev/null +++ b/azure-applicationinsights-query/azure/applicationinsights/query/models/events_browser_timing_result.py @@ -0,0 +1,84 @@ +# coding=utf-8 +# -------------------------------------------------------------------------- +# Copyright (c) Microsoft Corporation. All rights reserved. +# Licensed under the MIT License. See License.txt in the project root for +# license information. +# +# Code generated by Microsoft (R) AutoRest Code Generator. +# Changes may cause incorrect behavior and will be lost if the code is +# regenerated. +# -------------------------------------------------------------------------- + +from .events_result_data import EventsResultData + + +class EventsBrowserTimingResult(EventsResultData): + """A browser timing result. + + All required parameters must be populated in order to send to Azure. + + :param id: The unique ID for this event. + :type id: str + :param count: Count of the event + :type count: long + :param timestamp: Timestamp of the event + :type timestamp: datetime + :param custom_dimensions: Custom dimensions of the event + :type custom_dimensions: + ~azure.applicationinsights.query.models.EventsResultDataCustomDimensions + :param custom_measurements: Custom measurements of the event + :type custom_measurements: + ~azure.applicationinsights.query.models.EventsResultDataCustomMeasurements + :param operation: Operation info of the event + :type operation: + ~azure.applicationinsights.query.models.EventsOperationInfo + :param session: Session info of the event + :type session: ~azure.applicationinsights.query.models.EventsSessionInfo + :param user: User info of the event + :type user: ~azure.applicationinsights.query.models.EventsUserInfo + :param cloud: Cloud info of the event + :type cloud: ~azure.applicationinsights.query.models.EventsCloudInfo + :param ai: AI info of the event + :type ai: ~azure.applicationinsights.query.models.EventsAiInfo + :param application: Application info of the event + :type application: + ~azure.applicationinsights.query.models.EventsApplicationInfo + :param client: Client info of the event + :type client: ~azure.applicationinsights.query.models.EventsClientInfo + :param type: Required. Constant filled by server. + :type type: str + :param browser_timing: + :type browser_timing: + ~azure.applicationinsights.query.models.EventsBrowserTimingInfo + :param client_performance: + :type client_performance: + ~azure.applicationinsights.query.models.EventsClientPerformanceInfo + """ + + _validation = { + 'type': {'required': True}, + } + + _attribute_map = { + 'id': {'key': 'id', 'type': 'str'}, + 'count': {'key': 'count', 'type': 'long'}, + 'timestamp': {'key': 'timestamp', 'type': 'iso-8601'}, + 'custom_dimensions': {'key': 'customDimensions', 'type': 'EventsResultDataCustomDimensions'}, + 'custom_measurements': {'key': 'customMeasurements', 'type': 'EventsResultDataCustomMeasurements'}, + 'operation': {'key': 'operation', 'type': 'EventsOperationInfo'}, + 'session': {'key': 'session', 'type': 'EventsSessionInfo'}, + 'user': {'key': 'user', 'type': 'EventsUserInfo'}, + 'cloud': {'key': 'cloud', 'type': 'EventsCloudInfo'}, + 'ai': {'key': 'ai', 'type': 'EventsAiInfo'}, + 'application': {'key': 'application', 'type': 'EventsApplicationInfo'}, + 'client': {'key': 'client', 'type': 'EventsClientInfo'}, + 'type': {'key': 'type', 'type': 'str'}, + 'browser_timing': {'key': 'browserTiming', 'type': 'EventsBrowserTimingInfo'}, + 'client_performance': {'key': 'clientPerformance', 'type': 'EventsClientPerformanceInfo'}, + } + + def __init__(self, **kwargs): + super(EventsBrowserTimingResult, self).__init__(**kwargs) + self.browser_timing = kwargs.get('browser_timing', None) + self.client_performance = kwargs.get('client_performance', None) + self.type = 'browserTiming' diff --git a/azure-applicationinsights-query/azure/applicationinsights/query/models/events_browser_timing_result_py3.py b/azure-applicationinsights-query/azure/applicationinsights/query/models/events_browser_timing_result_py3.py new file mode 100644 index 000000000000..9779c8903b85 --- /dev/null +++ b/azure-applicationinsights-query/azure/applicationinsights/query/models/events_browser_timing_result_py3.py @@ -0,0 +1,84 @@ +# coding=utf-8 +# -------------------------------------------------------------------------- +# Copyright (c) Microsoft Corporation. All rights reserved. +# Licensed under the MIT License. See License.txt in the project root for +# license information. +# +# Code generated by Microsoft (R) AutoRest Code Generator. +# Changes may cause incorrect behavior and will be lost if the code is +# regenerated. +# -------------------------------------------------------------------------- + +from .events_result_data_py3 import EventsResultData + + +class EventsBrowserTimingResult(EventsResultData): + """A browser timing result. + + All required parameters must be populated in order to send to Azure. + + :param id: The unique ID for this event. + :type id: str + :param count: Count of the event + :type count: long + :param timestamp: Timestamp of the event + :type timestamp: datetime + :param custom_dimensions: Custom dimensions of the event + :type custom_dimensions: + ~azure.applicationinsights.query.models.EventsResultDataCustomDimensions + :param custom_measurements: Custom measurements of the event + :type custom_measurements: + ~azure.applicationinsights.query.models.EventsResultDataCustomMeasurements + :param operation: Operation info of the event + :type operation: + ~azure.applicationinsights.query.models.EventsOperationInfo + :param session: Session info of the event + :type session: ~azure.applicationinsights.query.models.EventsSessionInfo + :param user: User info of the event + :type user: ~azure.applicationinsights.query.models.EventsUserInfo + :param cloud: Cloud info of the event + :type cloud: ~azure.applicationinsights.query.models.EventsCloudInfo + :param ai: AI info of the event + :type ai: ~azure.applicationinsights.query.models.EventsAiInfo + :param application: Application info of the event + :type application: + ~azure.applicationinsights.query.models.EventsApplicationInfo + :param client: Client info of the event + :type client: ~azure.applicationinsights.query.models.EventsClientInfo + :param type: Required. Constant filled by server. + :type type: str + :param browser_timing: + :type browser_timing: + ~azure.applicationinsights.query.models.EventsBrowserTimingInfo + :param client_performance: + :type client_performance: + ~azure.applicationinsights.query.models.EventsClientPerformanceInfo + """ + + _validation = { + 'type': {'required': True}, + } + + _attribute_map = { + 'id': {'key': 'id', 'type': 'str'}, + 'count': {'key': 'count', 'type': 'long'}, + 'timestamp': {'key': 'timestamp', 'type': 'iso-8601'}, + 'custom_dimensions': {'key': 'customDimensions', 'type': 'EventsResultDataCustomDimensions'}, + 'custom_measurements': {'key': 'customMeasurements', 'type': 'EventsResultDataCustomMeasurements'}, + 'operation': {'key': 'operation', 'type': 'EventsOperationInfo'}, + 'session': {'key': 'session', 'type': 'EventsSessionInfo'}, + 'user': {'key': 'user', 'type': 'EventsUserInfo'}, + 'cloud': {'key': 'cloud', 'type': 'EventsCloudInfo'}, + 'ai': {'key': 'ai', 'type': 'EventsAiInfo'}, + 'application': {'key': 'application', 'type': 'EventsApplicationInfo'}, + 'client': {'key': 'client', 'type': 'EventsClientInfo'}, + 'type': {'key': 'type', 'type': 'str'}, + 'browser_timing': {'key': 'browserTiming', 'type': 'EventsBrowserTimingInfo'}, + 'client_performance': {'key': 'clientPerformance', 'type': 'EventsClientPerformanceInfo'}, + } + + def __init__(self, *, id: str=None, count: int=None, timestamp=None, custom_dimensions=None, custom_measurements=None, operation=None, session=None, user=None, cloud=None, ai=None, application=None, client=None, browser_timing=None, client_performance=None, **kwargs) -> None: + super(EventsBrowserTimingResult, self).__init__(id=id, count=count, timestamp=timestamp, custom_dimensions=custom_dimensions, custom_measurements=custom_measurements, operation=operation, session=session, user=user, cloud=cloud, ai=ai, application=application, client=client, **kwargs) + self.browser_timing = browser_timing + self.client_performance = client_performance + self.type = 'browserTiming' diff --git a/azure-applicationinsights-query/azure/applicationinsights/query/models/events_client_info.py b/azure-applicationinsights-query/azure/applicationinsights/query/models/events_client_info.py new file mode 100644 index 000000000000..7827e8167d1f --- /dev/null +++ b/azure-applicationinsights-query/azure/applicationinsights/query/models/events_client_info.py @@ -0,0 +1,56 @@ +# coding=utf-8 +# -------------------------------------------------------------------------- +# Copyright (c) Microsoft Corporation. All rights reserved. +# Licensed under the MIT License. See License.txt in the project root for +# license information. +# +# Code generated by Microsoft (R) AutoRest Code Generator. +# Changes may cause incorrect behavior and will be lost if the code is +# regenerated. +# -------------------------------------------------------------------------- + +from msrest.serialization import Model + + +class EventsClientInfo(Model): + """Client info for an event result. + + :param model: Model of the client + :type model: str + :param os: Operating system of the client + :type os: str + :param type: Type of the client + :type type: str + :param browser: Browser of the client + :type browser: str + :param ip: IP address of the client + :type ip: str + :param city: City of the client + :type city: str + :param state_or_province: State or province of the client + :type state_or_province: str + :param country_or_region: Country or region of the client + :type country_or_region: str + """ + + _attribute_map = { + 'model': {'key': 'model', 'type': 'str'}, + 'os': {'key': 'os', 'type': 'str'}, + 'type': {'key': 'type', 'type': 'str'}, + 'browser': {'key': 'browser', 'type': 'str'}, + 'ip': {'key': 'ip', 'type': 'str'}, + 'city': {'key': 'city', 'type': 'str'}, + 'state_or_province': {'key': 'stateOrProvince', 'type': 'str'}, + 'country_or_region': {'key': 'countryOrRegion', 'type': 'str'}, + } + + def __init__(self, **kwargs): + super(EventsClientInfo, self).__init__(**kwargs) + self.model = kwargs.get('model', None) + self.os = kwargs.get('os', None) + self.type = kwargs.get('type', None) + self.browser = kwargs.get('browser', None) + self.ip = kwargs.get('ip', None) + self.city = kwargs.get('city', None) + self.state_or_province = kwargs.get('state_or_province', None) + self.country_or_region = kwargs.get('country_or_region', None) diff --git a/azure-applicationinsights-query/azure/applicationinsights/query/models/events_client_info_py3.py b/azure-applicationinsights-query/azure/applicationinsights/query/models/events_client_info_py3.py new file mode 100644 index 000000000000..92bf9e596889 --- /dev/null +++ b/azure-applicationinsights-query/azure/applicationinsights/query/models/events_client_info_py3.py @@ -0,0 +1,56 @@ +# coding=utf-8 +# -------------------------------------------------------------------------- +# Copyright (c) Microsoft Corporation. All rights reserved. +# Licensed under the MIT License. See License.txt in the project root for +# license information. +# +# Code generated by Microsoft (R) AutoRest Code Generator. +# Changes may cause incorrect behavior and will be lost if the code is +# regenerated. +# -------------------------------------------------------------------------- + +from msrest.serialization import Model + + +class EventsClientInfo(Model): + """Client info for an event result. + + :param model: Model of the client + :type model: str + :param os: Operating system of the client + :type os: str + :param type: Type of the client + :type type: str + :param browser: Browser of the client + :type browser: str + :param ip: IP address of the client + :type ip: str + :param city: City of the client + :type city: str + :param state_or_province: State or province of the client + :type state_or_province: str + :param country_or_region: Country or region of the client + :type country_or_region: str + """ + + _attribute_map = { + 'model': {'key': 'model', 'type': 'str'}, + 'os': {'key': 'os', 'type': 'str'}, + 'type': {'key': 'type', 'type': 'str'}, + 'browser': {'key': 'browser', 'type': 'str'}, + 'ip': {'key': 'ip', 'type': 'str'}, + 'city': {'key': 'city', 'type': 'str'}, + 'state_or_province': {'key': 'stateOrProvince', 'type': 'str'}, + 'country_or_region': {'key': 'countryOrRegion', 'type': 'str'}, + } + + def __init__(self, *, model: str=None, os: str=None, type: str=None, browser: str=None, ip: str=None, city: str=None, state_or_province: str=None, country_or_region: str=None, **kwargs) -> None: + super(EventsClientInfo, self).__init__(**kwargs) + self.model = model + self.os = os + self.type = type + self.browser = browser + self.ip = ip + self.city = city + self.state_or_province = state_or_province + self.country_or_region = country_or_region diff --git a/azure-applicationinsights-query/azure/applicationinsights/query/models/events_client_performance_info.py b/azure-applicationinsights-query/azure/applicationinsights/query/models/events_client_performance_info.py new file mode 100644 index 000000000000..84186213f139 --- /dev/null +++ b/azure-applicationinsights-query/azure/applicationinsights/query/models/events_client_performance_info.py @@ -0,0 +1,28 @@ +# coding=utf-8 +# -------------------------------------------------------------------------- +# Copyright (c) Microsoft Corporation. All rights reserved. +# Licensed under the MIT License. See License.txt in the project root for +# license information. +# +# Code generated by Microsoft (R) AutoRest Code Generator. +# Changes may cause incorrect behavior and will be lost if the code is +# regenerated. +# -------------------------------------------------------------------------- + +from msrest.serialization import Model + + +class EventsClientPerformanceInfo(Model): + """Client performance information. + + :param name: The name of the client performance + :type name: str + """ + + _attribute_map = { + 'name': {'key': 'name', 'type': 'str'}, + } + + def __init__(self, **kwargs): + super(EventsClientPerformanceInfo, self).__init__(**kwargs) + self.name = kwargs.get('name', None) diff --git a/azure-applicationinsights-query/azure/applicationinsights/query/models/events_client_performance_info_py3.py b/azure-applicationinsights-query/azure/applicationinsights/query/models/events_client_performance_info_py3.py new file mode 100644 index 000000000000..e0c47362385a --- /dev/null +++ b/azure-applicationinsights-query/azure/applicationinsights/query/models/events_client_performance_info_py3.py @@ -0,0 +1,28 @@ +# coding=utf-8 +# -------------------------------------------------------------------------- +# Copyright (c) Microsoft Corporation. All rights reserved. +# Licensed under the MIT License. See License.txt in the project root for +# license information. +# +# Code generated by Microsoft (R) AutoRest Code Generator. +# Changes may cause incorrect behavior and will be lost if the code is +# regenerated. +# -------------------------------------------------------------------------- + +from msrest.serialization import Model + + +class EventsClientPerformanceInfo(Model): + """Client performance information. + + :param name: The name of the client performance + :type name: str + """ + + _attribute_map = { + 'name': {'key': 'name', 'type': 'str'}, + } + + def __init__(self, *, name: str=None, **kwargs) -> None: + super(EventsClientPerformanceInfo, self).__init__(**kwargs) + self.name = name diff --git a/azure-applicationinsights-query/azure/applicationinsights/query/models/events_cloud_info.py b/azure-applicationinsights-query/azure/applicationinsights/query/models/events_cloud_info.py new file mode 100644 index 000000000000..547985375c52 --- /dev/null +++ b/azure-applicationinsights-query/azure/applicationinsights/query/models/events_cloud_info.py @@ -0,0 +1,32 @@ +# coding=utf-8 +# -------------------------------------------------------------------------- +# Copyright (c) Microsoft Corporation. All rights reserved. +# Licensed under the MIT License. See License.txt in the project root for +# license information. +# +# Code generated by Microsoft (R) AutoRest Code Generator. +# Changes may cause incorrect behavior and will be lost if the code is +# regenerated. +# -------------------------------------------------------------------------- + +from msrest.serialization import Model + + +class EventsCloudInfo(Model): + """Cloud info for an event result. + + :param role_name: Role name of the cloud + :type role_name: str + :param role_instance: Role instance of the cloud + :type role_instance: str + """ + + _attribute_map = { + 'role_name': {'key': 'roleName', 'type': 'str'}, + 'role_instance': {'key': 'roleInstance', 'type': 'str'}, + } + + def __init__(self, **kwargs): + super(EventsCloudInfo, self).__init__(**kwargs) + self.role_name = kwargs.get('role_name', None) + self.role_instance = kwargs.get('role_instance', None) diff --git a/azure-applicationinsights-query/azure/applicationinsights/query/models/events_cloud_info_py3.py b/azure-applicationinsights-query/azure/applicationinsights/query/models/events_cloud_info_py3.py new file mode 100644 index 000000000000..1024176027b2 --- /dev/null +++ b/azure-applicationinsights-query/azure/applicationinsights/query/models/events_cloud_info_py3.py @@ -0,0 +1,32 @@ +# coding=utf-8 +# -------------------------------------------------------------------------- +# Copyright (c) Microsoft Corporation. All rights reserved. +# Licensed under the MIT License. See License.txt in the project root for +# license information. +# +# Code generated by Microsoft (R) AutoRest Code Generator. +# Changes may cause incorrect behavior and will be lost if the code is +# regenerated. +# -------------------------------------------------------------------------- + +from msrest.serialization import Model + + +class EventsCloudInfo(Model): + """Cloud info for an event result. + + :param role_name: Role name of the cloud + :type role_name: str + :param role_instance: Role instance of the cloud + :type role_instance: str + """ + + _attribute_map = { + 'role_name': {'key': 'roleName', 'type': 'str'}, + 'role_instance': {'key': 'roleInstance', 'type': 'str'}, + } + + def __init__(self, *, role_name: str=None, role_instance: str=None, **kwargs) -> None: + super(EventsCloudInfo, self).__init__(**kwargs) + self.role_name = role_name + self.role_instance = role_instance diff --git a/azure-applicationinsights-query/azure/applicationinsights/query/models/events_custom_event_info.py b/azure-applicationinsights-query/azure/applicationinsights/query/models/events_custom_event_info.py new file mode 100644 index 000000000000..1b0afe7f2232 --- /dev/null +++ b/azure-applicationinsights-query/azure/applicationinsights/query/models/events_custom_event_info.py @@ -0,0 +1,28 @@ +# coding=utf-8 +# -------------------------------------------------------------------------- +# Copyright (c) Microsoft Corporation. All rights reserved. +# Licensed under the MIT License. See License.txt in the project root for +# license information. +# +# Code generated by Microsoft (R) AutoRest Code Generator. +# Changes may cause incorrect behavior and will be lost if the code is +# regenerated. +# -------------------------------------------------------------------------- + +from msrest.serialization import Model + + +class EventsCustomEventInfo(Model): + """The custom event information. + + :param name: The name of the custom event + :type name: str + """ + + _attribute_map = { + 'name': {'key': 'name', 'type': 'str'}, + } + + def __init__(self, **kwargs): + super(EventsCustomEventInfo, self).__init__(**kwargs) + self.name = kwargs.get('name', None) diff --git a/azure-applicationinsights-query/azure/applicationinsights/query/models/events_custom_event_info_py3.py b/azure-applicationinsights-query/azure/applicationinsights/query/models/events_custom_event_info_py3.py new file mode 100644 index 000000000000..68ae8f3a7903 --- /dev/null +++ b/azure-applicationinsights-query/azure/applicationinsights/query/models/events_custom_event_info_py3.py @@ -0,0 +1,28 @@ +# coding=utf-8 +# -------------------------------------------------------------------------- +# Copyright (c) Microsoft Corporation. All rights reserved. +# Licensed under the MIT License. See License.txt in the project root for +# license information. +# +# Code generated by Microsoft (R) AutoRest Code Generator. +# Changes may cause incorrect behavior and will be lost if the code is +# regenerated. +# -------------------------------------------------------------------------- + +from msrest.serialization import Model + + +class EventsCustomEventInfo(Model): + """The custom event information. + + :param name: The name of the custom event + :type name: str + """ + + _attribute_map = { + 'name': {'key': 'name', 'type': 'str'}, + } + + def __init__(self, *, name: str=None, **kwargs) -> None: + super(EventsCustomEventInfo, self).__init__(**kwargs) + self.name = name diff --git a/azure-applicationinsights-query/azure/applicationinsights/query/models/events_custom_event_result.py b/azure-applicationinsights-query/azure/applicationinsights/query/models/events_custom_event_result.py new file mode 100644 index 000000000000..f8e3739c4ead --- /dev/null +++ b/azure-applicationinsights-query/azure/applicationinsights/query/models/events_custom_event_result.py @@ -0,0 +1,79 @@ +# coding=utf-8 +# -------------------------------------------------------------------------- +# Copyright (c) Microsoft Corporation. All rights reserved. +# Licensed under the MIT License. See License.txt in the project root for +# license information. +# +# Code generated by Microsoft (R) AutoRest Code Generator. +# Changes may cause incorrect behavior and will be lost if the code is +# regenerated. +# -------------------------------------------------------------------------- + +from .events_result_data import EventsResultData + + +class EventsCustomEventResult(EventsResultData): + """A custom event result. + + All required parameters must be populated in order to send to Azure. + + :param id: The unique ID for this event. + :type id: str + :param count: Count of the event + :type count: long + :param timestamp: Timestamp of the event + :type timestamp: datetime + :param custom_dimensions: Custom dimensions of the event + :type custom_dimensions: + ~azure.applicationinsights.query.models.EventsResultDataCustomDimensions + :param custom_measurements: Custom measurements of the event + :type custom_measurements: + ~azure.applicationinsights.query.models.EventsResultDataCustomMeasurements + :param operation: Operation info of the event + :type operation: + ~azure.applicationinsights.query.models.EventsOperationInfo + :param session: Session info of the event + :type session: ~azure.applicationinsights.query.models.EventsSessionInfo + :param user: User info of the event + :type user: ~azure.applicationinsights.query.models.EventsUserInfo + :param cloud: Cloud info of the event + :type cloud: ~azure.applicationinsights.query.models.EventsCloudInfo + :param ai: AI info of the event + :type ai: ~azure.applicationinsights.query.models.EventsAiInfo + :param application: Application info of the event + :type application: + ~azure.applicationinsights.query.models.EventsApplicationInfo + :param client: Client info of the event + :type client: ~azure.applicationinsights.query.models.EventsClientInfo + :param type: Required. Constant filled by server. + :type type: str + :param custom_event: + :type custom_event: + ~azure.applicationinsights.query.models.EventsCustomEventInfo + """ + + _validation = { + 'type': {'required': True}, + } + + _attribute_map = { + 'id': {'key': 'id', 'type': 'str'}, + 'count': {'key': 'count', 'type': 'long'}, + 'timestamp': {'key': 'timestamp', 'type': 'iso-8601'}, + 'custom_dimensions': {'key': 'customDimensions', 'type': 'EventsResultDataCustomDimensions'}, + 'custom_measurements': {'key': 'customMeasurements', 'type': 'EventsResultDataCustomMeasurements'}, + 'operation': {'key': 'operation', 'type': 'EventsOperationInfo'}, + 'session': {'key': 'session', 'type': 'EventsSessionInfo'}, + 'user': {'key': 'user', 'type': 'EventsUserInfo'}, + 'cloud': {'key': 'cloud', 'type': 'EventsCloudInfo'}, + 'ai': {'key': 'ai', 'type': 'EventsAiInfo'}, + 'application': {'key': 'application', 'type': 'EventsApplicationInfo'}, + 'client': {'key': 'client', 'type': 'EventsClientInfo'}, + 'type': {'key': 'type', 'type': 'str'}, + 'custom_event': {'key': 'customEvent', 'type': 'EventsCustomEventInfo'}, + } + + def __init__(self, **kwargs): + super(EventsCustomEventResult, self).__init__(**kwargs) + self.custom_event = kwargs.get('custom_event', None) + self.type = 'customEvent' diff --git a/azure-applicationinsights-query/azure/applicationinsights/query/models/events_custom_event_result_py3.py b/azure-applicationinsights-query/azure/applicationinsights/query/models/events_custom_event_result_py3.py new file mode 100644 index 000000000000..56f817395111 --- /dev/null +++ b/azure-applicationinsights-query/azure/applicationinsights/query/models/events_custom_event_result_py3.py @@ -0,0 +1,79 @@ +# coding=utf-8 +# -------------------------------------------------------------------------- +# Copyright (c) Microsoft Corporation. All rights reserved. +# Licensed under the MIT License. See License.txt in the project root for +# license information. +# +# Code generated by Microsoft (R) AutoRest Code Generator. +# Changes may cause incorrect behavior and will be lost if the code is +# regenerated. +# -------------------------------------------------------------------------- + +from .events_result_data_py3 import EventsResultData + + +class EventsCustomEventResult(EventsResultData): + """A custom event result. + + All required parameters must be populated in order to send to Azure. + + :param id: The unique ID for this event. + :type id: str + :param count: Count of the event + :type count: long + :param timestamp: Timestamp of the event + :type timestamp: datetime + :param custom_dimensions: Custom dimensions of the event + :type custom_dimensions: + ~azure.applicationinsights.query.models.EventsResultDataCustomDimensions + :param custom_measurements: Custom measurements of the event + :type custom_measurements: + ~azure.applicationinsights.query.models.EventsResultDataCustomMeasurements + :param operation: Operation info of the event + :type operation: + ~azure.applicationinsights.query.models.EventsOperationInfo + :param session: Session info of the event + :type session: ~azure.applicationinsights.query.models.EventsSessionInfo + :param user: User info of the event + :type user: ~azure.applicationinsights.query.models.EventsUserInfo + :param cloud: Cloud info of the event + :type cloud: ~azure.applicationinsights.query.models.EventsCloudInfo + :param ai: AI info of the event + :type ai: ~azure.applicationinsights.query.models.EventsAiInfo + :param application: Application info of the event + :type application: + ~azure.applicationinsights.query.models.EventsApplicationInfo + :param client: Client info of the event + :type client: ~azure.applicationinsights.query.models.EventsClientInfo + :param type: Required. Constant filled by server. + :type type: str + :param custom_event: + :type custom_event: + ~azure.applicationinsights.query.models.EventsCustomEventInfo + """ + + _validation = { + 'type': {'required': True}, + } + + _attribute_map = { + 'id': {'key': 'id', 'type': 'str'}, + 'count': {'key': 'count', 'type': 'long'}, + 'timestamp': {'key': 'timestamp', 'type': 'iso-8601'}, + 'custom_dimensions': {'key': 'customDimensions', 'type': 'EventsResultDataCustomDimensions'}, + 'custom_measurements': {'key': 'customMeasurements', 'type': 'EventsResultDataCustomMeasurements'}, + 'operation': {'key': 'operation', 'type': 'EventsOperationInfo'}, + 'session': {'key': 'session', 'type': 'EventsSessionInfo'}, + 'user': {'key': 'user', 'type': 'EventsUserInfo'}, + 'cloud': {'key': 'cloud', 'type': 'EventsCloudInfo'}, + 'ai': {'key': 'ai', 'type': 'EventsAiInfo'}, + 'application': {'key': 'application', 'type': 'EventsApplicationInfo'}, + 'client': {'key': 'client', 'type': 'EventsClientInfo'}, + 'type': {'key': 'type', 'type': 'str'}, + 'custom_event': {'key': 'customEvent', 'type': 'EventsCustomEventInfo'}, + } + + def __init__(self, *, id: str=None, count: int=None, timestamp=None, custom_dimensions=None, custom_measurements=None, operation=None, session=None, user=None, cloud=None, ai=None, application=None, client=None, custom_event=None, **kwargs) -> None: + super(EventsCustomEventResult, self).__init__(id=id, count=count, timestamp=timestamp, custom_dimensions=custom_dimensions, custom_measurements=custom_measurements, operation=operation, session=session, user=user, cloud=cloud, ai=ai, application=application, client=client, **kwargs) + self.custom_event = custom_event + self.type = 'customEvent' diff --git a/azure-applicationinsights-query/azure/applicationinsights/query/models/events_custom_metric_info.py b/azure-applicationinsights-query/azure/applicationinsights/query/models/events_custom_metric_info.py new file mode 100644 index 000000000000..161b88aab45c --- /dev/null +++ b/azure-applicationinsights-query/azure/applicationinsights/query/models/events_custom_metric_info.py @@ -0,0 +1,52 @@ +# coding=utf-8 +# -------------------------------------------------------------------------- +# Copyright (c) Microsoft Corporation. All rights reserved. +# Licensed under the MIT License. See License.txt in the project root for +# license information. +# +# Code generated by Microsoft (R) AutoRest Code Generator. +# Changes may cause incorrect behavior and will be lost if the code is +# regenerated. +# -------------------------------------------------------------------------- + +from msrest.serialization import Model + + +class EventsCustomMetricInfo(Model): + """The custom metric info. + + :param name: The name of the custom metric + :type name: str + :param value: The value of the custom metric + :type value: float + :param value_sum: The sum of the custom metric + :type value_sum: float + :param value_count: The count of the custom metric + :type value_count: int + :param value_min: The minimum value of the custom metric + :type value_min: float + :param value_max: The maximum value of the custom metric + :type value_max: float + :param value_std_dev: The standard deviation of the custom metric + :type value_std_dev: float + """ + + _attribute_map = { + 'name': {'key': 'name', 'type': 'str'}, + 'value': {'key': 'value', 'type': 'float'}, + 'value_sum': {'key': 'valueSum', 'type': 'float'}, + 'value_count': {'key': 'valueCount', 'type': 'int'}, + 'value_min': {'key': 'valueMin', 'type': 'float'}, + 'value_max': {'key': 'valueMax', 'type': 'float'}, + 'value_std_dev': {'key': 'valueStdDev', 'type': 'float'}, + } + + def __init__(self, **kwargs): + super(EventsCustomMetricInfo, self).__init__(**kwargs) + self.name = kwargs.get('name', None) + self.value = kwargs.get('value', None) + self.value_sum = kwargs.get('value_sum', None) + self.value_count = kwargs.get('value_count', None) + self.value_min = kwargs.get('value_min', None) + self.value_max = kwargs.get('value_max', None) + self.value_std_dev = kwargs.get('value_std_dev', None) diff --git a/azure-applicationinsights-query/azure/applicationinsights/query/models/events_custom_metric_info_py3.py b/azure-applicationinsights-query/azure/applicationinsights/query/models/events_custom_metric_info_py3.py new file mode 100644 index 000000000000..e2d46ef2d2ef --- /dev/null +++ b/azure-applicationinsights-query/azure/applicationinsights/query/models/events_custom_metric_info_py3.py @@ -0,0 +1,52 @@ +# coding=utf-8 +# -------------------------------------------------------------------------- +# Copyright (c) Microsoft Corporation. All rights reserved. +# Licensed under the MIT License. See License.txt in the project root for +# license information. +# +# Code generated by Microsoft (R) AutoRest Code Generator. +# Changes may cause incorrect behavior and will be lost if the code is +# regenerated. +# -------------------------------------------------------------------------- + +from msrest.serialization import Model + + +class EventsCustomMetricInfo(Model): + """The custom metric info. + + :param name: The name of the custom metric + :type name: str + :param value: The value of the custom metric + :type value: float + :param value_sum: The sum of the custom metric + :type value_sum: float + :param value_count: The count of the custom metric + :type value_count: int + :param value_min: The minimum value of the custom metric + :type value_min: float + :param value_max: The maximum value of the custom metric + :type value_max: float + :param value_std_dev: The standard deviation of the custom metric + :type value_std_dev: float + """ + + _attribute_map = { + 'name': {'key': 'name', 'type': 'str'}, + 'value': {'key': 'value', 'type': 'float'}, + 'value_sum': {'key': 'valueSum', 'type': 'float'}, + 'value_count': {'key': 'valueCount', 'type': 'int'}, + 'value_min': {'key': 'valueMin', 'type': 'float'}, + 'value_max': {'key': 'valueMax', 'type': 'float'}, + 'value_std_dev': {'key': 'valueStdDev', 'type': 'float'}, + } + + def __init__(self, *, name: str=None, value: float=None, value_sum: float=None, value_count: int=None, value_min: float=None, value_max: float=None, value_std_dev: float=None, **kwargs) -> None: + super(EventsCustomMetricInfo, self).__init__(**kwargs) + self.name = name + self.value = value + self.value_sum = value_sum + self.value_count = value_count + self.value_min = value_min + self.value_max = value_max + self.value_std_dev = value_std_dev diff --git a/azure-applicationinsights-query/azure/applicationinsights/query/models/events_custom_metric_result.py b/azure-applicationinsights-query/azure/applicationinsights/query/models/events_custom_metric_result.py new file mode 100644 index 000000000000..d420605530a8 --- /dev/null +++ b/azure-applicationinsights-query/azure/applicationinsights/query/models/events_custom_metric_result.py @@ -0,0 +1,79 @@ +# coding=utf-8 +# -------------------------------------------------------------------------- +# Copyright (c) Microsoft Corporation. All rights reserved. +# Licensed under the MIT License. See License.txt in the project root for +# license information. +# +# Code generated by Microsoft (R) AutoRest Code Generator. +# Changes may cause incorrect behavior and will be lost if the code is +# regenerated. +# -------------------------------------------------------------------------- + +from .events_result_data import EventsResultData + + +class EventsCustomMetricResult(EventsResultData): + """A custom metric result. + + All required parameters must be populated in order to send to Azure. + + :param id: The unique ID for this event. + :type id: str + :param count: Count of the event + :type count: long + :param timestamp: Timestamp of the event + :type timestamp: datetime + :param custom_dimensions: Custom dimensions of the event + :type custom_dimensions: + ~azure.applicationinsights.query.models.EventsResultDataCustomDimensions + :param custom_measurements: Custom measurements of the event + :type custom_measurements: + ~azure.applicationinsights.query.models.EventsResultDataCustomMeasurements + :param operation: Operation info of the event + :type operation: + ~azure.applicationinsights.query.models.EventsOperationInfo + :param session: Session info of the event + :type session: ~azure.applicationinsights.query.models.EventsSessionInfo + :param user: User info of the event + :type user: ~azure.applicationinsights.query.models.EventsUserInfo + :param cloud: Cloud info of the event + :type cloud: ~azure.applicationinsights.query.models.EventsCloudInfo + :param ai: AI info of the event + :type ai: ~azure.applicationinsights.query.models.EventsAiInfo + :param application: Application info of the event + :type application: + ~azure.applicationinsights.query.models.EventsApplicationInfo + :param client: Client info of the event + :type client: ~azure.applicationinsights.query.models.EventsClientInfo + :param type: Required. Constant filled by server. + :type type: str + :param custom_metric: + :type custom_metric: + ~azure.applicationinsights.query.models.EventsCustomMetricInfo + """ + + _validation = { + 'type': {'required': True}, + } + + _attribute_map = { + 'id': {'key': 'id', 'type': 'str'}, + 'count': {'key': 'count', 'type': 'long'}, + 'timestamp': {'key': 'timestamp', 'type': 'iso-8601'}, + 'custom_dimensions': {'key': 'customDimensions', 'type': 'EventsResultDataCustomDimensions'}, + 'custom_measurements': {'key': 'customMeasurements', 'type': 'EventsResultDataCustomMeasurements'}, + 'operation': {'key': 'operation', 'type': 'EventsOperationInfo'}, + 'session': {'key': 'session', 'type': 'EventsSessionInfo'}, + 'user': {'key': 'user', 'type': 'EventsUserInfo'}, + 'cloud': {'key': 'cloud', 'type': 'EventsCloudInfo'}, + 'ai': {'key': 'ai', 'type': 'EventsAiInfo'}, + 'application': {'key': 'application', 'type': 'EventsApplicationInfo'}, + 'client': {'key': 'client', 'type': 'EventsClientInfo'}, + 'type': {'key': 'type', 'type': 'str'}, + 'custom_metric': {'key': 'customMetric', 'type': 'EventsCustomMetricInfo'}, + } + + def __init__(self, **kwargs): + super(EventsCustomMetricResult, self).__init__(**kwargs) + self.custom_metric = kwargs.get('custom_metric', None) + self.type = 'customMetric' diff --git a/azure-applicationinsights-query/azure/applicationinsights/query/models/events_custom_metric_result_py3.py b/azure-applicationinsights-query/azure/applicationinsights/query/models/events_custom_metric_result_py3.py new file mode 100644 index 000000000000..1ee698b7826d --- /dev/null +++ b/azure-applicationinsights-query/azure/applicationinsights/query/models/events_custom_metric_result_py3.py @@ -0,0 +1,79 @@ +# coding=utf-8 +# -------------------------------------------------------------------------- +# Copyright (c) Microsoft Corporation. All rights reserved. +# Licensed under the MIT License. See License.txt in the project root for +# license information. +# +# Code generated by Microsoft (R) AutoRest Code Generator. +# Changes may cause incorrect behavior and will be lost if the code is +# regenerated. +# -------------------------------------------------------------------------- + +from .events_result_data_py3 import EventsResultData + + +class EventsCustomMetricResult(EventsResultData): + """A custom metric result. + + All required parameters must be populated in order to send to Azure. + + :param id: The unique ID for this event. + :type id: str + :param count: Count of the event + :type count: long + :param timestamp: Timestamp of the event + :type timestamp: datetime + :param custom_dimensions: Custom dimensions of the event + :type custom_dimensions: + ~azure.applicationinsights.query.models.EventsResultDataCustomDimensions + :param custom_measurements: Custom measurements of the event + :type custom_measurements: + ~azure.applicationinsights.query.models.EventsResultDataCustomMeasurements + :param operation: Operation info of the event + :type operation: + ~azure.applicationinsights.query.models.EventsOperationInfo + :param session: Session info of the event + :type session: ~azure.applicationinsights.query.models.EventsSessionInfo + :param user: User info of the event + :type user: ~azure.applicationinsights.query.models.EventsUserInfo + :param cloud: Cloud info of the event + :type cloud: ~azure.applicationinsights.query.models.EventsCloudInfo + :param ai: AI info of the event + :type ai: ~azure.applicationinsights.query.models.EventsAiInfo + :param application: Application info of the event + :type application: + ~azure.applicationinsights.query.models.EventsApplicationInfo + :param client: Client info of the event + :type client: ~azure.applicationinsights.query.models.EventsClientInfo + :param type: Required. Constant filled by server. + :type type: str + :param custom_metric: + :type custom_metric: + ~azure.applicationinsights.query.models.EventsCustomMetricInfo + """ + + _validation = { + 'type': {'required': True}, + } + + _attribute_map = { + 'id': {'key': 'id', 'type': 'str'}, + 'count': {'key': 'count', 'type': 'long'}, + 'timestamp': {'key': 'timestamp', 'type': 'iso-8601'}, + 'custom_dimensions': {'key': 'customDimensions', 'type': 'EventsResultDataCustomDimensions'}, + 'custom_measurements': {'key': 'customMeasurements', 'type': 'EventsResultDataCustomMeasurements'}, + 'operation': {'key': 'operation', 'type': 'EventsOperationInfo'}, + 'session': {'key': 'session', 'type': 'EventsSessionInfo'}, + 'user': {'key': 'user', 'type': 'EventsUserInfo'}, + 'cloud': {'key': 'cloud', 'type': 'EventsCloudInfo'}, + 'ai': {'key': 'ai', 'type': 'EventsAiInfo'}, + 'application': {'key': 'application', 'type': 'EventsApplicationInfo'}, + 'client': {'key': 'client', 'type': 'EventsClientInfo'}, + 'type': {'key': 'type', 'type': 'str'}, + 'custom_metric': {'key': 'customMetric', 'type': 'EventsCustomMetricInfo'}, + } + + def __init__(self, *, id: str=None, count: int=None, timestamp=None, custom_dimensions=None, custom_measurements=None, operation=None, session=None, user=None, cloud=None, ai=None, application=None, client=None, custom_metric=None, **kwargs) -> None: + super(EventsCustomMetricResult, self).__init__(id=id, count=count, timestamp=timestamp, custom_dimensions=custom_dimensions, custom_measurements=custom_measurements, operation=operation, session=session, user=user, cloud=cloud, ai=ai, application=application, client=client, **kwargs) + self.custom_metric = custom_metric + self.type = 'customMetric' diff --git a/azure-applicationinsights-query/azure/applicationinsights/query/models/events_dependency_info.py b/azure-applicationinsights-query/azure/applicationinsights/query/models/events_dependency_info.py new file mode 100644 index 000000000000..0e8ce3511e42 --- /dev/null +++ b/azure-applicationinsights-query/azure/applicationinsights/query/models/events_dependency_info.py @@ -0,0 +1,60 @@ +# coding=utf-8 +# -------------------------------------------------------------------------- +# Copyright (c) Microsoft Corporation. All rights reserved. +# Licensed under the MIT License. See License.txt in the project root for +# license information. +# +# Code generated by Microsoft (R) AutoRest Code Generator. +# Changes may cause incorrect behavior and will be lost if the code is +# regenerated. +# -------------------------------------------------------------------------- + +from msrest.serialization import Model + + +class EventsDependencyInfo(Model): + """The dependency info. + + :param target: The target of the dependency + :type target: str + :param data: The data of the dependency + :type data: str + :param success: Indicates if the dependency was successful + :type success: str + :param duration: The duration of the dependency + :type duration: long + :param performance_bucket: The performance bucket of the dependency + :type performance_bucket: str + :param result_code: The result code of the dependency + :type result_code: str + :param type: The type of the dependency + :type type: str + :param name: The name of the dependency + :type name: str + :param id: The ID of the dependency + :type id: str + """ + + _attribute_map = { + 'target': {'key': 'target', 'type': 'str'}, + 'data': {'key': 'data', 'type': 'str'}, + 'success': {'key': 'success', 'type': 'str'}, + 'duration': {'key': 'duration', 'type': 'long'}, + 'performance_bucket': {'key': 'performanceBucket', 'type': 'str'}, + 'result_code': {'key': 'resultCode', 'type': 'str'}, + 'type': {'key': 'type', 'type': 'str'}, + 'name': {'key': 'name', 'type': 'str'}, + 'id': {'key': 'id', 'type': 'str'}, + } + + def __init__(self, **kwargs): + super(EventsDependencyInfo, self).__init__(**kwargs) + self.target = kwargs.get('target', None) + self.data = kwargs.get('data', None) + self.success = kwargs.get('success', None) + self.duration = kwargs.get('duration', None) + self.performance_bucket = kwargs.get('performance_bucket', None) + self.result_code = kwargs.get('result_code', None) + self.type = kwargs.get('type', None) + self.name = kwargs.get('name', None) + self.id = kwargs.get('id', None) diff --git a/azure-applicationinsights-query/azure/applicationinsights/query/models/events_dependency_info_py3.py b/azure-applicationinsights-query/azure/applicationinsights/query/models/events_dependency_info_py3.py new file mode 100644 index 000000000000..4472b9ba4464 --- /dev/null +++ b/azure-applicationinsights-query/azure/applicationinsights/query/models/events_dependency_info_py3.py @@ -0,0 +1,60 @@ +# coding=utf-8 +# -------------------------------------------------------------------------- +# Copyright (c) Microsoft Corporation. All rights reserved. +# Licensed under the MIT License. See License.txt in the project root for +# license information. +# +# Code generated by Microsoft (R) AutoRest Code Generator. +# Changes may cause incorrect behavior and will be lost if the code is +# regenerated. +# -------------------------------------------------------------------------- + +from msrest.serialization import Model + + +class EventsDependencyInfo(Model): + """The dependency info. + + :param target: The target of the dependency + :type target: str + :param data: The data of the dependency + :type data: str + :param success: Indicates if the dependency was successful + :type success: str + :param duration: The duration of the dependency + :type duration: long + :param performance_bucket: The performance bucket of the dependency + :type performance_bucket: str + :param result_code: The result code of the dependency + :type result_code: str + :param type: The type of the dependency + :type type: str + :param name: The name of the dependency + :type name: str + :param id: The ID of the dependency + :type id: str + """ + + _attribute_map = { + 'target': {'key': 'target', 'type': 'str'}, + 'data': {'key': 'data', 'type': 'str'}, + 'success': {'key': 'success', 'type': 'str'}, + 'duration': {'key': 'duration', 'type': 'long'}, + 'performance_bucket': {'key': 'performanceBucket', 'type': 'str'}, + 'result_code': {'key': 'resultCode', 'type': 'str'}, + 'type': {'key': 'type', 'type': 'str'}, + 'name': {'key': 'name', 'type': 'str'}, + 'id': {'key': 'id', 'type': 'str'}, + } + + def __init__(self, *, target: str=None, data: str=None, success: str=None, duration: int=None, performance_bucket: str=None, result_code: str=None, type: str=None, name: str=None, id: str=None, **kwargs) -> None: + super(EventsDependencyInfo, self).__init__(**kwargs) + self.target = target + self.data = data + self.success = success + self.duration = duration + self.performance_bucket = performance_bucket + self.result_code = result_code + self.type = type + self.name = name + self.id = id diff --git a/azure-applicationinsights-query/azure/applicationinsights/query/models/events_dependency_result.py b/azure-applicationinsights-query/azure/applicationinsights/query/models/events_dependency_result.py new file mode 100644 index 000000000000..f8fa5ff21abf --- /dev/null +++ b/azure-applicationinsights-query/azure/applicationinsights/query/models/events_dependency_result.py @@ -0,0 +1,79 @@ +# coding=utf-8 +# -------------------------------------------------------------------------- +# Copyright (c) Microsoft Corporation. All rights reserved. +# Licensed under the MIT License. See License.txt in the project root for +# license information. +# +# Code generated by Microsoft (R) AutoRest Code Generator. +# Changes may cause incorrect behavior and will be lost if the code is +# regenerated. +# -------------------------------------------------------------------------- + +from .events_result_data import EventsResultData + + +class EventsDependencyResult(EventsResultData): + """A dependency result. + + All required parameters must be populated in order to send to Azure. + + :param id: The unique ID for this event. + :type id: str + :param count: Count of the event + :type count: long + :param timestamp: Timestamp of the event + :type timestamp: datetime + :param custom_dimensions: Custom dimensions of the event + :type custom_dimensions: + ~azure.applicationinsights.query.models.EventsResultDataCustomDimensions + :param custom_measurements: Custom measurements of the event + :type custom_measurements: + ~azure.applicationinsights.query.models.EventsResultDataCustomMeasurements + :param operation: Operation info of the event + :type operation: + ~azure.applicationinsights.query.models.EventsOperationInfo + :param session: Session info of the event + :type session: ~azure.applicationinsights.query.models.EventsSessionInfo + :param user: User info of the event + :type user: ~azure.applicationinsights.query.models.EventsUserInfo + :param cloud: Cloud info of the event + :type cloud: ~azure.applicationinsights.query.models.EventsCloudInfo + :param ai: AI info of the event + :type ai: ~azure.applicationinsights.query.models.EventsAiInfo + :param application: Application info of the event + :type application: + ~azure.applicationinsights.query.models.EventsApplicationInfo + :param client: Client info of the event + :type client: ~azure.applicationinsights.query.models.EventsClientInfo + :param type: Required. Constant filled by server. + :type type: str + :param dependency: + :type dependency: + ~azure.applicationinsights.query.models.EventsDependencyInfo + """ + + _validation = { + 'type': {'required': True}, + } + + _attribute_map = { + 'id': {'key': 'id', 'type': 'str'}, + 'count': {'key': 'count', 'type': 'long'}, + 'timestamp': {'key': 'timestamp', 'type': 'iso-8601'}, + 'custom_dimensions': {'key': 'customDimensions', 'type': 'EventsResultDataCustomDimensions'}, + 'custom_measurements': {'key': 'customMeasurements', 'type': 'EventsResultDataCustomMeasurements'}, + 'operation': {'key': 'operation', 'type': 'EventsOperationInfo'}, + 'session': {'key': 'session', 'type': 'EventsSessionInfo'}, + 'user': {'key': 'user', 'type': 'EventsUserInfo'}, + 'cloud': {'key': 'cloud', 'type': 'EventsCloudInfo'}, + 'ai': {'key': 'ai', 'type': 'EventsAiInfo'}, + 'application': {'key': 'application', 'type': 'EventsApplicationInfo'}, + 'client': {'key': 'client', 'type': 'EventsClientInfo'}, + 'type': {'key': 'type', 'type': 'str'}, + 'dependency': {'key': 'dependency', 'type': 'EventsDependencyInfo'}, + } + + def __init__(self, **kwargs): + super(EventsDependencyResult, self).__init__(**kwargs) + self.dependency = kwargs.get('dependency', None) + self.type = 'dependency' diff --git a/azure-applicationinsights-query/azure/applicationinsights/query/models/events_dependency_result_py3.py b/azure-applicationinsights-query/azure/applicationinsights/query/models/events_dependency_result_py3.py new file mode 100644 index 000000000000..6e70948305d5 --- /dev/null +++ b/azure-applicationinsights-query/azure/applicationinsights/query/models/events_dependency_result_py3.py @@ -0,0 +1,79 @@ +# coding=utf-8 +# -------------------------------------------------------------------------- +# Copyright (c) Microsoft Corporation. All rights reserved. +# Licensed under the MIT License. See License.txt in the project root for +# license information. +# +# Code generated by Microsoft (R) AutoRest Code Generator. +# Changes may cause incorrect behavior and will be lost if the code is +# regenerated. +# -------------------------------------------------------------------------- + +from .events_result_data_py3 import EventsResultData + + +class EventsDependencyResult(EventsResultData): + """A dependency result. + + All required parameters must be populated in order to send to Azure. + + :param id: The unique ID for this event. + :type id: str + :param count: Count of the event + :type count: long + :param timestamp: Timestamp of the event + :type timestamp: datetime + :param custom_dimensions: Custom dimensions of the event + :type custom_dimensions: + ~azure.applicationinsights.query.models.EventsResultDataCustomDimensions + :param custom_measurements: Custom measurements of the event + :type custom_measurements: + ~azure.applicationinsights.query.models.EventsResultDataCustomMeasurements + :param operation: Operation info of the event + :type operation: + ~azure.applicationinsights.query.models.EventsOperationInfo + :param session: Session info of the event + :type session: ~azure.applicationinsights.query.models.EventsSessionInfo + :param user: User info of the event + :type user: ~azure.applicationinsights.query.models.EventsUserInfo + :param cloud: Cloud info of the event + :type cloud: ~azure.applicationinsights.query.models.EventsCloudInfo + :param ai: AI info of the event + :type ai: ~azure.applicationinsights.query.models.EventsAiInfo + :param application: Application info of the event + :type application: + ~azure.applicationinsights.query.models.EventsApplicationInfo + :param client: Client info of the event + :type client: ~azure.applicationinsights.query.models.EventsClientInfo + :param type: Required. Constant filled by server. + :type type: str + :param dependency: + :type dependency: + ~azure.applicationinsights.query.models.EventsDependencyInfo + """ + + _validation = { + 'type': {'required': True}, + } + + _attribute_map = { + 'id': {'key': 'id', 'type': 'str'}, + 'count': {'key': 'count', 'type': 'long'}, + 'timestamp': {'key': 'timestamp', 'type': 'iso-8601'}, + 'custom_dimensions': {'key': 'customDimensions', 'type': 'EventsResultDataCustomDimensions'}, + 'custom_measurements': {'key': 'customMeasurements', 'type': 'EventsResultDataCustomMeasurements'}, + 'operation': {'key': 'operation', 'type': 'EventsOperationInfo'}, + 'session': {'key': 'session', 'type': 'EventsSessionInfo'}, + 'user': {'key': 'user', 'type': 'EventsUserInfo'}, + 'cloud': {'key': 'cloud', 'type': 'EventsCloudInfo'}, + 'ai': {'key': 'ai', 'type': 'EventsAiInfo'}, + 'application': {'key': 'application', 'type': 'EventsApplicationInfo'}, + 'client': {'key': 'client', 'type': 'EventsClientInfo'}, + 'type': {'key': 'type', 'type': 'str'}, + 'dependency': {'key': 'dependency', 'type': 'EventsDependencyInfo'}, + } + + def __init__(self, *, id: str=None, count: int=None, timestamp=None, custom_dimensions=None, custom_measurements=None, operation=None, session=None, user=None, cloud=None, ai=None, application=None, client=None, dependency=None, **kwargs) -> None: + super(EventsDependencyResult, self).__init__(id=id, count=count, timestamp=timestamp, custom_dimensions=custom_dimensions, custom_measurements=custom_measurements, operation=operation, session=session, user=user, cloud=cloud, ai=ai, application=application, client=client, **kwargs) + self.dependency = dependency + self.type = 'dependency' diff --git a/azure-applicationinsights-query/azure/applicationinsights/query/models/events_exception_detail.py b/azure-applicationinsights-query/azure/applicationinsights/query/models/events_exception_detail.py new file mode 100644 index 000000000000..6a6547a733fd --- /dev/null +++ b/azure-applicationinsights-query/azure/applicationinsights/query/models/events_exception_detail.py @@ -0,0 +1,49 @@ +# coding=utf-8 +# -------------------------------------------------------------------------- +# Copyright (c) Microsoft Corporation. All rights reserved. +# Licensed under the MIT License. See License.txt in the project root for +# license information. +# +# Code generated by Microsoft (R) AutoRest Code Generator. +# Changes may cause incorrect behavior and will be lost if the code is +# regenerated. +# -------------------------------------------------------------------------- + +from msrest.serialization import Model + + +class EventsExceptionDetail(Model): + """Exception details. + + :param severity_level: The severity level of the exception detail + :type severity_level: str + :param outer_id: The outer ID of the exception detail + :type outer_id: str + :param message: The message of the exception detail + :type message: str + :param type: The type of the exception detail + :type type: str + :param id: The ID of the exception detail + :type id: str + :param parsed_stack: The parsed stack + :type parsed_stack: + list[~azure.applicationinsights.query.models.EventsExceptionDetailsParsedStack] + """ + + _attribute_map = { + 'severity_level': {'key': 'severityLevel', 'type': 'str'}, + 'outer_id': {'key': 'outerId', 'type': 'str'}, + 'message': {'key': 'message', 'type': 'str'}, + 'type': {'key': 'type', 'type': 'str'}, + 'id': {'key': 'id', 'type': 'str'}, + 'parsed_stack': {'key': 'parsedStack', 'type': '[EventsExceptionDetailsParsedStack]'}, + } + + def __init__(self, **kwargs): + super(EventsExceptionDetail, self).__init__(**kwargs) + self.severity_level = kwargs.get('severity_level', None) + self.outer_id = kwargs.get('outer_id', None) + self.message = kwargs.get('message', None) + self.type = kwargs.get('type', None) + self.id = kwargs.get('id', None) + self.parsed_stack = kwargs.get('parsed_stack', None) diff --git a/azure-applicationinsights-query/azure/applicationinsights/query/models/events_exception_detail_py3.py b/azure-applicationinsights-query/azure/applicationinsights/query/models/events_exception_detail_py3.py new file mode 100644 index 000000000000..0d1b2a90958e --- /dev/null +++ b/azure-applicationinsights-query/azure/applicationinsights/query/models/events_exception_detail_py3.py @@ -0,0 +1,49 @@ +# coding=utf-8 +# -------------------------------------------------------------------------- +# Copyright (c) Microsoft Corporation. All rights reserved. +# Licensed under the MIT License. See License.txt in the project root for +# license information. +# +# Code generated by Microsoft (R) AutoRest Code Generator. +# Changes may cause incorrect behavior and will be lost if the code is +# regenerated. +# -------------------------------------------------------------------------- + +from msrest.serialization import Model + + +class EventsExceptionDetail(Model): + """Exception details. + + :param severity_level: The severity level of the exception detail + :type severity_level: str + :param outer_id: The outer ID of the exception detail + :type outer_id: str + :param message: The message of the exception detail + :type message: str + :param type: The type of the exception detail + :type type: str + :param id: The ID of the exception detail + :type id: str + :param parsed_stack: The parsed stack + :type parsed_stack: + list[~azure.applicationinsights.query.models.EventsExceptionDetailsParsedStack] + """ + + _attribute_map = { + 'severity_level': {'key': 'severityLevel', 'type': 'str'}, + 'outer_id': {'key': 'outerId', 'type': 'str'}, + 'message': {'key': 'message', 'type': 'str'}, + 'type': {'key': 'type', 'type': 'str'}, + 'id': {'key': 'id', 'type': 'str'}, + 'parsed_stack': {'key': 'parsedStack', 'type': '[EventsExceptionDetailsParsedStack]'}, + } + + def __init__(self, *, severity_level: str=None, outer_id: str=None, message: str=None, type: str=None, id: str=None, parsed_stack=None, **kwargs) -> None: + super(EventsExceptionDetail, self).__init__(**kwargs) + self.severity_level = severity_level + self.outer_id = outer_id + self.message = message + self.type = type + self.id = id + self.parsed_stack = parsed_stack diff --git a/azure-applicationinsights-query/azure/applicationinsights/query/models/events_exception_details_parsed_stack.py b/azure-applicationinsights-query/azure/applicationinsights/query/models/events_exception_details_parsed_stack.py new file mode 100644 index 000000000000..927bde74816a --- /dev/null +++ b/azure-applicationinsights-query/azure/applicationinsights/query/models/events_exception_details_parsed_stack.py @@ -0,0 +1,40 @@ +# coding=utf-8 +# -------------------------------------------------------------------------- +# Copyright (c) Microsoft Corporation. All rights reserved. +# Licensed under the MIT License. See License.txt in the project root for +# license information. +# +# Code generated by Microsoft (R) AutoRest Code Generator. +# Changes may cause incorrect behavior and will be lost if the code is +# regenerated. +# -------------------------------------------------------------------------- + +from msrest.serialization import Model + + +class EventsExceptionDetailsParsedStack(Model): + """A parsed stack entry. + + :param assembly: The assembly of the stack entry + :type assembly: str + :param method: The method of the stack entry + :type method: str + :param level: The level of the stack entry + :type level: long + :param line: The line of the stack entry + :type line: long + """ + + _attribute_map = { + 'assembly': {'key': 'assembly', 'type': 'str'}, + 'method': {'key': 'method', 'type': 'str'}, + 'level': {'key': 'level', 'type': 'long'}, + 'line': {'key': 'line', 'type': 'long'}, + } + + def __init__(self, **kwargs): + super(EventsExceptionDetailsParsedStack, self).__init__(**kwargs) + self.assembly = kwargs.get('assembly', None) + self.method = kwargs.get('method', None) + self.level = kwargs.get('level', None) + self.line = kwargs.get('line', None) diff --git a/azure-applicationinsights-query/azure/applicationinsights/query/models/events_exception_details_parsed_stack_py3.py b/azure-applicationinsights-query/azure/applicationinsights/query/models/events_exception_details_parsed_stack_py3.py new file mode 100644 index 000000000000..d32ca08daed9 --- /dev/null +++ b/azure-applicationinsights-query/azure/applicationinsights/query/models/events_exception_details_parsed_stack_py3.py @@ -0,0 +1,40 @@ +# coding=utf-8 +# -------------------------------------------------------------------------- +# Copyright (c) Microsoft Corporation. All rights reserved. +# Licensed under the MIT License. See License.txt in the project root for +# license information. +# +# Code generated by Microsoft (R) AutoRest Code Generator. +# Changes may cause incorrect behavior and will be lost if the code is +# regenerated. +# -------------------------------------------------------------------------- + +from msrest.serialization import Model + + +class EventsExceptionDetailsParsedStack(Model): + """A parsed stack entry. + + :param assembly: The assembly of the stack entry + :type assembly: str + :param method: The method of the stack entry + :type method: str + :param level: The level of the stack entry + :type level: long + :param line: The line of the stack entry + :type line: long + """ + + _attribute_map = { + 'assembly': {'key': 'assembly', 'type': 'str'}, + 'method': {'key': 'method', 'type': 'str'}, + 'level': {'key': 'level', 'type': 'long'}, + 'line': {'key': 'line', 'type': 'long'}, + } + + def __init__(self, *, assembly: str=None, method: str=None, level: int=None, line: int=None, **kwargs) -> None: + super(EventsExceptionDetailsParsedStack, self).__init__(**kwargs) + self.assembly = assembly + self.method = method + self.level = level + self.line = line diff --git a/azure-applicationinsights-query/azure/applicationinsights/query/models/events_exception_info.py b/azure-applicationinsights-query/azure/applicationinsights/query/models/events_exception_info.py new file mode 100644 index 000000000000..f2bedc61ca6b --- /dev/null +++ b/azure-applicationinsights-query/azure/applicationinsights/query/models/events_exception_info.py @@ -0,0 +1,89 @@ +# coding=utf-8 +# -------------------------------------------------------------------------- +# Copyright (c) Microsoft Corporation. All rights reserved. +# Licensed under the MIT License. See License.txt in the project root for +# license information. +# +# Code generated by Microsoft (R) AutoRest Code Generator. +# Changes may cause incorrect behavior and will be lost if the code is +# regenerated. +# -------------------------------------------------------------------------- + +from msrest.serialization import Model + + +class EventsExceptionInfo(Model): + """The exception info. + + :param severity_level: The severity level of the exception + :type severity_level: int + :param problem_id: The problem ID of the exception + :type problem_id: str + :param handled_at: Indicates where the exception was handled at + :type handled_at: str + :param assembly: The assembly which threw the exception + :type assembly: str + :param method: The method that threw the exception + :type method: str + :param message: The message of the exception + :type message: str + :param type: The type of the exception + :type type: str + :param outer_type: The outer type of the exception + :type outer_type: str + :param outer_method: The outer method of the exception + :type outer_method: str + :param outer_assembly: The outer assembly of the exception + :type outer_assembly: str + :param outer_message: The outer message of the exception + :type outer_message: str + :param innermost_type: The inner most type of the exception + :type innermost_type: str + :param innermost_message: The inner most message of the exception + :type innermost_message: str + :param innermost_method: The inner most method of the exception + :type innermost_method: str + :param innermost_assembly: The inner most assembly of the exception + :type innermost_assembly: str + :param details: The details of the exception + :type details: + list[~azure.applicationinsights.query.models.EventsExceptionDetail] + """ + + _attribute_map = { + 'severity_level': {'key': 'severityLevel', 'type': 'int'}, + 'problem_id': {'key': 'problemId', 'type': 'str'}, + 'handled_at': {'key': 'handledAt', 'type': 'str'}, + 'assembly': {'key': 'assembly', 'type': 'str'}, + 'method': {'key': 'method', 'type': 'str'}, + 'message': {'key': 'message', 'type': 'str'}, + 'type': {'key': 'type', 'type': 'str'}, + 'outer_type': {'key': 'outerType', 'type': 'str'}, + 'outer_method': {'key': 'outerMethod', 'type': 'str'}, + 'outer_assembly': {'key': 'outerAssembly', 'type': 'str'}, + 'outer_message': {'key': 'outerMessage', 'type': 'str'}, + 'innermost_type': {'key': 'innermostType', 'type': 'str'}, + 'innermost_message': {'key': 'innermostMessage', 'type': 'str'}, + 'innermost_method': {'key': 'innermostMethod', 'type': 'str'}, + 'innermost_assembly': {'key': 'innermostAssembly', 'type': 'str'}, + 'details': {'key': 'details', 'type': '[EventsExceptionDetail]'}, + } + + def __init__(self, **kwargs): + super(EventsExceptionInfo, self).__init__(**kwargs) + self.severity_level = kwargs.get('severity_level', None) + self.problem_id = kwargs.get('problem_id', None) + self.handled_at = kwargs.get('handled_at', None) + self.assembly = kwargs.get('assembly', None) + self.method = kwargs.get('method', None) + self.message = kwargs.get('message', None) + self.type = kwargs.get('type', None) + self.outer_type = kwargs.get('outer_type', None) + self.outer_method = kwargs.get('outer_method', None) + self.outer_assembly = kwargs.get('outer_assembly', None) + self.outer_message = kwargs.get('outer_message', None) + self.innermost_type = kwargs.get('innermost_type', None) + self.innermost_message = kwargs.get('innermost_message', None) + self.innermost_method = kwargs.get('innermost_method', None) + self.innermost_assembly = kwargs.get('innermost_assembly', None) + self.details = kwargs.get('details', None) diff --git a/azure-applicationinsights-query/azure/applicationinsights/query/models/events_exception_info_py3.py b/azure-applicationinsights-query/azure/applicationinsights/query/models/events_exception_info_py3.py new file mode 100644 index 000000000000..0585cc9cf538 --- /dev/null +++ b/azure-applicationinsights-query/azure/applicationinsights/query/models/events_exception_info_py3.py @@ -0,0 +1,89 @@ +# coding=utf-8 +# -------------------------------------------------------------------------- +# Copyright (c) Microsoft Corporation. All rights reserved. +# Licensed under the MIT License. See License.txt in the project root for +# license information. +# +# Code generated by Microsoft (R) AutoRest Code Generator. +# Changes may cause incorrect behavior and will be lost if the code is +# regenerated. +# -------------------------------------------------------------------------- + +from msrest.serialization import Model + + +class EventsExceptionInfo(Model): + """The exception info. + + :param severity_level: The severity level of the exception + :type severity_level: int + :param problem_id: The problem ID of the exception + :type problem_id: str + :param handled_at: Indicates where the exception was handled at + :type handled_at: str + :param assembly: The assembly which threw the exception + :type assembly: str + :param method: The method that threw the exception + :type method: str + :param message: The message of the exception + :type message: str + :param type: The type of the exception + :type type: str + :param outer_type: The outer type of the exception + :type outer_type: str + :param outer_method: The outer method of the exception + :type outer_method: str + :param outer_assembly: The outer assembly of the exception + :type outer_assembly: str + :param outer_message: The outer message of the exception + :type outer_message: str + :param innermost_type: The inner most type of the exception + :type innermost_type: str + :param innermost_message: The inner most message of the exception + :type innermost_message: str + :param innermost_method: The inner most method of the exception + :type innermost_method: str + :param innermost_assembly: The inner most assembly of the exception + :type innermost_assembly: str + :param details: The details of the exception + :type details: + list[~azure.applicationinsights.query.models.EventsExceptionDetail] + """ + + _attribute_map = { + 'severity_level': {'key': 'severityLevel', 'type': 'int'}, + 'problem_id': {'key': 'problemId', 'type': 'str'}, + 'handled_at': {'key': 'handledAt', 'type': 'str'}, + 'assembly': {'key': 'assembly', 'type': 'str'}, + 'method': {'key': 'method', 'type': 'str'}, + 'message': {'key': 'message', 'type': 'str'}, + 'type': {'key': 'type', 'type': 'str'}, + 'outer_type': {'key': 'outerType', 'type': 'str'}, + 'outer_method': {'key': 'outerMethod', 'type': 'str'}, + 'outer_assembly': {'key': 'outerAssembly', 'type': 'str'}, + 'outer_message': {'key': 'outerMessage', 'type': 'str'}, + 'innermost_type': {'key': 'innermostType', 'type': 'str'}, + 'innermost_message': {'key': 'innermostMessage', 'type': 'str'}, + 'innermost_method': {'key': 'innermostMethod', 'type': 'str'}, + 'innermost_assembly': {'key': 'innermostAssembly', 'type': 'str'}, + 'details': {'key': 'details', 'type': '[EventsExceptionDetail]'}, + } + + def __init__(self, *, severity_level: int=None, problem_id: str=None, handled_at: str=None, assembly: str=None, method: str=None, message: str=None, type: str=None, outer_type: str=None, outer_method: str=None, outer_assembly: str=None, outer_message: str=None, innermost_type: str=None, innermost_message: str=None, innermost_method: str=None, innermost_assembly: str=None, details=None, **kwargs) -> None: + super(EventsExceptionInfo, self).__init__(**kwargs) + self.severity_level = severity_level + self.problem_id = problem_id + self.handled_at = handled_at + self.assembly = assembly + self.method = method + self.message = message + self.type = type + self.outer_type = outer_type + self.outer_method = outer_method + self.outer_assembly = outer_assembly + self.outer_message = outer_message + self.innermost_type = innermost_type + self.innermost_message = innermost_message + self.innermost_method = innermost_method + self.innermost_assembly = innermost_assembly + self.details = details diff --git a/azure-applicationinsights-query/azure/applicationinsights/query/models/events_exception_result.py b/azure-applicationinsights-query/azure/applicationinsights/query/models/events_exception_result.py new file mode 100644 index 000000000000..33c1ad89bf4a --- /dev/null +++ b/azure-applicationinsights-query/azure/applicationinsights/query/models/events_exception_result.py @@ -0,0 +1,79 @@ +# coding=utf-8 +# -------------------------------------------------------------------------- +# Copyright (c) Microsoft Corporation. All rights reserved. +# Licensed under the MIT License. See License.txt in the project root for +# license information. +# +# Code generated by Microsoft (R) AutoRest Code Generator. +# Changes may cause incorrect behavior and will be lost if the code is +# regenerated. +# -------------------------------------------------------------------------- + +from .events_result_data import EventsResultData + + +class EventsExceptionResult(EventsResultData): + """An exception result. + + All required parameters must be populated in order to send to Azure. + + :param id: The unique ID for this event. + :type id: str + :param count: Count of the event + :type count: long + :param timestamp: Timestamp of the event + :type timestamp: datetime + :param custom_dimensions: Custom dimensions of the event + :type custom_dimensions: + ~azure.applicationinsights.query.models.EventsResultDataCustomDimensions + :param custom_measurements: Custom measurements of the event + :type custom_measurements: + ~azure.applicationinsights.query.models.EventsResultDataCustomMeasurements + :param operation: Operation info of the event + :type operation: + ~azure.applicationinsights.query.models.EventsOperationInfo + :param session: Session info of the event + :type session: ~azure.applicationinsights.query.models.EventsSessionInfo + :param user: User info of the event + :type user: ~azure.applicationinsights.query.models.EventsUserInfo + :param cloud: Cloud info of the event + :type cloud: ~azure.applicationinsights.query.models.EventsCloudInfo + :param ai: AI info of the event + :type ai: ~azure.applicationinsights.query.models.EventsAiInfo + :param application: Application info of the event + :type application: + ~azure.applicationinsights.query.models.EventsApplicationInfo + :param client: Client info of the event + :type client: ~azure.applicationinsights.query.models.EventsClientInfo + :param type: Required. Constant filled by server. + :type type: str + :param exception: + :type exception: + ~azure.applicationinsights.query.models.EventsExceptionInfo + """ + + _validation = { + 'type': {'required': True}, + } + + _attribute_map = { + 'id': {'key': 'id', 'type': 'str'}, + 'count': {'key': 'count', 'type': 'long'}, + 'timestamp': {'key': 'timestamp', 'type': 'iso-8601'}, + 'custom_dimensions': {'key': 'customDimensions', 'type': 'EventsResultDataCustomDimensions'}, + 'custom_measurements': {'key': 'customMeasurements', 'type': 'EventsResultDataCustomMeasurements'}, + 'operation': {'key': 'operation', 'type': 'EventsOperationInfo'}, + 'session': {'key': 'session', 'type': 'EventsSessionInfo'}, + 'user': {'key': 'user', 'type': 'EventsUserInfo'}, + 'cloud': {'key': 'cloud', 'type': 'EventsCloudInfo'}, + 'ai': {'key': 'ai', 'type': 'EventsAiInfo'}, + 'application': {'key': 'application', 'type': 'EventsApplicationInfo'}, + 'client': {'key': 'client', 'type': 'EventsClientInfo'}, + 'type': {'key': 'type', 'type': 'str'}, + 'exception': {'key': 'exception', 'type': 'EventsExceptionInfo'}, + } + + def __init__(self, **kwargs): + super(EventsExceptionResult, self).__init__(**kwargs) + self.exception = kwargs.get('exception', None) + self.type = 'exception' diff --git a/azure-applicationinsights-query/azure/applicationinsights/query/models/events_exception_result_py3.py b/azure-applicationinsights-query/azure/applicationinsights/query/models/events_exception_result_py3.py new file mode 100644 index 000000000000..88ea880b0e72 --- /dev/null +++ b/azure-applicationinsights-query/azure/applicationinsights/query/models/events_exception_result_py3.py @@ -0,0 +1,79 @@ +# coding=utf-8 +# -------------------------------------------------------------------------- +# Copyright (c) Microsoft Corporation. All rights reserved. +# Licensed under the MIT License. See License.txt in the project root for +# license information. +# +# Code generated by Microsoft (R) AutoRest Code Generator. +# Changes may cause incorrect behavior and will be lost if the code is +# regenerated. +# -------------------------------------------------------------------------- + +from .events_result_data_py3 import EventsResultData + + +class EventsExceptionResult(EventsResultData): + """An exception result. + + All required parameters must be populated in order to send to Azure. + + :param id: The unique ID for this event. + :type id: str + :param count: Count of the event + :type count: long + :param timestamp: Timestamp of the event + :type timestamp: datetime + :param custom_dimensions: Custom dimensions of the event + :type custom_dimensions: + ~azure.applicationinsights.query.models.EventsResultDataCustomDimensions + :param custom_measurements: Custom measurements of the event + :type custom_measurements: + ~azure.applicationinsights.query.models.EventsResultDataCustomMeasurements + :param operation: Operation info of the event + :type operation: + ~azure.applicationinsights.query.models.EventsOperationInfo + :param session: Session info of the event + :type session: ~azure.applicationinsights.query.models.EventsSessionInfo + :param user: User info of the event + :type user: ~azure.applicationinsights.query.models.EventsUserInfo + :param cloud: Cloud info of the event + :type cloud: ~azure.applicationinsights.query.models.EventsCloudInfo + :param ai: AI info of the event + :type ai: ~azure.applicationinsights.query.models.EventsAiInfo + :param application: Application info of the event + :type application: + ~azure.applicationinsights.query.models.EventsApplicationInfo + :param client: Client info of the event + :type client: ~azure.applicationinsights.query.models.EventsClientInfo + :param type: Required. Constant filled by server. + :type type: str + :param exception: + :type exception: + ~azure.applicationinsights.query.models.EventsExceptionInfo + """ + + _validation = { + 'type': {'required': True}, + } + + _attribute_map = { + 'id': {'key': 'id', 'type': 'str'}, + 'count': {'key': 'count', 'type': 'long'}, + 'timestamp': {'key': 'timestamp', 'type': 'iso-8601'}, + 'custom_dimensions': {'key': 'customDimensions', 'type': 'EventsResultDataCustomDimensions'}, + 'custom_measurements': {'key': 'customMeasurements', 'type': 'EventsResultDataCustomMeasurements'}, + 'operation': {'key': 'operation', 'type': 'EventsOperationInfo'}, + 'session': {'key': 'session', 'type': 'EventsSessionInfo'}, + 'user': {'key': 'user', 'type': 'EventsUserInfo'}, + 'cloud': {'key': 'cloud', 'type': 'EventsCloudInfo'}, + 'ai': {'key': 'ai', 'type': 'EventsAiInfo'}, + 'application': {'key': 'application', 'type': 'EventsApplicationInfo'}, + 'client': {'key': 'client', 'type': 'EventsClientInfo'}, + 'type': {'key': 'type', 'type': 'str'}, + 'exception': {'key': 'exception', 'type': 'EventsExceptionInfo'}, + } + + def __init__(self, *, id: str=None, count: int=None, timestamp=None, custom_dimensions=None, custom_measurements=None, operation=None, session=None, user=None, cloud=None, ai=None, application=None, client=None, exception=None, **kwargs) -> None: + super(EventsExceptionResult, self).__init__(id=id, count=count, timestamp=timestamp, custom_dimensions=custom_dimensions, custom_measurements=custom_measurements, operation=operation, session=session, user=user, cloud=cloud, ai=ai, application=application, client=client, **kwargs) + self.exception = exception + self.type = 'exception' diff --git a/azure-applicationinsights-query/azure/applicationinsights/query/models/events_operation_info.py b/azure-applicationinsights-query/azure/applicationinsights/query/models/events_operation_info.py new file mode 100644 index 000000000000..db94a4528554 --- /dev/null +++ b/azure-applicationinsights-query/azure/applicationinsights/query/models/events_operation_info.py @@ -0,0 +1,40 @@ +# coding=utf-8 +# -------------------------------------------------------------------------- +# Copyright (c) Microsoft Corporation. All rights reserved. +# Licensed under the MIT License. See License.txt in the project root for +# license information. +# +# Code generated by Microsoft (R) AutoRest Code Generator. +# Changes may cause incorrect behavior and will be lost if the code is +# regenerated. +# -------------------------------------------------------------------------- + +from msrest.serialization import Model + + +class EventsOperationInfo(Model): + """Operation info for an event result. + + :param name: Name of the operation + :type name: str + :param id: ID of the operation + :type id: str + :param parent_id: Parent ID of the operation + :type parent_id: str + :param synthetic_source: Synthetic source of the operation + :type synthetic_source: str + """ + + _attribute_map = { + 'name': {'key': 'name', 'type': 'str'}, + 'id': {'key': 'id', 'type': 'str'}, + 'parent_id': {'key': 'parentId', 'type': 'str'}, + 'synthetic_source': {'key': 'syntheticSource', 'type': 'str'}, + } + + def __init__(self, **kwargs): + super(EventsOperationInfo, self).__init__(**kwargs) + self.name = kwargs.get('name', None) + self.id = kwargs.get('id', None) + self.parent_id = kwargs.get('parent_id', None) + self.synthetic_source = kwargs.get('synthetic_source', None) diff --git a/azure-applicationinsights-query/azure/applicationinsights/query/models/events_operation_info_py3.py b/azure-applicationinsights-query/azure/applicationinsights/query/models/events_operation_info_py3.py new file mode 100644 index 000000000000..388b441aeca2 --- /dev/null +++ b/azure-applicationinsights-query/azure/applicationinsights/query/models/events_operation_info_py3.py @@ -0,0 +1,40 @@ +# coding=utf-8 +# -------------------------------------------------------------------------- +# Copyright (c) Microsoft Corporation. All rights reserved. +# Licensed under the MIT License. See License.txt in the project root for +# license information. +# +# Code generated by Microsoft (R) AutoRest Code Generator. +# Changes may cause incorrect behavior and will be lost if the code is +# regenerated. +# -------------------------------------------------------------------------- + +from msrest.serialization import Model + + +class EventsOperationInfo(Model): + """Operation info for an event result. + + :param name: Name of the operation + :type name: str + :param id: ID of the operation + :type id: str + :param parent_id: Parent ID of the operation + :type parent_id: str + :param synthetic_source: Synthetic source of the operation + :type synthetic_source: str + """ + + _attribute_map = { + 'name': {'key': 'name', 'type': 'str'}, + 'id': {'key': 'id', 'type': 'str'}, + 'parent_id': {'key': 'parentId', 'type': 'str'}, + 'synthetic_source': {'key': 'syntheticSource', 'type': 'str'}, + } + + def __init__(self, *, name: str=None, id: str=None, parent_id: str=None, synthetic_source: str=None, **kwargs) -> None: + super(EventsOperationInfo, self).__init__(**kwargs) + self.name = name + self.id = id + self.parent_id = parent_id + self.synthetic_source = synthetic_source diff --git a/azure-applicationinsights-query/azure/applicationinsights/query/models/events_page_view_info.py b/azure-applicationinsights-query/azure/applicationinsights/query/models/events_page_view_info.py new file mode 100644 index 000000000000..e19d3fc9f2ed --- /dev/null +++ b/azure-applicationinsights-query/azure/applicationinsights/query/models/events_page_view_info.py @@ -0,0 +1,40 @@ +# coding=utf-8 +# -------------------------------------------------------------------------- +# Copyright (c) Microsoft Corporation. All rights reserved. +# Licensed under the MIT License. See License.txt in the project root for +# license information. +# +# Code generated by Microsoft (R) AutoRest Code Generator. +# Changes may cause incorrect behavior and will be lost if the code is +# regenerated. +# -------------------------------------------------------------------------- + +from msrest.serialization import Model + + +class EventsPageViewInfo(Model): + """The page view information. + + :param name: The name of the page + :type name: str + :param url: The URL of the page + :type url: str + :param duration: The duration of the page view + :type duration: str + :param performance_bucket: The performance bucket of the page view + :type performance_bucket: str + """ + + _attribute_map = { + 'name': {'key': 'name', 'type': 'str'}, + 'url': {'key': 'url', 'type': 'str'}, + 'duration': {'key': 'duration', 'type': 'str'}, + 'performance_bucket': {'key': 'performanceBucket', 'type': 'str'}, + } + + def __init__(self, **kwargs): + super(EventsPageViewInfo, self).__init__(**kwargs) + self.name = kwargs.get('name', None) + self.url = kwargs.get('url', None) + self.duration = kwargs.get('duration', None) + self.performance_bucket = kwargs.get('performance_bucket', None) diff --git a/azure-applicationinsights-query/azure/applicationinsights/query/models/events_page_view_info_py3.py b/azure-applicationinsights-query/azure/applicationinsights/query/models/events_page_view_info_py3.py new file mode 100644 index 000000000000..e651e8fe5b4c --- /dev/null +++ b/azure-applicationinsights-query/azure/applicationinsights/query/models/events_page_view_info_py3.py @@ -0,0 +1,40 @@ +# coding=utf-8 +# -------------------------------------------------------------------------- +# Copyright (c) Microsoft Corporation. All rights reserved. +# Licensed under the MIT License. See License.txt in the project root for +# license information. +# +# Code generated by Microsoft (R) AutoRest Code Generator. +# Changes may cause incorrect behavior and will be lost if the code is +# regenerated. +# -------------------------------------------------------------------------- + +from msrest.serialization import Model + + +class EventsPageViewInfo(Model): + """The page view information. + + :param name: The name of the page + :type name: str + :param url: The URL of the page + :type url: str + :param duration: The duration of the page view + :type duration: str + :param performance_bucket: The performance bucket of the page view + :type performance_bucket: str + """ + + _attribute_map = { + 'name': {'key': 'name', 'type': 'str'}, + 'url': {'key': 'url', 'type': 'str'}, + 'duration': {'key': 'duration', 'type': 'str'}, + 'performance_bucket': {'key': 'performanceBucket', 'type': 'str'}, + } + + def __init__(self, *, name: str=None, url: str=None, duration: str=None, performance_bucket: str=None, **kwargs) -> None: + super(EventsPageViewInfo, self).__init__(**kwargs) + self.name = name + self.url = url + self.duration = duration + self.performance_bucket = performance_bucket diff --git a/azure-applicationinsights-query/azure/applicationinsights/query/models/events_page_view_result.py b/azure-applicationinsights-query/azure/applicationinsights/query/models/events_page_view_result.py new file mode 100644 index 000000000000..c8f859844aad --- /dev/null +++ b/azure-applicationinsights-query/azure/applicationinsights/query/models/events_page_view_result.py @@ -0,0 +1,79 @@ +# coding=utf-8 +# -------------------------------------------------------------------------- +# Copyright (c) Microsoft Corporation. All rights reserved. +# Licensed under the MIT License. See License.txt in the project root for +# license information. +# +# Code generated by Microsoft (R) AutoRest Code Generator. +# Changes may cause incorrect behavior and will be lost if the code is +# regenerated. +# -------------------------------------------------------------------------- + +from .events_result_data import EventsResultData + + +class EventsPageViewResult(EventsResultData): + """A page view result. + + All required parameters must be populated in order to send to Azure. + + :param id: The unique ID for this event. + :type id: str + :param count: Count of the event + :type count: long + :param timestamp: Timestamp of the event + :type timestamp: datetime + :param custom_dimensions: Custom dimensions of the event + :type custom_dimensions: + ~azure.applicationinsights.query.models.EventsResultDataCustomDimensions + :param custom_measurements: Custom measurements of the event + :type custom_measurements: + ~azure.applicationinsights.query.models.EventsResultDataCustomMeasurements + :param operation: Operation info of the event + :type operation: + ~azure.applicationinsights.query.models.EventsOperationInfo + :param session: Session info of the event + :type session: ~azure.applicationinsights.query.models.EventsSessionInfo + :param user: User info of the event + :type user: ~azure.applicationinsights.query.models.EventsUserInfo + :param cloud: Cloud info of the event + :type cloud: ~azure.applicationinsights.query.models.EventsCloudInfo + :param ai: AI info of the event + :type ai: ~azure.applicationinsights.query.models.EventsAiInfo + :param application: Application info of the event + :type application: + ~azure.applicationinsights.query.models.EventsApplicationInfo + :param client: Client info of the event + :type client: ~azure.applicationinsights.query.models.EventsClientInfo + :param type: Required. Constant filled by server. + :type type: str + :param page_view: + :type page_view: + ~azure.applicationinsights.query.models.EventsPageViewInfo + """ + + _validation = { + 'type': {'required': True}, + } + + _attribute_map = { + 'id': {'key': 'id', 'type': 'str'}, + 'count': {'key': 'count', 'type': 'long'}, + 'timestamp': {'key': 'timestamp', 'type': 'iso-8601'}, + 'custom_dimensions': {'key': 'customDimensions', 'type': 'EventsResultDataCustomDimensions'}, + 'custom_measurements': {'key': 'customMeasurements', 'type': 'EventsResultDataCustomMeasurements'}, + 'operation': {'key': 'operation', 'type': 'EventsOperationInfo'}, + 'session': {'key': 'session', 'type': 'EventsSessionInfo'}, + 'user': {'key': 'user', 'type': 'EventsUserInfo'}, + 'cloud': {'key': 'cloud', 'type': 'EventsCloudInfo'}, + 'ai': {'key': 'ai', 'type': 'EventsAiInfo'}, + 'application': {'key': 'application', 'type': 'EventsApplicationInfo'}, + 'client': {'key': 'client', 'type': 'EventsClientInfo'}, + 'type': {'key': 'type', 'type': 'str'}, + 'page_view': {'key': 'pageView', 'type': 'EventsPageViewInfo'}, + } + + def __init__(self, **kwargs): + super(EventsPageViewResult, self).__init__(**kwargs) + self.page_view = kwargs.get('page_view', None) + self.type = 'pageView' diff --git a/azure-applicationinsights-query/azure/applicationinsights/query/models/events_page_view_result_py3.py b/azure-applicationinsights-query/azure/applicationinsights/query/models/events_page_view_result_py3.py new file mode 100644 index 000000000000..c2d34a33f671 --- /dev/null +++ b/azure-applicationinsights-query/azure/applicationinsights/query/models/events_page_view_result_py3.py @@ -0,0 +1,79 @@ +# coding=utf-8 +# -------------------------------------------------------------------------- +# Copyright (c) Microsoft Corporation. All rights reserved. +# Licensed under the MIT License. See License.txt in the project root for +# license information. +# +# Code generated by Microsoft (R) AutoRest Code Generator. +# Changes may cause incorrect behavior and will be lost if the code is +# regenerated. +# -------------------------------------------------------------------------- + +from .events_result_data_py3 import EventsResultData + + +class EventsPageViewResult(EventsResultData): + """A page view result. + + All required parameters must be populated in order to send to Azure. + + :param id: The unique ID for this event. + :type id: str + :param count: Count of the event + :type count: long + :param timestamp: Timestamp of the event + :type timestamp: datetime + :param custom_dimensions: Custom dimensions of the event + :type custom_dimensions: + ~azure.applicationinsights.query.models.EventsResultDataCustomDimensions + :param custom_measurements: Custom measurements of the event + :type custom_measurements: + ~azure.applicationinsights.query.models.EventsResultDataCustomMeasurements + :param operation: Operation info of the event + :type operation: + ~azure.applicationinsights.query.models.EventsOperationInfo + :param session: Session info of the event + :type session: ~azure.applicationinsights.query.models.EventsSessionInfo + :param user: User info of the event + :type user: ~azure.applicationinsights.query.models.EventsUserInfo + :param cloud: Cloud info of the event + :type cloud: ~azure.applicationinsights.query.models.EventsCloudInfo + :param ai: AI info of the event + :type ai: ~azure.applicationinsights.query.models.EventsAiInfo + :param application: Application info of the event + :type application: + ~azure.applicationinsights.query.models.EventsApplicationInfo + :param client: Client info of the event + :type client: ~azure.applicationinsights.query.models.EventsClientInfo + :param type: Required. Constant filled by server. + :type type: str + :param page_view: + :type page_view: + ~azure.applicationinsights.query.models.EventsPageViewInfo + """ + + _validation = { + 'type': {'required': True}, + } + + _attribute_map = { + 'id': {'key': 'id', 'type': 'str'}, + 'count': {'key': 'count', 'type': 'long'}, + 'timestamp': {'key': 'timestamp', 'type': 'iso-8601'}, + 'custom_dimensions': {'key': 'customDimensions', 'type': 'EventsResultDataCustomDimensions'}, + 'custom_measurements': {'key': 'customMeasurements', 'type': 'EventsResultDataCustomMeasurements'}, + 'operation': {'key': 'operation', 'type': 'EventsOperationInfo'}, + 'session': {'key': 'session', 'type': 'EventsSessionInfo'}, + 'user': {'key': 'user', 'type': 'EventsUserInfo'}, + 'cloud': {'key': 'cloud', 'type': 'EventsCloudInfo'}, + 'ai': {'key': 'ai', 'type': 'EventsAiInfo'}, + 'application': {'key': 'application', 'type': 'EventsApplicationInfo'}, + 'client': {'key': 'client', 'type': 'EventsClientInfo'}, + 'type': {'key': 'type', 'type': 'str'}, + 'page_view': {'key': 'pageView', 'type': 'EventsPageViewInfo'}, + } + + def __init__(self, *, id: str=None, count: int=None, timestamp=None, custom_dimensions=None, custom_measurements=None, operation=None, session=None, user=None, cloud=None, ai=None, application=None, client=None, page_view=None, **kwargs) -> None: + super(EventsPageViewResult, self).__init__(id=id, count=count, timestamp=timestamp, custom_dimensions=custom_dimensions, custom_measurements=custom_measurements, operation=operation, session=session, user=user, cloud=cloud, ai=ai, application=application, client=client, **kwargs) + self.page_view = page_view + self.type = 'pageView' diff --git a/azure-applicationinsights-query/azure/applicationinsights/query/models/events_performance_counter_info.py b/azure-applicationinsights-query/azure/applicationinsights/query/models/events_performance_counter_info.py new file mode 100644 index 000000000000..3daf89d8bf1e --- /dev/null +++ b/azure-applicationinsights-query/azure/applicationinsights/query/models/events_performance_counter_info.py @@ -0,0 +1,48 @@ +# coding=utf-8 +# -------------------------------------------------------------------------- +# Copyright (c) Microsoft Corporation. All rights reserved. +# Licensed under the MIT License. See License.txt in the project root for +# license information. +# +# Code generated by Microsoft (R) AutoRest Code Generator. +# Changes may cause incorrect behavior and will be lost if the code is +# regenerated. +# -------------------------------------------------------------------------- + +from msrest.serialization import Model + + +class EventsPerformanceCounterInfo(Model): + """The performance counter info. + + :param value: The value of the performance counter + :type value: float + :param name: The name of the performance counter + :type name: str + :param category: The category of the performance counter + :type category: str + :param counter: The counter of the performance counter + :type counter: str + :param instance_name: The instance name of the performance counter + :type instance_name: str + :param instance: The instance of the performance counter + :type instance: str + """ + + _attribute_map = { + 'value': {'key': 'value', 'type': 'float'}, + 'name': {'key': 'name', 'type': 'str'}, + 'category': {'key': 'category', 'type': 'str'}, + 'counter': {'key': 'counter', 'type': 'str'}, + 'instance_name': {'key': 'instanceName', 'type': 'str'}, + 'instance': {'key': 'instance', 'type': 'str'}, + } + + def __init__(self, **kwargs): + super(EventsPerformanceCounterInfo, self).__init__(**kwargs) + self.value = kwargs.get('value', None) + self.name = kwargs.get('name', None) + self.category = kwargs.get('category', None) + self.counter = kwargs.get('counter', None) + self.instance_name = kwargs.get('instance_name', None) + self.instance = kwargs.get('instance', None) diff --git a/azure-applicationinsights-query/azure/applicationinsights/query/models/events_performance_counter_info_py3.py b/azure-applicationinsights-query/azure/applicationinsights/query/models/events_performance_counter_info_py3.py new file mode 100644 index 000000000000..7ec08ee47e26 --- /dev/null +++ b/azure-applicationinsights-query/azure/applicationinsights/query/models/events_performance_counter_info_py3.py @@ -0,0 +1,48 @@ +# coding=utf-8 +# -------------------------------------------------------------------------- +# Copyright (c) Microsoft Corporation. All rights reserved. +# Licensed under the MIT License. See License.txt in the project root for +# license information. +# +# Code generated by Microsoft (R) AutoRest Code Generator. +# Changes may cause incorrect behavior and will be lost if the code is +# regenerated. +# -------------------------------------------------------------------------- + +from msrest.serialization import Model + + +class EventsPerformanceCounterInfo(Model): + """The performance counter info. + + :param value: The value of the performance counter + :type value: float + :param name: The name of the performance counter + :type name: str + :param category: The category of the performance counter + :type category: str + :param counter: The counter of the performance counter + :type counter: str + :param instance_name: The instance name of the performance counter + :type instance_name: str + :param instance: The instance of the performance counter + :type instance: str + """ + + _attribute_map = { + 'value': {'key': 'value', 'type': 'float'}, + 'name': {'key': 'name', 'type': 'str'}, + 'category': {'key': 'category', 'type': 'str'}, + 'counter': {'key': 'counter', 'type': 'str'}, + 'instance_name': {'key': 'instanceName', 'type': 'str'}, + 'instance': {'key': 'instance', 'type': 'str'}, + } + + def __init__(self, *, value: float=None, name: str=None, category: str=None, counter: str=None, instance_name: str=None, instance: str=None, **kwargs) -> None: + super(EventsPerformanceCounterInfo, self).__init__(**kwargs) + self.value = value + self.name = name + self.category = category + self.counter = counter + self.instance_name = instance_name + self.instance = instance diff --git a/azure-applicationinsights-query/azure/applicationinsights/query/models/events_performance_counter_result.py b/azure-applicationinsights-query/azure/applicationinsights/query/models/events_performance_counter_result.py new file mode 100644 index 000000000000..d53b447a2f3c --- /dev/null +++ b/azure-applicationinsights-query/azure/applicationinsights/query/models/events_performance_counter_result.py @@ -0,0 +1,79 @@ +# coding=utf-8 +# -------------------------------------------------------------------------- +# Copyright (c) Microsoft Corporation. All rights reserved. +# Licensed under the MIT License. See License.txt in the project root for +# license information. +# +# Code generated by Microsoft (R) AutoRest Code Generator. +# Changes may cause incorrect behavior and will be lost if the code is +# regenerated. +# -------------------------------------------------------------------------- + +from .events_result_data import EventsResultData + + +class EventsPerformanceCounterResult(EventsResultData): + """A performance counter result. + + All required parameters must be populated in order to send to Azure. + + :param id: The unique ID for this event. + :type id: str + :param count: Count of the event + :type count: long + :param timestamp: Timestamp of the event + :type timestamp: datetime + :param custom_dimensions: Custom dimensions of the event + :type custom_dimensions: + ~azure.applicationinsights.query.models.EventsResultDataCustomDimensions + :param custom_measurements: Custom measurements of the event + :type custom_measurements: + ~azure.applicationinsights.query.models.EventsResultDataCustomMeasurements + :param operation: Operation info of the event + :type operation: + ~azure.applicationinsights.query.models.EventsOperationInfo + :param session: Session info of the event + :type session: ~azure.applicationinsights.query.models.EventsSessionInfo + :param user: User info of the event + :type user: ~azure.applicationinsights.query.models.EventsUserInfo + :param cloud: Cloud info of the event + :type cloud: ~azure.applicationinsights.query.models.EventsCloudInfo + :param ai: AI info of the event + :type ai: ~azure.applicationinsights.query.models.EventsAiInfo + :param application: Application info of the event + :type application: + ~azure.applicationinsights.query.models.EventsApplicationInfo + :param client: Client info of the event + :type client: ~azure.applicationinsights.query.models.EventsClientInfo + :param type: Required. Constant filled by server. + :type type: str + :param performance_counter: + :type performance_counter: + ~azure.applicationinsights.query.models.EventsPerformanceCounterInfo + """ + + _validation = { + 'type': {'required': True}, + } + + _attribute_map = { + 'id': {'key': 'id', 'type': 'str'}, + 'count': {'key': 'count', 'type': 'long'}, + 'timestamp': {'key': 'timestamp', 'type': 'iso-8601'}, + 'custom_dimensions': {'key': 'customDimensions', 'type': 'EventsResultDataCustomDimensions'}, + 'custom_measurements': {'key': 'customMeasurements', 'type': 'EventsResultDataCustomMeasurements'}, + 'operation': {'key': 'operation', 'type': 'EventsOperationInfo'}, + 'session': {'key': 'session', 'type': 'EventsSessionInfo'}, + 'user': {'key': 'user', 'type': 'EventsUserInfo'}, + 'cloud': {'key': 'cloud', 'type': 'EventsCloudInfo'}, + 'ai': {'key': 'ai', 'type': 'EventsAiInfo'}, + 'application': {'key': 'application', 'type': 'EventsApplicationInfo'}, + 'client': {'key': 'client', 'type': 'EventsClientInfo'}, + 'type': {'key': 'type', 'type': 'str'}, + 'performance_counter': {'key': 'performanceCounter', 'type': 'EventsPerformanceCounterInfo'}, + } + + def __init__(self, **kwargs): + super(EventsPerformanceCounterResult, self).__init__(**kwargs) + self.performance_counter = kwargs.get('performance_counter', None) + self.type = 'performanceCounter' diff --git a/azure-applicationinsights-query/azure/applicationinsights/query/models/events_performance_counter_result_py3.py b/azure-applicationinsights-query/azure/applicationinsights/query/models/events_performance_counter_result_py3.py new file mode 100644 index 000000000000..81a891767c69 --- /dev/null +++ b/azure-applicationinsights-query/azure/applicationinsights/query/models/events_performance_counter_result_py3.py @@ -0,0 +1,79 @@ +# coding=utf-8 +# -------------------------------------------------------------------------- +# Copyright (c) Microsoft Corporation. All rights reserved. +# Licensed under the MIT License. See License.txt in the project root for +# license information. +# +# Code generated by Microsoft (R) AutoRest Code Generator. +# Changes may cause incorrect behavior and will be lost if the code is +# regenerated. +# -------------------------------------------------------------------------- + +from .events_result_data_py3 import EventsResultData + + +class EventsPerformanceCounterResult(EventsResultData): + """A performance counter result. + + All required parameters must be populated in order to send to Azure. + + :param id: The unique ID for this event. + :type id: str + :param count: Count of the event + :type count: long + :param timestamp: Timestamp of the event + :type timestamp: datetime + :param custom_dimensions: Custom dimensions of the event + :type custom_dimensions: + ~azure.applicationinsights.query.models.EventsResultDataCustomDimensions + :param custom_measurements: Custom measurements of the event + :type custom_measurements: + ~azure.applicationinsights.query.models.EventsResultDataCustomMeasurements + :param operation: Operation info of the event + :type operation: + ~azure.applicationinsights.query.models.EventsOperationInfo + :param session: Session info of the event + :type session: ~azure.applicationinsights.query.models.EventsSessionInfo + :param user: User info of the event + :type user: ~azure.applicationinsights.query.models.EventsUserInfo + :param cloud: Cloud info of the event + :type cloud: ~azure.applicationinsights.query.models.EventsCloudInfo + :param ai: AI info of the event + :type ai: ~azure.applicationinsights.query.models.EventsAiInfo + :param application: Application info of the event + :type application: + ~azure.applicationinsights.query.models.EventsApplicationInfo + :param client: Client info of the event + :type client: ~azure.applicationinsights.query.models.EventsClientInfo + :param type: Required. Constant filled by server. + :type type: str + :param performance_counter: + :type performance_counter: + ~azure.applicationinsights.query.models.EventsPerformanceCounterInfo + """ + + _validation = { + 'type': {'required': True}, + } + + _attribute_map = { + 'id': {'key': 'id', 'type': 'str'}, + 'count': {'key': 'count', 'type': 'long'}, + 'timestamp': {'key': 'timestamp', 'type': 'iso-8601'}, + 'custom_dimensions': {'key': 'customDimensions', 'type': 'EventsResultDataCustomDimensions'}, + 'custom_measurements': {'key': 'customMeasurements', 'type': 'EventsResultDataCustomMeasurements'}, + 'operation': {'key': 'operation', 'type': 'EventsOperationInfo'}, + 'session': {'key': 'session', 'type': 'EventsSessionInfo'}, + 'user': {'key': 'user', 'type': 'EventsUserInfo'}, + 'cloud': {'key': 'cloud', 'type': 'EventsCloudInfo'}, + 'ai': {'key': 'ai', 'type': 'EventsAiInfo'}, + 'application': {'key': 'application', 'type': 'EventsApplicationInfo'}, + 'client': {'key': 'client', 'type': 'EventsClientInfo'}, + 'type': {'key': 'type', 'type': 'str'}, + 'performance_counter': {'key': 'performanceCounter', 'type': 'EventsPerformanceCounterInfo'}, + } + + def __init__(self, *, id: str=None, count: int=None, timestamp=None, custom_dimensions=None, custom_measurements=None, operation=None, session=None, user=None, cloud=None, ai=None, application=None, client=None, performance_counter=None, **kwargs) -> None: + super(EventsPerformanceCounterResult, self).__init__(id=id, count=count, timestamp=timestamp, custom_dimensions=custom_dimensions, custom_measurements=custom_measurements, operation=operation, session=session, user=user, cloud=cloud, ai=ai, application=application, client=client, **kwargs) + self.performance_counter = performance_counter + self.type = 'performanceCounter' diff --git a/azure-applicationinsights-query/azure/applicationinsights/query/models/events_request_info.py b/azure-applicationinsights-query/azure/applicationinsights/query/models/events_request_info.py new file mode 100644 index 000000000000..b4765967f7f3 --- /dev/null +++ b/azure-applicationinsights-query/azure/applicationinsights/query/models/events_request_info.py @@ -0,0 +1,56 @@ +# coding=utf-8 +# -------------------------------------------------------------------------- +# Copyright (c) Microsoft Corporation. All rights reserved. +# Licensed under the MIT License. See License.txt in the project root for +# license information. +# +# Code generated by Microsoft (R) AutoRest Code Generator. +# Changes may cause incorrect behavior and will be lost if the code is +# regenerated. +# -------------------------------------------------------------------------- + +from msrest.serialization import Model + + +class EventsRequestInfo(Model): + """The request info. + + :param name: The name of the request + :type name: str + :param url: The URL of the request + :type url: str + :param success: Indicates if the request was successful + :type success: str + :param duration: The duration of the request + :type duration: float + :param performance_bucket: The performance bucket of the request + :type performance_bucket: str + :param result_code: The result code of the request + :type result_code: str + :param source: The source of the request + :type source: str + :param id: The ID of the request + :type id: str + """ + + _attribute_map = { + 'name': {'key': 'name', 'type': 'str'}, + 'url': {'key': 'url', 'type': 'str'}, + 'success': {'key': 'success', 'type': 'str'}, + 'duration': {'key': 'duration', 'type': 'float'}, + 'performance_bucket': {'key': 'performanceBucket', 'type': 'str'}, + 'result_code': {'key': 'resultCode', 'type': 'str'}, + 'source': {'key': 'source', 'type': 'str'}, + 'id': {'key': 'id', 'type': 'str'}, + } + + def __init__(self, **kwargs): + super(EventsRequestInfo, self).__init__(**kwargs) + self.name = kwargs.get('name', None) + self.url = kwargs.get('url', None) + self.success = kwargs.get('success', None) + self.duration = kwargs.get('duration', None) + self.performance_bucket = kwargs.get('performance_bucket', None) + self.result_code = kwargs.get('result_code', None) + self.source = kwargs.get('source', None) + self.id = kwargs.get('id', None) diff --git a/azure-applicationinsights-query/azure/applicationinsights/query/models/events_request_info_py3.py b/azure-applicationinsights-query/azure/applicationinsights/query/models/events_request_info_py3.py new file mode 100644 index 000000000000..bdafd3755743 --- /dev/null +++ b/azure-applicationinsights-query/azure/applicationinsights/query/models/events_request_info_py3.py @@ -0,0 +1,56 @@ +# coding=utf-8 +# -------------------------------------------------------------------------- +# Copyright (c) Microsoft Corporation. All rights reserved. +# Licensed under the MIT License. See License.txt in the project root for +# license information. +# +# Code generated by Microsoft (R) AutoRest Code Generator. +# Changes may cause incorrect behavior and will be lost if the code is +# regenerated. +# -------------------------------------------------------------------------- + +from msrest.serialization import Model + + +class EventsRequestInfo(Model): + """The request info. + + :param name: The name of the request + :type name: str + :param url: The URL of the request + :type url: str + :param success: Indicates if the request was successful + :type success: str + :param duration: The duration of the request + :type duration: float + :param performance_bucket: The performance bucket of the request + :type performance_bucket: str + :param result_code: The result code of the request + :type result_code: str + :param source: The source of the request + :type source: str + :param id: The ID of the request + :type id: str + """ + + _attribute_map = { + 'name': {'key': 'name', 'type': 'str'}, + 'url': {'key': 'url', 'type': 'str'}, + 'success': {'key': 'success', 'type': 'str'}, + 'duration': {'key': 'duration', 'type': 'float'}, + 'performance_bucket': {'key': 'performanceBucket', 'type': 'str'}, + 'result_code': {'key': 'resultCode', 'type': 'str'}, + 'source': {'key': 'source', 'type': 'str'}, + 'id': {'key': 'id', 'type': 'str'}, + } + + def __init__(self, *, name: str=None, url: str=None, success: str=None, duration: float=None, performance_bucket: str=None, result_code: str=None, source: str=None, id: str=None, **kwargs) -> None: + super(EventsRequestInfo, self).__init__(**kwargs) + self.name = name + self.url = url + self.success = success + self.duration = duration + self.performance_bucket = performance_bucket + self.result_code = result_code + self.source = source + self.id = id diff --git a/azure-applicationinsights-query/azure/applicationinsights/query/models/events_request_result.py b/azure-applicationinsights-query/azure/applicationinsights/query/models/events_request_result.py new file mode 100644 index 000000000000..a57798516548 --- /dev/null +++ b/azure-applicationinsights-query/azure/applicationinsights/query/models/events_request_result.py @@ -0,0 +1,78 @@ +# coding=utf-8 +# -------------------------------------------------------------------------- +# Copyright (c) Microsoft Corporation. All rights reserved. +# Licensed under the MIT License. See License.txt in the project root for +# license information. +# +# Code generated by Microsoft (R) AutoRest Code Generator. +# Changes may cause incorrect behavior and will be lost if the code is +# regenerated. +# -------------------------------------------------------------------------- + +from .events_result_data import EventsResultData + + +class EventsRequestResult(EventsResultData): + """A request result. + + All required parameters must be populated in order to send to Azure. + + :param id: The unique ID for this event. + :type id: str + :param count: Count of the event + :type count: long + :param timestamp: Timestamp of the event + :type timestamp: datetime + :param custom_dimensions: Custom dimensions of the event + :type custom_dimensions: + ~azure.applicationinsights.query.models.EventsResultDataCustomDimensions + :param custom_measurements: Custom measurements of the event + :type custom_measurements: + ~azure.applicationinsights.query.models.EventsResultDataCustomMeasurements + :param operation: Operation info of the event + :type operation: + ~azure.applicationinsights.query.models.EventsOperationInfo + :param session: Session info of the event + :type session: ~azure.applicationinsights.query.models.EventsSessionInfo + :param user: User info of the event + :type user: ~azure.applicationinsights.query.models.EventsUserInfo + :param cloud: Cloud info of the event + :type cloud: ~azure.applicationinsights.query.models.EventsCloudInfo + :param ai: AI info of the event + :type ai: ~azure.applicationinsights.query.models.EventsAiInfo + :param application: Application info of the event + :type application: + ~azure.applicationinsights.query.models.EventsApplicationInfo + :param client: Client info of the event + :type client: ~azure.applicationinsights.query.models.EventsClientInfo + :param type: Required. Constant filled by server. + :type type: str + :param request: + :type request: ~azure.applicationinsights.query.models.EventsRequestInfo + """ + + _validation = { + 'type': {'required': True}, + } + + _attribute_map = { + 'id': {'key': 'id', 'type': 'str'}, + 'count': {'key': 'count', 'type': 'long'}, + 'timestamp': {'key': 'timestamp', 'type': 'iso-8601'}, + 'custom_dimensions': {'key': 'customDimensions', 'type': 'EventsResultDataCustomDimensions'}, + 'custom_measurements': {'key': 'customMeasurements', 'type': 'EventsResultDataCustomMeasurements'}, + 'operation': {'key': 'operation', 'type': 'EventsOperationInfo'}, + 'session': {'key': 'session', 'type': 'EventsSessionInfo'}, + 'user': {'key': 'user', 'type': 'EventsUserInfo'}, + 'cloud': {'key': 'cloud', 'type': 'EventsCloudInfo'}, + 'ai': {'key': 'ai', 'type': 'EventsAiInfo'}, + 'application': {'key': 'application', 'type': 'EventsApplicationInfo'}, + 'client': {'key': 'client', 'type': 'EventsClientInfo'}, + 'type': {'key': 'type', 'type': 'str'}, + 'request': {'key': 'request', 'type': 'EventsRequestInfo'}, + } + + def __init__(self, **kwargs): + super(EventsRequestResult, self).__init__(**kwargs) + self.request = kwargs.get('request', None) + self.type = 'request' diff --git a/azure-applicationinsights-query/azure/applicationinsights/query/models/events_request_result_py3.py b/azure-applicationinsights-query/azure/applicationinsights/query/models/events_request_result_py3.py new file mode 100644 index 000000000000..972054958ce4 --- /dev/null +++ b/azure-applicationinsights-query/azure/applicationinsights/query/models/events_request_result_py3.py @@ -0,0 +1,78 @@ +# coding=utf-8 +# -------------------------------------------------------------------------- +# Copyright (c) Microsoft Corporation. All rights reserved. +# Licensed under the MIT License. See License.txt in the project root for +# license information. +# +# Code generated by Microsoft (R) AutoRest Code Generator. +# Changes may cause incorrect behavior and will be lost if the code is +# regenerated. +# -------------------------------------------------------------------------- + +from .events_result_data_py3 import EventsResultData + + +class EventsRequestResult(EventsResultData): + """A request result. + + All required parameters must be populated in order to send to Azure. + + :param id: The unique ID for this event. + :type id: str + :param count: Count of the event + :type count: long + :param timestamp: Timestamp of the event + :type timestamp: datetime + :param custom_dimensions: Custom dimensions of the event + :type custom_dimensions: + ~azure.applicationinsights.query.models.EventsResultDataCustomDimensions + :param custom_measurements: Custom measurements of the event + :type custom_measurements: + ~azure.applicationinsights.query.models.EventsResultDataCustomMeasurements + :param operation: Operation info of the event + :type operation: + ~azure.applicationinsights.query.models.EventsOperationInfo + :param session: Session info of the event + :type session: ~azure.applicationinsights.query.models.EventsSessionInfo + :param user: User info of the event + :type user: ~azure.applicationinsights.query.models.EventsUserInfo + :param cloud: Cloud info of the event + :type cloud: ~azure.applicationinsights.query.models.EventsCloudInfo + :param ai: AI info of the event + :type ai: ~azure.applicationinsights.query.models.EventsAiInfo + :param application: Application info of the event + :type application: + ~azure.applicationinsights.query.models.EventsApplicationInfo + :param client: Client info of the event + :type client: ~azure.applicationinsights.query.models.EventsClientInfo + :param type: Required. Constant filled by server. + :type type: str + :param request: + :type request: ~azure.applicationinsights.query.models.EventsRequestInfo + """ + + _validation = { + 'type': {'required': True}, + } + + _attribute_map = { + 'id': {'key': 'id', 'type': 'str'}, + 'count': {'key': 'count', 'type': 'long'}, + 'timestamp': {'key': 'timestamp', 'type': 'iso-8601'}, + 'custom_dimensions': {'key': 'customDimensions', 'type': 'EventsResultDataCustomDimensions'}, + 'custom_measurements': {'key': 'customMeasurements', 'type': 'EventsResultDataCustomMeasurements'}, + 'operation': {'key': 'operation', 'type': 'EventsOperationInfo'}, + 'session': {'key': 'session', 'type': 'EventsSessionInfo'}, + 'user': {'key': 'user', 'type': 'EventsUserInfo'}, + 'cloud': {'key': 'cloud', 'type': 'EventsCloudInfo'}, + 'ai': {'key': 'ai', 'type': 'EventsAiInfo'}, + 'application': {'key': 'application', 'type': 'EventsApplicationInfo'}, + 'client': {'key': 'client', 'type': 'EventsClientInfo'}, + 'type': {'key': 'type', 'type': 'str'}, + 'request': {'key': 'request', 'type': 'EventsRequestInfo'}, + } + + def __init__(self, *, id: str=None, count: int=None, timestamp=None, custom_dimensions=None, custom_measurements=None, operation=None, session=None, user=None, cloud=None, ai=None, application=None, client=None, request=None, **kwargs) -> None: + super(EventsRequestResult, self).__init__(id=id, count=count, timestamp=timestamp, custom_dimensions=custom_dimensions, custom_measurements=custom_measurements, operation=operation, session=session, user=user, cloud=cloud, ai=ai, application=application, client=client, **kwargs) + self.request = request + self.type = 'request' diff --git a/azure-applicationinsights-query/azure/applicationinsights/query/models/events_result.py b/azure-applicationinsights-query/azure/applicationinsights/query/models/events_result.py new file mode 100644 index 000000000000..b84d8c770a35 --- /dev/null +++ b/azure-applicationinsights-query/azure/applicationinsights/query/models/events_result.py @@ -0,0 +1,32 @@ +# coding=utf-8 +# -------------------------------------------------------------------------- +# Copyright (c) Microsoft Corporation. All rights reserved. +# Licensed under the MIT License. See License.txt in the project root for +# license information. +# +# Code generated by Microsoft (R) AutoRest Code Generator. +# Changes may cause incorrect behavior and will be lost if the code is +# regenerated. +# -------------------------------------------------------------------------- + +from msrest.serialization import Model + + +class EventsResult(Model): + """An event query result. + + :param aimessages: OData messages for this response. + :type aimessages: list[~azure.applicationinsights.query.models.ErrorInfo] + :param value: + :type value: ~azure.applicationinsights.query.models.EventsResultData + """ + + _attribute_map = { + 'aimessages': {'key': '@ai\\.messages', 'type': '[ErrorInfo]'}, + 'value': {'key': 'value', 'type': 'EventsResultData'}, + } + + def __init__(self, **kwargs): + super(EventsResult, self).__init__(**kwargs) + self.aimessages = kwargs.get('aimessages', None) + self.value = kwargs.get('value', None) diff --git a/azure-applicationinsights-query/azure/applicationinsights/query/models/events_result_data.py b/azure-applicationinsights-query/azure/applicationinsights/query/models/events_result_data.py new file mode 100644 index 000000000000..c4cf3b6ebe09 --- /dev/null +++ b/azure-applicationinsights-query/azure/applicationinsights/query/models/events_result_data.py @@ -0,0 +1,97 @@ +# coding=utf-8 +# -------------------------------------------------------------------------- +# Copyright (c) Microsoft Corporation. All rights reserved. +# Licensed under the MIT License. See License.txt in the project root for +# license information. +# +# Code generated by Microsoft (R) AutoRest Code Generator. +# Changes may cause incorrect behavior and will be lost if the code is +# regenerated. +# -------------------------------------------------------------------------- + +from msrest.serialization import Model + + +class EventsResultData(Model): + """Events query result data. + + You probably want to use the sub-classes and not this class directly. Known + sub-classes are: EventsTraceResult, EventsCustomEventResult, + EventsPageViewResult, EventsBrowserTimingResult, EventsRequestResult, + EventsDependencyResult, EventsExceptionResult, + EventsAvailabilityResultResult, EventsPerformanceCounterResult, + EventsCustomMetricResult + + All required parameters must be populated in order to send to Azure. + + :param id: The unique ID for this event. + :type id: str + :param count: Count of the event + :type count: long + :param timestamp: Timestamp of the event + :type timestamp: datetime + :param custom_dimensions: Custom dimensions of the event + :type custom_dimensions: + ~azure.applicationinsights.query.models.EventsResultDataCustomDimensions + :param custom_measurements: Custom measurements of the event + :type custom_measurements: + ~azure.applicationinsights.query.models.EventsResultDataCustomMeasurements + :param operation: Operation info of the event + :type operation: + ~azure.applicationinsights.query.models.EventsOperationInfo + :param session: Session info of the event + :type session: ~azure.applicationinsights.query.models.EventsSessionInfo + :param user: User info of the event + :type user: ~azure.applicationinsights.query.models.EventsUserInfo + :param cloud: Cloud info of the event + :type cloud: ~azure.applicationinsights.query.models.EventsCloudInfo + :param ai: AI info of the event + :type ai: ~azure.applicationinsights.query.models.EventsAiInfo + :param application: Application info of the event + :type application: + ~azure.applicationinsights.query.models.EventsApplicationInfo + :param client: Client info of the event + :type client: ~azure.applicationinsights.query.models.EventsClientInfo + :param type: Required. Constant filled by server. + :type type: str + """ + + _validation = { + 'type': {'required': True}, + } + + _attribute_map = { + 'id': {'key': 'id', 'type': 'str'}, + 'count': {'key': 'count', 'type': 'long'}, + 'timestamp': {'key': 'timestamp', 'type': 'iso-8601'}, + 'custom_dimensions': {'key': 'customDimensions', 'type': 'EventsResultDataCustomDimensions'}, + 'custom_measurements': {'key': 'customMeasurements', 'type': 'EventsResultDataCustomMeasurements'}, + 'operation': {'key': 'operation', 'type': 'EventsOperationInfo'}, + 'session': {'key': 'session', 'type': 'EventsSessionInfo'}, + 'user': {'key': 'user', 'type': 'EventsUserInfo'}, + 'cloud': {'key': 'cloud', 'type': 'EventsCloudInfo'}, + 'ai': {'key': 'ai', 'type': 'EventsAiInfo'}, + 'application': {'key': 'application', 'type': 'EventsApplicationInfo'}, + 'client': {'key': 'client', 'type': 'EventsClientInfo'}, + 'type': {'key': 'type', 'type': 'str'}, + } + + _subtype_map = { + 'type': {'trace': 'EventsTraceResult', 'customEvent': 'EventsCustomEventResult', 'pageView': 'EventsPageViewResult', 'browserTiming': 'EventsBrowserTimingResult', 'request': 'EventsRequestResult', 'dependency': 'EventsDependencyResult', 'exception': 'EventsExceptionResult', 'availabilityResult': 'EventsAvailabilityResultResult', 'performanceCounter': 'EventsPerformanceCounterResult', 'customMetric': 'EventsCustomMetricResult'} + } + + def __init__(self, **kwargs): + super(EventsResultData, self).__init__(**kwargs) + self.id = kwargs.get('id', None) + self.count = kwargs.get('count', None) + self.timestamp = kwargs.get('timestamp', None) + self.custom_dimensions = kwargs.get('custom_dimensions', None) + self.custom_measurements = kwargs.get('custom_measurements', None) + self.operation = kwargs.get('operation', None) + self.session = kwargs.get('session', None) + self.user = kwargs.get('user', None) + self.cloud = kwargs.get('cloud', None) + self.ai = kwargs.get('ai', None) + self.application = kwargs.get('application', None) + self.client = kwargs.get('client', None) + self.type = None diff --git a/azure-applicationinsights-query/azure/applicationinsights/query/models/events_result_data_custom_dimensions.py b/azure-applicationinsights-query/azure/applicationinsights/query/models/events_result_data_custom_dimensions.py new file mode 100644 index 000000000000..2f50c8baeb6e --- /dev/null +++ b/azure-applicationinsights-query/azure/applicationinsights/query/models/events_result_data_custom_dimensions.py @@ -0,0 +1,28 @@ +# coding=utf-8 +# -------------------------------------------------------------------------- +# Copyright (c) Microsoft Corporation. All rights reserved. +# Licensed under the MIT License. See License.txt in the project root for +# license information. +# +# Code generated by Microsoft (R) AutoRest Code Generator. +# Changes may cause incorrect behavior and will be lost if the code is +# regenerated. +# -------------------------------------------------------------------------- + +from msrest.serialization import Model + + +class EventsResultDataCustomDimensions(Model): + """Custom dimensions of the event. + + :param additional_properties: + :type additional_properties: object + """ + + _attribute_map = { + 'additional_properties': {'key': 'additionalProperties', 'type': 'object'}, + } + + def __init__(self, **kwargs): + super(EventsResultDataCustomDimensions, self).__init__(**kwargs) + self.additional_properties = kwargs.get('additional_properties', None) diff --git a/azure-applicationinsights-query/azure/applicationinsights/query/models/events_result_data_custom_dimensions_py3.py b/azure-applicationinsights-query/azure/applicationinsights/query/models/events_result_data_custom_dimensions_py3.py new file mode 100644 index 000000000000..968ac0eb0ab1 --- /dev/null +++ b/azure-applicationinsights-query/azure/applicationinsights/query/models/events_result_data_custom_dimensions_py3.py @@ -0,0 +1,28 @@ +# coding=utf-8 +# -------------------------------------------------------------------------- +# Copyright (c) Microsoft Corporation. All rights reserved. +# Licensed under the MIT License. See License.txt in the project root for +# license information. +# +# Code generated by Microsoft (R) AutoRest Code Generator. +# Changes may cause incorrect behavior and will be lost if the code is +# regenerated. +# -------------------------------------------------------------------------- + +from msrest.serialization import Model + + +class EventsResultDataCustomDimensions(Model): + """Custom dimensions of the event. + + :param additional_properties: + :type additional_properties: object + """ + + _attribute_map = { + 'additional_properties': {'key': 'additionalProperties', 'type': 'object'}, + } + + def __init__(self, *, additional_properties=None, **kwargs) -> None: + super(EventsResultDataCustomDimensions, self).__init__(**kwargs) + self.additional_properties = additional_properties diff --git a/azure-applicationinsights-query/azure/applicationinsights/query/models/events_result_data_custom_measurements.py b/azure-applicationinsights-query/azure/applicationinsights/query/models/events_result_data_custom_measurements.py new file mode 100644 index 000000000000..907b52e1f5ea --- /dev/null +++ b/azure-applicationinsights-query/azure/applicationinsights/query/models/events_result_data_custom_measurements.py @@ -0,0 +1,28 @@ +# coding=utf-8 +# -------------------------------------------------------------------------- +# Copyright (c) Microsoft Corporation. All rights reserved. +# Licensed under the MIT License. See License.txt in the project root for +# license information. +# +# Code generated by Microsoft (R) AutoRest Code Generator. +# Changes may cause incorrect behavior and will be lost if the code is +# regenerated. +# -------------------------------------------------------------------------- + +from msrest.serialization import Model + + +class EventsResultDataCustomMeasurements(Model): + """Custom measurements of the event. + + :param additional_properties: + :type additional_properties: object + """ + + _attribute_map = { + 'additional_properties': {'key': 'additionalProperties', 'type': 'object'}, + } + + def __init__(self, **kwargs): + super(EventsResultDataCustomMeasurements, self).__init__(**kwargs) + self.additional_properties = kwargs.get('additional_properties', None) diff --git a/azure-applicationinsights-query/azure/applicationinsights/query/models/events_result_data_custom_measurements_py3.py b/azure-applicationinsights-query/azure/applicationinsights/query/models/events_result_data_custom_measurements_py3.py new file mode 100644 index 000000000000..018286f96593 --- /dev/null +++ b/azure-applicationinsights-query/azure/applicationinsights/query/models/events_result_data_custom_measurements_py3.py @@ -0,0 +1,28 @@ +# coding=utf-8 +# -------------------------------------------------------------------------- +# Copyright (c) Microsoft Corporation. All rights reserved. +# Licensed under the MIT License. See License.txt in the project root for +# license information. +# +# Code generated by Microsoft (R) AutoRest Code Generator. +# Changes may cause incorrect behavior and will be lost if the code is +# regenerated. +# -------------------------------------------------------------------------- + +from msrest.serialization import Model + + +class EventsResultDataCustomMeasurements(Model): + """Custom measurements of the event. + + :param additional_properties: + :type additional_properties: object + """ + + _attribute_map = { + 'additional_properties': {'key': 'additionalProperties', 'type': 'object'}, + } + + def __init__(self, *, additional_properties=None, **kwargs) -> None: + super(EventsResultDataCustomMeasurements, self).__init__(**kwargs) + self.additional_properties = additional_properties diff --git a/azure-applicationinsights-query/azure/applicationinsights/query/models/events_result_data_py3.py b/azure-applicationinsights-query/azure/applicationinsights/query/models/events_result_data_py3.py new file mode 100644 index 000000000000..34ec898acd06 --- /dev/null +++ b/azure-applicationinsights-query/azure/applicationinsights/query/models/events_result_data_py3.py @@ -0,0 +1,97 @@ +# coding=utf-8 +# -------------------------------------------------------------------------- +# Copyright (c) Microsoft Corporation. All rights reserved. +# Licensed under the MIT License. See License.txt in the project root for +# license information. +# +# Code generated by Microsoft (R) AutoRest Code Generator. +# Changes may cause incorrect behavior and will be lost if the code is +# regenerated. +# -------------------------------------------------------------------------- + +from msrest.serialization import Model + + +class EventsResultData(Model): + """Events query result data. + + You probably want to use the sub-classes and not this class directly. Known + sub-classes are: EventsTraceResult, EventsCustomEventResult, + EventsPageViewResult, EventsBrowserTimingResult, EventsRequestResult, + EventsDependencyResult, EventsExceptionResult, + EventsAvailabilityResultResult, EventsPerformanceCounterResult, + EventsCustomMetricResult + + All required parameters must be populated in order to send to Azure. + + :param id: The unique ID for this event. + :type id: str + :param count: Count of the event + :type count: long + :param timestamp: Timestamp of the event + :type timestamp: datetime + :param custom_dimensions: Custom dimensions of the event + :type custom_dimensions: + ~azure.applicationinsights.query.models.EventsResultDataCustomDimensions + :param custom_measurements: Custom measurements of the event + :type custom_measurements: + ~azure.applicationinsights.query.models.EventsResultDataCustomMeasurements + :param operation: Operation info of the event + :type operation: + ~azure.applicationinsights.query.models.EventsOperationInfo + :param session: Session info of the event + :type session: ~azure.applicationinsights.query.models.EventsSessionInfo + :param user: User info of the event + :type user: ~azure.applicationinsights.query.models.EventsUserInfo + :param cloud: Cloud info of the event + :type cloud: ~azure.applicationinsights.query.models.EventsCloudInfo + :param ai: AI info of the event + :type ai: ~azure.applicationinsights.query.models.EventsAiInfo + :param application: Application info of the event + :type application: + ~azure.applicationinsights.query.models.EventsApplicationInfo + :param client: Client info of the event + :type client: ~azure.applicationinsights.query.models.EventsClientInfo + :param type: Required. Constant filled by server. + :type type: str + """ + + _validation = { + 'type': {'required': True}, + } + + _attribute_map = { + 'id': {'key': 'id', 'type': 'str'}, + 'count': {'key': 'count', 'type': 'long'}, + 'timestamp': {'key': 'timestamp', 'type': 'iso-8601'}, + 'custom_dimensions': {'key': 'customDimensions', 'type': 'EventsResultDataCustomDimensions'}, + 'custom_measurements': {'key': 'customMeasurements', 'type': 'EventsResultDataCustomMeasurements'}, + 'operation': {'key': 'operation', 'type': 'EventsOperationInfo'}, + 'session': {'key': 'session', 'type': 'EventsSessionInfo'}, + 'user': {'key': 'user', 'type': 'EventsUserInfo'}, + 'cloud': {'key': 'cloud', 'type': 'EventsCloudInfo'}, + 'ai': {'key': 'ai', 'type': 'EventsAiInfo'}, + 'application': {'key': 'application', 'type': 'EventsApplicationInfo'}, + 'client': {'key': 'client', 'type': 'EventsClientInfo'}, + 'type': {'key': 'type', 'type': 'str'}, + } + + _subtype_map = { + 'type': {'trace': 'EventsTraceResult', 'customEvent': 'EventsCustomEventResult', 'pageView': 'EventsPageViewResult', 'browserTiming': 'EventsBrowserTimingResult', 'request': 'EventsRequestResult', 'dependency': 'EventsDependencyResult', 'exception': 'EventsExceptionResult', 'availabilityResult': 'EventsAvailabilityResultResult', 'performanceCounter': 'EventsPerformanceCounterResult', 'customMetric': 'EventsCustomMetricResult'} + } + + def __init__(self, *, id: str=None, count: int=None, timestamp=None, custom_dimensions=None, custom_measurements=None, operation=None, session=None, user=None, cloud=None, ai=None, application=None, client=None, **kwargs) -> None: + super(EventsResultData, self).__init__(**kwargs) + self.id = id + self.count = count + self.timestamp = timestamp + self.custom_dimensions = custom_dimensions + self.custom_measurements = custom_measurements + self.operation = operation + self.session = session + self.user = user + self.cloud = cloud + self.ai = ai + self.application = application + self.client = client + self.type = None diff --git a/azure-applicationinsights-query/azure/applicationinsights/query/models/events_result_py3.py b/azure-applicationinsights-query/azure/applicationinsights/query/models/events_result_py3.py new file mode 100644 index 000000000000..a154e05aef55 --- /dev/null +++ b/azure-applicationinsights-query/azure/applicationinsights/query/models/events_result_py3.py @@ -0,0 +1,32 @@ +# coding=utf-8 +# -------------------------------------------------------------------------- +# Copyright (c) Microsoft Corporation. All rights reserved. +# Licensed under the MIT License. See License.txt in the project root for +# license information. +# +# Code generated by Microsoft (R) AutoRest Code Generator. +# Changes may cause incorrect behavior and will be lost if the code is +# regenerated. +# -------------------------------------------------------------------------- + +from msrest.serialization import Model + + +class EventsResult(Model): + """An event query result. + + :param aimessages: OData messages for this response. + :type aimessages: list[~azure.applicationinsights.query.models.ErrorInfo] + :param value: + :type value: ~azure.applicationinsights.query.models.EventsResultData + """ + + _attribute_map = { + 'aimessages': {'key': '@ai\\.messages', 'type': '[ErrorInfo]'}, + 'value': {'key': 'value', 'type': 'EventsResultData'}, + } + + def __init__(self, *, aimessages=None, value=None, **kwargs) -> None: + super(EventsResult, self).__init__(**kwargs) + self.aimessages = aimessages + self.value = value diff --git a/azure-applicationinsights-query/azure/applicationinsights/query/models/events_results.py b/azure-applicationinsights-query/azure/applicationinsights/query/models/events_results.py new file mode 100644 index 000000000000..8b9a2228d1b4 --- /dev/null +++ b/azure-applicationinsights-query/azure/applicationinsights/query/models/events_results.py @@ -0,0 +1,37 @@ +# coding=utf-8 +# -------------------------------------------------------------------------- +# Copyright (c) Microsoft Corporation. All rights reserved. +# Licensed under the MIT License. See License.txt in the project root for +# license information. +# +# Code generated by Microsoft (R) AutoRest Code Generator. +# Changes may cause incorrect behavior and will be lost if the code is +# regenerated. +# -------------------------------------------------------------------------- + +from msrest.serialization import Model + + +class EventsResults(Model): + """An events query result. + + :param odatacontext: OData context metadata endpoint for this response + :type odatacontext: str + :param aimessages: OData messages for this response. + :type aimessages: list[~azure.applicationinsights.query.models.ErrorInfo] + :param value: Contents of the events query result. + :type value: + list[~azure.applicationinsights.query.models.EventsResultData] + """ + + _attribute_map = { + 'odatacontext': {'key': '@odata\\.context', 'type': 'str'}, + 'aimessages': {'key': '@ai\\.messages', 'type': '[ErrorInfo]'}, + 'value': {'key': 'value', 'type': '[EventsResultData]'}, + } + + def __init__(self, **kwargs): + super(EventsResults, self).__init__(**kwargs) + self.odatacontext = kwargs.get('odatacontext', None) + self.aimessages = kwargs.get('aimessages', None) + self.value = kwargs.get('value', None) diff --git a/azure-applicationinsights-query/azure/applicationinsights/query/models/events_results_py3.py b/azure-applicationinsights-query/azure/applicationinsights/query/models/events_results_py3.py new file mode 100644 index 000000000000..65a22168d007 --- /dev/null +++ b/azure-applicationinsights-query/azure/applicationinsights/query/models/events_results_py3.py @@ -0,0 +1,37 @@ +# coding=utf-8 +# -------------------------------------------------------------------------- +# Copyright (c) Microsoft Corporation. All rights reserved. +# Licensed under the MIT License. See License.txt in the project root for +# license information. +# +# Code generated by Microsoft (R) AutoRest Code Generator. +# Changes may cause incorrect behavior and will be lost if the code is +# regenerated. +# -------------------------------------------------------------------------- + +from msrest.serialization import Model + + +class EventsResults(Model): + """An events query result. + + :param odatacontext: OData context metadata endpoint for this response + :type odatacontext: str + :param aimessages: OData messages for this response. + :type aimessages: list[~azure.applicationinsights.query.models.ErrorInfo] + :param value: Contents of the events query result. + :type value: + list[~azure.applicationinsights.query.models.EventsResultData] + """ + + _attribute_map = { + 'odatacontext': {'key': '@odata\\.context', 'type': 'str'}, + 'aimessages': {'key': '@ai\\.messages', 'type': '[ErrorInfo]'}, + 'value': {'key': 'value', 'type': '[EventsResultData]'}, + } + + def __init__(self, *, odatacontext: str=None, aimessages=None, value=None, **kwargs) -> None: + super(EventsResults, self).__init__(**kwargs) + self.odatacontext = odatacontext + self.aimessages = aimessages + self.value = value diff --git a/azure-applicationinsights-query/azure/applicationinsights/query/models/events_session_info.py b/azure-applicationinsights-query/azure/applicationinsights/query/models/events_session_info.py new file mode 100644 index 000000000000..9d4077762533 --- /dev/null +++ b/azure-applicationinsights-query/azure/applicationinsights/query/models/events_session_info.py @@ -0,0 +1,28 @@ +# coding=utf-8 +# -------------------------------------------------------------------------- +# Copyright (c) Microsoft Corporation. All rights reserved. +# Licensed under the MIT License. See License.txt in the project root for +# license information. +# +# Code generated by Microsoft (R) AutoRest Code Generator. +# Changes may cause incorrect behavior and will be lost if the code is +# regenerated. +# -------------------------------------------------------------------------- + +from msrest.serialization import Model + + +class EventsSessionInfo(Model): + """Session info for an event result. + + :param id: ID of the session + :type id: str + """ + + _attribute_map = { + 'id': {'key': 'id', 'type': 'str'}, + } + + def __init__(self, **kwargs): + super(EventsSessionInfo, self).__init__(**kwargs) + self.id = kwargs.get('id', None) diff --git a/azure-applicationinsights-query/azure/applicationinsights/query/models/events_session_info_py3.py b/azure-applicationinsights-query/azure/applicationinsights/query/models/events_session_info_py3.py new file mode 100644 index 000000000000..92a81d9668d1 --- /dev/null +++ b/azure-applicationinsights-query/azure/applicationinsights/query/models/events_session_info_py3.py @@ -0,0 +1,28 @@ +# coding=utf-8 +# -------------------------------------------------------------------------- +# Copyright (c) Microsoft Corporation. All rights reserved. +# Licensed under the MIT License. See License.txt in the project root for +# license information. +# +# Code generated by Microsoft (R) AutoRest Code Generator. +# Changes may cause incorrect behavior and will be lost if the code is +# regenerated. +# -------------------------------------------------------------------------- + +from msrest.serialization import Model + + +class EventsSessionInfo(Model): + """Session info for an event result. + + :param id: ID of the session + :type id: str + """ + + _attribute_map = { + 'id': {'key': 'id', 'type': 'str'}, + } + + def __init__(self, *, id: str=None, **kwargs) -> None: + super(EventsSessionInfo, self).__init__(**kwargs) + self.id = id diff --git a/azure-applicationinsights-query/azure/applicationinsights/query/models/events_trace_info.py b/azure-applicationinsights-query/azure/applicationinsights/query/models/events_trace_info.py new file mode 100644 index 000000000000..9eff63baf551 --- /dev/null +++ b/azure-applicationinsights-query/azure/applicationinsights/query/models/events_trace_info.py @@ -0,0 +1,32 @@ +# coding=utf-8 +# -------------------------------------------------------------------------- +# Copyright (c) Microsoft Corporation. All rights reserved. +# Licensed under the MIT License. See License.txt in the project root for +# license information. +# +# Code generated by Microsoft (R) AutoRest Code Generator. +# Changes may cause incorrect behavior and will be lost if the code is +# regenerated. +# -------------------------------------------------------------------------- + +from msrest.serialization import Model + + +class EventsTraceInfo(Model): + """The trace information. + + :param message: The trace message + :type message: str + :param severity_level: The trace severity level + :type severity_level: int + """ + + _attribute_map = { + 'message': {'key': 'message', 'type': 'str'}, + 'severity_level': {'key': 'severityLevel', 'type': 'int'}, + } + + def __init__(self, **kwargs): + super(EventsTraceInfo, self).__init__(**kwargs) + self.message = kwargs.get('message', None) + self.severity_level = kwargs.get('severity_level', None) diff --git a/azure-applicationinsights-query/azure/applicationinsights/query/models/events_trace_info_py3.py b/azure-applicationinsights-query/azure/applicationinsights/query/models/events_trace_info_py3.py new file mode 100644 index 000000000000..88956ebe1543 --- /dev/null +++ b/azure-applicationinsights-query/azure/applicationinsights/query/models/events_trace_info_py3.py @@ -0,0 +1,32 @@ +# coding=utf-8 +# -------------------------------------------------------------------------- +# Copyright (c) Microsoft Corporation. All rights reserved. +# Licensed under the MIT License. See License.txt in the project root for +# license information. +# +# Code generated by Microsoft (R) AutoRest Code Generator. +# Changes may cause incorrect behavior and will be lost if the code is +# regenerated. +# -------------------------------------------------------------------------- + +from msrest.serialization import Model + + +class EventsTraceInfo(Model): + """The trace information. + + :param message: The trace message + :type message: str + :param severity_level: The trace severity level + :type severity_level: int + """ + + _attribute_map = { + 'message': {'key': 'message', 'type': 'str'}, + 'severity_level': {'key': 'severityLevel', 'type': 'int'}, + } + + def __init__(self, *, message: str=None, severity_level: int=None, **kwargs) -> None: + super(EventsTraceInfo, self).__init__(**kwargs) + self.message = message + self.severity_level = severity_level diff --git a/azure-applicationinsights-query/azure/applicationinsights/query/models/events_trace_result.py b/azure-applicationinsights-query/azure/applicationinsights/query/models/events_trace_result.py new file mode 100644 index 000000000000..2d26495c9f82 --- /dev/null +++ b/azure-applicationinsights-query/azure/applicationinsights/query/models/events_trace_result.py @@ -0,0 +1,78 @@ +# coding=utf-8 +# -------------------------------------------------------------------------- +# Copyright (c) Microsoft Corporation. All rights reserved. +# Licensed under the MIT License. See License.txt in the project root for +# license information. +# +# Code generated by Microsoft (R) AutoRest Code Generator. +# Changes may cause incorrect behavior and will be lost if the code is +# regenerated. +# -------------------------------------------------------------------------- + +from .events_result_data import EventsResultData + + +class EventsTraceResult(EventsResultData): + """A trace result. + + All required parameters must be populated in order to send to Azure. + + :param id: The unique ID for this event. + :type id: str + :param count: Count of the event + :type count: long + :param timestamp: Timestamp of the event + :type timestamp: datetime + :param custom_dimensions: Custom dimensions of the event + :type custom_dimensions: + ~azure.applicationinsights.query.models.EventsResultDataCustomDimensions + :param custom_measurements: Custom measurements of the event + :type custom_measurements: + ~azure.applicationinsights.query.models.EventsResultDataCustomMeasurements + :param operation: Operation info of the event + :type operation: + ~azure.applicationinsights.query.models.EventsOperationInfo + :param session: Session info of the event + :type session: ~azure.applicationinsights.query.models.EventsSessionInfo + :param user: User info of the event + :type user: ~azure.applicationinsights.query.models.EventsUserInfo + :param cloud: Cloud info of the event + :type cloud: ~azure.applicationinsights.query.models.EventsCloudInfo + :param ai: AI info of the event + :type ai: ~azure.applicationinsights.query.models.EventsAiInfo + :param application: Application info of the event + :type application: + ~azure.applicationinsights.query.models.EventsApplicationInfo + :param client: Client info of the event + :type client: ~azure.applicationinsights.query.models.EventsClientInfo + :param type: Required. Constant filled by server. + :type type: str + :param trace: + :type trace: ~azure.applicationinsights.query.models.EventsTraceInfo + """ + + _validation = { + 'type': {'required': True}, + } + + _attribute_map = { + 'id': {'key': 'id', 'type': 'str'}, + 'count': {'key': 'count', 'type': 'long'}, + 'timestamp': {'key': 'timestamp', 'type': 'iso-8601'}, + 'custom_dimensions': {'key': 'customDimensions', 'type': 'EventsResultDataCustomDimensions'}, + 'custom_measurements': {'key': 'customMeasurements', 'type': 'EventsResultDataCustomMeasurements'}, + 'operation': {'key': 'operation', 'type': 'EventsOperationInfo'}, + 'session': {'key': 'session', 'type': 'EventsSessionInfo'}, + 'user': {'key': 'user', 'type': 'EventsUserInfo'}, + 'cloud': {'key': 'cloud', 'type': 'EventsCloudInfo'}, + 'ai': {'key': 'ai', 'type': 'EventsAiInfo'}, + 'application': {'key': 'application', 'type': 'EventsApplicationInfo'}, + 'client': {'key': 'client', 'type': 'EventsClientInfo'}, + 'type': {'key': 'type', 'type': 'str'}, + 'trace': {'key': 'trace', 'type': 'EventsTraceInfo'}, + } + + def __init__(self, **kwargs): + super(EventsTraceResult, self).__init__(**kwargs) + self.trace = kwargs.get('trace', None) + self.type = 'trace' diff --git a/azure-applicationinsights-query/azure/applicationinsights/query/models/events_trace_result_py3.py b/azure-applicationinsights-query/azure/applicationinsights/query/models/events_trace_result_py3.py new file mode 100644 index 000000000000..681f33d29018 --- /dev/null +++ b/azure-applicationinsights-query/azure/applicationinsights/query/models/events_trace_result_py3.py @@ -0,0 +1,78 @@ +# coding=utf-8 +# -------------------------------------------------------------------------- +# Copyright (c) Microsoft Corporation. All rights reserved. +# Licensed under the MIT License. See License.txt in the project root for +# license information. +# +# Code generated by Microsoft (R) AutoRest Code Generator. +# Changes may cause incorrect behavior and will be lost if the code is +# regenerated. +# -------------------------------------------------------------------------- + +from .events_result_data_py3 import EventsResultData + + +class EventsTraceResult(EventsResultData): + """A trace result. + + All required parameters must be populated in order to send to Azure. + + :param id: The unique ID for this event. + :type id: str + :param count: Count of the event + :type count: long + :param timestamp: Timestamp of the event + :type timestamp: datetime + :param custom_dimensions: Custom dimensions of the event + :type custom_dimensions: + ~azure.applicationinsights.query.models.EventsResultDataCustomDimensions + :param custom_measurements: Custom measurements of the event + :type custom_measurements: + ~azure.applicationinsights.query.models.EventsResultDataCustomMeasurements + :param operation: Operation info of the event + :type operation: + ~azure.applicationinsights.query.models.EventsOperationInfo + :param session: Session info of the event + :type session: ~azure.applicationinsights.query.models.EventsSessionInfo + :param user: User info of the event + :type user: ~azure.applicationinsights.query.models.EventsUserInfo + :param cloud: Cloud info of the event + :type cloud: ~azure.applicationinsights.query.models.EventsCloudInfo + :param ai: AI info of the event + :type ai: ~azure.applicationinsights.query.models.EventsAiInfo + :param application: Application info of the event + :type application: + ~azure.applicationinsights.query.models.EventsApplicationInfo + :param client: Client info of the event + :type client: ~azure.applicationinsights.query.models.EventsClientInfo + :param type: Required. Constant filled by server. + :type type: str + :param trace: + :type trace: ~azure.applicationinsights.query.models.EventsTraceInfo + """ + + _validation = { + 'type': {'required': True}, + } + + _attribute_map = { + 'id': {'key': 'id', 'type': 'str'}, + 'count': {'key': 'count', 'type': 'long'}, + 'timestamp': {'key': 'timestamp', 'type': 'iso-8601'}, + 'custom_dimensions': {'key': 'customDimensions', 'type': 'EventsResultDataCustomDimensions'}, + 'custom_measurements': {'key': 'customMeasurements', 'type': 'EventsResultDataCustomMeasurements'}, + 'operation': {'key': 'operation', 'type': 'EventsOperationInfo'}, + 'session': {'key': 'session', 'type': 'EventsSessionInfo'}, + 'user': {'key': 'user', 'type': 'EventsUserInfo'}, + 'cloud': {'key': 'cloud', 'type': 'EventsCloudInfo'}, + 'ai': {'key': 'ai', 'type': 'EventsAiInfo'}, + 'application': {'key': 'application', 'type': 'EventsApplicationInfo'}, + 'client': {'key': 'client', 'type': 'EventsClientInfo'}, + 'type': {'key': 'type', 'type': 'str'}, + 'trace': {'key': 'trace', 'type': 'EventsTraceInfo'}, + } + + def __init__(self, *, id: str=None, count: int=None, timestamp=None, custom_dimensions=None, custom_measurements=None, operation=None, session=None, user=None, cloud=None, ai=None, application=None, client=None, trace=None, **kwargs) -> None: + super(EventsTraceResult, self).__init__(id=id, count=count, timestamp=timestamp, custom_dimensions=custom_dimensions, custom_measurements=custom_measurements, operation=operation, session=session, user=user, cloud=cloud, ai=ai, application=application, client=client, **kwargs) + self.trace = trace + self.type = 'trace' diff --git a/azure-applicationinsights-query/azure/applicationinsights/query/models/events_user_info.py b/azure-applicationinsights-query/azure/applicationinsights/query/models/events_user_info.py new file mode 100644 index 000000000000..a5753b1a30ff --- /dev/null +++ b/azure-applicationinsights-query/azure/applicationinsights/query/models/events_user_info.py @@ -0,0 +1,36 @@ +# coding=utf-8 +# -------------------------------------------------------------------------- +# Copyright (c) Microsoft Corporation. All rights reserved. +# Licensed under the MIT License. See License.txt in the project root for +# license information. +# +# Code generated by Microsoft (R) AutoRest Code Generator. +# Changes may cause incorrect behavior and will be lost if the code is +# regenerated. +# -------------------------------------------------------------------------- + +from msrest.serialization import Model + + +class EventsUserInfo(Model): + """User info for an event result. + + :param id: ID of the user + :type id: str + :param account_id: Account ID of the user + :type account_id: str + :param authenticated_id: Authenticated ID of the user + :type authenticated_id: str + """ + + _attribute_map = { + 'id': {'key': 'id', 'type': 'str'}, + 'account_id': {'key': 'accountId', 'type': 'str'}, + 'authenticated_id': {'key': 'authenticatedId', 'type': 'str'}, + } + + def __init__(self, **kwargs): + super(EventsUserInfo, self).__init__(**kwargs) + self.id = kwargs.get('id', None) + self.account_id = kwargs.get('account_id', None) + self.authenticated_id = kwargs.get('authenticated_id', None) diff --git a/azure-applicationinsights-query/azure/applicationinsights/query/models/events_user_info_py3.py b/azure-applicationinsights-query/azure/applicationinsights/query/models/events_user_info_py3.py new file mode 100644 index 000000000000..910dbb4c3b3d --- /dev/null +++ b/azure-applicationinsights-query/azure/applicationinsights/query/models/events_user_info_py3.py @@ -0,0 +1,36 @@ +# coding=utf-8 +# -------------------------------------------------------------------------- +# Copyright (c) Microsoft Corporation. All rights reserved. +# Licensed under the MIT License. See License.txt in the project root for +# license information. +# +# Code generated by Microsoft (R) AutoRest Code Generator. +# Changes may cause incorrect behavior and will be lost if the code is +# regenerated. +# -------------------------------------------------------------------------- + +from msrest.serialization import Model + + +class EventsUserInfo(Model): + """User info for an event result. + + :param id: ID of the user + :type id: str + :param account_id: Account ID of the user + :type account_id: str + :param authenticated_id: Authenticated ID of the user + :type authenticated_id: str + """ + + _attribute_map = { + 'id': {'key': 'id', 'type': 'str'}, + 'account_id': {'key': 'accountId', 'type': 'str'}, + 'authenticated_id': {'key': 'authenticatedId', 'type': 'str'}, + } + + def __init__(self, *, id: str=None, account_id: str=None, authenticated_id: str=None, **kwargs) -> None: + super(EventsUserInfo, self).__init__(**kwargs) + self.id = id + self.account_id = account_id + self.authenticated_id = authenticated_id diff --git a/azure-applicationinsights-query/azure/applicationinsights/query/models/metrics_post_body_schema.py b/azure-applicationinsights-query/azure/applicationinsights/query/models/metrics_post_body_schema.py new file mode 100644 index 000000000000..130ecf0ba8c3 --- /dev/null +++ b/azure-applicationinsights-query/azure/applicationinsights/query/models/metrics_post_body_schema.py @@ -0,0 +1,42 @@ +# coding=utf-8 +# -------------------------------------------------------------------------- +# Copyright (c) Microsoft Corporation. All rights reserved. +# Licensed under the MIT License. See License.txt in the project root for +# license information. +# +# Code generated by Microsoft (R) AutoRest Code Generator. +# Changes may cause incorrect behavior and will be lost if the code is +# regenerated. +# -------------------------------------------------------------------------- + +from msrest.serialization import Model + + +class MetricsPostBodySchema(Model): + """A metric request. + + All required parameters must be populated in order to send to Azure. + + :param id: Required. An identifier for this query. Must be unique within + the post body of the request. This identifier will be the 'id' property + of the response object representing this query. + :type id: str + :param parameters: Required. The parameters for a single metrics query + :type parameters: + ~azure.applicationinsights.query.models.MetricsPostBodySchemaParameters + """ + + _validation = { + 'id': {'required': True}, + 'parameters': {'required': True}, + } + + _attribute_map = { + 'id': {'key': 'id', 'type': 'str'}, + 'parameters': {'key': 'parameters', 'type': 'MetricsPostBodySchemaParameters'}, + } + + def __init__(self, **kwargs): + super(MetricsPostBodySchema, self).__init__(**kwargs) + self.id = kwargs.get('id', None) + self.parameters = kwargs.get('parameters', None) diff --git a/azure-applicationinsights-query/azure/applicationinsights/query/models/metrics_post_body_schema_parameters.py b/azure-applicationinsights-query/azure/applicationinsights/query/models/metrics_post_body_schema_parameters.py new file mode 100644 index 000000000000..2431f9a36184 --- /dev/null +++ b/azure-applicationinsights-query/azure/applicationinsights/query/models/metrics_post_body_schema_parameters.py @@ -0,0 +1,82 @@ +# coding=utf-8 +# -------------------------------------------------------------------------- +# Copyright (c) Microsoft Corporation. All rights reserved. +# Licensed under the MIT License. See License.txt in the project root for +# license information. +# +# Code generated by Microsoft (R) AutoRest Code Generator. +# Changes may cause incorrect behavior and will be lost if the code is +# regenerated. +# -------------------------------------------------------------------------- + +from msrest.serialization import Model + + +class MetricsPostBodySchemaParameters(Model): + """The parameters for a single metrics query. + + All required parameters must be populated in order to send to Azure. + + :param metric_id: Required. Possible values include: 'requests/count', + 'requests/duration', 'requests/failed', 'users/count', + 'users/authenticated', 'pageViews/count', 'pageViews/duration', + 'client/processingDuration', 'client/receiveDuration', + 'client/networkDuration', 'client/sendDuration', 'client/totalDuration', + 'dependencies/count', 'dependencies/failed', 'dependencies/duration', + 'exceptions/count', 'exceptions/browser', 'exceptions/server', + 'sessions/count', 'performanceCounters/requestExecutionTime', + 'performanceCounters/requestsPerSecond', + 'performanceCounters/requestsInQueue', + 'performanceCounters/memoryAvailableBytes', + 'performanceCounters/exceptionsPerSecond', + 'performanceCounters/processCpuPercentage', + 'performanceCounters/processIOBytesPerSecond', + 'performanceCounters/processPrivateBytes', + 'performanceCounters/processorCpuPercentage', + 'availabilityResults/availabilityPercentage', + 'availabilityResults/duration', 'billing/telemetryCount', + 'customEvents/count' + :type metric_id: str or ~azure.applicationinsights.query.models.MetricId + :param timespan: + :type timespan: str + :param aggregation: + :type aggregation: list[str or + ~azure.applicationinsights.query.models.MetricsAggregation] + :param interval: + :type interval: timedelta + :param segment: + :type segment: list[str or + ~azure.applicationinsights.query.models.MetricsSegment] + :param top: + :type top: int + :param orderby: + :type orderby: str + :param filter: + :type filter: str + """ + + _validation = { + 'metric_id': {'required': True}, + } + + _attribute_map = { + 'metric_id': {'key': 'metricId', 'type': 'str'}, + 'timespan': {'key': 'timespan', 'type': 'str'}, + 'aggregation': {'key': 'aggregation', 'type': '[str]'}, + 'interval': {'key': 'interval', 'type': 'duration'}, + 'segment': {'key': 'segment', 'type': '[str]'}, + 'top': {'key': 'top', 'type': 'int'}, + 'orderby': {'key': 'orderby', 'type': 'str'}, + 'filter': {'key': 'filter', 'type': 'str'}, + } + + def __init__(self, **kwargs): + super(MetricsPostBodySchemaParameters, self).__init__(**kwargs) + self.metric_id = kwargs.get('metric_id', None) + self.timespan = kwargs.get('timespan', None) + self.aggregation = kwargs.get('aggregation', None) + self.interval = kwargs.get('interval', None) + self.segment = kwargs.get('segment', None) + self.top = kwargs.get('top', None) + self.orderby = kwargs.get('orderby', None) + self.filter = kwargs.get('filter', None) diff --git a/azure-applicationinsights-query/azure/applicationinsights/query/models/metrics_post_body_schema_parameters_py3.py b/azure-applicationinsights-query/azure/applicationinsights/query/models/metrics_post_body_schema_parameters_py3.py new file mode 100644 index 000000000000..7329e3052166 --- /dev/null +++ b/azure-applicationinsights-query/azure/applicationinsights/query/models/metrics_post_body_schema_parameters_py3.py @@ -0,0 +1,82 @@ +# coding=utf-8 +# -------------------------------------------------------------------------- +# Copyright (c) Microsoft Corporation. All rights reserved. +# Licensed under the MIT License. See License.txt in the project root for +# license information. +# +# Code generated by Microsoft (R) AutoRest Code Generator. +# Changes may cause incorrect behavior and will be lost if the code is +# regenerated. +# -------------------------------------------------------------------------- + +from msrest.serialization import Model + + +class MetricsPostBodySchemaParameters(Model): + """The parameters for a single metrics query. + + All required parameters must be populated in order to send to Azure. + + :param metric_id: Required. Possible values include: 'requests/count', + 'requests/duration', 'requests/failed', 'users/count', + 'users/authenticated', 'pageViews/count', 'pageViews/duration', + 'client/processingDuration', 'client/receiveDuration', + 'client/networkDuration', 'client/sendDuration', 'client/totalDuration', + 'dependencies/count', 'dependencies/failed', 'dependencies/duration', + 'exceptions/count', 'exceptions/browser', 'exceptions/server', + 'sessions/count', 'performanceCounters/requestExecutionTime', + 'performanceCounters/requestsPerSecond', + 'performanceCounters/requestsInQueue', + 'performanceCounters/memoryAvailableBytes', + 'performanceCounters/exceptionsPerSecond', + 'performanceCounters/processCpuPercentage', + 'performanceCounters/processIOBytesPerSecond', + 'performanceCounters/processPrivateBytes', + 'performanceCounters/processorCpuPercentage', + 'availabilityResults/availabilityPercentage', + 'availabilityResults/duration', 'billing/telemetryCount', + 'customEvents/count' + :type metric_id: str or ~azure.applicationinsights.query.models.MetricId + :param timespan: + :type timespan: str + :param aggregation: + :type aggregation: list[str or + ~azure.applicationinsights.query.models.MetricsAggregation] + :param interval: + :type interval: timedelta + :param segment: + :type segment: list[str or + ~azure.applicationinsights.query.models.MetricsSegment] + :param top: + :type top: int + :param orderby: + :type orderby: str + :param filter: + :type filter: str + """ + + _validation = { + 'metric_id': {'required': True}, + } + + _attribute_map = { + 'metric_id': {'key': 'metricId', 'type': 'str'}, + 'timespan': {'key': 'timespan', 'type': 'str'}, + 'aggregation': {'key': 'aggregation', 'type': '[str]'}, + 'interval': {'key': 'interval', 'type': 'duration'}, + 'segment': {'key': 'segment', 'type': '[str]'}, + 'top': {'key': 'top', 'type': 'int'}, + 'orderby': {'key': 'orderby', 'type': 'str'}, + 'filter': {'key': 'filter', 'type': 'str'}, + } + + def __init__(self, *, metric_id, timespan: str=None, aggregation=None, interval=None, segment=None, top: int=None, orderby: str=None, filter: str=None, **kwargs) -> None: + super(MetricsPostBodySchemaParameters, self).__init__(**kwargs) + self.metric_id = metric_id + self.timespan = timespan + self.aggregation = aggregation + self.interval = interval + self.segment = segment + self.top = top + self.orderby = orderby + self.filter = filter diff --git a/azure-applicationinsights-query/azure/applicationinsights/query/models/metrics_post_body_schema_py3.py b/azure-applicationinsights-query/azure/applicationinsights/query/models/metrics_post_body_schema_py3.py new file mode 100644 index 000000000000..0a4fe848984b --- /dev/null +++ b/azure-applicationinsights-query/azure/applicationinsights/query/models/metrics_post_body_schema_py3.py @@ -0,0 +1,42 @@ +# coding=utf-8 +# -------------------------------------------------------------------------- +# Copyright (c) Microsoft Corporation. All rights reserved. +# Licensed under the MIT License. See License.txt in the project root for +# license information. +# +# Code generated by Microsoft (R) AutoRest Code Generator. +# Changes may cause incorrect behavior and will be lost if the code is +# regenerated. +# -------------------------------------------------------------------------- + +from msrest.serialization import Model + + +class MetricsPostBodySchema(Model): + """A metric request. + + All required parameters must be populated in order to send to Azure. + + :param id: Required. An identifier for this query. Must be unique within + the post body of the request. This identifier will be the 'id' property + of the response object representing this query. + :type id: str + :param parameters: Required. The parameters for a single metrics query + :type parameters: + ~azure.applicationinsights.query.models.MetricsPostBodySchemaParameters + """ + + _validation = { + 'id': {'required': True}, + 'parameters': {'required': True}, + } + + _attribute_map = { + 'id': {'key': 'id', 'type': 'str'}, + 'parameters': {'key': 'parameters', 'type': 'MetricsPostBodySchemaParameters'}, + } + + def __init__(self, *, id: str, parameters, **kwargs) -> None: + super(MetricsPostBodySchema, self).__init__(**kwargs) + self.id = id + self.parameters = parameters diff --git a/azure-applicationinsights-query/azure/applicationinsights/query/models/metrics_result.py b/azure-applicationinsights-query/azure/applicationinsights/query/models/metrics_result.py new file mode 100644 index 000000000000..6c8de065aa0f --- /dev/null +++ b/azure-applicationinsights-query/azure/applicationinsights/query/models/metrics_result.py @@ -0,0 +1,28 @@ +# coding=utf-8 +# -------------------------------------------------------------------------- +# Copyright (c) Microsoft Corporation. All rights reserved. +# Licensed under the MIT License. See License.txt in the project root for +# license information. +# +# Code generated by Microsoft (R) AutoRest Code Generator. +# Changes may cause incorrect behavior and will be lost if the code is +# regenerated. +# -------------------------------------------------------------------------- + +from msrest.serialization import Model + + +class MetricsResult(Model): + """A metric result. + + :param value: + :type value: ~azure.applicationinsights.query.models.MetricsResultInfo + """ + + _attribute_map = { + 'value': {'key': 'value', 'type': 'MetricsResultInfo'}, + } + + def __init__(self, **kwargs): + super(MetricsResult, self).__init__(**kwargs) + self.value = kwargs.get('value', None) diff --git a/azure-applicationinsights-query/azure/applicationinsights/query/models/metrics_result_info.py b/azure-applicationinsights-query/azure/applicationinsights/query/models/metrics_result_info.py new file mode 100644 index 000000000000..69f9b4ca3861 --- /dev/null +++ b/azure-applicationinsights-query/azure/applicationinsights/query/models/metrics_result_info.py @@ -0,0 +1,46 @@ +# coding=utf-8 +# -------------------------------------------------------------------------- +# Copyright (c) Microsoft Corporation. All rights reserved. +# Licensed under the MIT License. See License.txt in the project root for +# license information. +# +# Code generated by Microsoft (R) AutoRest Code Generator. +# Changes may cause incorrect behavior and will be lost if the code is +# regenerated. +# -------------------------------------------------------------------------- + +from msrest.serialization import Model + + +class MetricsResultInfo(Model): + """A metric result data. + + :param additional_properties: Unmatched properties from the message are + deserialized this collection + :type additional_properties: dict[str, object] + :param start: Start time of the metric. + :type start: datetime + :param end: Start time of the metric. + :type end: datetime + :param interval: The interval used to segment the metric data. + :type interval: timedelta + :param segments: Segmented metric data (if segmented). + :type segments: + list[~azure.applicationinsights.query.models.MetricsSegmentInfo] + """ + + _attribute_map = { + 'additional_properties': {'key': '', 'type': '{object}'}, + 'start': {'key': 'start', 'type': 'iso-8601'}, + 'end': {'key': 'end', 'type': 'iso-8601'}, + 'interval': {'key': 'interval', 'type': 'duration'}, + 'segments': {'key': 'segments', 'type': '[MetricsSegmentInfo]'}, + } + + def __init__(self, **kwargs): + super(MetricsResultInfo, self).__init__(**kwargs) + self.additional_properties = kwargs.get('additional_properties', None) + self.start = kwargs.get('start', None) + self.end = kwargs.get('end', None) + self.interval = kwargs.get('interval', None) + self.segments = kwargs.get('segments', None) diff --git a/azure-applicationinsights-query/azure/applicationinsights/query/models/metrics_result_info_py3.py b/azure-applicationinsights-query/azure/applicationinsights/query/models/metrics_result_info_py3.py new file mode 100644 index 000000000000..e4005451e9b6 --- /dev/null +++ b/azure-applicationinsights-query/azure/applicationinsights/query/models/metrics_result_info_py3.py @@ -0,0 +1,46 @@ +# coding=utf-8 +# -------------------------------------------------------------------------- +# Copyright (c) Microsoft Corporation. All rights reserved. +# Licensed under the MIT License. See License.txt in the project root for +# license information. +# +# Code generated by Microsoft (R) AutoRest Code Generator. +# Changes may cause incorrect behavior and will be lost if the code is +# regenerated. +# -------------------------------------------------------------------------- + +from msrest.serialization import Model + + +class MetricsResultInfo(Model): + """A metric result data. + + :param additional_properties: Unmatched properties from the message are + deserialized this collection + :type additional_properties: dict[str, object] + :param start: Start time of the metric. + :type start: datetime + :param end: Start time of the metric. + :type end: datetime + :param interval: The interval used to segment the metric data. + :type interval: timedelta + :param segments: Segmented metric data (if segmented). + :type segments: + list[~azure.applicationinsights.query.models.MetricsSegmentInfo] + """ + + _attribute_map = { + 'additional_properties': {'key': '', 'type': '{object}'}, + 'start': {'key': 'start', 'type': 'iso-8601'}, + 'end': {'key': 'end', 'type': 'iso-8601'}, + 'interval': {'key': 'interval', 'type': 'duration'}, + 'segments': {'key': 'segments', 'type': '[MetricsSegmentInfo]'}, + } + + def __init__(self, *, additional_properties=None, start=None, end=None, interval=None, segments=None, **kwargs) -> None: + super(MetricsResultInfo, self).__init__(**kwargs) + self.additional_properties = additional_properties + self.start = start + self.end = end + self.interval = interval + self.segments = segments diff --git a/azure-applicationinsights-query/azure/applicationinsights/query/models/metrics_result_py3.py b/azure-applicationinsights-query/azure/applicationinsights/query/models/metrics_result_py3.py new file mode 100644 index 000000000000..caad749117bf --- /dev/null +++ b/azure-applicationinsights-query/azure/applicationinsights/query/models/metrics_result_py3.py @@ -0,0 +1,28 @@ +# coding=utf-8 +# -------------------------------------------------------------------------- +# Copyright (c) Microsoft Corporation. All rights reserved. +# Licensed under the MIT License. See License.txt in the project root for +# license information. +# +# Code generated by Microsoft (R) AutoRest Code Generator. +# Changes may cause incorrect behavior and will be lost if the code is +# regenerated. +# -------------------------------------------------------------------------- + +from msrest.serialization import Model + + +class MetricsResult(Model): + """A metric result. + + :param value: + :type value: ~azure.applicationinsights.query.models.MetricsResultInfo + """ + + _attribute_map = { + 'value': {'key': 'value', 'type': 'MetricsResultInfo'}, + } + + def __init__(self, *, value=None, **kwargs) -> None: + super(MetricsResult, self).__init__(**kwargs) + self.value = value diff --git a/azure-applicationinsights-query/azure/applicationinsights/query/models/metrics_results_item.py b/azure-applicationinsights-query/azure/applicationinsights/query/models/metrics_results_item.py new file mode 100644 index 000000000000..05367f7646cf --- /dev/null +++ b/azure-applicationinsights-query/azure/applicationinsights/query/models/metrics_results_item.py @@ -0,0 +1,44 @@ +# coding=utf-8 +# -------------------------------------------------------------------------- +# Copyright (c) Microsoft Corporation. All rights reserved. +# Licensed under the MIT License. See License.txt in the project root for +# license information. +# +# Code generated by Microsoft (R) AutoRest Code Generator. +# Changes may cause incorrect behavior and will be lost if the code is +# regenerated. +# -------------------------------------------------------------------------- + +from msrest.serialization import Model + + +class MetricsResultsItem(Model): + """MetricsResultsItem. + + All required parameters must be populated in order to send to Azure. + + :param id: Required. The specified ID for this metric. + :type id: str + :param status: Required. The HTTP status code of this metric query. + :type status: int + :param body: Required. The results of this metric query. + :type body: ~azure.applicationinsights.query.models.MetricsResult + """ + + _validation = { + 'id': {'required': True}, + 'status': {'required': True}, + 'body': {'required': True}, + } + + _attribute_map = { + 'id': {'key': 'id', 'type': 'str'}, + 'status': {'key': 'status', 'type': 'int'}, + 'body': {'key': 'body', 'type': 'MetricsResult'}, + } + + def __init__(self, **kwargs): + super(MetricsResultsItem, self).__init__(**kwargs) + self.id = kwargs.get('id', None) + self.status = kwargs.get('status', None) + self.body = kwargs.get('body', None) diff --git a/azure-applicationinsights-query/azure/applicationinsights/query/models/metrics_results_item_py3.py b/azure-applicationinsights-query/azure/applicationinsights/query/models/metrics_results_item_py3.py new file mode 100644 index 000000000000..69d079f49b10 --- /dev/null +++ b/azure-applicationinsights-query/azure/applicationinsights/query/models/metrics_results_item_py3.py @@ -0,0 +1,44 @@ +# coding=utf-8 +# -------------------------------------------------------------------------- +# Copyright (c) Microsoft Corporation. All rights reserved. +# Licensed under the MIT License. See License.txt in the project root for +# license information. +# +# Code generated by Microsoft (R) AutoRest Code Generator. +# Changes may cause incorrect behavior and will be lost if the code is +# regenerated. +# -------------------------------------------------------------------------- + +from msrest.serialization import Model + + +class MetricsResultsItem(Model): + """MetricsResultsItem. + + All required parameters must be populated in order to send to Azure. + + :param id: Required. The specified ID for this metric. + :type id: str + :param status: Required. The HTTP status code of this metric query. + :type status: int + :param body: Required. The results of this metric query. + :type body: ~azure.applicationinsights.query.models.MetricsResult + """ + + _validation = { + 'id': {'required': True}, + 'status': {'required': True}, + 'body': {'required': True}, + } + + _attribute_map = { + 'id': {'key': 'id', 'type': 'str'}, + 'status': {'key': 'status', 'type': 'int'}, + 'body': {'key': 'body', 'type': 'MetricsResult'}, + } + + def __init__(self, *, id: str, status: int, body, **kwargs) -> None: + super(MetricsResultsItem, self).__init__(**kwargs) + self.id = id + self.status = status + self.body = body diff --git a/azure-applicationinsights-query/azure/applicationinsights/query/models/metrics_segment_info.py b/azure-applicationinsights-query/azure/applicationinsights/query/models/metrics_segment_info.py new file mode 100644 index 000000000000..9fc5d23a86d1 --- /dev/null +++ b/azure-applicationinsights-query/azure/applicationinsights/query/models/metrics_segment_info.py @@ -0,0 +1,44 @@ +# coding=utf-8 +# -------------------------------------------------------------------------- +# Copyright (c) Microsoft Corporation. All rights reserved. +# Licensed under the MIT License. See License.txt in the project root for +# license information. +# +# Code generated by Microsoft (R) AutoRest Code Generator. +# Changes may cause incorrect behavior and will be lost if the code is +# regenerated. +# -------------------------------------------------------------------------- + +from msrest.serialization import Model + + +class MetricsSegmentInfo(Model): + """A metric segment. + + :param additional_properties: Unmatched properties from the message are + deserialized this collection + :type additional_properties: dict[str, object] + :param start: Start time of the metric segment (only when an interval was + specified). + :type start: datetime + :param end: Start time of the metric segment (only when an interval was + specified). + :type end: datetime + :param segments: Segmented metric data (if further segmented). + :type segments: + list[~azure.applicationinsights.query.models.MetricsSegmentInfo] + """ + + _attribute_map = { + 'additional_properties': {'key': '', 'type': '{object}'}, + 'start': {'key': 'start', 'type': 'iso-8601'}, + 'end': {'key': 'end', 'type': 'iso-8601'}, + 'segments': {'key': 'segments', 'type': '[MetricsSegmentInfo]'}, + } + + def __init__(self, **kwargs): + super(MetricsSegmentInfo, self).__init__(**kwargs) + self.additional_properties = kwargs.get('additional_properties', None) + self.start = kwargs.get('start', None) + self.end = kwargs.get('end', None) + self.segments = kwargs.get('segments', None) diff --git a/azure-applicationinsights-query/azure/applicationinsights/query/models/metrics_segment_info_py3.py b/azure-applicationinsights-query/azure/applicationinsights/query/models/metrics_segment_info_py3.py new file mode 100644 index 000000000000..0fa80b9df930 --- /dev/null +++ b/azure-applicationinsights-query/azure/applicationinsights/query/models/metrics_segment_info_py3.py @@ -0,0 +1,44 @@ +# coding=utf-8 +# -------------------------------------------------------------------------- +# Copyright (c) Microsoft Corporation. All rights reserved. +# Licensed under the MIT License. See License.txt in the project root for +# license information. +# +# Code generated by Microsoft (R) AutoRest Code Generator. +# Changes may cause incorrect behavior and will be lost if the code is +# regenerated. +# -------------------------------------------------------------------------- + +from msrest.serialization import Model + + +class MetricsSegmentInfo(Model): + """A metric segment. + + :param additional_properties: Unmatched properties from the message are + deserialized this collection + :type additional_properties: dict[str, object] + :param start: Start time of the metric segment (only when an interval was + specified). + :type start: datetime + :param end: Start time of the metric segment (only when an interval was + specified). + :type end: datetime + :param segments: Segmented metric data (if further segmented). + :type segments: + list[~azure.applicationinsights.query.models.MetricsSegmentInfo] + """ + + _attribute_map = { + 'additional_properties': {'key': '', 'type': '{object}'}, + 'start': {'key': 'start', 'type': 'iso-8601'}, + 'end': {'key': 'end', 'type': 'iso-8601'}, + 'segments': {'key': 'segments', 'type': '[MetricsSegmentInfo]'}, + } + + def __init__(self, *, additional_properties=None, start=None, end=None, segments=None, **kwargs) -> None: + super(MetricsSegmentInfo, self).__init__(**kwargs) + self.additional_properties = additional_properties + self.start = start + self.end = end + self.segments = segments diff --git a/azure-applicationinsights-query/azure/applicationinsights/query/models/query_body.py b/azure-applicationinsights-query/azure/applicationinsights/query/models/query_body.py new file mode 100644 index 000000000000..7c140d71d81d --- /dev/null +++ b/azure-applicationinsights-query/azure/applicationinsights/query/models/query_body.py @@ -0,0 +1,46 @@ +# coding=utf-8 +# -------------------------------------------------------------------------- +# Copyright (c) Microsoft Corporation. All rights reserved. +# Licensed under the MIT License. See License.txt in the project root for +# license information. +# +# Code generated by Microsoft (R) AutoRest Code Generator. +# Changes may cause incorrect behavior and will be lost if the code is +# regenerated. +# -------------------------------------------------------------------------- + +from msrest.serialization import Model + + +class QueryBody(Model): + """The Analytics query. Learn more about the [Analytics query + syntax](https://azure.microsoft.com/documentation/articles/app-insights-analytics-reference/). + + All required parameters must be populated in order to send to Azure. + + :param query: Required. The query to execute. + :type query: str + :param timespan: Optional. The timespan over which to query data. This is + an ISO8601 time period value. This timespan is applied in addition to any + that are specified in the query expression. + :type timespan: str + :param applications: A list of Application IDs for cross-application + queries. + :type applications: list[str] + """ + + _validation = { + 'query': {'required': True}, + } + + _attribute_map = { + 'query': {'key': 'query', 'type': 'str'}, + 'timespan': {'key': 'timespan', 'type': 'str'}, + 'applications': {'key': 'applications', 'type': '[str]'}, + } + + def __init__(self, **kwargs): + super(QueryBody, self).__init__(**kwargs) + self.query = kwargs.get('query', None) + self.timespan = kwargs.get('timespan', None) + self.applications = kwargs.get('applications', None) diff --git a/azure-applicationinsights-query/azure/applicationinsights/query/models/query_body_py3.py b/azure-applicationinsights-query/azure/applicationinsights/query/models/query_body_py3.py new file mode 100644 index 000000000000..4e718edc98a3 --- /dev/null +++ b/azure-applicationinsights-query/azure/applicationinsights/query/models/query_body_py3.py @@ -0,0 +1,46 @@ +# coding=utf-8 +# -------------------------------------------------------------------------- +# Copyright (c) Microsoft Corporation. All rights reserved. +# Licensed under the MIT License. See License.txt in the project root for +# license information. +# +# Code generated by Microsoft (R) AutoRest Code Generator. +# Changes may cause incorrect behavior and will be lost if the code is +# regenerated. +# -------------------------------------------------------------------------- + +from msrest.serialization import Model + + +class QueryBody(Model): + """The Analytics query. Learn more about the [Analytics query + syntax](https://azure.microsoft.com/documentation/articles/app-insights-analytics-reference/). + + All required parameters must be populated in order to send to Azure. + + :param query: Required. The query to execute. + :type query: str + :param timespan: Optional. The timespan over which to query data. This is + an ISO8601 time period value. This timespan is applied in addition to any + that are specified in the query expression. + :type timespan: str + :param applications: A list of Application IDs for cross-application + queries. + :type applications: list[str] + """ + + _validation = { + 'query': {'required': True}, + } + + _attribute_map = { + 'query': {'key': 'query', 'type': 'str'}, + 'timespan': {'key': 'timespan', 'type': 'str'}, + 'applications': {'key': 'applications', 'type': '[str]'}, + } + + def __init__(self, *, query: str, timespan: str=None, applications=None, **kwargs) -> None: + super(QueryBody, self).__init__(**kwargs) + self.query = query + self.timespan = timespan + self.applications = applications diff --git a/azure-applicationinsights-query/azure/applicationinsights/query/models/query_results.py b/azure-applicationinsights-query/azure/applicationinsights/query/models/query_results.py new file mode 100644 index 000000000000..e2f709b3bbb7 --- /dev/null +++ b/azure-applicationinsights-query/azure/applicationinsights/query/models/query_results.py @@ -0,0 +1,36 @@ +# coding=utf-8 +# -------------------------------------------------------------------------- +# Copyright (c) Microsoft Corporation. All rights reserved. +# Licensed under the MIT License. See License.txt in the project root for +# license information. +# +# Code generated by Microsoft (R) AutoRest Code Generator. +# Changes may cause incorrect behavior and will be lost if the code is +# regenerated. +# -------------------------------------------------------------------------- + +from msrest.serialization import Model + + +class QueryResults(Model): + """A query response. + + Contains the tables, columns & rows resulting from a query. + + All required parameters must be populated in order to send to Azure. + + :param tables: Required. The list of tables, columns and rows. + :type tables: list[~azure.applicationinsights.query.models.Table] + """ + + _validation = { + 'tables': {'required': True}, + } + + _attribute_map = { + 'tables': {'key': 'tables', 'type': '[Table]'}, + } + + def __init__(self, **kwargs): + super(QueryResults, self).__init__(**kwargs) + self.tables = kwargs.get('tables', None) diff --git a/azure-applicationinsights-query/azure/applicationinsights/query/models/query_results_py3.py b/azure-applicationinsights-query/azure/applicationinsights/query/models/query_results_py3.py new file mode 100644 index 000000000000..eb60942e72d9 --- /dev/null +++ b/azure-applicationinsights-query/azure/applicationinsights/query/models/query_results_py3.py @@ -0,0 +1,36 @@ +# coding=utf-8 +# -------------------------------------------------------------------------- +# Copyright (c) Microsoft Corporation. All rights reserved. +# Licensed under the MIT License. See License.txt in the project root for +# license information. +# +# Code generated by Microsoft (R) AutoRest Code Generator. +# Changes may cause incorrect behavior and will be lost if the code is +# regenerated. +# -------------------------------------------------------------------------- + +from msrest.serialization import Model + + +class QueryResults(Model): + """A query response. + + Contains the tables, columns & rows resulting from a query. + + All required parameters must be populated in order to send to Azure. + + :param tables: Required. The list of tables, columns and rows. + :type tables: list[~azure.applicationinsights.query.models.Table] + """ + + _validation = { + 'tables': {'required': True}, + } + + _attribute_map = { + 'tables': {'key': 'tables', 'type': '[Table]'}, + } + + def __init__(self, *, tables, **kwargs) -> None: + super(QueryResults, self).__init__(**kwargs) + self.tables = tables diff --git a/azure-applicationinsights-query/azure/applicationinsights/query/models/table.py b/azure-applicationinsights-query/azure/applicationinsights/query/models/table.py new file mode 100644 index 000000000000..8dfb68e9a880 --- /dev/null +++ b/azure-applicationinsights-query/azure/applicationinsights/query/models/table.py @@ -0,0 +1,46 @@ +# coding=utf-8 +# -------------------------------------------------------------------------- +# Copyright (c) Microsoft Corporation. All rights reserved. +# Licensed under the MIT License. See License.txt in the project root for +# license information. +# +# Code generated by Microsoft (R) AutoRest Code Generator. +# Changes may cause incorrect behavior and will be lost if the code is +# regenerated. +# -------------------------------------------------------------------------- + +from msrest.serialization import Model + + +class Table(Model): + """A query response table. + + Contains the columns and rows for one table in a query response. + + All required parameters must be populated in order to send to Azure. + + :param name: Required. The name of the table. + :type name: str + :param columns: Required. The list of columns in this table. + :type columns: list[~azure.applicationinsights.query.models.Column] + :param rows: Required. The resulting rows from this query. + :type rows: list[list[object]] + """ + + _validation = { + 'name': {'required': True}, + 'columns': {'required': True}, + 'rows': {'required': True}, + } + + _attribute_map = { + 'name': {'key': 'name', 'type': 'str'}, + 'columns': {'key': 'columns', 'type': '[Column]'}, + 'rows': {'key': 'rows', 'type': '[[object]]'}, + } + + def __init__(self, **kwargs): + super(Table, self).__init__(**kwargs) + self.name = kwargs.get('name', None) + self.columns = kwargs.get('columns', None) + self.rows = kwargs.get('rows', None) diff --git a/azure-applicationinsights-query/azure/applicationinsights/query/models/table_py3.py b/azure-applicationinsights-query/azure/applicationinsights/query/models/table_py3.py new file mode 100644 index 000000000000..d829ede6f2b1 --- /dev/null +++ b/azure-applicationinsights-query/azure/applicationinsights/query/models/table_py3.py @@ -0,0 +1,46 @@ +# coding=utf-8 +# -------------------------------------------------------------------------- +# Copyright (c) Microsoft Corporation. All rights reserved. +# Licensed under the MIT License. See License.txt in the project root for +# license information. +# +# Code generated by Microsoft (R) AutoRest Code Generator. +# Changes may cause incorrect behavior and will be lost if the code is +# regenerated. +# -------------------------------------------------------------------------- + +from msrest.serialization import Model + + +class Table(Model): + """A query response table. + + Contains the columns and rows for one table in a query response. + + All required parameters must be populated in order to send to Azure. + + :param name: Required. The name of the table. + :type name: str + :param columns: Required. The list of columns in this table. + :type columns: list[~azure.applicationinsights.query.models.Column] + :param rows: Required. The resulting rows from this query. + :type rows: list[list[object]] + """ + + _validation = { + 'name': {'required': True}, + 'columns': {'required': True}, + 'rows': {'required': True}, + } + + _attribute_map = { + 'name': {'key': 'name', 'type': 'str'}, + 'columns': {'key': 'columns', 'type': '[Column]'}, + 'rows': {'key': 'rows', 'type': '[[object]]'}, + } + + def __init__(self, *, name: str, columns, rows, **kwargs) -> None: + super(Table, self).__init__(**kwargs) + self.name = name + self.columns = columns + self.rows = rows diff --git a/azure-applicationinsights-query/azure/applicationinsights/query/operations/__init__.py b/azure-applicationinsights-query/azure/applicationinsights/query/operations/__init__.py new file mode 100644 index 000000000000..f7125d05cb08 --- /dev/null +++ b/azure-applicationinsights-query/azure/applicationinsights/query/operations/__init__.py @@ -0,0 +1,20 @@ +# coding=utf-8 +# -------------------------------------------------------------------------- +# Copyright (c) Microsoft Corporation. All rights reserved. +# Licensed under the MIT License. See License.txt in the project root for +# license information. +# +# Code generated by Microsoft (R) AutoRest Code Generator. +# Changes may cause incorrect behavior and will be lost if the code is +# regenerated. +# -------------------------------------------------------------------------- + +from .metrics_operations import MetricsOperations +from .events_operations import EventsOperations +from .query_operations import QueryOperations + +__all__ = [ + 'MetricsOperations', + 'EventsOperations', + 'QueryOperations', +] diff --git a/azure-applicationinsights-query/azure/applicationinsights/query/operations/events_operations.py b/azure-applicationinsights-query/azure/applicationinsights/query/operations/events_operations.py new file mode 100644 index 000000000000..a4e9050e661d --- /dev/null +++ b/azure-applicationinsights-query/azure/applicationinsights/query/operations/events_operations.py @@ -0,0 +1,273 @@ +# coding=utf-8 +# -------------------------------------------------------------------------- +# Copyright (c) Microsoft Corporation. All rights reserved. +# Licensed under the MIT License. See License.txt in the project root for +# license information. +# +# Code generated by Microsoft (R) AutoRest Code Generator. +# Changes may cause incorrect behavior and will be lost if the code is +# regenerated. +# -------------------------------------------------------------------------- + +from msrest.pipeline import ClientRawResponse + +from .. import models + + +class EventsOperations(object): + """EventsOperations operations. + + :param client: Client for service requests. + :param config: Configuration of service client. + :param serializer: An object model serializer. + :param deserializer: An object model deserializer. + """ + + models = models + + def __init__(self, client, config, serializer, deserializer): + + self._client = client + self._serialize = serializer + self._deserialize = deserializer + + self.config = config + + def get_by_type( + self, app_id, event_type, timespan=None, filter=None, search=None, orderby=None, select=None, skip=None, top=None, format=None, count=None, apply=None, custom_headers=None, raw=False, **operation_config): + """Execute OData query. + + Executes an OData query for events. + + :param app_id: ID of the application. This is Application ID from the + API Access settings blade in the Azure portal. + :type app_id: str + :param event_type: The type of events to query; either a standard + event type (`traces`, `customEvents`, `pageViews`, `requests`, + `dependencies`, `exceptions`, `availabilityResults`) or `$all` to + query across all event types. Possible values include: '$all', + 'traces', 'customEvents', 'pageViews', 'browserTimings', 'requests', + 'dependencies', 'exceptions', 'availabilityResults', + 'performanceCounters', 'customMetrics' + :type event_type: str or + ~azure.applicationinsights.query.models.EventType + :param timespan: Optional. The timespan over which to retrieve events. + This is an ISO8601 time period value. This timespan is applied in + addition to any that are specified in the Odata expression. + :type timespan: str + :param filter: An expression used to filter the returned events + :type filter: str + :param search: A free-text search expression to match for whether a + particular event should be returned + :type search: str + :param orderby: A comma-separated list of properties with \\"asc\\" + (the default) or \\"desc\\" to control the order of returned events + :type orderby: str + :param select: Limits the properties to just those requested on each + returned event + :type select: str + :param skip: The number of items to skip over before returning events + :type skip: int + :param top: The number of events to return + :type top: int + :param format: Format for the returned events + :type format: str + :param count: Request a count of matching items included with the + returned events + :type count: bool + :param apply: An expression used for aggregation over returned events + :type apply: str + :param dict custom_headers: headers that will be added to the request + :param bool raw: returns the direct response alongside the + deserialized response + :param operation_config: :ref:`Operation configuration + overrides`. + :return: EventsResults or ClientRawResponse if raw=true + :rtype: ~azure.applicationinsights.query.models.EventsResults or + ~msrest.pipeline.ClientRawResponse + :raises: + :class:`ErrorResponseException` + """ + # Construct URL + url = self.get_by_type.metadata['url'] + path_format_arguments = { + 'appId': self._serialize.url("app_id", app_id, 'str'), + 'eventType': self._serialize.url("event_type", event_type, 'str') + } + url = self._client.format_url(url, **path_format_arguments) + + # Construct parameters + query_parameters = {} + if timespan is not None: + query_parameters['timespan'] = self._serialize.query("timespan", timespan, 'str') + if filter is not None: + query_parameters['$filter'] = self._serialize.query("filter", filter, 'str') + if search is not None: + query_parameters['$search'] = self._serialize.query("search", search, 'str') + if orderby is not None: + query_parameters['$orderby'] = self._serialize.query("orderby", orderby, 'str') + if select is not None: + query_parameters['$select'] = self._serialize.query("select", select, 'str') + if skip is not None: + query_parameters['$skip'] = self._serialize.query("skip", skip, 'int') + if top is not None: + query_parameters['$top'] = self._serialize.query("top", top, 'int') + if format is not None: + query_parameters['$format'] = self._serialize.query("format", format, 'str') + if count is not None: + query_parameters['$count'] = self._serialize.query("count", count, 'bool') + if apply is not None: + query_parameters['$apply'] = self._serialize.query("apply", apply, 'str') + + # Construct headers + header_parameters = {} + header_parameters['Accept'] = 'application/json' + if custom_headers: + header_parameters.update(custom_headers) + + # Construct and send request + request = self._client.get(url, query_parameters, header_parameters) + response = self._client.send(request, stream=False, **operation_config) + + if response.status_code not in [200]: + raise models.ErrorResponseException(self._deserialize, response) + + deserialized = None + + if response.status_code == 200: + deserialized = self._deserialize('EventsResults', response) + + if raw: + client_raw_response = ClientRawResponse(deserialized, response) + return client_raw_response + + return deserialized + get_by_type.metadata = {'url': '/apps/{appId}/events/{eventType}'} + + def get( + self, app_id, event_type, event_id, timespan=None, custom_headers=None, raw=False, **operation_config): + """Get an event. + + Gets the data for a single event. + + :param app_id: ID of the application. This is Application ID from the + API Access settings blade in the Azure portal. + :type app_id: str + :param event_type: The type of events to query; either a standard + event type (`traces`, `customEvents`, `pageViews`, `requests`, + `dependencies`, `exceptions`, `availabilityResults`) or `$all` to + query across all event types. Possible values include: '$all', + 'traces', 'customEvents', 'pageViews', 'browserTimings', 'requests', + 'dependencies', 'exceptions', 'availabilityResults', + 'performanceCounters', 'customMetrics' + :type event_type: str or + ~azure.applicationinsights.query.models.EventType + :param event_id: ID of event. + :type event_id: str + :param timespan: Optional. The timespan over which to retrieve events. + This is an ISO8601 time period value. This timespan is applied in + addition to any that are specified in the Odata expression. + :type timespan: str + :param dict custom_headers: headers that will be added to the request + :param bool raw: returns the direct response alongside the + deserialized response + :param operation_config: :ref:`Operation configuration + overrides`. + :return: EventsResults or ClientRawResponse if raw=true + :rtype: ~azure.applicationinsights.query.models.EventsResults or + ~msrest.pipeline.ClientRawResponse + :raises: + :class:`ErrorResponseException` + """ + # Construct URL + url = self.get.metadata['url'] + path_format_arguments = { + 'appId': self._serialize.url("app_id", app_id, 'str'), + 'eventType': self._serialize.url("event_type", event_type, 'str'), + 'eventId': self._serialize.url("event_id", event_id, 'str') + } + url = self._client.format_url(url, **path_format_arguments) + + # Construct parameters + query_parameters = {} + if timespan is not None: + query_parameters['timespan'] = self._serialize.query("timespan", timespan, 'str') + + # Construct headers + header_parameters = {} + header_parameters['Accept'] = 'application/json' + if custom_headers: + header_parameters.update(custom_headers) + + # Construct and send request + request = self._client.get(url, query_parameters, header_parameters) + response = self._client.send(request, stream=False, **operation_config) + + if response.status_code not in [200]: + raise models.ErrorResponseException(self._deserialize, response) + + deserialized = None + + if response.status_code == 200: + deserialized = self._deserialize('EventsResults', response) + + if raw: + client_raw_response = ClientRawResponse(deserialized, response) + return client_raw_response + + return deserialized + get.metadata = {'url': '/apps/{appId}/events/{eventType}/{eventId}'} + + def get_odata_metadata( + self, app_id, custom_headers=None, raw=False, **operation_config): + """Get OData metadata. + + Gets OData EDMX metadata describing the event data model. + + :param app_id: ID of the application. This is Application ID from the + API Access settings blade in the Azure portal. + :type app_id: str + :param dict custom_headers: headers that will be added to the request + :param bool raw: returns the direct response alongside the + deserialized response + :param operation_config: :ref:`Operation configuration + overrides`. + :return: object or ClientRawResponse if raw=true + :rtype: object or ~msrest.pipeline.ClientRawResponse + :raises: + :class:`ErrorResponseException` + """ + # Construct URL + url = self.get_odata_metadata.metadata['url'] + path_format_arguments = { + 'appId': self._serialize.url("app_id", app_id, 'str') + } + url = self._client.format_url(url, **path_format_arguments) + + # Construct parameters + query_parameters = {} + + # Construct headers + header_parameters = {} + header_parameters['Accept'] = 'application/xml;charset=utf-8' + if custom_headers: + header_parameters.update(custom_headers) + + # Construct and send request + request = self._client.get(url, query_parameters, header_parameters) + response = self._client.send(request, stream=False, **operation_config) + + if response.status_code not in [200]: + raise models.ErrorResponseException(self._deserialize, response) + + deserialized = None + + if response.status_code == 200: + deserialized = self._deserialize('object', response) + + if raw: + client_raw_response = ClientRawResponse(deserialized, response) + return client_raw_response + + return deserialized + get_odata_metadata.metadata = {'url': '/apps/{appId}/events/$metadata'} diff --git a/azure-applicationinsights-query/azure/applicationinsights/query/operations/metrics_operations.py b/azure-applicationinsights-query/azure/applicationinsights/query/operations/metrics_operations.py new file mode 100644 index 000000000000..2639e0466f5a --- /dev/null +++ b/azure-applicationinsights-query/azure/applicationinsights/query/operations/metrics_operations.py @@ -0,0 +1,282 @@ +# coding=utf-8 +# -------------------------------------------------------------------------- +# Copyright (c) Microsoft Corporation. All rights reserved. +# Licensed under the MIT License. See License.txt in the project root for +# license information. +# +# Code generated by Microsoft (R) AutoRest Code Generator. +# Changes may cause incorrect behavior and will be lost if the code is +# regenerated. +# -------------------------------------------------------------------------- + +from msrest.pipeline import ClientRawResponse + +from .. import models + + +class MetricsOperations(object): + """MetricsOperations operations. + + :param client: Client for service requests. + :param config: Configuration of service client. + :param serializer: An object model serializer. + :param deserializer: An object model deserializer. + """ + + models = models + + def __init__(self, client, config, serializer, deserializer): + + self._client = client + self._serialize = serializer + self._deserialize = deserializer + + self.config = config + + def get( + self, app_id, metric_id, timespan=None, interval=None, aggregation=None, segment=None, top=None, orderby=None, filter=None, custom_headers=None, raw=False, **operation_config): + """Retrieve metric data. + + Gets metric values for a single metric. + + :param app_id: ID of the application. This is Application ID from the + API Access settings blade in the Azure portal. + :type app_id: str + :param metric_id: ID of the metric. This is either a standard AI + metric, or an application-specific custom metric. Possible values + include: 'requests/count', 'requests/duration', 'requests/failed', + 'users/count', 'users/authenticated', 'pageViews/count', + 'pageViews/duration', 'client/processingDuration', + 'client/receiveDuration', 'client/networkDuration', + 'client/sendDuration', 'client/totalDuration', 'dependencies/count', + 'dependencies/failed', 'dependencies/duration', 'exceptions/count', + 'exceptions/browser', 'exceptions/server', 'sessions/count', + 'performanceCounters/requestExecutionTime', + 'performanceCounters/requestsPerSecond', + 'performanceCounters/requestsInQueue', + 'performanceCounters/memoryAvailableBytes', + 'performanceCounters/exceptionsPerSecond', + 'performanceCounters/processCpuPercentage', + 'performanceCounters/processIOBytesPerSecond', + 'performanceCounters/processPrivateBytes', + 'performanceCounters/processorCpuPercentage', + 'availabilityResults/availabilityPercentage', + 'availabilityResults/duration', 'billing/telemetryCount', + 'customEvents/count' + :type metric_id: str or + ~azure.applicationinsights.query.models.MetricId + :param timespan: The timespan over which to retrieve metric values. + This is an ISO8601 time period value. If timespan is omitted, a + default time range of `PT12H` ("last 12 hours") is used. The actual + timespan that is queried may be adjusted by the server based. In all + cases, the actual time span used for the query is included in the + response. + :type timespan: str + :param interval: The time interval to use when retrieving metric + values. This is an ISO8601 duration. If interval is omitted, the + metric value is aggregated across the entire timespan. If interval is + supplied, the server may adjust the interval to a more appropriate + size based on the timespan used for the query. In all cases, the + actual interval used for the query is included in the response. + :type interval: timedelta + :param aggregation: The aggregation to use when computing the metric + values. To retrieve more than one aggregation at a time, separate them + with a comma. If no aggregation is specified, then the default + aggregation for the metric is used. + :type aggregation: list[str or + ~azure.applicationinsights.query.models.MetricsAggregation] + :param segment: The name of the dimension to segment the metric values + by. This dimension must be applicable to the metric you are + retrieving. To segment by more than one dimension at a time, separate + them with a comma (,). In this case, the metric data will be segmented + in the order the dimensions are listed in the parameter. + :type segment: list[str or + ~azure.applicationinsights.query.models.MetricsSegment] + :param top: The number of segments to return. This value is only + valid when segment is specified. + :type top: int + :param orderby: The aggregation function and direction to sort the + segments by. This value is only valid when segment is specified. + :type orderby: str + :param filter: An expression used to filter the results. This value + should be a valid OData filter expression where the keys of each + clause should be applicable dimensions for the metric you are + retrieving. + :type filter: str + :param dict custom_headers: headers that will be added to the request + :param bool raw: returns the direct response alongside the + deserialized response + :param operation_config: :ref:`Operation configuration + overrides`. + :return: MetricsResult or ClientRawResponse if raw=true + :rtype: ~azure.applicationinsights.query.models.MetricsResult or + ~msrest.pipeline.ClientRawResponse + :raises: + :class:`ErrorResponseException` + """ + # Construct URL + url = self.get.metadata['url'] + path_format_arguments = { + 'appId': self._serialize.url("app_id", app_id, 'str'), + 'metricId': self._serialize.url("metric_id", metric_id, 'str') + } + url = self._client.format_url(url, **path_format_arguments) + + # Construct parameters + query_parameters = {} + if timespan is not None: + query_parameters['timespan'] = self._serialize.query("timespan", timespan, 'str') + if interval is not None: + query_parameters['interval'] = self._serialize.query("interval", interval, 'duration') + if aggregation is not None: + query_parameters['aggregation'] = self._serialize.query("aggregation", aggregation, '[str]', div=',', min_items=1) + if segment is not None: + query_parameters['segment'] = self._serialize.query("segment", segment, '[str]', div=',', min_items=1) + if top is not None: + query_parameters['top'] = self._serialize.query("top", top, 'int') + if orderby is not None: + query_parameters['orderby'] = self._serialize.query("orderby", orderby, 'str') + if filter is not None: + query_parameters['filter'] = self._serialize.query("filter", filter, 'str') + + # Construct headers + header_parameters = {} + header_parameters['Accept'] = 'application/json' + if custom_headers: + header_parameters.update(custom_headers) + + # Construct and send request + request = self._client.get(url, query_parameters, header_parameters) + response = self._client.send(request, stream=False, **operation_config) + + if response.status_code not in [200]: + raise models.ErrorResponseException(self._deserialize, response) + + deserialized = None + + if response.status_code == 200: + deserialized = self._deserialize('MetricsResult', response) + + if raw: + client_raw_response = ClientRawResponse(deserialized, response) + return client_raw_response + + return deserialized + get.metadata = {'url': '/apps/{appId}/metrics/{metricId}'} + + def get_multiple( + self, app_id, body, custom_headers=None, raw=False, **operation_config): + """Retrieve metric data. + + Gets metric values for multiple metrics. + + :param app_id: ID of the application. This is Application ID from the + API Access settings blade in the Azure portal. + :type app_id: str + :param body: The batched metrics query. + :type body: + list[~azure.applicationinsights.query.models.MetricsPostBodySchema] + :param dict custom_headers: headers that will be added to the request + :param bool raw: returns the direct response alongside the + deserialized response + :param operation_config: :ref:`Operation configuration + overrides`. + :return: list or ClientRawResponse if raw=true + :rtype: + list[~azure.applicationinsights.query.models.MetricsResultsItem] or + ~msrest.pipeline.ClientRawResponse + :raises: + :class:`ErrorResponseException` + """ + # Construct URL + url = self.get_multiple.metadata['url'] + path_format_arguments = { + 'appId': self._serialize.url("app_id", app_id, 'str') + } + url = self._client.format_url(url, **path_format_arguments) + + # Construct parameters + query_parameters = {} + + # Construct headers + header_parameters = {} + header_parameters['Accept'] = 'application/json' + header_parameters['Content-Type'] = 'application/json; charset=utf-8' + if custom_headers: + header_parameters.update(custom_headers) + + # Construct body + body_content = self._serialize.body(body, '[MetricsPostBodySchema]') + + # Construct and send request + request = self._client.post(url, query_parameters, header_parameters, body_content) + response = self._client.send(request, stream=False, **operation_config) + + if response.status_code not in [200]: + raise models.ErrorResponseException(self._deserialize, response) + + deserialized = None + + if response.status_code == 200: + deserialized = self._deserialize('[MetricsResultsItem]', response) + + if raw: + client_raw_response = ClientRawResponse(deserialized, response) + return client_raw_response + + return deserialized + get_multiple.metadata = {'url': '/apps/{appId}/metrics'} + + def get_metadata( + self, app_id, custom_headers=None, raw=False, **operation_config): + """Retrieve metric metadata. + + Gets metadata describing the available metrics. + + :param app_id: ID of the application. This is Application ID from the + API Access settings blade in the Azure portal. + :type app_id: str + :param dict custom_headers: headers that will be added to the request + :param bool raw: returns the direct response alongside the + deserialized response + :param operation_config: :ref:`Operation configuration + overrides`. + :return: object or ClientRawResponse if raw=true + :rtype: object or ~msrest.pipeline.ClientRawResponse + :raises: + :class:`ErrorResponseException` + """ + # Construct URL + url = self.get_metadata.metadata['url'] + path_format_arguments = { + 'appId': self._serialize.url("app_id", app_id, 'str') + } + url = self._client.format_url(url, **path_format_arguments) + + # Construct parameters + query_parameters = {} + + # Construct headers + header_parameters = {} + header_parameters['Accept'] = 'application/json' + if custom_headers: + header_parameters.update(custom_headers) + + # Construct and send request + request = self._client.get(url, query_parameters, header_parameters) + response = self._client.send(request, stream=False, **operation_config) + + if response.status_code not in [200]: + raise models.ErrorResponseException(self._deserialize, response) + + deserialized = None + + if response.status_code == 200: + deserialized = self._deserialize('object', response) + + if raw: + client_raw_response = ClientRawResponse(deserialized, response) + return client_raw_response + + return deserialized + get_metadata.metadata = {'url': '/apps/{appId}/metrics/metadata'} diff --git a/azure-applicationinsights-query/azure/applicationinsights/query/operations/query_operations.py b/azure-applicationinsights-query/azure/applicationinsights/query/operations/query_operations.py new file mode 100644 index 000000000000..7250d777b407 --- /dev/null +++ b/azure-applicationinsights-query/azure/applicationinsights/query/operations/query_operations.py @@ -0,0 +1,99 @@ +# coding=utf-8 +# -------------------------------------------------------------------------- +# Copyright (c) Microsoft Corporation. All rights reserved. +# Licensed under the MIT License. See License.txt in the project root for +# license information. +# +# Code generated by Microsoft (R) AutoRest Code Generator. +# Changes may cause incorrect behavior and will be lost if the code is +# regenerated. +# -------------------------------------------------------------------------- + +from msrest.pipeline import ClientRawResponse + +from .. import models + + +class QueryOperations(object): + """QueryOperations operations. + + :param client: Client for service requests. + :param config: Configuration of service client. + :param serializer: An object model serializer. + :param deserializer: An object model deserializer. + """ + + models = models + + def __init__(self, client, config, serializer, deserializer): + + self._client = client + self._serialize = serializer + self._deserialize = deserializer + + self.config = config + + def execute( + self, app_id, body, custom_headers=None, raw=False, **operation_config): + """Execute an Analytics query. + + Executes an Analytics query for data. + [Here](https://dev.applicationinsights.io/documentation/Using-the-API/Query) + is an example for using POST with an Analytics query. + + :param app_id: ID of the application. This is Application ID from the + API Access settings blade in the Azure portal. + :type app_id: str + :param body: The Analytics query. Learn more about the [Analytics + query + syntax](https://azure.microsoft.com/documentation/articles/app-insights-analytics-reference/) + :type body: ~azure.applicationinsights.query.models.QueryBody + :param dict custom_headers: headers that will be added to the request + :param bool raw: returns the direct response alongside the + deserialized response + :param operation_config: :ref:`Operation configuration + overrides`. + :return: QueryResults or ClientRawResponse if raw=true + :rtype: ~azure.applicationinsights.query.models.QueryResults or + ~msrest.pipeline.ClientRawResponse + :raises: + :class:`ErrorResponseException` + """ + # Construct URL + url = self.execute.metadata['url'] + path_format_arguments = { + 'appId': self._serialize.url("app_id", app_id, 'str') + } + url = self._client.format_url(url, **path_format_arguments) + + # Construct parameters + query_parameters = {} + + # Construct headers + header_parameters = {} + header_parameters['Accept'] = 'application/json' + header_parameters['Content-Type'] = 'application/json; charset=utf-8' + if custom_headers: + header_parameters.update(custom_headers) + + # Construct body + body_content = self._serialize.body(body, 'QueryBody') + + # Construct and send request + request = self._client.post(url, query_parameters, header_parameters, body_content) + response = self._client.send(request, stream=False, **operation_config) + + if response.status_code not in [200]: + raise models.ErrorResponseException(self._deserialize, response) + + deserialized = None + + if response.status_code == 200: + deserialized = self._deserialize('QueryResults', response) + + if raw: + client_raw_response = ClientRawResponse(deserialized, response) + return client_raw_response + + return deserialized + execute.metadata = {'url': '/apps/{appId}/query'} diff --git a/azure-applicationinsights-query/azure/applicationinsights/query/version.py b/azure-applicationinsights-query/azure/applicationinsights/query/version.py new file mode 100644 index 000000000000..e0ec669828cb --- /dev/null +++ b/azure-applicationinsights-query/azure/applicationinsights/query/version.py @@ -0,0 +1,13 @@ +# coding=utf-8 +# -------------------------------------------------------------------------- +# Copyright (c) Microsoft Corporation. All rights reserved. +# Licensed under the MIT License. See License.txt in the project root for +# license information. +# +# Code generated by Microsoft (R) AutoRest Code Generator. +# Changes may cause incorrect behavior and will be lost if the code is +# regenerated. +# -------------------------------------------------------------------------- + +VERSION = "0.1.0" + diff --git a/azure-applicationinsights-query/models/__init__.py b/azure-applicationinsights-query/models/__init__.py new file mode 100644 index 000000000000..0fb0a6c567d4 --- /dev/null +++ b/azure-applicationinsights-query/models/__init__.py @@ -0,0 +1,170 @@ +# coding=utf-8 +# -------------------------------------------------------------------------- +# Copyright (c) Microsoft Corporation. All rights reserved. +# Licensed under the MIT License. See License.txt in the project root for +# license information. +# +# Code generated by Microsoft (R) AutoRest Code Generator. +# Changes may cause incorrect behavior and will be lost if the code is +# regenerated. +# -------------------------------------------------------------------------- + +try: + from .metrics_post_body_schema_parameters_py3 import MetricsPostBodySchemaParameters + from .metrics_post_body_schema_py3 import MetricsPostBodySchema + from .metrics_segment_info_py3 import MetricsSegmentInfo + from .metrics_result_info_py3 import MetricsResultInfo + from .metrics_result_py3 import MetricsResult + from .metrics_results_item_py3 import MetricsResultsItem + from .error_detail_py3 import ErrorDetail + from .error_info_py3 import ErrorInfo + from .events_result_data_custom_dimensions_py3 import EventsResultDataCustomDimensions + from .events_result_data_custom_measurements_py3 import EventsResultDataCustomMeasurements + from .events_operation_info_py3 import EventsOperationInfo + from .events_session_info_py3 import EventsSessionInfo + from .events_user_info_py3 import EventsUserInfo + from .events_cloud_info_py3 import EventsCloudInfo + from .events_ai_info_py3 import EventsAiInfo + from .events_application_info_py3 import EventsApplicationInfo + from .events_client_info_py3 import EventsClientInfo + from .events_result_data_py3 import EventsResultData + from .events_results_py3 import EventsResults + from .events_result_py3 import EventsResult + from .events_trace_info_py3 import EventsTraceInfo + from .events_trace_result_py3 import EventsTraceResult + from .events_custom_event_info_py3 import EventsCustomEventInfo + from .events_custom_event_result_py3 import EventsCustomEventResult + from .events_page_view_info_py3 import EventsPageViewInfo + from .events_page_view_result_py3 import EventsPageViewResult + from .events_browser_timing_info_py3 import EventsBrowserTimingInfo + from .events_client_performance_info_py3 import EventsClientPerformanceInfo + from .events_browser_timing_result_py3 import EventsBrowserTimingResult + from .events_request_info_py3 import EventsRequestInfo + from .events_request_result_py3 import EventsRequestResult + from .events_dependency_info_py3 import EventsDependencyInfo + from .events_dependency_result_py3 import EventsDependencyResult + from .events_exception_details_parsed_stack_py3 import EventsExceptionDetailsParsedStack + from .events_exception_detail_py3 import EventsExceptionDetail + from .events_exception_info_py3 import EventsExceptionInfo + from .events_exception_result_py3 import EventsExceptionResult + from .events_availability_result_info_py3 import EventsAvailabilityResultInfo + from .events_availability_result_result_py3 import EventsAvailabilityResultResult + from .events_performance_counter_info_py3 import EventsPerformanceCounterInfo + from .events_performance_counter_result_py3 import EventsPerformanceCounterResult + from .events_custom_metric_info_py3 import EventsCustomMetricInfo + from .events_custom_metric_result_py3 import EventsCustomMetricResult + from .query_body_py3 import QueryBody + from .column_py3 import Column + from .table_py3 import Table + from .query_results_py3 import QueryResults + from .error_response_py3 import ErrorResponse, ErrorResponseException +except (SyntaxError, ImportError): + from .metrics_post_body_schema_parameters import MetricsPostBodySchemaParameters + from .metrics_post_body_schema import MetricsPostBodySchema + from .metrics_segment_info import MetricsSegmentInfo + from .metrics_result_info import MetricsResultInfo + from .metrics_result import MetricsResult + from .metrics_results_item import MetricsResultsItem + from .error_detail import ErrorDetail + from .error_info import ErrorInfo + from .events_result_data_custom_dimensions import EventsResultDataCustomDimensions + from .events_result_data_custom_measurements import EventsResultDataCustomMeasurements + from .events_operation_info import EventsOperationInfo + from .events_session_info import EventsSessionInfo + from .events_user_info import EventsUserInfo + from .events_cloud_info import EventsCloudInfo + from .events_ai_info import EventsAiInfo + from .events_application_info import EventsApplicationInfo + from .events_client_info import EventsClientInfo + from .events_result_data import EventsResultData + from .events_results import EventsResults + from .events_result import EventsResult + from .events_trace_info import EventsTraceInfo + from .events_trace_result import EventsTraceResult + from .events_custom_event_info import EventsCustomEventInfo + from .events_custom_event_result import EventsCustomEventResult + from .events_page_view_info import EventsPageViewInfo + from .events_page_view_result import EventsPageViewResult + from .events_browser_timing_info import EventsBrowserTimingInfo + from .events_client_performance_info import EventsClientPerformanceInfo + from .events_browser_timing_result import EventsBrowserTimingResult + from .events_request_info import EventsRequestInfo + from .events_request_result import EventsRequestResult + from .events_dependency_info import EventsDependencyInfo + from .events_dependency_result import EventsDependencyResult + from .events_exception_details_parsed_stack import EventsExceptionDetailsParsedStack + from .events_exception_detail import EventsExceptionDetail + from .events_exception_info import EventsExceptionInfo + from .events_exception_result import EventsExceptionResult + from .events_availability_result_info import EventsAvailabilityResultInfo + from .events_availability_result_result import EventsAvailabilityResultResult + from .events_performance_counter_info import EventsPerformanceCounterInfo + from .events_performance_counter_result import EventsPerformanceCounterResult + from .events_custom_metric_info import EventsCustomMetricInfo + from .events_custom_metric_result import EventsCustomMetricResult + from .query_body import QueryBody + from .column import Column + from .table import Table + from .query_results import QueryResults + from .error_response import ErrorResponse, ErrorResponseException +from .application_insights_data_client_enums import ( + MetricId, + MetricsAggregation, + MetricsSegment, + EventType, +) + +__all__ = [ + 'MetricsPostBodySchemaParameters', + 'MetricsPostBodySchema', + 'MetricsSegmentInfo', + 'MetricsResultInfo', + 'MetricsResult', + 'MetricsResultsItem', + 'ErrorDetail', + 'ErrorInfo', + 'EventsResultDataCustomDimensions', + 'EventsResultDataCustomMeasurements', + 'EventsOperationInfo', + 'EventsSessionInfo', + 'EventsUserInfo', + 'EventsCloudInfo', + 'EventsAiInfo', + 'EventsApplicationInfo', + 'EventsClientInfo', + 'EventsResultData', + 'EventsResults', + 'EventsResult', + 'EventsTraceInfo', + 'EventsTraceResult', + 'EventsCustomEventInfo', + 'EventsCustomEventResult', + 'EventsPageViewInfo', + 'EventsPageViewResult', + 'EventsBrowserTimingInfo', + 'EventsClientPerformanceInfo', + 'EventsBrowserTimingResult', + 'EventsRequestInfo', + 'EventsRequestResult', + 'EventsDependencyInfo', + 'EventsDependencyResult', + 'EventsExceptionDetailsParsedStack', + 'EventsExceptionDetail', + 'EventsExceptionInfo', + 'EventsExceptionResult', + 'EventsAvailabilityResultInfo', + 'EventsAvailabilityResultResult', + 'EventsPerformanceCounterInfo', + 'EventsPerformanceCounterResult', + 'EventsCustomMetricInfo', + 'EventsCustomMetricResult', + 'QueryBody', + 'Column', + 'Table', + 'QueryResults', + 'ErrorResponse', 'ErrorResponseException', + 'MetricId', + 'MetricsAggregation', + 'MetricsSegment', + 'EventType', +] diff --git a/azure-applicationinsights-query/models/application_insights_data_client_enums.py b/azure-applicationinsights-query/models/application_insights_data_client_enums.py new file mode 100644 index 000000000000..f81da2b46d59 --- /dev/null +++ b/azure-applicationinsights-query/models/application_insights_data_client_enums.py @@ -0,0 +1,93 @@ +# coding=utf-8 +# -------------------------------------------------------------------------- +# Copyright (c) Microsoft Corporation. All rights reserved. +# Licensed under the MIT License. See License.txt in the project root for +# license information. +# +# Code generated by Microsoft (R) AutoRest Code Generator. +# Changes may cause incorrect behavior and will be lost if the code is +# regenerated. +# -------------------------------------------------------------------------- + +from enum import Enum + + +class MetricId(str, Enum): + + requestscount = "requests/count" + requestsduration = "requests/duration" + requestsfailed = "requests/failed" + userscount = "users/count" + usersauthenticated = "users/authenticated" + page_viewscount = "pageViews/count" + page_viewsduration = "pageViews/duration" + clientprocessing_duration = "client/processingDuration" + clientreceive_duration = "client/receiveDuration" + clientnetwork_duration = "client/networkDuration" + clientsend_duration = "client/sendDuration" + clienttotal_duration = "client/totalDuration" + dependenciescount = "dependencies/count" + dependenciesfailed = "dependencies/failed" + dependenciesduration = "dependencies/duration" + exceptionscount = "exceptions/count" + exceptionsbrowser = "exceptions/browser" + exceptionsserver = "exceptions/server" + sessionscount = "sessions/count" + performance_countersrequest_execution_time = "performanceCounters/requestExecutionTime" + performance_countersrequests_per_second = "performanceCounters/requestsPerSecond" + performance_countersrequests_in_queue = "performanceCounters/requestsInQueue" + performance_countersmemory_available_bytes = "performanceCounters/memoryAvailableBytes" + performance_countersexceptions_per_second = "performanceCounters/exceptionsPerSecond" + performance_countersprocess_cpu_percentage = "performanceCounters/processCpuPercentage" + performance_countersprocess_io_bytes_per_second = "performanceCounters/processIOBytesPerSecond" + performance_countersprocess_private_bytes = "performanceCounters/processPrivateBytes" + performance_countersprocessor_cpu_percentage = "performanceCounters/processorCpuPercentage" + availability_resultsavailability_percentage = "availabilityResults/availabilityPercentage" + availability_resultsduration = "availabilityResults/duration" + billingtelemetry_count = "billing/telemetryCount" + custom_eventscount = "customEvents/count" + + +class MetricsAggregation(str, Enum): + + min = "min" + max = "max" + avg = "avg" + sum = "sum" + count = "count" + unique = "unique" + + +class MetricsSegment(str, Enum): + + application_build = "applicationBuild" + application_version = "applicationVersion" + authenticated_or_anonymous_traffic = "authenticatedOrAnonymousTraffic" + browser = "browser" + browser_version = "browserVersion" + city = "city" + cloud_role_name = "cloudRoleName" + cloud_service_name = "cloudServiceName" + continent = "continent" + country_or_region = "countryOrRegion" + deployment_id = "deploymentId" + deployment_unit = "deploymentUnit" + device_type = "deviceType" + environment = "environment" + hosting_location = "hostingLocation" + instance_name = "instanceName" + + +class EventType(str, Enum): + + all = "$all" + traces = "traces" + custom_events = "customEvents" + page_views = "pageViews" + browser_timings = "browserTimings" + requests = "requests" + dependencies = "dependencies" + exceptions = "exceptions" + availability_results = "availabilityResults" + performance_counters = "performanceCounters" + custom_metrics = "customMetrics" diff --git a/azure-applicationinsights-query/models/column.py b/azure-applicationinsights-query/models/column.py new file mode 100644 index 000000000000..fde9b294d351 --- /dev/null +++ b/azure-applicationinsights-query/models/column.py @@ -0,0 +1,34 @@ +# coding=utf-8 +# -------------------------------------------------------------------------- +# Copyright (c) Microsoft Corporation. All rights reserved. +# Licensed under the MIT License. See License.txt in the project root for +# license information. +# +# Code generated by Microsoft (R) AutoRest Code Generator. +# Changes may cause incorrect behavior and will be lost if the code is +# regenerated. +# -------------------------------------------------------------------------- + +from msrest.serialization import Model + + +class Column(Model): + """A table column. + + A column in a table. + + :param name: The name of this column. + :type name: str + :param type: The data type of this column. + :type type: str + """ + + _attribute_map = { + 'name': {'key': 'name', 'type': 'str'}, + 'type': {'key': 'type', 'type': 'str'}, + } + + def __init__(self, **kwargs): + super(Column, self).__init__(**kwargs) + self.name = kwargs.get('name', None) + self.type = kwargs.get('type', None) diff --git a/azure-applicationinsights-query/models/column_py3.py b/azure-applicationinsights-query/models/column_py3.py new file mode 100644 index 000000000000..4df2ac58398f --- /dev/null +++ b/azure-applicationinsights-query/models/column_py3.py @@ -0,0 +1,34 @@ +# coding=utf-8 +# -------------------------------------------------------------------------- +# Copyright (c) Microsoft Corporation. All rights reserved. +# Licensed under the MIT License. See License.txt in the project root for +# license information. +# +# Code generated by Microsoft (R) AutoRest Code Generator. +# Changes may cause incorrect behavior and will be lost if the code is +# regenerated. +# -------------------------------------------------------------------------- + +from msrest.serialization import Model + + +class Column(Model): + """A table column. + + A column in a table. + + :param name: The name of this column. + :type name: str + :param type: The data type of this column. + :type type: str + """ + + _attribute_map = { + 'name': {'key': 'name', 'type': 'str'}, + 'type': {'key': 'type', 'type': 'str'}, + } + + def __init__(self, *, name: str=None, type: str=None, **kwargs) -> None: + super(Column, self).__init__(**kwargs) + self.name = name + self.type = type diff --git a/azure-applicationinsights-query/models/error_detail.py b/azure-applicationinsights-query/models/error_detail.py new file mode 100644 index 000000000000..3fd620dffa45 --- /dev/null +++ b/azure-applicationinsights-query/models/error_detail.py @@ -0,0 +1,58 @@ +# coding=utf-8 +# -------------------------------------------------------------------------- +# Copyright (c) Microsoft Corporation. All rights reserved. +# Licensed under the MIT License. See License.txt in the project root for +# license information. +# +# Code generated by Microsoft (R) AutoRest Code Generator. +# Changes may cause incorrect behavior and will be lost if the code is +# regenerated. +# -------------------------------------------------------------------------- + +from msrest.serialization import Model + + +class ErrorDetail(Model): + """Error details. + + All required parameters must be populated in order to send to Azure. + + :param code: Required. The error's code. + :type code: str + :param message: Required. A human readable error message. + :type message: str + :param target: Indicates which property in the request is responsible for + the error. + :type target: str + :param value: Indicates which value in 'target' is responsible for the + error. + :type value: str + :param resources: Indicates resources which were responsible for the + error. + :type resources: list[str] + :param additional_properties: + :type additional_properties: object + """ + + _validation = { + 'code': {'required': True}, + 'message': {'required': True}, + } + + _attribute_map = { + 'code': {'key': 'code', 'type': 'str'}, + 'message': {'key': 'message', 'type': 'str'}, + 'target': {'key': 'target', 'type': 'str'}, + 'value': {'key': 'value', 'type': 'str'}, + 'resources': {'key': 'resources', 'type': '[str]'}, + 'additional_properties': {'key': 'additionalProperties', 'type': 'object'}, + } + + def __init__(self, **kwargs): + super(ErrorDetail, self).__init__(**kwargs) + self.code = kwargs.get('code', None) + self.message = kwargs.get('message', None) + self.target = kwargs.get('target', None) + self.value = kwargs.get('value', None) + self.resources = kwargs.get('resources', None) + self.additional_properties = kwargs.get('additional_properties', None) diff --git a/azure-applicationinsights-query/models/error_detail_py3.py b/azure-applicationinsights-query/models/error_detail_py3.py new file mode 100644 index 000000000000..8c714de89d18 --- /dev/null +++ b/azure-applicationinsights-query/models/error_detail_py3.py @@ -0,0 +1,58 @@ +# coding=utf-8 +# -------------------------------------------------------------------------- +# Copyright (c) Microsoft Corporation. All rights reserved. +# Licensed under the MIT License. See License.txt in the project root for +# license information. +# +# Code generated by Microsoft (R) AutoRest Code Generator. +# Changes may cause incorrect behavior and will be lost if the code is +# regenerated. +# -------------------------------------------------------------------------- + +from msrest.serialization import Model + + +class ErrorDetail(Model): + """Error details. + + All required parameters must be populated in order to send to Azure. + + :param code: Required. The error's code. + :type code: str + :param message: Required. A human readable error message. + :type message: str + :param target: Indicates which property in the request is responsible for + the error. + :type target: str + :param value: Indicates which value in 'target' is responsible for the + error. + :type value: str + :param resources: Indicates resources which were responsible for the + error. + :type resources: list[str] + :param additional_properties: + :type additional_properties: object + """ + + _validation = { + 'code': {'required': True}, + 'message': {'required': True}, + } + + _attribute_map = { + 'code': {'key': 'code', 'type': 'str'}, + 'message': {'key': 'message', 'type': 'str'}, + 'target': {'key': 'target', 'type': 'str'}, + 'value': {'key': 'value', 'type': 'str'}, + 'resources': {'key': 'resources', 'type': '[str]'}, + 'additional_properties': {'key': 'additionalProperties', 'type': 'object'}, + } + + def __init__(self, *, code: str, message: str, target: str=None, value: str=None, resources=None, additional_properties=None, **kwargs) -> None: + super(ErrorDetail, self).__init__(**kwargs) + self.code = code + self.message = message + self.target = target + self.value = value + self.resources = resources + self.additional_properties = additional_properties diff --git a/azure-applicationinsights-query/models/error_info.py b/azure-applicationinsights-query/models/error_info.py new file mode 100644 index 000000000000..14f34f097774 --- /dev/null +++ b/azure-applicationinsights-query/models/error_info.py @@ -0,0 +1,51 @@ +# coding=utf-8 +# -------------------------------------------------------------------------- +# Copyright (c) Microsoft Corporation. All rights reserved. +# Licensed under the MIT License. See License.txt in the project root for +# license information. +# +# Code generated by Microsoft (R) AutoRest Code Generator. +# Changes may cause incorrect behavior and will be lost if the code is +# regenerated. +# -------------------------------------------------------------------------- + +from msrest.serialization import Model + + +class ErrorInfo(Model): + """The code and message for an error. + + All required parameters must be populated in order to send to Azure. + + :param code: Required. A machine readable error code. + :type code: str + :param message: Required. A human readable error message. + :type message: str + :param details: error details. + :type details: list[~azure.applicationinsights.query.models.ErrorDetail] + :param innererror: Inner error details if they exist. + :type innererror: ~azure.applicationinsights.query.models.ErrorInfo + :param additional_properties: + :type additional_properties: object + """ + + _validation = { + 'code': {'required': True}, + 'message': {'required': True}, + } + + _attribute_map = { + 'code': {'key': 'code', 'type': 'str'}, + 'message': {'key': 'message', 'type': 'str'}, + 'details': {'key': 'details', 'type': '[ErrorDetail]'}, + 'innererror': {'key': 'innererror', 'type': 'ErrorInfo'}, + 'additional_properties': {'key': 'additionalProperties', 'type': 'object'}, + } + + def __init__(self, **kwargs): + super(ErrorInfo, self).__init__(**kwargs) + self.code = kwargs.get('code', None) + self.message = kwargs.get('message', None) + self.details = kwargs.get('details', None) + self.innererror = kwargs.get('innererror', None) + self.additional_properties = kwargs.get('additional_properties', None) diff --git a/azure-applicationinsights-query/models/error_info_py3.py b/azure-applicationinsights-query/models/error_info_py3.py new file mode 100644 index 000000000000..8d01ca19f1b8 --- /dev/null +++ b/azure-applicationinsights-query/models/error_info_py3.py @@ -0,0 +1,51 @@ +# coding=utf-8 +# -------------------------------------------------------------------------- +# Copyright (c) Microsoft Corporation. All rights reserved. +# Licensed under the MIT License. See License.txt in the project root for +# license information. +# +# Code generated by Microsoft (R) AutoRest Code Generator. +# Changes may cause incorrect behavior and will be lost if the code is +# regenerated. +# -------------------------------------------------------------------------- + +from msrest.serialization import Model + + +class ErrorInfo(Model): + """The code and message for an error. + + All required parameters must be populated in order to send to Azure. + + :param code: Required. A machine readable error code. + :type code: str + :param message: Required. A human readable error message. + :type message: str + :param details: error details. + :type details: list[~azure.applicationinsights.query.models.ErrorDetail] + :param innererror: Inner error details if they exist. + :type innererror: ~azure.applicationinsights.query.models.ErrorInfo + :param additional_properties: + :type additional_properties: object + """ + + _validation = { + 'code': {'required': True}, + 'message': {'required': True}, + } + + _attribute_map = { + 'code': {'key': 'code', 'type': 'str'}, + 'message': {'key': 'message', 'type': 'str'}, + 'details': {'key': 'details', 'type': '[ErrorDetail]'}, + 'innererror': {'key': 'innererror', 'type': 'ErrorInfo'}, + 'additional_properties': {'key': 'additionalProperties', 'type': 'object'}, + } + + def __init__(self, *, code: str, message: str, details=None, innererror=None, additional_properties=None, **kwargs) -> None: + super(ErrorInfo, self).__init__(**kwargs) + self.code = code + self.message = message + self.details = details + self.innererror = innererror + self.additional_properties = additional_properties diff --git a/azure-applicationinsights-query/models/error_response.py b/azure-applicationinsights-query/models/error_response.py new file mode 100644 index 000000000000..4461869de892 --- /dev/null +++ b/azure-applicationinsights-query/models/error_response.py @@ -0,0 +1,49 @@ +# coding=utf-8 +# -------------------------------------------------------------------------- +# Copyright (c) Microsoft Corporation. All rights reserved. +# Licensed under the MIT License. See License.txt in the project root for +# license information. +# +# Code generated by Microsoft (R) AutoRest Code Generator. +# Changes may cause incorrect behavior and will be lost if the code is +# regenerated. +# -------------------------------------------------------------------------- + +from msrest.serialization import Model +from msrest.exceptions import HttpOperationError + + +class ErrorResponse(Model): + """Error details. + + Contains details when the response code indicates an error. + + All required parameters must be populated in order to send to Azure. + + :param error: Required. The error details. + :type error: ~azure.applicationinsights.query.models.ErrorInfo + """ + + _validation = { + 'error': {'required': True}, + } + + _attribute_map = { + 'error': {'key': 'error', 'type': 'ErrorInfo'}, + } + + def __init__(self, **kwargs): + super(ErrorResponse, self).__init__(**kwargs) + self.error = kwargs.get('error', None) + + +class ErrorResponseException(HttpOperationError): + """Server responsed with exception of type: 'ErrorResponse'. + + :param deserialize: A deserializer + :param response: Server response to be deserialized. + """ + + def __init__(self, deserialize, response, *args): + + super(ErrorResponseException, self).__init__(deserialize, response, 'ErrorResponse', *args) diff --git a/azure-applicationinsights-query/models/error_response_py3.py b/azure-applicationinsights-query/models/error_response_py3.py new file mode 100644 index 000000000000..af501a2f5965 --- /dev/null +++ b/azure-applicationinsights-query/models/error_response_py3.py @@ -0,0 +1,49 @@ +# coding=utf-8 +# -------------------------------------------------------------------------- +# Copyright (c) Microsoft Corporation. All rights reserved. +# Licensed under the MIT License. See License.txt in the project root for +# license information. +# +# Code generated by Microsoft (R) AutoRest Code Generator. +# Changes may cause incorrect behavior and will be lost if the code is +# regenerated. +# -------------------------------------------------------------------------- + +from msrest.serialization import Model +from msrest.exceptions import HttpOperationError + + +class ErrorResponse(Model): + """Error details. + + Contains details when the response code indicates an error. + + All required parameters must be populated in order to send to Azure. + + :param error: Required. The error details. + :type error: ~azure.applicationinsights.query.models.ErrorInfo + """ + + _validation = { + 'error': {'required': True}, + } + + _attribute_map = { + 'error': {'key': 'error', 'type': 'ErrorInfo'}, + } + + def __init__(self, *, error, **kwargs) -> None: + super(ErrorResponse, self).__init__(**kwargs) + self.error = error + + +class ErrorResponseException(HttpOperationError): + """Server responsed with exception of type: 'ErrorResponse'. + + :param deserialize: A deserializer + :param response: Server response to be deserialized. + """ + + def __init__(self, deserialize, response, *args): + + super(ErrorResponseException, self).__init__(deserialize, response, 'ErrorResponse', *args) diff --git a/azure-applicationinsights-query/models/events_ai_info.py b/azure-applicationinsights-query/models/events_ai_info.py new file mode 100644 index 000000000000..61f01cdf44a7 --- /dev/null +++ b/azure-applicationinsights-query/models/events_ai_info.py @@ -0,0 +1,40 @@ +# coding=utf-8 +# -------------------------------------------------------------------------- +# Copyright (c) Microsoft Corporation. All rights reserved. +# Licensed under the MIT License. See License.txt in the project root for +# license information. +# +# Code generated by Microsoft (R) AutoRest Code Generator. +# Changes may cause incorrect behavior and will be lost if the code is +# regenerated. +# -------------------------------------------------------------------------- + +from msrest.serialization import Model + + +class EventsAiInfo(Model): + """AI related application info for an event result. + + :param i_key: iKey of the app + :type i_key: str + :param app_name: Name of the application + :type app_name: str + :param app_id: ID of the application + :type app_id: str + :param sdk_version: SDK version of the application + :type sdk_version: str + """ + + _attribute_map = { + 'i_key': {'key': 'iKey', 'type': 'str'}, + 'app_name': {'key': 'appName', 'type': 'str'}, + 'app_id': {'key': 'appId', 'type': 'str'}, + 'sdk_version': {'key': 'sdkVersion', 'type': 'str'}, + } + + def __init__(self, **kwargs): + super(EventsAiInfo, self).__init__(**kwargs) + self.i_key = kwargs.get('i_key', None) + self.app_name = kwargs.get('app_name', None) + self.app_id = kwargs.get('app_id', None) + self.sdk_version = kwargs.get('sdk_version', None) diff --git a/azure-applicationinsights-query/models/events_ai_info_py3.py b/azure-applicationinsights-query/models/events_ai_info_py3.py new file mode 100644 index 000000000000..ab903f4b09e3 --- /dev/null +++ b/azure-applicationinsights-query/models/events_ai_info_py3.py @@ -0,0 +1,40 @@ +# coding=utf-8 +# -------------------------------------------------------------------------- +# Copyright (c) Microsoft Corporation. All rights reserved. +# Licensed under the MIT License. See License.txt in the project root for +# license information. +# +# Code generated by Microsoft (R) AutoRest Code Generator. +# Changes may cause incorrect behavior and will be lost if the code is +# regenerated. +# -------------------------------------------------------------------------- + +from msrest.serialization import Model + + +class EventsAiInfo(Model): + """AI related application info for an event result. + + :param i_key: iKey of the app + :type i_key: str + :param app_name: Name of the application + :type app_name: str + :param app_id: ID of the application + :type app_id: str + :param sdk_version: SDK version of the application + :type sdk_version: str + """ + + _attribute_map = { + 'i_key': {'key': 'iKey', 'type': 'str'}, + 'app_name': {'key': 'appName', 'type': 'str'}, + 'app_id': {'key': 'appId', 'type': 'str'}, + 'sdk_version': {'key': 'sdkVersion', 'type': 'str'}, + } + + def __init__(self, *, i_key: str=None, app_name: str=None, app_id: str=None, sdk_version: str=None, **kwargs) -> None: + super(EventsAiInfo, self).__init__(**kwargs) + self.i_key = i_key + self.app_name = app_name + self.app_id = app_id + self.sdk_version = sdk_version diff --git a/azure-applicationinsights-query/models/events_application_info.py b/azure-applicationinsights-query/models/events_application_info.py new file mode 100644 index 000000000000..5ed98e5c8b19 --- /dev/null +++ b/azure-applicationinsights-query/models/events_application_info.py @@ -0,0 +1,28 @@ +# coding=utf-8 +# -------------------------------------------------------------------------- +# Copyright (c) Microsoft Corporation. All rights reserved. +# Licensed under the MIT License. See License.txt in the project root for +# license information. +# +# Code generated by Microsoft (R) AutoRest Code Generator. +# Changes may cause incorrect behavior and will be lost if the code is +# regenerated. +# -------------------------------------------------------------------------- + +from msrest.serialization import Model + + +class EventsApplicationInfo(Model): + """Application info for an event result. + + :param version: Version of the application + :type version: str + """ + + _attribute_map = { + 'version': {'key': 'version', 'type': 'str'}, + } + + def __init__(self, **kwargs): + super(EventsApplicationInfo, self).__init__(**kwargs) + self.version = kwargs.get('version', None) diff --git a/azure-applicationinsights-query/models/events_application_info_py3.py b/azure-applicationinsights-query/models/events_application_info_py3.py new file mode 100644 index 000000000000..03ede06633b7 --- /dev/null +++ b/azure-applicationinsights-query/models/events_application_info_py3.py @@ -0,0 +1,28 @@ +# coding=utf-8 +# -------------------------------------------------------------------------- +# Copyright (c) Microsoft Corporation. All rights reserved. +# Licensed under the MIT License. See License.txt in the project root for +# license information. +# +# Code generated by Microsoft (R) AutoRest Code Generator. +# Changes may cause incorrect behavior and will be lost if the code is +# regenerated. +# -------------------------------------------------------------------------- + +from msrest.serialization import Model + + +class EventsApplicationInfo(Model): + """Application info for an event result. + + :param version: Version of the application + :type version: str + """ + + _attribute_map = { + 'version': {'key': 'version', 'type': 'str'}, + } + + def __init__(self, *, version: str=None, **kwargs) -> None: + super(EventsApplicationInfo, self).__init__(**kwargs) + self.version = version diff --git a/azure-applicationinsights-query/models/events_availability_result_info.py b/azure-applicationinsights-query/models/events_availability_result_info.py new file mode 100644 index 000000000000..3daaca0578a2 --- /dev/null +++ b/azure-applicationinsights-query/models/events_availability_result_info.py @@ -0,0 +1,57 @@ +# coding=utf-8 +# -------------------------------------------------------------------------- +# Copyright (c) Microsoft Corporation. All rights reserved. +# Licensed under the MIT License. See License.txt in the project root for +# license information. +# +# Code generated by Microsoft (R) AutoRest Code Generator. +# Changes may cause incorrect behavior and will be lost if the code is +# regenerated. +# -------------------------------------------------------------------------- + +from msrest.serialization import Model + + +class EventsAvailabilityResultInfo(Model): + """The availability result info. + + :param name: The name of the availability result + :type name: str + :param success: Indicates if the availability result was successful + :type success: str + :param duration: The duration of the availability result + :type duration: long + :param performance_bucket: The performance bucket of the availability + result + :type performance_bucket: str + :param message: The message of the availability result + :type message: str + :param location: The location of the availability result + :type location: str + :param id: The ID of the availability result + :type id: str + :param size: The size of the availability result + :type size: str + """ + + _attribute_map = { + 'name': {'key': 'name', 'type': 'str'}, + 'success': {'key': 'success', 'type': 'str'}, + 'duration': {'key': 'duration', 'type': 'long'}, + 'performance_bucket': {'key': 'performanceBucket', 'type': 'str'}, + 'message': {'key': 'message', 'type': 'str'}, + 'location': {'key': 'location', 'type': 'str'}, + 'id': {'key': 'id', 'type': 'str'}, + 'size': {'key': 'size', 'type': 'str'}, + } + + def __init__(self, **kwargs): + super(EventsAvailabilityResultInfo, self).__init__(**kwargs) + self.name = kwargs.get('name', None) + self.success = kwargs.get('success', None) + self.duration = kwargs.get('duration', None) + self.performance_bucket = kwargs.get('performance_bucket', None) + self.message = kwargs.get('message', None) + self.location = kwargs.get('location', None) + self.id = kwargs.get('id', None) + self.size = kwargs.get('size', None) diff --git a/azure-applicationinsights-query/models/events_availability_result_info_py3.py b/azure-applicationinsights-query/models/events_availability_result_info_py3.py new file mode 100644 index 000000000000..90bd69d03aa9 --- /dev/null +++ b/azure-applicationinsights-query/models/events_availability_result_info_py3.py @@ -0,0 +1,57 @@ +# coding=utf-8 +# -------------------------------------------------------------------------- +# Copyright (c) Microsoft Corporation. All rights reserved. +# Licensed under the MIT License. See License.txt in the project root for +# license information. +# +# Code generated by Microsoft (R) AutoRest Code Generator. +# Changes may cause incorrect behavior and will be lost if the code is +# regenerated. +# -------------------------------------------------------------------------- + +from msrest.serialization import Model + + +class EventsAvailabilityResultInfo(Model): + """The availability result info. + + :param name: The name of the availability result + :type name: str + :param success: Indicates if the availability result was successful + :type success: str + :param duration: The duration of the availability result + :type duration: long + :param performance_bucket: The performance bucket of the availability + result + :type performance_bucket: str + :param message: The message of the availability result + :type message: str + :param location: The location of the availability result + :type location: str + :param id: The ID of the availability result + :type id: str + :param size: The size of the availability result + :type size: str + """ + + _attribute_map = { + 'name': {'key': 'name', 'type': 'str'}, + 'success': {'key': 'success', 'type': 'str'}, + 'duration': {'key': 'duration', 'type': 'long'}, + 'performance_bucket': {'key': 'performanceBucket', 'type': 'str'}, + 'message': {'key': 'message', 'type': 'str'}, + 'location': {'key': 'location', 'type': 'str'}, + 'id': {'key': 'id', 'type': 'str'}, + 'size': {'key': 'size', 'type': 'str'}, + } + + def __init__(self, *, name: str=None, success: str=None, duration: int=None, performance_bucket: str=None, message: str=None, location: str=None, id: str=None, size: str=None, **kwargs) -> None: + super(EventsAvailabilityResultInfo, self).__init__(**kwargs) + self.name = name + self.success = success + self.duration = duration + self.performance_bucket = performance_bucket + self.message = message + self.location = location + self.id = id + self.size = size diff --git a/azure-applicationinsights-query/models/events_availability_result_result.py b/azure-applicationinsights-query/models/events_availability_result_result.py new file mode 100644 index 000000000000..729504b268e8 --- /dev/null +++ b/azure-applicationinsights-query/models/events_availability_result_result.py @@ -0,0 +1,79 @@ +# coding=utf-8 +# -------------------------------------------------------------------------- +# Copyright (c) Microsoft Corporation. All rights reserved. +# Licensed under the MIT License. See License.txt in the project root for +# license information. +# +# Code generated by Microsoft (R) AutoRest Code Generator. +# Changes may cause incorrect behavior and will be lost if the code is +# regenerated. +# -------------------------------------------------------------------------- + +from .events_result_data import EventsResultData + + +class EventsAvailabilityResultResult(EventsResultData): + """An availability result result. + + All required parameters must be populated in order to send to Azure. + + :param id: The unique ID for this event. + :type id: str + :param count: Count of the event + :type count: long + :param timestamp: Timestamp of the event + :type timestamp: datetime + :param custom_dimensions: Custom dimensions of the event + :type custom_dimensions: + ~azure.applicationinsights.query.models.EventsResultDataCustomDimensions + :param custom_measurements: Custom measurements of the event + :type custom_measurements: + ~azure.applicationinsights.query.models.EventsResultDataCustomMeasurements + :param operation: Operation info of the event + :type operation: + ~azure.applicationinsights.query.models.EventsOperationInfo + :param session: Session info of the event + :type session: ~azure.applicationinsights.query.models.EventsSessionInfo + :param user: User info of the event + :type user: ~azure.applicationinsights.query.models.EventsUserInfo + :param cloud: Cloud info of the event + :type cloud: ~azure.applicationinsights.query.models.EventsCloudInfo + :param ai: AI info of the event + :type ai: ~azure.applicationinsights.query.models.EventsAiInfo + :param application: Application info of the event + :type application: + ~azure.applicationinsights.query.models.EventsApplicationInfo + :param client: Client info of the event + :type client: ~azure.applicationinsights.query.models.EventsClientInfo + :param type: Required. Constant filled by server. + :type type: str + :param availability_result: + :type availability_result: + ~azure.applicationinsights.query.models.EventsAvailabilityResultInfo + """ + + _validation = { + 'type': {'required': True}, + } + + _attribute_map = { + 'id': {'key': 'id', 'type': 'str'}, + 'count': {'key': 'count', 'type': 'long'}, + 'timestamp': {'key': 'timestamp', 'type': 'iso-8601'}, + 'custom_dimensions': {'key': 'customDimensions', 'type': 'EventsResultDataCustomDimensions'}, + 'custom_measurements': {'key': 'customMeasurements', 'type': 'EventsResultDataCustomMeasurements'}, + 'operation': {'key': 'operation', 'type': 'EventsOperationInfo'}, + 'session': {'key': 'session', 'type': 'EventsSessionInfo'}, + 'user': {'key': 'user', 'type': 'EventsUserInfo'}, + 'cloud': {'key': 'cloud', 'type': 'EventsCloudInfo'}, + 'ai': {'key': 'ai', 'type': 'EventsAiInfo'}, + 'application': {'key': 'application', 'type': 'EventsApplicationInfo'}, + 'client': {'key': 'client', 'type': 'EventsClientInfo'}, + 'type': {'key': 'type', 'type': 'str'}, + 'availability_result': {'key': 'availabilityResult', 'type': 'EventsAvailabilityResultInfo'}, + } + + def __init__(self, **kwargs): + super(EventsAvailabilityResultResult, self).__init__(**kwargs) + self.availability_result = kwargs.get('availability_result', None) + self.type = 'availabilityResult' diff --git a/azure-applicationinsights-query/models/events_availability_result_result_py3.py b/azure-applicationinsights-query/models/events_availability_result_result_py3.py new file mode 100644 index 000000000000..9a6da5a4488d --- /dev/null +++ b/azure-applicationinsights-query/models/events_availability_result_result_py3.py @@ -0,0 +1,79 @@ +# coding=utf-8 +# -------------------------------------------------------------------------- +# Copyright (c) Microsoft Corporation. All rights reserved. +# Licensed under the MIT License. See License.txt in the project root for +# license information. +# +# Code generated by Microsoft (R) AutoRest Code Generator. +# Changes may cause incorrect behavior and will be lost if the code is +# regenerated. +# -------------------------------------------------------------------------- + +from .events_result_data_py3 import EventsResultData + + +class EventsAvailabilityResultResult(EventsResultData): + """An availability result result. + + All required parameters must be populated in order to send to Azure. + + :param id: The unique ID for this event. + :type id: str + :param count: Count of the event + :type count: long + :param timestamp: Timestamp of the event + :type timestamp: datetime + :param custom_dimensions: Custom dimensions of the event + :type custom_dimensions: + ~azure.applicationinsights.query.models.EventsResultDataCustomDimensions + :param custom_measurements: Custom measurements of the event + :type custom_measurements: + ~azure.applicationinsights.query.models.EventsResultDataCustomMeasurements + :param operation: Operation info of the event + :type operation: + ~azure.applicationinsights.query.models.EventsOperationInfo + :param session: Session info of the event + :type session: ~azure.applicationinsights.query.models.EventsSessionInfo + :param user: User info of the event + :type user: ~azure.applicationinsights.query.models.EventsUserInfo + :param cloud: Cloud info of the event + :type cloud: ~azure.applicationinsights.query.models.EventsCloudInfo + :param ai: AI info of the event + :type ai: ~azure.applicationinsights.query.models.EventsAiInfo + :param application: Application info of the event + :type application: + ~azure.applicationinsights.query.models.EventsApplicationInfo + :param client: Client info of the event + :type client: ~azure.applicationinsights.query.models.EventsClientInfo + :param type: Required. Constant filled by server. + :type type: str + :param availability_result: + :type availability_result: + ~azure.applicationinsights.query.models.EventsAvailabilityResultInfo + """ + + _validation = { + 'type': {'required': True}, + } + + _attribute_map = { + 'id': {'key': 'id', 'type': 'str'}, + 'count': {'key': 'count', 'type': 'long'}, + 'timestamp': {'key': 'timestamp', 'type': 'iso-8601'}, + 'custom_dimensions': {'key': 'customDimensions', 'type': 'EventsResultDataCustomDimensions'}, + 'custom_measurements': {'key': 'customMeasurements', 'type': 'EventsResultDataCustomMeasurements'}, + 'operation': {'key': 'operation', 'type': 'EventsOperationInfo'}, + 'session': {'key': 'session', 'type': 'EventsSessionInfo'}, + 'user': {'key': 'user', 'type': 'EventsUserInfo'}, + 'cloud': {'key': 'cloud', 'type': 'EventsCloudInfo'}, + 'ai': {'key': 'ai', 'type': 'EventsAiInfo'}, + 'application': {'key': 'application', 'type': 'EventsApplicationInfo'}, + 'client': {'key': 'client', 'type': 'EventsClientInfo'}, + 'type': {'key': 'type', 'type': 'str'}, + 'availability_result': {'key': 'availabilityResult', 'type': 'EventsAvailabilityResultInfo'}, + } + + def __init__(self, *, id: str=None, count: int=None, timestamp=None, custom_dimensions=None, custom_measurements=None, operation=None, session=None, user=None, cloud=None, ai=None, application=None, client=None, availability_result=None, **kwargs) -> None: + super(EventsAvailabilityResultResult, self).__init__(id=id, count=count, timestamp=timestamp, custom_dimensions=custom_dimensions, custom_measurements=custom_measurements, operation=operation, session=session, user=user, cloud=cloud, ai=ai, application=application, client=client, **kwargs) + self.availability_result = availability_result + self.type = 'availabilityResult' diff --git a/azure-applicationinsights-query/models/events_browser_timing_info.py b/azure-applicationinsights-query/models/events_browser_timing_info.py new file mode 100644 index 000000000000..1686e263cfbf --- /dev/null +++ b/azure-applicationinsights-query/models/events_browser_timing_info.py @@ -0,0 +1,64 @@ +# coding=utf-8 +# -------------------------------------------------------------------------- +# Copyright (c) Microsoft Corporation. All rights reserved. +# Licensed under the MIT License. See License.txt in the project root for +# license information. +# +# Code generated by Microsoft (R) AutoRest Code Generator. +# Changes may cause incorrect behavior and will be lost if the code is +# regenerated. +# -------------------------------------------------------------------------- + +from msrest.serialization import Model + + +class EventsBrowserTimingInfo(Model): + """The browser timing information. + + :param url_path: The path of the URL + :type url_path: str + :param url_host: The host of the URL + :type url_host: str + :param name: The name of the page + :type name: str + :param url: The url of the page + :type url: str + :param total_duration: The total duration of the load + :type total_duration: long + :param performance_bucket: The performance bucket of the load + :type performance_bucket: str + :param network_duration: The network duration of the load + :type network_duration: long + :param send_duration: The send duration of the load + :type send_duration: long + :param receive_duration: The receive duration of the load + :type receive_duration: long + :param processing_duration: The processing duration of the load + :type processing_duration: long + """ + + _attribute_map = { + 'url_path': {'key': 'urlPath', 'type': 'str'}, + 'url_host': {'key': 'urlHost', 'type': 'str'}, + 'name': {'key': 'name', 'type': 'str'}, + 'url': {'key': 'url', 'type': 'str'}, + 'total_duration': {'key': 'totalDuration', 'type': 'long'}, + 'performance_bucket': {'key': 'performanceBucket', 'type': 'str'}, + 'network_duration': {'key': 'networkDuration', 'type': 'long'}, + 'send_duration': {'key': 'sendDuration', 'type': 'long'}, + 'receive_duration': {'key': 'receiveDuration', 'type': 'long'}, + 'processing_duration': {'key': 'processingDuration', 'type': 'long'}, + } + + def __init__(self, **kwargs): + super(EventsBrowserTimingInfo, self).__init__(**kwargs) + self.url_path = kwargs.get('url_path', None) + self.url_host = kwargs.get('url_host', None) + self.name = kwargs.get('name', None) + self.url = kwargs.get('url', None) + self.total_duration = kwargs.get('total_duration', None) + self.performance_bucket = kwargs.get('performance_bucket', None) + self.network_duration = kwargs.get('network_duration', None) + self.send_duration = kwargs.get('send_duration', None) + self.receive_duration = kwargs.get('receive_duration', None) + self.processing_duration = kwargs.get('processing_duration', None) diff --git a/azure-applicationinsights-query/models/events_browser_timing_info_py3.py b/azure-applicationinsights-query/models/events_browser_timing_info_py3.py new file mode 100644 index 000000000000..f32fabc2b31c --- /dev/null +++ b/azure-applicationinsights-query/models/events_browser_timing_info_py3.py @@ -0,0 +1,64 @@ +# coding=utf-8 +# -------------------------------------------------------------------------- +# Copyright (c) Microsoft Corporation. All rights reserved. +# Licensed under the MIT License. See License.txt in the project root for +# license information. +# +# Code generated by Microsoft (R) AutoRest Code Generator. +# Changes may cause incorrect behavior and will be lost if the code is +# regenerated. +# -------------------------------------------------------------------------- + +from msrest.serialization import Model + + +class EventsBrowserTimingInfo(Model): + """The browser timing information. + + :param url_path: The path of the URL + :type url_path: str + :param url_host: The host of the URL + :type url_host: str + :param name: The name of the page + :type name: str + :param url: The url of the page + :type url: str + :param total_duration: The total duration of the load + :type total_duration: long + :param performance_bucket: The performance bucket of the load + :type performance_bucket: str + :param network_duration: The network duration of the load + :type network_duration: long + :param send_duration: The send duration of the load + :type send_duration: long + :param receive_duration: The receive duration of the load + :type receive_duration: long + :param processing_duration: The processing duration of the load + :type processing_duration: long + """ + + _attribute_map = { + 'url_path': {'key': 'urlPath', 'type': 'str'}, + 'url_host': {'key': 'urlHost', 'type': 'str'}, + 'name': {'key': 'name', 'type': 'str'}, + 'url': {'key': 'url', 'type': 'str'}, + 'total_duration': {'key': 'totalDuration', 'type': 'long'}, + 'performance_bucket': {'key': 'performanceBucket', 'type': 'str'}, + 'network_duration': {'key': 'networkDuration', 'type': 'long'}, + 'send_duration': {'key': 'sendDuration', 'type': 'long'}, + 'receive_duration': {'key': 'receiveDuration', 'type': 'long'}, + 'processing_duration': {'key': 'processingDuration', 'type': 'long'}, + } + + def __init__(self, *, url_path: str=None, url_host: str=None, name: str=None, url: str=None, total_duration: int=None, performance_bucket: str=None, network_duration: int=None, send_duration: int=None, receive_duration: int=None, processing_duration: int=None, **kwargs) -> None: + super(EventsBrowserTimingInfo, self).__init__(**kwargs) + self.url_path = url_path + self.url_host = url_host + self.name = name + self.url = url + self.total_duration = total_duration + self.performance_bucket = performance_bucket + self.network_duration = network_duration + self.send_duration = send_duration + self.receive_duration = receive_duration + self.processing_duration = processing_duration diff --git a/azure-applicationinsights-query/models/events_browser_timing_result.py b/azure-applicationinsights-query/models/events_browser_timing_result.py new file mode 100644 index 000000000000..15bada46f728 --- /dev/null +++ b/azure-applicationinsights-query/models/events_browser_timing_result.py @@ -0,0 +1,84 @@ +# coding=utf-8 +# -------------------------------------------------------------------------- +# Copyright (c) Microsoft Corporation. All rights reserved. +# Licensed under the MIT License. See License.txt in the project root for +# license information. +# +# Code generated by Microsoft (R) AutoRest Code Generator. +# Changes may cause incorrect behavior and will be lost if the code is +# regenerated. +# -------------------------------------------------------------------------- + +from .events_result_data import EventsResultData + + +class EventsBrowserTimingResult(EventsResultData): + """A browser timing result. + + All required parameters must be populated in order to send to Azure. + + :param id: The unique ID for this event. + :type id: str + :param count: Count of the event + :type count: long + :param timestamp: Timestamp of the event + :type timestamp: datetime + :param custom_dimensions: Custom dimensions of the event + :type custom_dimensions: + ~azure.applicationinsights.query.models.EventsResultDataCustomDimensions + :param custom_measurements: Custom measurements of the event + :type custom_measurements: + ~azure.applicationinsights.query.models.EventsResultDataCustomMeasurements + :param operation: Operation info of the event + :type operation: + ~azure.applicationinsights.query.models.EventsOperationInfo + :param session: Session info of the event + :type session: ~azure.applicationinsights.query.models.EventsSessionInfo + :param user: User info of the event + :type user: ~azure.applicationinsights.query.models.EventsUserInfo + :param cloud: Cloud info of the event + :type cloud: ~azure.applicationinsights.query.models.EventsCloudInfo + :param ai: AI info of the event + :type ai: ~azure.applicationinsights.query.models.EventsAiInfo + :param application: Application info of the event + :type application: + ~azure.applicationinsights.query.models.EventsApplicationInfo + :param client: Client info of the event + :type client: ~azure.applicationinsights.query.models.EventsClientInfo + :param type: Required. Constant filled by server. + :type type: str + :param browser_timing: + :type browser_timing: + ~azure.applicationinsights.query.models.EventsBrowserTimingInfo + :param client_performance: + :type client_performance: + ~azure.applicationinsights.query.models.EventsClientPerformanceInfo + """ + + _validation = { + 'type': {'required': True}, + } + + _attribute_map = { + 'id': {'key': 'id', 'type': 'str'}, + 'count': {'key': 'count', 'type': 'long'}, + 'timestamp': {'key': 'timestamp', 'type': 'iso-8601'}, + 'custom_dimensions': {'key': 'customDimensions', 'type': 'EventsResultDataCustomDimensions'}, + 'custom_measurements': {'key': 'customMeasurements', 'type': 'EventsResultDataCustomMeasurements'}, + 'operation': {'key': 'operation', 'type': 'EventsOperationInfo'}, + 'session': {'key': 'session', 'type': 'EventsSessionInfo'}, + 'user': {'key': 'user', 'type': 'EventsUserInfo'}, + 'cloud': {'key': 'cloud', 'type': 'EventsCloudInfo'}, + 'ai': {'key': 'ai', 'type': 'EventsAiInfo'}, + 'application': {'key': 'application', 'type': 'EventsApplicationInfo'}, + 'client': {'key': 'client', 'type': 'EventsClientInfo'}, + 'type': {'key': 'type', 'type': 'str'}, + 'browser_timing': {'key': 'browserTiming', 'type': 'EventsBrowserTimingInfo'}, + 'client_performance': {'key': 'clientPerformance', 'type': 'EventsClientPerformanceInfo'}, + } + + def __init__(self, **kwargs): + super(EventsBrowserTimingResult, self).__init__(**kwargs) + self.browser_timing = kwargs.get('browser_timing', None) + self.client_performance = kwargs.get('client_performance', None) + self.type = 'browserTiming' diff --git a/azure-applicationinsights-query/models/events_browser_timing_result_py3.py b/azure-applicationinsights-query/models/events_browser_timing_result_py3.py new file mode 100644 index 000000000000..9779c8903b85 --- /dev/null +++ b/azure-applicationinsights-query/models/events_browser_timing_result_py3.py @@ -0,0 +1,84 @@ +# coding=utf-8 +# -------------------------------------------------------------------------- +# Copyright (c) Microsoft Corporation. All rights reserved. +# Licensed under the MIT License. See License.txt in the project root for +# license information. +# +# Code generated by Microsoft (R) AutoRest Code Generator. +# Changes may cause incorrect behavior and will be lost if the code is +# regenerated. +# -------------------------------------------------------------------------- + +from .events_result_data_py3 import EventsResultData + + +class EventsBrowserTimingResult(EventsResultData): + """A browser timing result. + + All required parameters must be populated in order to send to Azure. + + :param id: The unique ID for this event. + :type id: str + :param count: Count of the event + :type count: long + :param timestamp: Timestamp of the event + :type timestamp: datetime + :param custom_dimensions: Custom dimensions of the event + :type custom_dimensions: + ~azure.applicationinsights.query.models.EventsResultDataCustomDimensions + :param custom_measurements: Custom measurements of the event + :type custom_measurements: + ~azure.applicationinsights.query.models.EventsResultDataCustomMeasurements + :param operation: Operation info of the event + :type operation: + ~azure.applicationinsights.query.models.EventsOperationInfo + :param session: Session info of the event + :type session: ~azure.applicationinsights.query.models.EventsSessionInfo + :param user: User info of the event + :type user: ~azure.applicationinsights.query.models.EventsUserInfo + :param cloud: Cloud info of the event + :type cloud: ~azure.applicationinsights.query.models.EventsCloudInfo + :param ai: AI info of the event + :type ai: ~azure.applicationinsights.query.models.EventsAiInfo + :param application: Application info of the event + :type application: + ~azure.applicationinsights.query.models.EventsApplicationInfo + :param client: Client info of the event + :type client: ~azure.applicationinsights.query.models.EventsClientInfo + :param type: Required. Constant filled by server. + :type type: str + :param browser_timing: + :type browser_timing: + ~azure.applicationinsights.query.models.EventsBrowserTimingInfo + :param client_performance: + :type client_performance: + ~azure.applicationinsights.query.models.EventsClientPerformanceInfo + """ + + _validation = { + 'type': {'required': True}, + } + + _attribute_map = { + 'id': {'key': 'id', 'type': 'str'}, + 'count': {'key': 'count', 'type': 'long'}, + 'timestamp': {'key': 'timestamp', 'type': 'iso-8601'}, + 'custom_dimensions': {'key': 'customDimensions', 'type': 'EventsResultDataCustomDimensions'}, + 'custom_measurements': {'key': 'customMeasurements', 'type': 'EventsResultDataCustomMeasurements'}, + 'operation': {'key': 'operation', 'type': 'EventsOperationInfo'}, + 'session': {'key': 'session', 'type': 'EventsSessionInfo'}, + 'user': {'key': 'user', 'type': 'EventsUserInfo'}, + 'cloud': {'key': 'cloud', 'type': 'EventsCloudInfo'}, + 'ai': {'key': 'ai', 'type': 'EventsAiInfo'}, + 'application': {'key': 'application', 'type': 'EventsApplicationInfo'}, + 'client': {'key': 'client', 'type': 'EventsClientInfo'}, + 'type': {'key': 'type', 'type': 'str'}, + 'browser_timing': {'key': 'browserTiming', 'type': 'EventsBrowserTimingInfo'}, + 'client_performance': {'key': 'clientPerformance', 'type': 'EventsClientPerformanceInfo'}, + } + + def __init__(self, *, id: str=None, count: int=None, timestamp=None, custom_dimensions=None, custom_measurements=None, operation=None, session=None, user=None, cloud=None, ai=None, application=None, client=None, browser_timing=None, client_performance=None, **kwargs) -> None: + super(EventsBrowserTimingResult, self).__init__(id=id, count=count, timestamp=timestamp, custom_dimensions=custom_dimensions, custom_measurements=custom_measurements, operation=operation, session=session, user=user, cloud=cloud, ai=ai, application=application, client=client, **kwargs) + self.browser_timing = browser_timing + self.client_performance = client_performance + self.type = 'browserTiming' diff --git a/azure-applicationinsights-query/models/events_client_info.py b/azure-applicationinsights-query/models/events_client_info.py new file mode 100644 index 000000000000..7827e8167d1f --- /dev/null +++ b/azure-applicationinsights-query/models/events_client_info.py @@ -0,0 +1,56 @@ +# coding=utf-8 +# -------------------------------------------------------------------------- +# Copyright (c) Microsoft Corporation. All rights reserved. +# Licensed under the MIT License. See License.txt in the project root for +# license information. +# +# Code generated by Microsoft (R) AutoRest Code Generator. +# Changes may cause incorrect behavior and will be lost if the code is +# regenerated. +# -------------------------------------------------------------------------- + +from msrest.serialization import Model + + +class EventsClientInfo(Model): + """Client info for an event result. + + :param model: Model of the client + :type model: str + :param os: Operating system of the client + :type os: str + :param type: Type of the client + :type type: str + :param browser: Browser of the client + :type browser: str + :param ip: IP address of the client + :type ip: str + :param city: City of the client + :type city: str + :param state_or_province: State or province of the client + :type state_or_province: str + :param country_or_region: Country or region of the client + :type country_or_region: str + """ + + _attribute_map = { + 'model': {'key': 'model', 'type': 'str'}, + 'os': {'key': 'os', 'type': 'str'}, + 'type': {'key': 'type', 'type': 'str'}, + 'browser': {'key': 'browser', 'type': 'str'}, + 'ip': {'key': 'ip', 'type': 'str'}, + 'city': {'key': 'city', 'type': 'str'}, + 'state_or_province': {'key': 'stateOrProvince', 'type': 'str'}, + 'country_or_region': {'key': 'countryOrRegion', 'type': 'str'}, + } + + def __init__(self, **kwargs): + super(EventsClientInfo, self).__init__(**kwargs) + self.model = kwargs.get('model', None) + self.os = kwargs.get('os', None) + self.type = kwargs.get('type', None) + self.browser = kwargs.get('browser', None) + self.ip = kwargs.get('ip', None) + self.city = kwargs.get('city', None) + self.state_or_province = kwargs.get('state_or_province', None) + self.country_or_region = kwargs.get('country_or_region', None) diff --git a/azure-applicationinsights-query/models/events_client_info_py3.py b/azure-applicationinsights-query/models/events_client_info_py3.py new file mode 100644 index 000000000000..92bf9e596889 --- /dev/null +++ b/azure-applicationinsights-query/models/events_client_info_py3.py @@ -0,0 +1,56 @@ +# coding=utf-8 +# -------------------------------------------------------------------------- +# Copyright (c) Microsoft Corporation. All rights reserved. +# Licensed under the MIT License. See License.txt in the project root for +# license information. +# +# Code generated by Microsoft (R) AutoRest Code Generator. +# Changes may cause incorrect behavior and will be lost if the code is +# regenerated. +# -------------------------------------------------------------------------- + +from msrest.serialization import Model + + +class EventsClientInfo(Model): + """Client info for an event result. + + :param model: Model of the client + :type model: str + :param os: Operating system of the client + :type os: str + :param type: Type of the client + :type type: str + :param browser: Browser of the client + :type browser: str + :param ip: IP address of the client + :type ip: str + :param city: City of the client + :type city: str + :param state_or_province: State or province of the client + :type state_or_province: str + :param country_or_region: Country or region of the client + :type country_or_region: str + """ + + _attribute_map = { + 'model': {'key': 'model', 'type': 'str'}, + 'os': {'key': 'os', 'type': 'str'}, + 'type': {'key': 'type', 'type': 'str'}, + 'browser': {'key': 'browser', 'type': 'str'}, + 'ip': {'key': 'ip', 'type': 'str'}, + 'city': {'key': 'city', 'type': 'str'}, + 'state_or_province': {'key': 'stateOrProvince', 'type': 'str'}, + 'country_or_region': {'key': 'countryOrRegion', 'type': 'str'}, + } + + def __init__(self, *, model: str=None, os: str=None, type: str=None, browser: str=None, ip: str=None, city: str=None, state_or_province: str=None, country_or_region: str=None, **kwargs) -> None: + super(EventsClientInfo, self).__init__(**kwargs) + self.model = model + self.os = os + self.type = type + self.browser = browser + self.ip = ip + self.city = city + self.state_or_province = state_or_province + self.country_or_region = country_or_region diff --git a/azure-applicationinsights-query/models/events_client_performance_info.py b/azure-applicationinsights-query/models/events_client_performance_info.py new file mode 100644 index 000000000000..84186213f139 --- /dev/null +++ b/azure-applicationinsights-query/models/events_client_performance_info.py @@ -0,0 +1,28 @@ +# coding=utf-8 +# -------------------------------------------------------------------------- +# Copyright (c) Microsoft Corporation. All rights reserved. +# Licensed under the MIT License. See License.txt in the project root for +# license information. +# +# Code generated by Microsoft (R) AutoRest Code Generator. +# Changes may cause incorrect behavior and will be lost if the code is +# regenerated. +# -------------------------------------------------------------------------- + +from msrest.serialization import Model + + +class EventsClientPerformanceInfo(Model): + """Client performance information. + + :param name: The name of the client performance + :type name: str + """ + + _attribute_map = { + 'name': {'key': 'name', 'type': 'str'}, + } + + def __init__(self, **kwargs): + super(EventsClientPerformanceInfo, self).__init__(**kwargs) + self.name = kwargs.get('name', None) diff --git a/azure-applicationinsights-query/models/events_client_performance_info_py3.py b/azure-applicationinsights-query/models/events_client_performance_info_py3.py new file mode 100644 index 000000000000..e0c47362385a --- /dev/null +++ b/azure-applicationinsights-query/models/events_client_performance_info_py3.py @@ -0,0 +1,28 @@ +# coding=utf-8 +# -------------------------------------------------------------------------- +# Copyright (c) Microsoft Corporation. All rights reserved. +# Licensed under the MIT License. See License.txt in the project root for +# license information. +# +# Code generated by Microsoft (R) AutoRest Code Generator. +# Changes may cause incorrect behavior and will be lost if the code is +# regenerated. +# -------------------------------------------------------------------------- + +from msrest.serialization import Model + + +class EventsClientPerformanceInfo(Model): + """Client performance information. + + :param name: The name of the client performance + :type name: str + """ + + _attribute_map = { + 'name': {'key': 'name', 'type': 'str'}, + } + + def __init__(self, *, name: str=None, **kwargs) -> None: + super(EventsClientPerformanceInfo, self).__init__(**kwargs) + self.name = name diff --git a/azure-applicationinsights-query/models/events_cloud_info.py b/azure-applicationinsights-query/models/events_cloud_info.py new file mode 100644 index 000000000000..547985375c52 --- /dev/null +++ b/azure-applicationinsights-query/models/events_cloud_info.py @@ -0,0 +1,32 @@ +# coding=utf-8 +# -------------------------------------------------------------------------- +# Copyright (c) Microsoft Corporation. All rights reserved. +# Licensed under the MIT License. See License.txt in the project root for +# license information. +# +# Code generated by Microsoft (R) AutoRest Code Generator. +# Changes may cause incorrect behavior and will be lost if the code is +# regenerated. +# -------------------------------------------------------------------------- + +from msrest.serialization import Model + + +class EventsCloudInfo(Model): + """Cloud info for an event result. + + :param role_name: Role name of the cloud + :type role_name: str + :param role_instance: Role instance of the cloud + :type role_instance: str + """ + + _attribute_map = { + 'role_name': {'key': 'roleName', 'type': 'str'}, + 'role_instance': {'key': 'roleInstance', 'type': 'str'}, + } + + def __init__(self, **kwargs): + super(EventsCloudInfo, self).__init__(**kwargs) + self.role_name = kwargs.get('role_name', None) + self.role_instance = kwargs.get('role_instance', None) diff --git a/azure-applicationinsights-query/models/events_cloud_info_py3.py b/azure-applicationinsights-query/models/events_cloud_info_py3.py new file mode 100644 index 000000000000..1024176027b2 --- /dev/null +++ b/azure-applicationinsights-query/models/events_cloud_info_py3.py @@ -0,0 +1,32 @@ +# coding=utf-8 +# -------------------------------------------------------------------------- +# Copyright (c) Microsoft Corporation. All rights reserved. +# Licensed under the MIT License. See License.txt in the project root for +# license information. +# +# Code generated by Microsoft (R) AutoRest Code Generator. +# Changes may cause incorrect behavior and will be lost if the code is +# regenerated. +# -------------------------------------------------------------------------- + +from msrest.serialization import Model + + +class EventsCloudInfo(Model): + """Cloud info for an event result. + + :param role_name: Role name of the cloud + :type role_name: str + :param role_instance: Role instance of the cloud + :type role_instance: str + """ + + _attribute_map = { + 'role_name': {'key': 'roleName', 'type': 'str'}, + 'role_instance': {'key': 'roleInstance', 'type': 'str'}, + } + + def __init__(self, *, role_name: str=None, role_instance: str=None, **kwargs) -> None: + super(EventsCloudInfo, self).__init__(**kwargs) + self.role_name = role_name + self.role_instance = role_instance diff --git a/azure-applicationinsights-query/models/events_custom_event_info.py b/azure-applicationinsights-query/models/events_custom_event_info.py new file mode 100644 index 000000000000..1b0afe7f2232 --- /dev/null +++ b/azure-applicationinsights-query/models/events_custom_event_info.py @@ -0,0 +1,28 @@ +# coding=utf-8 +# -------------------------------------------------------------------------- +# Copyright (c) Microsoft Corporation. All rights reserved. +# Licensed under the MIT License. See License.txt in the project root for +# license information. +# +# Code generated by Microsoft (R) AutoRest Code Generator. +# Changes may cause incorrect behavior and will be lost if the code is +# regenerated. +# -------------------------------------------------------------------------- + +from msrest.serialization import Model + + +class EventsCustomEventInfo(Model): + """The custom event information. + + :param name: The name of the custom event + :type name: str + """ + + _attribute_map = { + 'name': {'key': 'name', 'type': 'str'}, + } + + def __init__(self, **kwargs): + super(EventsCustomEventInfo, self).__init__(**kwargs) + self.name = kwargs.get('name', None) diff --git a/azure-applicationinsights-query/models/events_custom_event_info_py3.py b/azure-applicationinsights-query/models/events_custom_event_info_py3.py new file mode 100644 index 000000000000..68ae8f3a7903 --- /dev/null +++ b/azure-applicationinsights-query/models/events_custom_event_info_py3.py @@ -0,0 +1,28 @@ +# coding=utf-8 +# -------------------------------------------------------------------------- +# Copyright (c) Microsoft Corporation. All rights reserved. +# Licensed under the MIT License. See License.txt in the project root for +# license information. +# +# Code generated by Microsoft (R) AutoRest Code Generator. +# Changes may cause incorrect behavior and will be lost if the code is +# regenerated. +# -------------------------------------------------------------------------- + +from msrest.serialization import Model + + +class EventsCustomEventInfo(Model): + """The custom event information. + + :param name: The name of the custom event + :type name: str + """ + + _attribute_map = { + 'name': {'key': 'name', 'type': 'str'}, + } + + def __init__(self, *, name: str=None, **kwargs) -> None: + super(EventsCustomEventInfo, self).__init__(**kwargs) + self.name = name diff --git a/azure-applicationinsights-query/models/events_custom_event_result.py b/azure-applicationinsights-query/models/events_custom_event_result.py new file mode 100644 index 000000000000..f8e3739c4ead --- /dev/null +++ b/azure-applicationinsights-query/models/events_custom_event_result.py @@ -0,0 +1,79 @@ +# coding=utf-8 +# -------------------------------------------------------------------------- +# Copyright (c) Microsoft Corporation. All rights reserved. +# Licensed under the MIT License. See License.txt in the project root for +# license information. +# +# Code generated by Microsoft (R) AutoRest Code Generator. +# Changes may cause incorrect behavior and will be lost if the code is +# regenerated. +# -------------------------------------------------------------------------- + +from .events_result_data import EventsResultData + + +class EventsCustomEventResult(EventsResultData): + """A custom event result. + + All required parameters must be populated in order to send to Azure. + + :param id: The unique ID for this event. + :type id: str + :param count: Count of the event + :type count: long + :param timestamp: Timestamp of the event + :type timestamp: datetime + :param custom_dimensions: Custom dimensions of the event + :type custom_dimensions: + ~azure.applicationinsights.query.models.EventsResultDataCustomDimensions + :param custom_measurements: Custom measurements of the event + :type custom_measurements: + ~azure.applicationinsights.query.models.EventsResultDataCustomMeasurements + :param operation: Operation info of the event + :type operation: + ~azure.applicationinsights.query.models.EventsOperationInfo + :param session: Session info of the event + :type session: ~azure.applicationinsights.query.models.EventsSessionInfo + :param user: User info of the event + :type user: ~azure.applicationinsights.query.models.EventsUserInfo + :param cloud: Cloud info of the event + :type cloud: ~azure.applicationinsights.query.models.EventsCloudInfo + :param ai: AI info of the event + :type ai: ~azure.applicationinsights.query.models.EventsAiInfo + :param application: Application info of the event + :type application: + ~azure.applicationinsights.query.models.EventsApplicationInfo + :param client: Client info of the event + :type client: ~azure.applicationinsights.query.models.EventsClientInfo + :param type: Required. Constant filled by server. + :type type: str + :param custom_event: + :type custom_event: + ~azure.applicationinsights.query.models.EventsCustomEventInfo + """ + + _validation = { + 'type': {'required': True}, + } + + _attribute_map = { + 'id': {'key': 'id', 'type': 'str'}, + 'count': {'key': 'count', 'type': 'long'}, + 'timestamp': {'key': 'timestamp', 'type': 'iso-8601'}, + 'custom_dimensions': {'key': 'customDimensions', 'type': 'EventsResultDataCustomDimensions'}, + 'custom_measurements': {'key': 'customMeasurements', 'type': 'EventsResultDataCustomMeasurements'}, + 'operation': {'key': 'operation', 'type': 'EventsOperationInfo'}, + 'session': {'key': 'session', 'type': 'EventsSessionInfo'}, + 'user': {'key': 'user', 'type': 'EventsUserInfo'}, + 'cloud': {'key': 'cloud', 'type': 'EventsCloudInfo'}, + 'ai': {'key': 'ai', 'type': 'EventsAiInfo'}, + 'application': {'key': 'application', 'type': 'EventsApplicationInfo'}, + 'client': {'key': 'client', 'type': 'EventsClientInfo'}, + 'type': {'key': 'type', 'type': 'str'}, + 'custom_event': {'key': 'customEvent', 'type': 'EventsCustomEventInfo'}, + } + + def __init__(self, **kwargs): + super(EventsCustomEventResult, self).__init__(**kwargs) + self.custom_event = kwargs.get('custom_event', None) + self.type = 'customEvent' diff --git a/azure-applicationinsights-query/models/events_custom_event_result_py3.py b/azure-applicationinsights-query/models/events_custom_event_result_py3.py new file mode 100644 index 000000000000..56f817395111 --- /dev/null +++ b/azure-applicationinsights-query/models/events_custom_event_result_py3.py @@ -0,0 +1,79 @@ +# coding=utf-8 +# -------------------------------------------------------------------------- +# Copyright (c) Microsoft Corporation. All rights reserved. +# Licensed under the MIT License. See License.txt in the project root for +# license information. +# +# Code generated by Microsoft (R) AutoRest Code Generator. +# Changes may cause incorrect behavior and will be lost if the code is +# regenerated. +# -------------------------------------------------------------------------- + +from .events_result_data_py3 import EventsResultData + + +class EventsCustomEventResult(EventsResultData): + """A custom event result. + + All required parameters must be populated in order to send to Azure. + + :param id: The unique ID for this event. + :type id: str + :param count: Count of the event + :type count: long + :param timestamp: Timestamp of the event + :type timestamp: datetime + :param custom_dimensions: Custom dimensions of the event + :type custom_dimensions: + ~azure.applicationinsights.query.models.EventsResultDataCustomDimensions + :param custom_measurements: Custom measurements of the event + :type custom_measurements: + ~azure.applicationinsights.query.models.EventsResultDataCustomMeasurements + :param operation: Operation info of the event + :type operation: + ~azure.applicationinsights.query.models.EventsOperationInfo + :param session: Session info of the event + :type session: ~azure.applicationinsights.query.models.EventsSessionInfo + :param user: User info of the event + :type user: ~azure.applicationinsights.query.models.EventsUserInfo + :param cloud: Cloud info of the event + :type cloud: ~azure.applicationinsights.query.models.EventsCloudInfo + :param ai: AI info of the event + :type ai: ~azure.applicationinsights.query.models.EventsAiInfo + :param application: Application info of the event + :type application: + ~azure.applicationinsights.query.models.EventsApplicationInfo + :param client: Client info of the event + :type client: ~azure.applicationinsights.query.models.EventsClientInfo + :param type: Required. Constant filled by server. + :type type: str + :param custom_event: + :type custom_event: + ~azure.applicationinsights.query.models.EventsCustomEventInfo + """ + + _validation = { + 'type': {'required': True}, + } + + _attribute_map = { + 'id': {'key': 'id', 'type': 'str'}, + 'count': {'key': 'count', 'type': 'long'}, + 'timestamp': {'key': 'timestamp', 'type': 'iso-8601'}, + 'custom_dimensions': {'key': 'customDimensions', 'type': 'EventsResultDataCustomDimensions'}, + 'custom_measurements': {'key': 'customMeasurements', 'type': 'EventsResultDataCustomMeasurements'}, + 'operation': {'key': 'operation', 'type': 'EventsOperationInfo'}, + 'session': {'key': 'session', 'type': 'EventsSessionInfo'}, + 'user': {'key': 'user', 'type': 'EventsUserInfo'}, + 'cloud': {'key': 'cloud', 'type': 'EventsCloudInfo'}, + 'ai': {'key': 'ai', 'type': 'EventsAiInfo'}, + 'application': {'key': 'application', 'type': 'EventsApplicationInfo'}, + 'client': {'key': 'client', 'type': 'EventsClientInfo'}, + 'type': {'key': 'type', 'type': 'str'}, + 'custom_event': {'key': 'customEvent', 'type': 'EventsCustomEventInfo'}, + } + + def __init__(self, *, id: str=None, count: int=None, timestamp=None, custom_dimensions=None, custom_measurements=None, operation=None, session=None, user=None, cloud=None, ai=None, application=None, client=None, custom_event=None, **kwargs) -> None: + super(EventsCustomEventResult, self).__init__(id=id, count=count, timestamp=timestamp, custom_dimensions=custom_dimensions, custom_measurements=custom_measurements, operation=operation, session=session, user=user, cloud=cloud, ai=ai, application=application, client=client, **kwargs) + self.custom_event = custom_event + self.type = 'customEvent' diff --git a/azure-applicationinsights-query/models/events_custom_metric_info.py b/azure-applicationinsights-query/models/events_custom_metric_info.py new file mode 100644 index 000000000000..161b88aab45c --- /dev/null +++ b/azure-applicationinsights-query/models/events_custom_metric_info.py @@ -0,0 +1,52 @@ +# coding=utf-8 +# -------------------------------------------------------------------------- +# Copyright (c) Microsoft Corporation. All rights reserved. +# Licensed under the MIT License. See License.txt in the project root for +# license information. +# +# Code generated by Microsoft (R) AutoRest Code Generator. +# Changes may cause incorrect behavior and will be lost if the code is +# regenerated. +# -------------------------------------------------------------------------- + +from msrest.serialization import Model + + +class EventsCustomMetricInfo(Model): + """The custom metric info. + + :param name: The name of the custom metric + :type name: str + :param value: The value of the custom metric + :type value: float + :param value_sum: The sum of the custom metric + :type value_sum: float + :param value_count: The count of the custom metric + :type value_count: int + :param value_min: The minimum value of the custom metric + :type value_min: float + :param value_max: The maximum value of the custom metric + :type value_max: float + :param value_std_dev: The standard deviation of the custom metric + :type value_std_dev: float + """ + + _attribute_map = { + 'name': {'key': 'name', 'type': 'str'}, + 'value': {'key': 'value', 'type': 'float'}, + 'value_sum': {'key': 'valueSum', 'type': 'float'}, + 'value_count': {'key': 'valueCount', 'type': 'int'}, + 'value_min': {'key': 'valueMin', 'type': 'float'}, + 'value_max': {'key': 'valueMax', 'type': 'float'}, + 'value_std_dev': {'key': 'valueStdDev', 'type': 'float'}, + } + + def __init__(self, **kwargs): + super(EventsCustomMetricInfo, self).__init__(**kwargs) + self.name = kwargs.get('name', None) + self.value = kwargs.get('value', None) + self.value_sum = kwargs.get('value_sum', None) + self.value_count = kwargs.get('value_count', None) + self.value_min = kwargs.get('value_min', None) + self.value_max = kwargs.get('value_max', None) + self.value_std_dev = kwargs.get('value_std_dev', None) diff --git a/azure-applicationinsights-query/models/events_custom_metric_info_py3.py b/azure-applicationinsights-query/models/events_custom_metric_info_py3.py new file mode 100644 index 000000000000..e2d46ef2d2ef --- /dev/null +++ b/azure-applicationinsights-query/models/events_custom_metric_info_py3.py @@ -0,0 +1,52 @@ +# coding=utf-8 +# -------------------------------------------------------------------------- +# Copyright (c) Microsoft Corporation. All rights reserved. +# Licensed under the MIT License. See License.txt in the project root for +# license information. +# +# Code generated by Microsoft (R) AutoRest Code Generator. +# Changes may cause incorrect behavior and will be lost if the code is +# regenerated. +# -------------------------------------------------------------------------- + +from msrest.serialization import Model + + +class EventsCustomMetricInfo(Model): + """The custom metric info. + + :param name: The name of the custom metric + :type name: str + :param value: The value of the custom metric + :type value: float + :param value_sum: The sum of the custom metric + :type value_sum: float + :param value_count: The count of the custom metric + :type value_count: int + :param value_min: The minimum value of the custom metric + :type value_min: float + :param value_max: The maximum value of the custom metric + :type value_max: float + :param value_std_dev: The standard deviation of the custom metric + :type value_std_dev: float + """ + + _attribute_map = { + 'name': {'key': 'name', 'type': 'str'}, + 'value': {'key': 'value', 'type': 'float'}, + 'value_sum': {'key': 'valueSum', 'type': 'float'}, + 'value_count': {'key': 'valueCount', 'type': 'int'}, + 'value_min': {'key': 'valueMin', 'type': 'float'}, + 'value_max': {'key': 'valueMax', 'type': 'float'}, + 'value_std_dev': {'key': 'valueStdDev', 'type': 'float'}, + } + + def __init__(self, *, name: str=None, value: float=None, value_sum: float=None, value_count: int=None, value_min: float=None, value_max: float=None, value_std_dev: float=None, **kwargs) -> None: + super(EventsCustomMetricInfo, self).__init__(**kwargs) + self.name = name + self.value = value + self.value_sum = value_sum + self.value_count = value_count + self.value_min = value_min + self.value_max = value_max + self.value_std_dev = value_std_dev diff --git a/azure-applicationinsights-query/models/events_custom_metric_result.py b/azure-applicationinsights-query/models/events_custom_metric_result.py new file mode 100644 index 000000000000..d420605530a8 --- /dev/null +++ b/azure-applicationinsights-query/models/events_custom_metric_result.py @@ -0,0 +1,79 @@ +# coding=utf-8 +# -------------------------------------------------------------------------- +# Copyright (c) Microsoft Corporation. All rights reserved. +# Licensed under the MIT License. See License.txt in the project root for +# license information. +# +# Code generated by Microsoft (R) AutoRest Code Generator. +# Changes may cause incorrect behavior and will be lost if the code is +# regenerated. +# -------------------------------------------------------------------------- + +from .events_result_data import EventsResultData + + +class EventsCustomMetricResult(EventsResultData): + """A custom metric result. + + All required parameters must be populated in order to send to Azure. + + :param id: The unique ID for this event. + :type id: str + :param count: Count of the event + :type count: long + :param timestamp: Timestamp of the event + :type timestamp: datetime + :param custom_dimensions: Custom dimensions of the event + :type custom_dimensions: + ~azure.applicationinsights.query.models.EventsResultDataCustomDimensions + :param custom_measurements: Custom measurements of the event + :type custom_measurements: + ~azure.applicationinsights.query.models.EventsResultDataCustomMeasurements + :param operation: Operation info of the event + :type operation: + ~azure.applicationinsights.query.models.EventsOperationInfo + :param session: Session info of the event + :type session: ~azure.applicationinsights.query.models.EventsSessionInfo + :param user: User info of the event + :type user: ~azure.applicationinsights.query.models.EventsUserInfo + :param cloud: Cloud info of the event + :type cloud: ~azure.applicationinsights.query.models.EventsCloudInfo + :param ai: AI info of the event + :type ai: ~azure.applicationinsights.query.models.EventsAiInfo + :param application: Application info of the event + :type application: + ~azure.applicationinsights.query.models.EventsApplicationInfo + :param client: Client info of the event + :type client: ~azure.applicationinsights.query.models.EventsClientInfo + :param type: Required. Constant filled by server. + :type type: str + :param custom_metric: + :type custom_metric: + ~azure.applicationinsights.query.models.EventsCustomMetricInfo + """ + + _validation = { + 'type': {'required': True}, + } + + _attribute_map = { + 'id': {'key': 'id', 'type': 'str'}, + 'count': {'key': 'count', 'type': 'long'}, + 'timestamp': {'key': 'timestamp', 'type': 'iso-8601'}, + 'custom_dimensions': {'key': 'customDimensions', 'type': 'EventsResultDataCustomDimensions'}, + 'custom_measurements': {'key': 'customMeasurements', 'type': 'EventsResultDataCustomMeasurements'}, + 'operation': {'key': 'operation', 'type': 'EventsOperationInfo'}, + 'session': {'key': 'session', 'type': 'EventsSessionInfo'}, + 'user': {'key': 'user', 'type': 'EventsUserInfo'}, + 'cloud': {'key': 'cloud', 'type': 'EventsCloudInfo'}, + 'ai': {'key': 'ai', 'type': 'EventsAiInfo'}, + 'application': {'key': 'application', 'type': 'EventsApplicationInfo'}, + 'client': {'key': 'client', 'type': 'EventsClientInfo'}, + 'type': {'key': 'type', 'type': 'str'}, + 'custom_metric': {'key': 'customMetric', 'type': 'EventsCustomMetricInfo'}, + } + + def __init__(self, **kwargs): + super(EventsCustomMetricResult, self).__init__(**kwargs) + self.custom_metric = kwargs.get('custom_metric', None) + self.type = 'customMetric' diff --git a/azure-applicationinsights-query/models/events_custom_metric_result_py3.py b/azure-applicationinsights-query/models/events_custom_metric_result_py3.py new file mode 100644 index 000000000000..1ee698b7826d --- /dev/null +++ b/azure-applicationinsights-query/models/events_custom_metric_result_py3.py @@ -0,0 +1,79 @@ +# coding=utf-8 +# -------------------------------------------------------------------------- +# Copyright (c) Microsoft Corporation. All rights reserved. +# Licensed under the MIT License. See License.txt in the project root for +# license information. +# +# Code generated by Microsoft (R) AutoRest Code Generator. +# Changes may cause incorrect behavior and will be lost if the code is +# regenerated. +# -------------------------------------------------------------------------- + +from .events_result_data_py3 import EventsResultData + + +class EventsCustomMetricResult(EventsResultData): + """A custom metric result. + + All required parameters must be populated in order to send to Azure. + + :param id: The unique ID for this event. + :type id: str + :param count: Count of the event + :type count: long + :param timestamp: Timestamp of the event + :type timestamp: datetime + :param custom_dimensions: Custom dimensions of the event + :type custom_dimensions: + ~azure.applicationinsights.query.models.EventsResultDataCustomDimensions + :param custom_measurements: Custom measurements of the event + :type custom_measurements: + ~azure.applicationinsights.query.models.EventsResultDataCustomMeasurements + :param operation: Operation info of the event + :type operation: + ~azure.applicationinsights.query.models.EventsOperationInfo + :param session: Session info of the event + :type session: ~azure.applicationinsights.query.models.EventsSessionInfo + :param user: User info of the event + :type user: ~azure.applicationinsights.query.models.EventsUserInfo + :param cloud: Cloud info of the event + :type cloud: ~azure.applicationinsights.query.models.EventsCloudInfo + :param ai: AI info of the event + :type ai: ~azure.applicationinsights.query.models.EventsAiInfo + :param application: Application info of the event + :type application: + ~azure.applicationinsights.query.models.EventsApplicationInfo + :param client: Client info of the event + :type client: ~azure.applicationinsights.query.models.EventsClientInfo + :param type: Required. Constant filled by server. + :type type: str + :param custom_metric: + :type custom_metric: + ~azure.applicationinsights.query.models.EventsCustomMetricInfo + """ + + _validation = { + 'type': {'required': True}, + } + + _attribute_map = { + 'id': {'key': 'id', 'type': 'str'}, + 'count': {'key': 'count', 'type': 'long'}, + 'timestamp': {'key': 'timestamp', 'type': 'iso-8601'}, + 'custom_dimensions': {'key': 'customDimensions', 'type': 'EventsResultDataCustomDimensions'}, + 'custom_measurements': {'key': 'customMeasurements', 'type': 'EventsResultDataCustomMeasurements'}, + 'operation': {'key': 'operation', 'type': 'EventsOperationInfo'}, + 'session': {'key': 'session', 'type': 'EventsSessionInfo'}, + 'user': {'key': 'user', 'type': 'EventsUserInfo'}, + 'cloud': {'key': 'cloud', 'type': 'EventsCloudInfo'}, + 'ai': {'key': 'ai', 'type': 'EventsAiInfo'}, + 'application': {'key': 'application', 'type': 'EventsApplicationInfo'}, + 'client': {'key': 'client', 'type': 'EventsClientInfo'}, + 'type': {'key': 'type', 'type': 'str'}, + 'custom_metric': {'key': 'customMetric', 'type': 'EventsCustomMetricInfo'}, + } + + def __init__(self, *, id: str=None, count: int=None, timestamp=None, custom_dimensions=None, custom_measurements=None, operation=None, session=None, user=None, cloud=None, ai=None, application=None, client=None, custom_metric=None, **kwargs) -> None: + super(EventsCustomMetricResult, self).__init__(id=id, count=count, timestamp=timestamp, custom_dimensions=custom_dimensions, custom_measurements=custom_measurements, operation=operation, session=session, user=user, cloud=cloud, ai=ai, application=application, client=client, **kwargs) + self.custom_metric = custom_metric + self.type = 'customMetric' diff --git a/azure-applicationinsights-query/models/events_dependency_info.py b/azure-applicationinsights-query/models/events_dependency_info.py new file mode 100644 index 000000000000..0e8ce3511e42 --- /dev/null +++ b/azure-applicationinsights-query/models/events_dependency_info.py @@ -0,0 +1,60 @@ +# coding=utf-8 +# -------------------------------------------------------------------------- +# Copyright (c) Microsoft Corporation. All rights reserved. +# Licensed under the MIT License. See License.txt in the project root for +# license information. +# +# Code generated by Microsoft (R) AutoRest Code Generator. +# Changes may cause incorrect behavior and will be lost if the code is +# regenerated. +# -------------------------------------------------------------------------- + +from msrest.serialization import Model + + +class EventsDependencyInfo(Model): + """The dependency info. + + :param target: The target of the dependency + :type target: str + :param data: The data of the dependency + :type data: str + :param success: Indicates if the dependency was successful + :type success: str + :param duration: The duration of the dependency + :type duration: long + :param performance_bucket: The performance bucket of the dependency + :type performance_bucket: str + :param result_code: The result code of the dependency + :type result_code: str + :param type: The type of the dependency + :type type: str + :param name: The name of the dependency + :type name: str + :param id: The ID of the dependency + :type id: str + """ + + _attribute_map = { + 'target': {'key': 'target', 'type': 'str'}, + 'data': {'key': 'data', 'type': 'str'}, + 'success': {'key': 'success', 'type': 'str'}, + 'duration': {'key': 'duration', 'type': 'long'}, + 'performance_bucket': {'key': 'performanceBucket', 'type': 'str'}, + 'result_code': {'key': 'resultCode', 'type': 'str'}, + 'type': {'key': 'type', 'type': 'str'}, + 'name': {'key': 'name', 'type': 'str'}, + 'id': {'key': 'id', 'type': 'str'}, + } + + def __init__(self, **kwargs): + super(EventsDependencyInfo, self).__init__(**kwargs) + self.target = kwargs.get('target', None) + self.data = kwargs.get('data', None) + self.success = kwargs.get('success', None) + self.duration = kwargs.get('duration', None) + self.performance_bucket = kwargs.get('performance_bucket', None) + self.result_code = kwargs.get('result_code', None) + self.type = kwargs.get('type', None) + self.name = kwargs.get('name', None) + self.id = kwargs.get('id', None) diff --git a/azure-applicationinsights-query/models/events_dependency_info_py3.py b/azure-applicationinsights-query/models/events_dependency_info_py3.py new file mode 100644 index 000000000000..4472b9ba4464 --- /dev/null +++ b/azure-applicationinsights-query/models/events_dependency_info_py3.py @@ -0,0 +1,60 @@ +# coding=utf-8 +# -------------------------------------------------------------------------- +# Copyright (c) Microsoft Corporation. All rights reserved. +# Licensed under the MIT License. See License.txt in the project root for +# license information. +# +# Code generated by Microsoft (R) AutoRest Code Generator. +# Changes may cause incorrect behavior and will be lost if the code is +# regenerated. +# -------------------------------------------------------------------------- + +from msrest.serialization import Model + + +class EventsDependencyInfo(Model): + """The dependency info. + + :param target: The target of the dependency + :type target: str + :param data: The data of the dependency + :type data: str + :param success: Indicates if the dependency was successful + :type success: str + :param duration: The duration of the dependency + :type duration: long + :param performance_bucket: The performance bucket of the dependency + :type performance_bucket: str + :param result_code: The result code of the dependency + :type result_code: str + :param type: The type of the dependency + :type type: str + :param name: The name of the dependency + :type name: str + :param id: The ID of the dependency + :type id: str + """ + + _attribute_map = { + 'target': {'key': 'target', 'type': 'str'}, + 'data': {'key': 'data', 'type': 'str'}, + 'success': {'key': 'success', 'type': 'str'}, + 'duration': {'key': 'duration', 'type': 'long'}, + 'performance_bucket': {'key': 'performanceBucket', 'type': 'str'}, + 'result_code': {'key': 'resultCode', 'type': 'str'}, + 'type': {'key': 'type', 'type': 'str'}, + 'name': {'key': 'name', 'type': 'str'}, + 'id': {'key': 'id', 'type': 'str'}, + } + + def __init__(self, *, target: str=None, data: str=None, success: str=None, duration: int=None, performance_bucket: str=None, result_code: str=None, type: str=None, name: str=None, id: str=None, **kwargs) -> None: + super(EventsDependencyInfo, self).__init__(**kwargs) + self.target = target + self.data = data + self.success = success + self.duration = duration + self.performance_bucket = performance_bucket + self.result_code = result_code + self.type = type + self.name = name + self.id = id diff --git a/azure-applicationinsights-query/models/events_dependency_result.py b/azure-applicationinsights-query/models/events_dependency_result.py new file mode 100644 index 000000000000..f8fa5ff21abf --- /dev/null +++ b/azure-applicationinsights-query/models/events_dependency_result.py @@ -0,0 +1,79 @@ +# coding=utf-8 +# -------------------------------------------------------------------------- +# Copyright (c) Microsoft Corporation. All rights reserved. +# Licensed under the MIT License. See License.txt in the project root for +# license information. +# +# Code generated by Microsoft (R) AutoRest Code Generator. +# Changes may cause incorrect behavior and will be lost if the code is +# regenerated. +# -------------------------------------------------------------------------- + +from .events_result_data import EventsResultData + + +class EventsDependencyResult(EventsResultData): + """A dependency result. + + All required parameters must be populated in order to send to Azure. + + :param id: The unique ID for this event. + :type id: str + :param count: Count of the event + :type count: long + :param timestamp: Timestamp of the event + :type timestamp: datetime + :param custom_dimensions: Custom dimensions of the event + :type custom_dimensions: + ~azure.applicationinsights.query.models.EventsResultDataCustomDimensions + :param custom_measurements: Custom measurements of the event + :type custom_measurements: + ~azure.applicationinsights.query.models.EventsResultDataCustomMeasurements + :param operation: Operation info of the event + :type operation: + ~azure.applicationinsights.query.models.EventsOperationInfo + :param session: Session info of the event + :type session: ~azure.applicationinsights.query.models.EventsSessionInfo + :param user: User info of the event + :type user: ~azure.applicationinsights.query.models.EventsUserInfo + :param cloud: Cloud info of the event + :type cloud: ~azure.applicationinsights.query.models.EventsCloudInfo + :param ai: AI info of the event + :type ai: ~azure.applicationinsights.query.models.EventsAiInfo + :param application: Application info of the event + :type application: + ~azure.applicationinsights.query.models.EventsApplicationInfo + :param client: Client info of the event + :type client: ~azure.applicationinsights.query.models.EventsClientInfo + :param type: Required. Constant filled by server. + :type type: str + :param dependency: + :type dependency: + ~azure.applicationinsights.query.models.EventsDependencyInfo + """ + + _validation = { + 'type': {'required': True}, + } + + _attribute_map = { + 'id': {'key': 'id', 'type': 'str'}, + 'count': {'key': 'count', 'type': 'long'}, + 'timestamp': {'key': 'timestamp', 'type': 'iso-8601'}, + 'custom_dimensions': {'key': 'customDimensions', 'type': 'EventsResultDataCustomDimensions'}, + 'custom_measurements': {'key': 'customMeasurements', 'type': 'EventsResultDataCustomMeasurements'}, + 'operation': {'key': 'operation', 'type': 'EventsOperationInfo'}, + 'session': {'key': 'session', 'type': 'EventsSessionInfo'}, + 'user': {'key': 'user', 'type': 'EventsUserInfo'}, + 'cloud': {'key': 'cloud', 'type': 'EventsCloudInfo'}, + 'ai': {'key': 'ai', 'type': 'EventsAiInfo'}, + 'application': {'key': 'application', 'type': 'EventsApplicationInfo'}, + 'client': {'key': 'client', 'type': 'EventsClientInfo'}, + 'type': {'key': 'type', 'type': 'str'}, + 'dependency': {'key': 'dependency', 'type': 'EventsDependencyInfo'}, + } + + def __init__(self, **kwargs): + super(EventsDependencyResult, self).__init__(**kwargs) + self.dependency = kwargs.get('dependency', None) + self.type = 'dependency' diff --git a/azure-applicationinsights-query/models/events_dependency_result_py3.py b/azure-applicationinsights-query/models/events_dependency_result_py3.py new file mode 100644 index 000000000000..6e70948305d5 --- /dev/null +++ b/azure-applicationinsights-query/models/events_dependency_result_py3.py @@ -0,0 +1,79 @@ +# coding=utf-8 +# -------------------------------------------------------------------------- +# Copyright (c) Microsoft Corporation. All rights reserved. +# Licensed under the MIT License. See License.txt in the project root for +# license information. +# +# Code generated by Microsoft (R) AutoRest Code Generator. +# Changes may cause incorrect behavior and will be lost if the code is +# regenerated. +# -------------------------------------------------------------------------- + +from .events_result_data_py3 import EventsResultData + + +class EventsDependencyResult(EventsResultData): + """A dependency result. + + All required parameters must be populated in order to send to Azure. + + :param id: The unique ID for this event. + :type id: str + :param count: Count of the event + :type count: long + :param timestamp: Timestamp of the event + :type timestamp: datetime + :param custom_dimensions: Custom dimensions of the event + :type custom_dimensions: + ~azure.applicationinsights.query.models.EventsResultDataCustomDimensions + :param custom_measurements: Custom measurements of the event + :type custom_measurements: + ~azure.applicationinsights.query.models.EventsResultDataCustomMeasurements + :param operation: Operation info of the event + :type operation: + ~azure.applicationinsights.query.models.EventsOperationInfo + :param session: Session info of the event + :type session: ~azure.applicationinsights.query.models.EventsSessionInfo + :param user: User info of the event + :type user: ~azure.applicationinsights.query.models.EventsUserInfo + :param cloud: Cloud info of the event + :type cloud: ~azure.applicationinsights.query.models.EventsCloudInfo + :param ai: AI info of the event + :type ai: ~azure.applicationinsights.query.models.EventsAiInfo + :param application: Application info of the event + :type application: + ~azure.applicationinsights.query.models.EventsApplicationInfo + :param client: Client info of the event + :type client: ~azure.applicationinsights.query.models.EventsClientInfo + :param type: Required. Constant filled by server. + :type type: str + :param dependency: + :type dependency: + ~azure.applicationinsights.query.models.EventsDependencyInfo + """ + + _validation = { + 'type': {'required': True}, + } + + _attribute_map = { + 'id': {'key': 'id', 'type': 'str'}, + 'count': {'key': 'count', 'type': 'long'}, + 'timestamp': {'key': 'timestamp', 'type': 'iso-8601'}, + 'custom_dimensions': {'key': 'customDimensions', 'type': 'EventsResultDataCustomDimensions'}, + 'custom_measurements': {'key': 'customMeasurements', 'type': 'EventsResultDataCustomMeasurements'}, + 'operation': {'key': 'operation', 'type': 'EventsOperationInfo'}, + 'session': {'key': 'session', 'type': 'EventsSessionInfo'}, + 'user': {'key': 'user', 'type': 'EventsUserInfo'}, + 'cloud': {'key': 'cloud', 'type': 'EventsCloudInfo'}, + 'ai': {'key': 'ai', 'type': 'EventsAiInfo'}, + 'application': {'key': 'application', 'type': 'EventsApplicationInfo'}, + 'client': {'key': 'client', 'type': 'EventsClientInfo'}, + 'type': {'key': 'type', 'type': 'str'}, + 'dependency': {'key': 'dependency', 'type': 'EventsDependencyInfo'}, + } + + def __init__(self, *, id: str=None, count: int=None, timestamp=None, custom_dimensions=None, custom_measurements=None, operation=None, session=None, user=None, cloud=None, ai=None, application=None, client=None, dependency=None, **kwargs) -> None: + super(EventsDependencyResult, self).__init__(id=id, count=count, timestamp=timestamp, custom_dimensions=custom_dimensions, custom_measurements=custom_measurements, operation=operation, session=session, user=user, cloud=cloud, ai=ai, application=application, client=client, **kwargs) + self.dependency = dependency + self.type = 'dependency' diff --git a/azure-applicationinsights-query/models/events_exception_detail.py b/azure-applicationinsights-query/models/events_exception_detail.py new file mode 100644 index 000000000000..6a6547a733fd --- /dev/null +++ b/azure-applicationinsights-query/models/events_exception_detail.py @@ -0,0 +1,49 @@ +# coding=utf-8 +# -------------------------------------------------------------------------- +# Copyright (c) Microsoft Corporation. All rights reserved. +# Licensed under the MIT License. See License.txt in the project root for +# license information. +# +# Code generated by Microsoft (R) AutoRest Code Generator. +# Changes may cause incorrect behavior and will be lost if the code is +# regenerated. +# -------------------------------------------------------------------------- + +from msrest.serialization import Model + + +class EventsExceptionDetail(Model): + """Exception details. + + :param severity_level: The severity level of the exception detail + :type severity_level: str + :param outer_id: The outer ID of the exception detail + :type outer_id: str + :param message: The message of the exception detail + :type message: str + :param type: The type of the exception detail + :type type: str + :param id: The ID of the exception detail + :type id: str + :param parsed_stack: The parsed stack + :type parsed_stack: + list[~azure.applicationinsights.query.models.EventsExceptionDetailsParsedStack] + """ + + _attribute_map = { + 'severity_level': {'key': 'severityLevel', 'type': 'str'}, + 'outer_id': {'key': 'outerId', 'type': 'str'}, + 'message': {'key': 'message', 'type': 'str'}, + 'type': {'key': 'type', 'type': 'str'}, + 'id': {'key': 'id', 'type': 'str'}, + 'parsed_stack': {'key': 'parsedStack', 'type': '[EventsExceptionDetailsParsedStack]'}, + } + + def __init__(self, **kwargs): + super(EventsExceptionDetail, self).__init__(**kwargs) + self.severity_level = kwargs.get('severity_level', None) + self.outer_id = kwargs.get('outer_id', None) + self.message = kwargs.get('message', None) + self.type = kwargs.get('type', None) + self.id = kwargs.get('id', None) + self.parsed_stack = kwargs.get('parsed_stack', None) diff --git a/azure-applicationinsights-query/models/events_exception_detail_py3.py b/azure-applicationinsights-query/models/events_exception_detail_py3.py new file mode 100644 index 000000000000..0d1b2a90958e --- /dev/null +++ b/azure-applicationinsights-query/models/events_exception_detail_py3.py @@ -0,0 +1,49 @@ +# coding=utf-8 +# -------------------------------------------------------------------------- +# Copyright (c) Microsoft Corporation. All rights reserved. +# Licensed under the MIT License. See License.txt in the project root for +# license information. +# +# Code generated by Microsoft (R) AutoRest Code Generator. +# Changes may cause incorrect behavior and will be lost if the code is +# regenerated. +# -------------------------------------------------------------------------- + +from msrest.serialization import Model + + +class EventsExceptionDetail(Model): + """Exception details. + + :param severity_level: The severity level of the exception detail + :type severity_level: str + :param outer_id: The outer ID of the exception detail + :type outer_id: str + :param message: The message of the exception detail + :type message: str + :param type: The type of the exception detail + :type type: str + :param id: The ID of the exception detail + :type id: str + :param parsed_stack: The parsed stack + :type parsed_stack: + list[~azure.applicationinsights.query.models.EventsExceptionDetailsParsedStack] + """ + + _attribute_map = { + 'severity_level': {'key': 'severityLevel', 'type': 'str'}, + 'outer_id': {'key': 'outerId', 'type': 'str'}, + 'message': {'key': 'message', 'type': 'str'}, + 'type': {'key': 'type', 'type': 'str'}, + 'id': {'key': 'id', 'type': 'str'}, + 'parsed_stack': {'key': 'parsedStack', 'type': '[EventsExceptionDetailsParsedStack]'}, + } + + def __init__(self, *, severity_level: str=None, outer_id: str=None, message: str=None, type: str=None, id: str=None, parsed_stack=None, **kwargs) -> None: + super(EventsExceptionDetail, self).__init__(**kwargs) + self.severity_level = severity_level + self.outer_id = outer_id + self.message = message + self.type = type + self.id = id + self.parsed_stack = parsed_stack diff --git a/azure-applicationinsights-query/models/events_exception_details_parsed_stack.py b/azure-applicationinsights-query/models/events_exception_details_parsed_stack.py new file mode 100644 index 000000000000..927bde74816a --- /dev/null +++ b/azure-applicationinsights-query/models/events_exception_details_parsed_stack.py @@ -0,0 +1,40 @@ +# coding=utf-8 +# -------------------------------------------------------------------------- +# Copyright (c) Microsoft Corporation. All rights reserved. +# Licensed under the MIT License. See License.txt in the project root for +# license information. +# +# Code generated by Microsoft (R) AutoRest Code Generator. +# Changes may cause incorrect behavior and will be lost if the code is +# regenerated. +# -------------------------------------------------------------------------- + +from msrest.serialization import Model + + +class EventsExceptionDetailsParsedStack(Model): + """A parsed stack entry. + + :param assembly: The assembly of the stack entry + :type assembly: str + :param method: The method of the stack entry + :type method: str + :param level: The level of the stack entry + :type level: long + :param line: The line of the stack entry + :type line: long + """ + + _attribute_map = { + 'assembly': {'key': 'assembly', 'type': 'str'}, + 'method': {'key': 'method', 'type': 'str'}, + 'level': {'key': 'level', 'type': 'long'}, + 'line': {'key': 'line', 'type': 'long'}, + } + + def __init__(self, **kwargs): + super(EventsExceptionDetailsParsedStack, self).__init__(**kwargs) + self.assembly = kwargs.get('assembly', None) + self.method = kwargs.get('method', None) + self.level = kwargs.get('level', None) + self.line = kwargs.get('line', None) diff --git a/azure-applicationinsights-query/models/events_exception_details_parsed_stack_py3.py b/azure-applicationinsights-query/models/events_exception_details_parsed_stack_py3.py new file mode 100644 index 000000000000..d32ca08daed9 --- /dev/null +++ b/azure-applicationinsights-query/models/events_exception_details_parsed_stack_py3.py @@ -0,0 +1,40 @@ +# coding=utf-8 +# -------------------------------------------------------------------------- +# Copyright (c) Microsoft Corporation. All rights reserved. +# Licensed under the MIT License. See License.txt in the project root for +# license information. +# +# Code generated by Microsoft (R) AutoRest Code Generator. +# Changes may cause incorrect behavior and will be lost if the code is +# regenerated. +# -------------------------------------------------------------------------- + +from msrest.serialization import Model + + +class EventsExceptionDetailsParsedStack(Model): + """A parsed stack entry. + + :param assembly: The assembly of the stack entry + :type assembly: str + :param method: The method of the stack entry + :type method: str + :param level: The level of the stack entry + :type level: long + :param line: The line of the stack entry + :type line: long + """ + + _attribute_map = { + 'assembly': {'key': 'assembly', 'type': 'str'}, + 'method': {'key': 'method', 'type': 'str'}, + 'level': {'key': 'level', 'type': 'long'}, + 'line': {'key': 'line', 'type': 'long'}, + } + + def __init__(self, *, assembly: str=None, method: str=None, level: int=None, line: int=None, **kwargs) -> None: + super(EventsExceptionDetailsParsedStack, self).__init__(**kwargs) + self.assembly = assembly + self.method = method + self.level = level + self.line = line diff --git a/azure-applicationinsights-query/models/events_exception_info.py b/azure-applicationinsights-query/models/events_exception_info.py new file mode 100644 index 000000000000..986f82cbc365 --- /dev/null +++ b/azure-applicationinsights-query/models/events_exception_info.py @@ -0,0 +1,89 @@ +# coding=utf-8 +# -------------------------------------------------------------------------- +# Copyright (c) Microsoft Corporation. All rights reserved. +# Licensed under the MIT License. See License.txt in the project root for +# license information. +# +# Code generated by Microsoft (R) AutoRest Code Generator. +# Changes may cause incorrect behavior and will be lost if the code is +# regenerated. +# -------------------------------------------------------------------------- + +from msrest.serialization import Model + + +class EventsExceptionInfo(Model): + """The exception info. + + :param severity_level: The severity level of the exception + :type severity_level: int + :param problem_id: The problem ID of the exception + :type problem_id: str + :param handled_at: Indicates where the exception was handled at + :type handled_at: str + :param assembly: The assembly which threw the exception + :type assembly: str + :param method: The method that threw the exception + :type method: str + :param message: The message of the exception + :type message: str + :param type: The type of the exception + :type type: str + :param outer_type: The outer type of the exception + :type outer_type: str + :param outer_method: The outer method of the exception + :type outer_method: str + :param outer_assembly: The outer assmebly of the exception + :type outer_assembly: str + :param outer_message: The outer message of the exception + :type outer_message: str + :param innermost_type: The inner most type of the exception + :type innermost_type: str + :param innermost_message: The inner most message of the exception + :type innermost_message: str + :param innermost_method: The inner most method of the exception + :type innermost_method: str + :param innermost_assembly: The inner most assembly of the exception + :type innermost_assembly: str + :param details: The details of the exception + :type details: + list[~azure.applicationinsights.query.models.EventsExceptionDetail] + """ + + _attribute_map = { + 'severity_level': {'key': 'severityLevel', 'type': 'int'}, + 'problem_id': {'key': 'problemId', 'type': 'str'}, + 'handled_at': {'key': 'handledAt', 'type': 'str'}, + 'assembly': {'key': 'assembly', 'type': 'str'}, + 'method': {'key': 'method', 'type': 'str'}, + 'message': {'key': 'message', 'type': 'str'}, + 'type': {'key': 'type', 'type': 'str'}, + 'outer_type': {'key': 'outerType', 'type': 'str'}, + 'outer_method': {'key': 'outerMethod', 'type': 'str'}, + 'outer_assembly': {'key': 'outerAssembly', 'type': 'str'}, + 'outer_message': {'key': 'outerMessage', 'type': 'str'}, + 'innermost_type': {'key': 'innermostType', 'type': 'str'}, + 'innermost_message': {'key': 'innermostMessage', 'type': 'str'}, + 'innermost_method': {'key': 'innermostMethod', 'type': 'str'}, + 'innermost_assembly': {'key': 'innermostAssembly', 'type': 'str'}, + 'details': {'key': 'details', 'type': '[EventsExceptionDetail]'}, + } + + def __init__(self, **kwargs): + super(EventsExceptionInfo, self).__init__(**kwargs) + self.severity_level = kwargs.get('severity_level', None) + self.problem_id = kwargs.get('problem_id', None) + self.handled_at = kwargs.get('handled_at', None) + self.assembly = kwargs.get('assembly', None) + self.method = kwargs.get('method', None) + self.message = kwargs.get('message', None) + self.type = kwargs.get('type', None) + self.outer_type = kwargs.get('outer_type', None) + self.outer_method = kwargs.get('outer_method', None) + self.outer_assembly = kwargs.get('outer_assembly', None) + self.outer_message = kwargs.get('outer_message', None) + self.innermost_type = kwargs.get('innermost_type', None) + self.innermost_message = kwargs.get('innermost_message', None) + self.innermost_method = kwargs.get('innermost_method', None) + self.innermost_assembly = kwargs.get('innermost_assembly', None) + self.details = kwargs.get('details', None) diff --git a/azure-applicationinsights-query/models/events_exception_info_py3.py b/azure-applicationinsights-query/models/events_exception_info_py3.py new file mode 100644 index 000000000000..8c77597625c2 --- /dev/null +++ b/azure-applicationinsights-query/models/events_exception_info_py3.py @@ -0,0 +1,89 @@ +# coding=utf-8 +# -------------------------------------------------------------------------- +# Copyright (c) Microsoft Corporation. All rights reserved. +# Licensed under the MIT License. See License.txt in the project root for +# license information. +# +# Code generated by Microsoft (R) AutoRest Code Generator. +# Changes may cause incorrect behavior and will be lost if the code is +# regenerated. +# -------------------------------------------------------------------------- + +from msrest.serialization import Model + + +class EventsExceptionInfo(Model): + """The exception info. + + :param severity_level: The severity level of the exception + :type severity_level: int + :param problem_id: The problem ID of the exception + :type problem_id: str + :param handled_at: Indicates where the exception was handled at + :type handled_at: str + :param assembly: The assembly which threw the exception + :type assembly: str + :param method: The method that threw the exception + :type method: str + :param message: The message of the exception + :type message: str + :param type: The type of the exception + :type type: str + :param outer_type: The outer type of the exception + :type outer_type: str + :param outer_method: The outer method of the exception + :type outer_method: str + :param outer_assembly: The outer assmebly of the exception + :type outer_assembly: str + :param outer_message: The outer message of the exception + :type outer_message: str + :param innermost_type: The inner most type of the exception + :type innermost_type: str + :param innermost_message: The inner most message of the exception + :type innermost_message: str + :param innermost_method: The inner most method of the exception + :type innermost_method: str + :param innermost_assembly: The inner most assembly of the exception + :type innermost_assembly: str + :param details: The details of the exception + :type details: + list[~azure.applicationinsights.query.models.EventsExceptionDetail] + """ + + _attribute_map = { + 'severity_level': {'key': 'severityLevel', 'type': 'int'}, + 'problem_id': {'key': 'problemId', 'type': 'str'}, + 'handled_at': {'key': 'handledAt', 'type': 'str'}, + 'assembly': {'key': 'assembly', 'type': 'str'}, + 'method': {'key': 'method', 'type': 'str'}, + 'message': {'key': 'message', 'type': 'str'}, + 'type': {'key': 'type', 'type': 'str'}, + 'outer_type': {'key': 'outerType', 'type': 'str'}, + 'outer_method': {'key': 'outerMethod', 'type': 'str'}, + 'outer_assembly': {'key': 'outerAssembly', 'type': 'str'}, + 'outer_message': {'key': 'outerMessage', 'type': 'str'}, + 'innermost_type': {'key': 'innermostType', 'type': 'str'}, + 'innermost_message': {'key': 'innermostMessage', 'type': 'str'}, + 'innermost_method': {'key': 'innermostMethod', 'type': 'str'}, + 'innermost_assembly': {'key': 'innermostAssembly', 'type': 'str'}, + 'details': {'key': 'details', 'type': '[EventsExceptionDetail]'}, + } + + def __init__(self, *, severity_level: int=None, problem_id: str=None, handled_at: str=None, assembly: str=None, method: str=None, message: str=None, type: str=None, outer_type: str=None, outer_method: str=None, outer_assembly: str=None, outer_message: str=None, innermost_type: str=None, innermost_message: str=None, innermost_method: str=None, innermost_assembly: str=None, details=None, **kwargs) -> None: + super(EventsExceptionInfo, self).__init__(**kwargs) + self.severity_level = severity_level + self.problem_id = problem_id + self.handled_at = handled_at + self.assembly = assembly + self.method = method + self.message = message + self.type = type + self.outer_type = outer_type + self.outer_method = outer_method + self.outer_assembly = outer_assembly + self.outer_message = outer_message + self.innermost_type = innermost_type + self.innermost_message = innermost_message + self.innermost_method = innermost_method + self.innermost_assembly = innermost_assembly + self.details = details diff --git a/azure-applicationinsights-query/models/events_exception_result.py b/azure-applicationinsights-query/models/events_exception_result.py new file mode 100644 index 000000000000..33c1ad89bf4a --- /dev/null +++ b/azure-applicationinsights-query/models/events_exception_result.py @@ -0,0 +1,79 @@ +# coding=utf-8 +# -------------------------------------------------------------------------- +# Copyright (c) Microsoft Corporation. All rights reserved. +# Licensed under the MIT License. See License.txt in the project root for +# license information. +# +# Code generated by Microsoft (R) AutoRest Code Generator. +# Changes may cause incorrect behavior and will be lost if the code is +# regenerated. +# -------------------------------------------------------------------------- + +from .events_result_data import EventsResultData + + +class EventsExceptionResult(EventsResultData): + """An exception result. + + All required parameters must be populated in order to send to Azure. + + :param id: The unique ID for this event. + :type id: str + :param count: Count of the event + :type count: long + :param timestamp: Timestamp of the event + :type timestamp: datetime + :param custom_dimensions: Custom dimensions of the event + :type custom_dimensions: + ~azure.applicationinsights.query.models.EventsResultDataCustomDimensions + :param custom_measurements: Custom measurements of the event + :type custom_measurements: + ~azure.applicationinsights.query.models.EventsResultDataCustomMeasurements + :param operation: Operation info of the event + :type operation: + ~azure.applicationinsights.query.models.EventsOperationInfo + :param session: Session info of the event + :type session: ~azure.applicationinsights.query.models.EventsSessionInfo + :param user: User info of the event + :type user: ~azure.applicationinsights.query.models.EventsUserInfo + :param cloud: Cloud info of the event + :type cloud: ~azure.applicationinsights.query.models.EventsCloudInfo + :param ai: AI info of the event + :type ai: ~azure.applicationinsights.query.models.EventsAiInfo + :param application: Application info of the event + :type application: + ~azure.applicationinsights.query.models.EventsApplicationInfo + :param client: Client info of the event + :type client: ~azure.applicationinsights.query.models.EventsClientInfo + :param type: Required. Constant filled by server. + :type type: str + :param exception: + :type exception: + ~azure.applicationinsights.query.models.EventsExceptionInfo + """ + + _validation = { + 'type': {'required': True}, + } + + _attribute_map = { + 'id': {'key': 'id', 'type': 'str'}, + 'count': {'key': 'count', 'type': 'long'}, + 'timestamp': {'key': 'timestamp', 'type': 'iso-8601'}, + 'custom_dimensions': {'key': 'customDimensions', 'type': 'EventsResultDataCustomDimensions'}, + 'custom_measurements': {'key': 'customMeasurements', 'type': 'EventsResultDataCustomMeasurements'}, + 'operation': {'key': 'operation', 'type': 'EventsOperationInfo'}, + 'session': {'key': 'session', 'type': 'EventsSessionInfo'}, + 'user': {'key': 'user', 'type': 'EventsUserInfo'}, + 'cloud': {'key': 'cloud', 'type': 'EventsCloudInfo'}, + 'ai': {'key': 'ai', 'type': 'EventsAiInfo'}, + 'application': {'key': 'application', 'type': 'EventsApplicationInfo'}, + 'client': {'key': 'client', 'type': 'EventsClientInfo'}, + 'type': {'key': 'type', 'type': 'str'}, + 'exception': {'key': 'exception', 'type': 'EventsExceptionInfo'}, + } + + def __init__(self, **kwargs): + super(EventsExceptionResult, self).__init__(**kwargs) + self.exception = kwargs.get('exception', None) + self.type = 'exception' diff --git a/azure-applicationinsights-query/models/events_exception_result_py3.py b/azure-applicationinsights-query/models/events_exception_result_py3.py new file mode 100644 index 000000000000..88ea880b0e72 --- /dev/null +++ b/azure-applicationinsights-query/models/events_exception_result_py3.py @@ -0,0 +1,79 @@ +# coding=utf-8 +# -------------------------------------------------------------------------- +# Copyright (c) Microsoft Corporation. All rights reserved. +# Licensed under the MIT License. See License.txt in the project root for +# license information. +# +# Code generated by Microsoft (R) AutoRest Code Generator. +# Changes may cause incorrect behavior and will be lost if the code is +# regenerated. +# -------------------------------------------------------------------------- + +from .events_result_data_py3 import EventsResultData + + +class EventsExceptionResult(EventsResultData): + """An exception result. + + All required parameters must be populated in order to send to Azure. + + :param id: The unique ID for this event. + :type id: str + :param count: Count of the event + :type count: long + :param timestamp: Timestamp of the event + :type timestamp: datetime + :param custom_dimensions: Custom dimensions of the event + :type custom_dimensions: + ~azure.applicationinsights.query.models.EventsResultDataCustomDimensions + :param custom_measurements: Custom measurements of the event + :type custom_measurements: + ~azure.applicationinsights.query.models.EventsResultDataCustomMeasurements + :param operation: Operation info of the event + :type operation: + ~azure.applicationinsights.query.models.EventsOperationInfo + :param session: Session info of the event + :type session: ~azure.applicationinsights.query.models.EventsSessionInfo + :param user: User info of the event + :type user: ~azure.applicationinsights.query.models.EventsUserInfo + :param cloud: Cloud info of the event + :type cloud: ~azure.applicationinsights.query.models.EventsCloudInfo + :param ai: AI info of the event + :type ai: ~azure.applicationinsights.query.models.EventsAiInfo + :param application: Application info of the event + :type application: + ~azure.applicationinsights.query.models.EventsApplicationInfo + :param client: Client info of the event + :type client: ~azure.applicationinsights.query.models.EventsClientInfo + :param type: Required. Constant filled by server. + :type type: str + :param exception: + :type exception: + ~azure.applicationinsights.query.models.EventsExceptionInfo + """ + + _validation = { + 'type': {'required': True}, + } + + _attribute_map = { + 'id': {'key': 'id', 'type': 'str'}, + 'count': {'key': 'count', 'type': 'long'}, + 'timestamp': {'key': 'timestamp', 'type': 'iso-8601'}, + 'custom_dimensions': {'key': 'customDimensions', 'type': 'EventsResultDataCustomDimensions'}, + 'custom_measurements': {'key': 'customMeasurements', 'type': 'EventsResultDataCustomMeasurements'}, + 'operation': {'key': 'operation', 'type': 'EventsOperationInfo'}, + 'session': {'key': 'session', 'type': 'EventsSessionInfo'}, + 'user': {'key': 'user', 'type': 'EventsUserInfo'}, + 'cloud': {'key': 'cloud', 'type': 'EventsCloudInfo'}, + 'ai': {'key': 'ai', 'type': 'EventsAiInfo'}, + 'application': {'key': 'application', 'type': 'EventsApplicationInfo'}, + 'client': {'key': 'client', 'type': 'EventsClientInfo'}, + 'type': {'key': 'type', 'type': 'str'}, + 'exception': {'key': 'exception', 'type': 'EventsExceptionInfo'}, + } + + def __init__(self, *, id: str=None, count: int=None, timestamp=None, custom_dimensions=None, custom_measurements=None, operation=None, session=None, user=None, cloud=None, ai=None, application=None, client=None, exception=None, **kwargs) -> None: + super(EventsExceptionResult, self).__init__(id=id, count=count, timestamp=timestamp, custom_dimensions=custom_dimensions, custom_measurements=custom_measurements, operation=operation, session=session, user=user, cloud=cloud, ai=ai, application=application, client=client, **kwargs) + self.exception = exception + self.type = 'exception' diff --git a/azure-applicationinsights-query/models/events_operation_info.py b/azure-applicationinsights-query/models/events_operation_info.py new file mode 100644 index 000000000000..db94a4528554 --- /dev/null +++ b/azure-applicationinsights-query/models/events_operation_info.py @@ -0,0 +1,40 @@ +# coding=utf-8 +# -------------------------------------------------------------------------- +# Copyright (c) Microsoft Corporation. All rights reserved. +# Licensed under the MIT License. See License.txt in the project root for +# license information. +# +# Code generated by Microsoft (R) AutoRest Code Generator. +# Changes may cause incorrect behavior and will be lost if the code is +# regenerated. +# -------------------------------------------------------------------------- + +from msrest.serialization import Model + + +class EventsOperationInfo(Model): + """Operation info for an event result. + + :param name: Name of the operation + :type name: str + :param id: ID of the operation + :type id: str + :param parent_id: Parent ID of the operation + :type parent_id: str + :param synthetic_source: Synthetic source of the operation + :type synthetic_source: str + """ + + _attribute_map = { + 'name': {'key': 'name', 'type': 'str'}, + 'id': {'key': 'id', 'type': 'str'}, + 'parent_id': {'key': 'parentId', 'type': 'str'}, + 'synthetic_source': {'key': 'syntheticSource', 'type': 'str'}, + } + + def __init__(self, **kwargs): + super(EventsOperationInfo, self).__init__(**kwargs) + self.name = kwargs.get('name', None) + self.id = kwargs.get('id', None) + self.parent_id = kwargs.get('parent_id', None) + self.synthetic_source = kwargs.get('synthetic_source', None) diff --git a/azure-applicationinsights-query/models/events_operation_info_py3.py b/azure-applicationinsights-query/models/events_operation_info_py3.py new file mode 100644 index 000000000000..388b441aeca2 --- /dev/null +++ b/azure-applicationinsights-query/models/events_operation_info_py3.py @@ -0,0 +1,40 @@ +# coding=utf-8 +# -------------------------------------------------------------------------- +# Copyright (c) Microsoft Corporation. All rights reserved. +# Licensed under the MIT License. See License.txt in the project root for +# license information. +# +# Code generated by Microsoft (R) AutoRest Code Generator. +# Changes may cause incorrect behavior and will be lost if the code is +# regenerated. +# -------------------------------------------------------------------------- + +from msrest.serialization import Model + + +class EventsOperationInfo(Model): + """Operation info for an event result. + + :param name: Name of the operation + :type name: str + :param id: ID of the operation + :type id: str + :param parent_id: Parent ID of the operation + :type parent_id: str + :param synthetic_source: Synthetic source of the operation + :type synthetic_source: str + """ + + _attribute_map = { + 'name': {'key': 'name', 'type': 'str'}, + 'id': {'key': 'id', 'type': 'str'}, + 'parent_id': {'key': 'parentId', 'type': 'str'}, + 'synthetic_source': {'key': 'syntheticSource', 'type': 'str'}, + } + + def __init__(self, *, name: str=None, id: str=None, parent_id: str=None, synthetic_source: str=None, **kwargs) -> None: + super(EventsOperationInfo, self).__init__(**kwargs) + self.name = name + self.id = id + self.parent_id = parent_id + self.synthetic_source = synthetic_source diff --git a/azure-applicationinsights-query/models/events_page_view_info.py b/azure-applicationinsights-query/models/events_page_view_info.py new file mode 100644 index 000000000000..e19d3fc9f2ed --- /dev/null +++ b/azure-applicationinsights-query/models/events_page_view_info.py @@ -0,0 +1,40 @@ +# coding=utf-8 +# -------------------------------------------------------------------------- +# Copyright (c) Microsoft Corporation. All rights reserved. +# Licensed under the MIT License. See License.txt in the project root for +# license information. +# +# Code generated by Microsoft (R) AutoRest Code Generator. +# Changes may cause incorrect behavior and will be lost if the code is +# regenerated. +# -------------------------------------------------------------------------- + +from msrest.serialization import Model + + +class EventsPageViewInfo(Model): + """The page view information. + + :param name: The name of the page + :type name: str + :param url: The URL of the page + :type url: str + :param duration: The duration of the page view + :type duration: str + :param performance_bucket: The performance bucket of the page view + :type performance_bucket: str + """ + + _attribute_map = { + 'name': {'key': 'name', 'type': 'str'}, + 'url': {'key': 'url', 'type': 'str'}, + 'duration': {'key': 'duration', 'type': 'str'}, + 'performance_bucket': {'key': 'performanceBucket', 'type': 'str'}, + } + + def __init__(self, **kwargs): + super(EventsPageViewInfo, self).__init__(**kwargs) + self.name = kwargs.get('name', None) + self.url = kwargs.get('url', None) + self.duration = kwargs.get('duration', None) + self.performance_bucket = kwargs.get('performance_bucket', None) diff --git a/azure-applicationinsights-query/models/events_page_view_info_py3.py b/azure-applicationinsights-query/models/events_page_view_info_py3.py new file mode 100644 index 000000000000..e651e8fe5b4c --- /dev/null +++ b/azure-applicationinsights-query/models/events_page_view_info_py3.py @@ -0,0 +1,40 @@ +# coding=utf-8 +# -------------------------------------------------------------------------- +# Copyright (c) Microsoft Corporation. All rights reserved. +# Licensed under the MIT License. See License.txt in the project root for +# license information. +# +# Code generated by Microsoft (R) AutoRest Code Generator. +# Changes may cause incorrect behavior and will be lost if the code is +# regenerated. +# -------------------------------------------------------------------------- + +from msrest.serialization import Model + + +class EventsPageViewInfo(Model): + """The page view information. + + :param name: The name of the page + :type name: str + :param url: The URL of the page + :type url: str + :param duration: The duration of the page view + :type duration: str + :param performance_bucket: The performance bucket of the page view + :type performance_bucket: str + """ + + _attribute_map = { + 'name': {'key': 'name', 'type': 'str'}, + 'url': {'key': 'url', 'type': 'str'}, + 'duration': {'key': 'duration', 'type': 'str'}, + 'performance_bucket': {'key': 'performanceBucket', 'type': 'str'}, + } + + def __init__(self, *, name: str=None, url: str=None, duration: str=None, performance_bucket: str=None, **kwargs) -> None: + super(EventsPageViewInfo, self).__init__(**kwargs) + self.name = name + self.url = url + self.duration = duration + self.performance_bucket = performance_bucket diff --git a/azure-applicationinsights-query/models/events_page_view_result.py b/azure-applicationinsights-query/models/events_page_view_result.py new file mode 100644 index 000000000000..c8f859844aad --- /dev/null +++ b/azure-applicationinsights-query/models/events_page_view_result.py @@ -0,0 +1,79 @@ +# coding=utf-8 +# -------------------------------------------------------------------------- +# Copyright (c) Microsoft Corporation. All rights reserved. +# Licensed under the MIT License. See License.txt in the project root for +# license information. +# +# Code generated by Microsoft (R) AutoRest Code Generator. +# Changes may cause incorrect behavior and will be lost if the code is +# regenerated. +# -------------------------------------------------------------------------- + +from .events_result_data import EventsResultData + + +class EventsPageViewResult(EventsResultData): + """A page view result. + + All required parameters must be populated in order to send to Azure. + + :param id: The unique ID for this event. + :type id: str + :param count: Count of the event + :type count: long + :param timestamp: Timestamp of the event + :type timestamp: datetime + :param custom_dimensions: Custom dimensions of the event + :type custom_dimensions: + ~azure.applicationinsights.query.models.EventsResultDataCustomDimensions + :param custom_measurements: Custom measurements of the event + :type custom_measurements: + ~azure.applicationinsights.query.models.EventsResultDataCustomMeasurements + :param operation: Operation info of the event + :type operation: + ~azure.applicationinsights.query.models.EventsOperationInfo + :param session: Session info of the event + :type session: ~azure.applicationinsights.query.models.EventsSessionInfo + :param user: User info of the event + :type user: ~azure.applicationinsights.query.models.EventsUserInfo + :param cloud: Cloud info of the event + :type cloud: ~azure.applicationinsights.query.models.EventsCloudInfo + :param ai: AI info of the event + :type ai: ~azure.applicationinsights.query.models.EventsAiInfo + :param application: Application info of the event + :type application: + ~azure.applicationinsights.query.models.EventsApplicationInfo + :param client: Client info of the event + :type client: ~azure.applicationinsights.query.models.EventsClientInfo + :param type: Required. Constant filled by server. + :type type: str + :param page_view: + :type page_view: + ~azure.applicationinsights.query.models.EventsPageViewInfo + """ + + _validation = { + 'type': {'required': True}, + } + + _attribute_map = { + 'id': {'key': 'id', 'type': 'str'}, + 'count': {'key': 'count', 'type': 'long'}, + 'timestamp': {'key': 'timestamp', 'type': 'iso-8601'}, + 'custom_dimensions': {'key': 'customDimensions', 'type': 'EventsResultDataCustomDimensions'}, + 'custom_measurements': {'key': 'customMeasurements', 'type': 'EventsResultDataCustomMeasurements'}, + 'operation': {'key': 'operation', 'type': 'EventsOperationInfo'}, + 'session': {'key': 'session', 'type': 'EventsSessionInfo'}, + 'user': {'key': 'user', 'type': 'EventsUserInfo'}, + 'cloud': {'key': 'cloud', 'type': 'EventsCloudInfo'}, + 'ai': {'key': 'ai', 'type': 'EventsAiInfo'}, + 'application': {'key': 'application', 'type': 'EventsApplicationInfo'}, + 'client': {'key': 'client', 'type': 'EventsClientInfo'}, + 'type': {'key': 'type', 'type': 'str'}, + 'page_view': {'key': 'pageView', 'type': 'EventsPageViewInfo'}, + } + + def __init__(self, **kwargs): + super(EventsPageViewResult, self).__init__(**kwargs) + self.page_view = kwargs.get('page_view', None) + self.type = 'pageView' diff --git a/azure-applicationinsights-query/models/events_page_view_result_py3.py b/azure-applicationinsights-query/models/events_page_view_result_py3.py new file mode 100644 index 000000000000..c2d34a33f671 --- /dev/null +++ b/azure-applicationinsights-query/models/events_page_view_result_py3.py @@ -0,0 +1,79 @@ +# coding=utf-8 +# -------------------------------------------------------------------------- +# Copyright (c) Microsoft Corporation. All rights reserved. +# Licensed under the MIT License. See License.txt in the project root for +# license information. +# +# Code generated by Microsoft (R) AutoRest Code Generator. +# Changes may cause incorrect behavior and will be lost if the code is +# regenerated. +# -------------------------------------------------------------------------- + +from .events_result_data_py3 import EventsResultData + + +class EventsPageViewResult(EventsResultData): + """A page view result. + + All required parameters must be populated in order to send to Azure. + + :param id: The unique ID for this event. + :type id: str + :param count: Count of the event + :type count: long + :param timestamp: Timestamp of the event + :type timestamp: datetime + :param custom_dimensions: Custom dimensions of the event + :type custom_dimensions: + ~azure.applicationinsights.query.models.EventsResultDataCustomDimensions + :param custom_measurements: Custom measurements of the event + :type custom_measurements: + ~azure.applicationinsights.query.models.EventsResultDataCustomMeasurements + :param operation: Operation info of the event + :type operation: + ~azure.applicationinsights.query.models.EventsOperationInfo + :param session: Session info of the event + :type session: ~azure.applicationinsights.query.models.EventsSessionInfo + :param user: User info of the event + :type user: ~azure.applicationinsights.query.models.EventsUserInfo + :param cloud: Cloud info of the event + :type cloud: ~azure.applicationinsights.query.models.EventsCloudInfo + :param ai: AI info of the event + :type ai: ~azure.applicationinsights.query.models.EventsAiInfo + :param application: Application info of the event + :type application: + ~azure.applicationinsights.query.models.EventsApplicationInfo + :param client: Client info of the event + :type client: ~azure.applicationinsights.query.models.EventsClientInfo + :param type: Required. Constant filled by server. + :type type: str + :param page_view: + :type page_view: + ~azure.applicationinsights.query.models.EventsPageViewInfo + """ + + _validation = { + 'type': {'required': True}, + } + + _attribute_map = { + 'id': {'key': 'id', 'type': 'str'}, + 'count': {'key': 'count', 'type': 'long'}, + 'timestamp': {'key': 'timestamp', 'type': 'iso-8601'}, + 'custom_dimensions': {'key': 'customDimensions', 'type': 'EventsResultDataCustomDimensions'}, + 'custom_measurements': {'key': 'customMeasurements', 'type': 'EventsResultDataCustomMeasurements'}, + 'operation': {'key': 'operation', 'type': 'EventsOperationInfo'}, + 'session': {'key': 'session', 'type': 'EventsSessionInfo'}, + 'user': {'key': 'user', 'type': 'EventsUserInfo'}, + 'cloud': {'key': 'cloud', 'type': 'EventsCloudInfo'}, + 'ai': {'key': 'ai', 'type': 'EventsAiInfo'}, + 'application': {'key': 'application', 'type': 'EventsApplicationInfo'}, + 'client': {'key': 'client', 'type': 'EventsClientInfo'}, + 'type': {'key': 'type', 'type': 'str'}, + 'page_view': {'key': 'pageView', 'type': 'EventsPageViewInfo'}, + } + + def __init__(self, *, id: str=None, count: int=None, timestamp=None, custom_dimensions=None, custom_measurements=None, operation=None, session=None, user=None, cloud=None, ai=None, application=None, client=None, page_view=None, **kwargs) -> None: + super(EventsPageViewResult, self).__init__(id=id, count=count, timestamp=timestamp, custom_dimensions=custom_dimensions, custom_measurements=custom_measurements, operation=operation, session=session, user=user, cloud=cloud, ai=ai, application=application, client=client, **kwargs) + self.page_view = page_view + self.type = 'pageView' diff --git a/azure-applicationinsights-query/models/events_performance_counter_info.py b/azure-applicationinsights-query/models/events_performance_counter_info.py new file mode 100644 index 000000000000..3daf89d8bf1e --- /dev/null +++ b/azure-applicationinsights-query/models/events_performance_counter_info.py @@ -0,0 +1,48 @@ +# coding=utf-8 +# -------------------------------------------------------------------------- +# Copyright (c) Microsoft Corporation. All rights reserved. +# Licensed under the MIT License. See License.txt in the project root for +# license information. +# +# Code generated by Microsoft (R) AutoRest Code Generator. +# Changes may cause incorrect behavior and will be lost if the code is +# regenerated. +# -------------------------------------------------------------------------- + +from msrest.serialization import Model + + +class EventsPerformanceCounterInfo(Model): + """The performance counter info. + + :param value: The value of the performance counter + :type value: float + :param name: The name of the performance counter + :type name: str + :param category: The category of the performance counter + :type category: str + :param counter: The counter of the performance counter + :type counter: str + :param instance_name: The instance name of the performance counter + :type instance_name: str + :param instance: The instance of the performance counter + :type instance: str + """ + + _attribute_map = { + 'value': {'key': 'value', 'type': 'float'}, + 'name': {'key': 'name', 'type': 'str'}, + 'category': {'key': 'category', 'type': 'str'}, + 'counter': {'key': 'counter', 'type': 'str'}, + 'instance_name': {'key': 'instanceName', 'type': 'str'}, + 'instance': {'key': 'instance', 'type': 'str'}, + } + + def __init__(self, **kwargs): + super(EventsPerformanceCounterInfo, self).__init__(**kwargs) + self.value = kwargs.get('value', None) + self.name = kwargs.get('name', None) + self.category = kwargs.get('category', None) + self.counter = kwargs.get('counter', None) + self.instance_name = kwargs.get('instance_name', None) + self.instance = kwargs.get('instance', None) diff --git a/azure-applicationinsights-query/models/events_performance_counter_info_py3.py b/azure-applicationinsights-query/models/events_performance_counter_info_py3.py new file mode 100644 index 000000000000..7ec08ee47e26 --- /dev/null +++ b/azure-applicationinsights-query/models/events_performance_counter_info_py3.py @@ -0,0 +1,48 @@ +# coding=utf-8 +# -------------------------------------------------------------------------- +# Copyright (c) Microsoft Corporation. All rights reserved. +# Licensed under the MIT License. See License.txt in the project root for +# license information. +# +# Code generated by Microsoft (R) AutoRest Code Generator. +# Changes may cause incorrect behavior and will be lost if the code is +# regenerated. +# -------------------------------------------------------------------------- + +from msrest.serialization import Model + + +class EventsPerformanceCounterInfo(Model): + """The performance counter info. + + :param value: The value of the performance counter + :type value: float + :param name: The name of the performance counter + :type name: str + :param category: The category of the performance counter + :type category: str + :param counter: The counter of the performance counter + :type counter: str + :param instance_name: The instance name of the performance counter + :type instance_name: str + :param instance: The instance of the performance counter + :type instance: str + """ + + _attribute_map = { + 'value': {'key': 'value', 'type': 'float'}, + 'name': {'key': 'name', 'type': 'str'}, + 'category': {'key': 'category', 'type': 'str'}, + 'counter': {'key': 'counter', 'type': 'str'}, + 'instance_name': {'key': 'instanceName', 'type': 'str'}, + 'instance': {'key': 'instance', 'type': 'str'}, + } + + def __init__(self, *, value: float=None, name: str=None, category: str=None, counter: str=None, instance_name: str=None, instance: str=None, **kwargs) -> None: + super(EventsPerformanceCounterInfo, self).__init__(**kwargs) + self.value = value + self.name = name + self.category = category + self.counter = counter + self.instance_name = instance_name + self.instance = instance diff --git a/azure-applicationinsights-query/models/events_performance_counter_result.py b/azure-applicationinsights-query/models/events_performance_counter_result.py new file mode 100644 index 000000000000..d53b447a2f3c --- /dev/null +++ b/azure-applicationinsights-query/models/events_performance_counter_result.py @@ -0,0 +1,79 @@ +# coding=utf-8 +# -------------------------------------------------------------------------- +# Copyright (c) Microsoft Corporation. All rights reserved. +# Licensed under the MIT License. See License.txt in the project root for +# license information. +# +# Code generated by Microsoft (R) AutoRest Code Generator. +# Changes may cause incorrect behavior and will be lost if the code is +# regenerated. +# -------------------------------------------------------------------------- + +from .events_result_data import EventsResultData + + +class EventsPerformanceCounterResult(EventsResultData): + """A performance counter result. + + All required parameters must be populated in order to send to Azure. + + :param id: The unique ID for this event. + :type id: str + :param count: Count of the event + :type count: long + :param timestamp: Timestamp of the event + :type timestamp: datetime + :param custom_dimensions: Custom dimensions of the event + :type custom_dimensions: + ~azure.applicationinsights.query.models.EventsResultDataCustomDimensions + :param custom_measurements: Custom measurements of the event + :type custom_measurements: + ~azure.applicationinsights.query.models.EventsResultDataCustomMeasurements + :param operation: Operation info of the event + :type operation: + ~azure.applicationinsights.query.models.EventsOperationInfo + :param session: Session info of the event + :type session: ~azure.applicationinsights.query.models.EventsSessionInfo + :param user: User info of the event + :type user: ~azure.applicationinsights.query.models.EventsUserInfo + :param cloud: Cloud info of the event + :type cloud: ~azure.applicationinsights.query.models.EventsCloudInfo + :param ai: AI info of the event + :type ai: ~azure.applicationinsights.query.models.EventsAiInfo + :param application: Application info of the event + :type application: + ~azure.applicationinsights.query.models.EventsApplicationInfo + :param client: Client info of the event + :type client: ~azure.applicationinsights.query.models.EventsClientInfo + :param type: Required. Constant filled by server. + :type type: str + :param performance_counter: + :type performance_counter: + ~azure.applicationinsights.query.models.EventsPerformanceCounterInfo + """ + + _validation = { + 'type': {'required': True}, + } + + _attribute_map = { + 'id': {'key': 'id', 'type': 'str'}, + 'count': {'key': 'count', 'type': 'long'}, + 'timestamp': {'key': 'timestamp', 'type': 'iso-8601'}, + 'custom_dimensions': {'key': 'customDimensions', 'type': 'EventsResultDataCustomDimensions'}, + 'custom_measurements': {'key': 'customMeasurements', 'type': 'EventsResultDataCustomMeasurements'}, + 'operation': {'key': 'operation', 'type': 'EventsOperationInfo'}, + 'session': {'key': 'session', 'type': 'EventsSessionInfo'}, + 'user': {'key': 'user', 'type': 'EventsUserInfo'}, + 'cloud': {'key': 'cloud', 'type': 'EventsCloudInfo'}, + 'ai': {'key': 'ai', 'type': 'EventsAiInfo'}, + 'application': {'key': 'application', 'type': 'EventsApplicationInfo'}, + 'client': {'key': 'client', 'type': 'EventsClientInfo'}, + 'type': {'key': 'type', 'type': 'str'}, + 'performance_counter': {'key': 'performanceCounter', 'type': 'EventsPerformanceCounterInfo'}, + } + + def __init__(self, **kwargs): + super(EventsPerformanceCounterResult, self).__init__(**kwargs) + self.performance_counter = kwargs.get('performance_counter', None) + self.type = 'performanceCounter' diff --git a/azure-applicationinsights-query/models/events_performance_counter_result_py3.py b/azure-applicationinsights-query/models/events_performance_counter_result_py3.py new file mode 100644 index 000000000000..81a891767c69 --- /dev/null +++ b/azure-applicationinsights-query/models/events_performance_counter_result_py3.py @@ -0,0 +1,79 @@ +# coding=utf-8 +# -------------------------------------------------------------------------- +# Copyright (c) Microsoft Corporation. All rights reserved. +# Licensed under the MIT License. See License.txt in the project root for +# license information. +# +# Code generated by Microsoft (R) AutoRest Code Generator. +# Changes may cause incorrect behavior and will be lost if the code is +# regenerated. +# -------------------------------------------------------------------------- + +from .events_result_data_py3 import EventsResultData + + +class EventsPerformanceCounterResult(EventsResultData): + """A performance counter result. + + All required parameters must be populated in order to send to Azure. + + :param id: The unique ID for this event. + :type id: str + :param count: Count of the event + :type count: long + :param timestamp: Timestamp of the event + :type timestamp: datetime + :param custom_dimensions: Custom dimensions of the event + :type custom_dimensions: + ~azure.applicationinsights.query.models.EventsResultDataCustomDimensions + :param custom_measurements: Custom measurements of the event + :type custom_measurements: + ~azure.applicationinsights.query.models.EventsResultDataCustomMeasurements + :param operation: Operation info of the event + :type operation: + ~azure.applicationinsights.query.models.EventsOperationInfo + :param session: Session info of the event + :type session: ~azure.applicationinsights.query.models.EventsSessionInfo + :param user: User info of the event + :type user: ~azure.applicationinsights.query.models.EventsUserInfo + :param cloud: Cloud info of the event + :type cloud: ~azure.applicationinsights.query.models.EventsCloudInfo + :param ai: AI info of the event + :type ai: ~azure.applicationinsights.query.models.EventsAiInfo + :param application: Application info of the event + :type application: + ~azure.applicationinsights.query.models.EventsApplicationInfo + :param client: Client info of the event + :type client: ~azure.applicationinsights.query.models.EventsClientInfo + :param type: Required. Constant filled by server. + :type type: str + :param performance_counter: + :type performance_counter: + ~azure.applicationinsights.query.models.EventsPerformanceCounterInfo + """ + + _validation = { + 'type': {'required': True}, + } + + _attribute_map = { + 'id': {'key': 'id', 'type': 'str'}, + 'count': {'key': 'count', 'type': 'long'}, + 'timestamp': {'key': 'timestamp', 'type': 'iso-8601'}, + 'custom_dimensions': {'key': 'customDimensions', 'type': 'EventsResultDataCustomDimensions'}, + 'custom_measurements': {'key': 'customMeasurements', 'type': 'EventsResultDataCustomMeasurements'}, + 'operation': {'key': 'operation', 'type': 'EventsOperationInfo'}, + 'session': {'key': 'session', 'type': 'EventsSessionInfo'}, + 'user': {'key': 'user', 'type': 'EventsUserInfo'}, + 'cloud': {'key': 'cloud', 'type': 'EventsCloudInfo'}, + 'ai': {'key': 'ai', 'type': 'EventsAiInfo'}, + 'application': {'key': 'application', 'type': 'EventsApplicationInfo'}, + 'client': {'key': 'client', 'type': 'EventsClientInfo'}, + 'type': {'key': 'type', 'type': 'str'}, + 'performance_counter': {'key': 'performanceCounter', 'type': 'EventsPerformanceCounterInfo'}, + } + + def __init__(self, *, id: str=None, count: int=None, timestamp=None, custom_dimensions=None, custom_measurements=None, operation=None, session=None, user=None, cloud=None, ai=None, application=None, client=None, performance_counter=None, **kwargs) -> None: + super(EventsPerformanceCounterResult, self).__init__(id=id, count=count, timestamp=timestamp, custom_dimensions=custom_dimensions, custom_measurements=custom_measurements, operation=operation, session=session, user=user, cloud=cloud, ai=ai, application=application, client=client, **kwargs) + self.performance_counter = performance_counter + self.type = 'performanceCounter' diff --git a/azure-applicationinsights-query/models/events_request_info.py b/azure-applicationinsights-query/models/events_request_info.py new file mode 100644 index 000000000000..b4765967f7f3 --- /dev/null +++ b/azure-applicationinsights-query/models/events_request_info.py @@ -0,0 +1,56 @@ +# coding=utf-8 +# -------------------------------------------------------------------------- +# Copyright (c) Microsoft Corporation. All rights reserved. +# Licensed under the MIT License. See License.txt in the project root for +# license information. +# +# Code generated by Microsoft (R) AutoRest Code Generator. +# Changes may cause incorrect behavior and will be lost if the code is +# regenerated. +# -------------------------------------------------------------------------- + +from msrest.serialization import Model + + +class EventsRequestInfo(Model): + """The request info. + + :param name: The name of the request + :type name: str + :param url: The URL of the request + :type url: str + :param success: Indicates if the request was successful + :type success: str + :param duration: The duration of the request + :type duration: float + :param performance_bucket: The performance bucket of the request + :type performance_bucket: str + :param result_code: The result code of the request + :type result_code: str + :param source: The source of the request + :type source: str + :param id: The ID of the request + :type id: str + """ + + _attribute_map = { + 'name': {'key': 'name', 'type': 'str'}, + 'url': {'key': 'url', 'type': 'str'}, + 'success': {'key': 'success', 'type': 'str'}, + 'duration': {'key': 'duration', 'type': 'float'}, + 'performance_bucket': {'key': 'performanceBucket', 'type': 'str'}, + 'result_code': {'key': 'resultCode', 'type': 'str'}, + 'source': {'key': 'source', 'type': 'str'}, + 'id': {'key': 'id', 'type': 'str'}, + } + + def __init__(self, **kwargs): + super(EventsRequestInfo, self).__init__(**kwargs) + self.name = kwargs.get('name', None) + self.url = kwargs.get('url', None) + self.success = kwargs.get('success', None) + self.duration = kwargs.get('duration', None) + self.performance_bucket = kwargs.get('performance_bucket', None) + self.result_code = kwargs.get('result_code', None) + self.source = kwargs.get('source', None) + self.id = kwargs.get('id', None) diff --git a/azure-applicationinsights-query/models/events_request_info_py3.py b/azure-applicationinsights-query/models/events_request_info_py3.py new file mode 100644 index 000000000000..bdafd3755743 --- /dev/null +++ b/azure-applicationinsights-query/models/events_request_info_py3.py @@ -0,0 +1,56 @@ +# coding=utf-8 +# -------------------------------------------------------------------------- +# Copyright (c) Microsoft Corporation. All rights reserved. +# Licensed under the MIT License. See License.txt in the project root for +# license information. +# +# Code generated by Microsoft (R) AutoRest Code Generator. +# Changes may cause incorrect behavior and will be lost if the code is +# regenerated. +# -------------------------------------------------------------------------- + +from msrest.serialization import Model + + +class EventsRequestInfo(Model): + """The request info. + + :param name: The name of the request + :type name: str + :param url: The URL of the request + :type url: str + :param success: Indicates if the request was successful + :type success: str + :param duration: The duration of the request + :type duration: float + :param performance_bucket: The performance bucket of the request + :type performance_bucket: str + :param result_code: The result code of the request + :type result_code: str + :param source: The source of the request + :type source: str + :param id: The ID of the request + :type id: str + """ + + _attribute_map = { + 'name': {'key': 'name', 'type': 'str'}, + 'url': {'key': 'url', 'type': 'str'}, + 'success': {'key': 'success', 'type': 'str'}, + 'duration': {'key': 'duration', 'type': 'float'}, + 'performance_bucket': {'key': 'performanceBucket', 'type': 'str'}, + 'result_code': {'key': 'resultCode', 'type': 'str'}, + 'source': {'key': 'source', 'type': 'str'}, + 'id': {'key': 'id', 'type': 'str'}, + } + + def __init__(self, *, name: str=None, url: str=None, success: str=None, duration: float=None, performance_bucket: str=None, result_code: str=None, source: str=None, id: str=None, **kwargs) -> None: + super(EventsRequestInfo, self).__init__(**kwargs) + self.name = name + self.url = url + self.success = success + self.duration = duration + self.performance_bucket = performance_bucket + self.result_code = result_code + self.source = source + self.id = id diff --git a/azure-applicationinsights-query/models/events_request_result.py b/azure-applicationinsights-query/models/events_request_result.py new file mode 100644 index 000000000000..a57798516548 --- /dev/null +++ b/azure-applicationinsights-query/models/events_request_result.py @@ -0,0 +1,78 @@ +# coding=utf-8 +# -------------------------------------------------------------------------- +# Copyright (c) Microsoft Corporation. All rights reserved. +# Licensed under the MIT License. See License.txt in the project root for +# license information. +# +# Code generated by Microsoft (R) AutoRest Code Generator. +# Changes may cause incorrect behavior and will be lost if the code is +# regenerated. +# -------------------------------------------------------------------------- + +from .events_result_data import EventsResultData + + +class EventsRequestResult(EventsResultData): + """A request result. + + All required parameters must be populated in order to send to Azure. + + :param id: The unique ID for this event. + :type id: str + :param count: Count of the event + :type count: long + :param timestamp: Timestamp of the event + :type timestamp: datetime + :param custom_dimensions: Custom dimensions of the event + :type custom_dimensions: + ~azure.applicationinsights.query.models.EventsResultDataCustomDimensions + :param custom_measurements: Custom measurements of the event + :type custom_measurements: + ~azure.applicationinsights.query.models.EventsResultDataCustomMeasurements + :param operation: Operation info of the event + :type operation: + ~azure.applicationinsights.query.models.EventsOperationInfo + :param session: Session info of the event + :type session: ~azure.applicationinsights.query.models.EventsSessionInfo + :param user: User info of the event + :type user: ~azure.applicationinsights.query.models.EventsUserInfo + :param cloud: Cloud info of the event + :type cloud: ~azure.applicationinsights.query.models.EventsCloudInfo + :param ai: AI info of the event + :type ai: ~azure.applicationinsights.query.models.EventsAiInfo + :param application: Application info of the event + :type application: + ~azure.applicationinsights.query.models.EventsApplicationInfo + :param client: Client info of the event + :type client: ~azure.applicationinsights.query.models.EventsClientInfo + :param type: Required. Constant filled by server. + :type type: str + :param request: + :type request: ~azure.applicationinsights.query.models.EventsRequestInfo + """ + + _validation = { + 'type': {'required': True}, + } + + _attribute_map = { + 'id': {'key': 'id', 'type': 'str'}, + 'count': {'key': 'count', 'type': 'long'}, + 'timestamp': {'key': 'timestamp', 'type': 'iso-8601'}, + 'custom_dimensions': {'key': 'customDimensions', 'type': 'EventsResultDataCustomDimensions'}, + 'custom_measurements': {'key': 'customMeasurements', 'type': 'EventsResultDataCustomMeasurements'}, + 'operation': {'key': 'operation', 'type': 'EventsOperationInfo'}, + 'session': {'key': 'session', 'type': 'EventsSessionInfo'}, + 'user': {'key': 'user', 'type': 'EventsUserInfo'}, + 'cloud': {'key': 'cloud', 'type': 'EventsCloudInfo'}, + 'ai': {'key': 'ai', 'type': 'EventsAiInfo'}, + 'application': {'key': 'application', 'type': 'EventsApplicationInfo'}, + 'client': {'key': 'client', 'type': 'EventsClientInfo'}, + 'type': {'key': 'type', 'type': 'str'}, + 'request': {'key': 'request', 'type': 'EventsRequestInfo'}, + } + + def __init__(self, **kwargs): + super(EventsRequestResult, self).__init__(**kwargs) + self.request = kwargs.get('request', None) + self.type = 'request' diff --git a/azure-applicationinsights-query/models/events_request_result_py3.py b/azure-applicationinsights-query/models/events_request_result_py3.py new file mode 100644 index 000000000000..972054958ce4 --- /dev/null +++ b/azure-applicationinsights-query/models/events_request_result_py3.py @@ -0,0 +1,78 @@ +# coding=utf-8 +# -------------------------------------------------------------------------- +# Copyright (c) Microsoft Corporation. All rights reserved. +# Licensed under the MIT License. See License.txt in the project root for +# license information. +# +# Code generated by Microsoft (R) AutoRest Code Generator. +# Changes may cause incorrect behavior and will be lost if the code is +# regenerated. +# -------------------------------------------------------------------------- + +from .events_result_data_py3 import EventsResultData + + +class EventsRequestResult(EventsResultData): + """A request result. + + All required parameters must be populated in order to send to Azure. + + :param id: The unique ID for this event. + :type id: str + :param count: Count of the event + :type count: long + :param timestamp: Timestamp of the event + :type timestamp: datetime + :param custom_dimensions: Custom dimensions of the event + :type custom_dimensions: + ~azure.applicationinsights.query.models.EventsResultDataCustomDimensions + :param custom_measurements: Custom measurements of the event + :type custom_measurements: + ~azure.applicationinsights.query.models.EventsResultDataCustomMeasurements + :param operation: Operation info of the event + :type operation: + ~azure.applicationinsights.query.models.EventsOperationInfo + :param session: Session info of the event + :type session: ~azure.applicationinsights.query.models.EventsSessionInfo + :param user: User info of the event + :type user: ~azure.applicationinsights.query.models.EventsUserInfo + :param cloud: Cloud info of the event + :type cloud: ~azure.applicationinsights.query.models.EventsCloudInfo + :param ai: AI info of the event + :type ai: ~azure.applicationinsights.query.models.EventsAiInfo + :param application: Application info of the event + :type application: + ~azure.applicationinsights.query.models.EventsApplicationInfo + :param client: Client info of the event + :type client: ~azure.applicationinsights.query.models.EventsClientInfo + :param type: Required. Constant filled by server. + :type type: str + :param request: + :type request: ~azure.applicationinsights.query.models.EventsRequestInfo + """ + + _validation = { + 'type': {'required': True}, + } + + _attribute_map = { + 'id': {'key': 'id', 'type': 'str'}, + 'count': {'key': 'count', 'type': 'long'}, + 'timestamp': {'key': 'timestamp', 'type': 'iso-8601'}, + 'custom_dimensions': {'key': 'customDimensions', 'type': 'EventsResultDataCustomDimensions'}, + 'custom_measurements': {'key': 'customMeasurements', 'type': 'EventsResultDataCustomMeasurements'}, + 'operation': {'key': 'operation', 'type': 'EventsOperationInfo'}, + 'session': {'key': 'session', 'type': 'EventsSessionInfo'}, + 'user': {'key': 'user', 'type': 'EventsUserInfo'}, + 'cloud': {'key': 'cloud', 'type': 'EventsCloudInfo'}, + 'ai': {'key': 'ai', 'type': 'EventsAiInfo'}, + 'application': {'key': 'application', 'type': 'EventsApplicationInfo'}, + 'client': {'key': 'client', 'type': 'EventsClientInfo'}, + 'type': {'key': 'type', 'type': 'str'}, + 'request': {'key': 'request', 'type': 'EventsRequestInfo'}, + } + + def __init__(self, *, id: str=None, count: int=None, timestamp=None, custom_dimensions=None, custom_measurements=None, operation=None, session=None, user=None, cloud=None, ai=None, application=None, client=None, request=None, **kwargs) -> None: + super(EventsRequestResult, self).__init__(id=id, count=count, timestamp=timestamp, custom_dimensions=custom_dimensions, custom_measurements=custom_measurements, operation=operation, session=session, user=user, cloud=cloud, ai=ai, application=application, client=client, **kwargs) + self.request = request + self.type = 'request' diff --git a/azure-applicationinsights-query/models/events_result.py b/azure-applicationinsights-query/models/events_result.py new file mode 100644 index 000000000000..b84d8c770a35 --- /dev/null +++ b/azure-applicationinsights-query/models/events_result.py @@ -0,0 +1,32 @@ +# coding=utf-8 +# -------------------------------------------------------------------------- +# Copyright (c) Microsoft Corporation. All rights reserved. +# Licensed under the MIT License. See License.txt in the project root for +# license information. +# +# Code generated by Microsoft (R) AutoRest Code Generator. +# Changes may cause incorrect behavior and will be lost if the code is +# regenerated. +# -------------------------------------------------------------------------- + +from msrest.serialization import Model + + +class EventsResult(Model): + """An event query result. + + :param aimessages: OData messages for this response. + :type aimessages: list[~azure.applicationinsights.query.models.ErrorInfo] + :param value: + :type value: ~azure.applicationinsights.query.models.EventsResultData + """ + + _attribute_map = { + 'aimessages': {'key': '@ai\\.messages', 'type': '[ErrorInfo]'}, + 'value': {'key': 'value', 'type': 'EventsResultData'}, + } + + def __init__(self, **kwargs): + super(EventsResult, self).__init__(**kwargs) + self.aimessages = kwargs.get('aimessages', None) + self.value = kwargs.get('value', None) diff --git a/azure-applicationinsights-query/models/events_result_data.py b/azure-applicationinsights-query/models/events_result_data.py new file mode 100644 index 000000000000..c4cf3b6ebe09 --- /dev/null +++ b/azure-applicationinsights-query/models/events_result_data.py @@ -0,0 +1,97 @@ +# coding=utf-8 +# -------------------------------------------------------------------------- +# Copyright (c) Microsoft Corporation. All rights reserved. +# Licensed under the MIT License. See License.txt in the project root for +# license information. +# +# Code generated by Microsoft (R) AutoRest Code Generator. +# Changes may cause incorrect behavior and will be lost if the code is +# regenerated. +# -------------------------------------------------------------------------- + +from msrest.serialization import Model + + +class EventsResultData(Model): + """Events query result data. + + You probably want to use the sub-classes and not this class directly. Known + sub-classes are: EventsTraceResult, EventsCustomEventResult, + EventsPageViewResult, EventsBrowserTimingResult, EventsRequestResult, + EventsDependencyResult, EventsExceptionResult, + EventsAvailabilityResultResult, EventsPerformanceCounterResult, + EventsCustomMetricResult + + All required parameters must be populated in order to send to Azure. + + :param id: The unique ID for this event. + :type id: str + :param count: Count of the event + :type count: long + :param timestamp: Timestamp of the event + :type timestamp: datetime + :param custom_dimensions: Custom dimensions of the event + :type custom_dimensions: + ~azure.applicationinsights.query.models.EventsResultDataCustomDimensions + :param custom_measurements: Custom measurements of the event + :type custom_measurements: + ~azure.applicationinsights.query.models.EventsResultDataCustomMeasurements + :param operation: Operation info of the event + :type operation: + ~azure.applicationinsights.query.models.EventsOperationInfo + :param session: Session info of the event + :type session: ~azure.applicationinsights.query.models.EventsSessionInfo + :param user: User info of the event + :type user: ~azure.applicationinsights.query.models.EventsUserInfo + :param cloud: Cloud info of the event + :type cloud: ~azure.applicationinsights.query.models.EventsCloudInfo + :param ai: AI info of the event + :type ai: ~azure.applicationinsights.query.models.EventsAiInfo + :param application: Application info of the event + :type application: + ~azure.applicationinsights.query.models.EventsApplicationInfo + :param client: Client info of the event + :type client: ~azure.applicationinsights.query.models.EventsClientInfo + :param type: Required. Constant filled by server. + :type type: str + """ + + _validation = { + 'type': {'required': True}, + } + + _attribute_map = { + 'id': {'key': 'id', 'type': 'str'}, + 'count': {'key': 'count', 'type': 'long'}, + 'timestamp': {'key': 'timestamp', 'type': 'iso-8601'}, + 'custom_dimensions': {'key': 'customDimensions', 'type': 'EventsResultDataCustomDimensions'}, + 'custom_measurements': {'key': 'customMeasurements', 'type': 'EventsResultDataCustomMeasurements'}, + 'operation': {'key': 'operation', 'type': 'EventsOperationInfo'}, + 'session': {'key': 'session', 'type': 'EventsSessionInfo'}, + 'user': {'key': 'user', 'type': 'EventsUserInfo'}, + 'cloud': {'key': 'cloud', 'type': 'EventsCloudInfo'}, + 'ai': {'key': 'ai', 'type': 'EventsAiInfo'}, + 'application': {'key': 'application', 'type': 'EventsApplicationInfo'}, + 'client': {'key': 'client', 'type': 'EventsClientInfo'}, + 'type': {'key': 'type', 'type': 'str'}, + } + + _subtype_map = { + 'type': {'trace': 'EventsTraceResult', 'customEvent': 'EventsCustomEventResult', 'pageView': 'EventsPageViewResult', 'browserTiming': 'EventsBrowserTimingResult', 'request': 'EventsRequestResult', 'dependency': 'EventsDependencyResult', 'exception': 'EventsExceptionResult', 'availabilityResult': 'EventsAvailabilityResultResult', 'performanceCounter': 'EventsPerformanceCounterResult', 'customMetric': 'EventsCustomMetricResult'} + } + + def __init__(self, **kwargs): + super(EventsResultData, self).__init__(**kwargs) + self.id = kwargs.get('id', None) + self.count = kwargs.get('count', None) + self.timestamp = kwargs.get('timestamp', None) + self.custom_dimensions = kwargs.get('custom_dimensions', None) + self.custom_measurements = kwargs.get('custom_measurements', None) + self.operation = kwargs.get('operation', None) + self.session = kwargs.get('session', None) + self.user = kwargs.get('user', None) + self.cloud = kwargs.get('cloud', None) + self.ai = kwargs.get('ai', None) + self.application = kwargs.get('application', None) + self.client = kwargs.get('client', None) + self.type = None diff --git a/azure-applicationinsights-query/models/events_result_data_custom_dimensions.py b/azure-applicationinsights-query/models/events_result_data_custom_dimensions.py new file mode 100644 index 000000000000..2f50c8baeb6e --- /dev/null +++ b/azure-applicationinsights-query/models/events_result_data_custom_dimensions.py @@ -0,0 +1,28 @@ +# coding=utf-8 +# -------------------------------------------------------------------------- +# Copyright (c) Microsoft Corporation. All rights reserved. +# Licensed under the MIT License. See License.txt in the project root for +# license information. +# +# Code generated by Microsoft (R) AutoRest Code Generator. +# Changes may cause incorrect behavior and will be lost if the code is +# regenerated. +# -------------------------------------------------------------------------- + +from msrest.serialization import Model + + +class EventsResultDataCustomDimensions(Model): + """Custom dimensions of the event. + + :param additional_properties: + :type additional_properties: object + """ + + _attribute_map = { + 'additional_properties': {'key': 'additionalProperties', 'type': 'object'}, + } + + def __init__(self, **kwargs): + super(EventsResultDataCustomDimensions, self).__init__(**kwargs) + self.additional_properties = kwargs.get('additional_properties', None) diff --git a/azure-applicationinsights-query/models/events_result_data_custom_dimensions_py3.py b/azure-applicationinsights-query/models/events_result_data_custom_dimensions_py3.py new file mode 100644 index 000000000000..968ac0eb0ab1 --- /dev/null +++ b/azure-applicationinsights-query/models/events_result_data_custom_dimensions_py3.py @@ -0,0 +1,28 @@ +# coding=utf-8 +# -------------------------------------------------------------------------- +# Copyright (c) Microsoft Corporation. All rights reserved. +# Licensed under the MIT License. See License.txt in the project root for +# license information. +# +# Code generated by Microsoft (R) AutoRest Code Generator. +# Changes may cause incorrect behavior and will be lost if the code is +# regenerated. +# -------------------------------------------------------------------------- + +from msrest.serialization import Model + + +class EventsResultDataCustomDimensions(Model): + """Custom dimensions of the event. + + :param additional_properties: + :type additional_properties: object + """ + + _attribute_map = { + 'additional_properties': {'key': 'additionalProperties', 'type': 'object'}, + } + + def __init__(self, *, additional_properties=None, **kwargs) -> None: + super(EventsResultDataCustomDimensions, self).__init__(**kwargs) + self.additional_properties = additional_properties diff --git a/azure-applicationinsights-query/models/events_result_data_custom_measurements.py b/azure-applicationinsights-query/models/events_result_data_custom_measurements.py new file mode 100644 index 000000000000..907b52e1f5ea --- /dev/null +++ b/azure-applicationinsights-query/models/events_result_data_custom_measurements.py @@ -0,0 +1,28 @@ +# coding=utf-8 +# -------------------------------------------------------------------------- +# Copyright (c) Microsoft Corporation. All rights reserved. +# Licensed under the MIT License. See License.txt in the project root for +# license information. +# +# Code generated by Microsoft (R) AutoRest Code Generator. +# Changes may cause incorrect behavior and will be lost if the code is +# regenerated. +# -------------------------------------------------------------------------- + +from msrest.serialization import Model + + +class EventsResultDataCustomMeasurements(Model): + """Custom measurements of the event. + + :param additional_properties: + :type additional_properties: object + """ + + _attribute_map = { + 'additional_properties': {'key': 'additionalProperties', 'type': 'object'}, + } + + def __init__(self, **kwargs): + super(EventsResultDataCustomMeasurements, self).__init__(**kwargs) + self.additional_properties = kwargs.get('additional_properties', None) diff --git a/azure-applicationinsights-query/models/events_result_data_custom_measurements_py3.py b/azure-applicationinsights-query/models/events_result_data_custom_measurements_py3.py new file mode 100644 index 000000000000..018286f96593 --- /dev/null +++ b/azure-applicationinsights-query/models/events_result_data_custom_measurements_py3.py @@ -0,0 +1,28 @@ +# coding=utf-8 +# -------------------------------------------------------------------------- +# Copyright (c) Microsoft Corporation. All rights reserved. +# Licensed under the MIT License. See License.txt in the project root for +# license information. +# +# Code generated by Microsoft (R) AutoRest Code Generator. +# Changes may cause incorrect behavior and will be lost if the code is +# regenerated. +# -------------------------------------------------------------------------- + +from msrest.serialization import Model + + +class EventsResultDataCustomMeasurements(Model): + """Custom measurements of the event. + + :param additional_properties: + :type additional_properties: object + """ + + _attribute_map = { + 'additional_properties': {'key': 'additionalProperties', 'type': 'object'}, + } + + def __init__(self, *, additional_properties=None, **kwargs) -> None: + super(EventsResultDataCustomMeasurements, self).__init__(**kwargs) + self.additional_properties = additional_properties diff --git a/azure-applicationinsights-query/models/events_result_data_py3.py b/azure-applicationinsights-query/models/events_result_data_py3.py new file mode 100644 index 000000000000..34ec898acd06 --- /dev/null +++ b/azure-applicationinsights-query/models/events_result_data_py3.py @@ -0,0 +1,97 @@ +# coding=utf-8 +# -------------------------------------------------------------------------- +# Copyright (c) Microsoft Corporation. All rights reserved. +# Licensed under the MIT License. See License.txt in the project root for +# license information. +# +# Code generated by Microsoft (R) AutoRest Code Generator. +# Changes may cause incorrect behavior and will be lost if the code is +# regenerated. +# -------------------------------------------------------------------------- + +from msrest.serialization import Model + + +class EventsResultData(Model): + """Events query result data. + + You probably want to use the sub-classes and not this class directly. Known + sub-classes are: EventsTraceResult, EventsCustomEventResult, + EventsPageViewResult, EventsBrowserTimingResult, EventsRequestResult, + EventsDependencyResult, EventsExceptionResult, + EventsAvailabilityResultResult, EventsPerformanceCounterResult, + EventsCustomMetricResult + + All required parameters must be populated in order to send to Azure. + + :param id: The unique ID for this event. + :type id: str + :param count: Count of the event + :type count: long + :param timestamp: Timestamp of the event + :type timestamp: datetime + :param custom_dimensions: Custom dimensions of the event + :type custom_dimensions: + ~azure.applicationinsights.query.models.EventsResultDataCustomDimensions + :param custom_measurements: Custom measurements of the event + :type custom_measurements: + ~azure.applicationinsights.query.models.EventsResultDataCustomMeasurements + :param operation: Operation info of the event + :type operation: + ~azure.applicationinsights.query.models.EventsOperationInfo + :param session: Session info of the event + :type session: ~azure.applicationinsights.query.models.EventsSessionInfo + :param user: User info of the event + :type user: ~azure.applicationinsights.query.models.EventsUserInfo + :param cloud: Cloud info of the event + :type cloud: ~azure.applicationinsights.query.models.EventsCloudInfo + :param ai: AI info of the event + :type ai: ~azure.applicationinsights.query.models.EventsAiInfo + :param application: Application info of the event + :type application: + ~azure.applicationinsights.query.models.EventsApplicationInfo + :param client: Client info of the event + :type client: ~azure.applicationinsights.query.models.EventsClientInfo + :param type: Required. Constant filled by server. + :type type: str + """ + + _validation = { + 'type': {'required': True}, + } + + _attribute_map = { + 'id': {'key': 'id', 'type': 'str'}, + 'count': {'key': 'count', 'type': 'long'}, + 'timestamp': {'key': 'timestamp', 'type': 'iso-8601'}, + 'custom_dimensions': {'key': 'customDimensions', 'type': 'EventsResultDataCustomDimensions'}, + 'custom_measurements': {'key': 'customMeasurements', 'type': 'EventsResultDataCustomMeasurements'}, + 'operation': {'key': 'operation', 'type': 'EventsOperationInfo'}, + 'session': {'key': 'session', 'type': 'EventsSessionInfo'}, + 'user': {'key': 'user', 'type': 'EventsUserInfo'}, + 'cloud': {'key': 'cloud', 'type': 'EventsCloudInfo'}, + 'ai': {'key': 'ai', 'type': 'EventsAiInfo'}, + 'application': {'key': 'application', 'type': 'EventsApplicationInfo'}, + 'client': {'key': 'client', 'type': 'EventsClientInfo'}, + 'type': {'key': 'type', 'type': 'str'}, + } + + _subtype_map = { + 'type': {'trace': 'EventsTraceResult', 'customEvent': 'EventsCustomEventResult', 'pageView': 'EventsPageViewResult', 'browserTiming': 'EventsBrowserTimingResult', 'request': 'EventsRequestResult', 'dependency': 'EventsDependencyResult', 'exception': 'EventsExceptionResult', 'availabilityResult': 'EventsAvailabilityResultResult', 'performanceCounter': 'EventsPerformanceCounterResult', 'customMetric': 'EventsCustomMetricResult'} + } + + def __init__(self, *, id: str=None, count: int=None, timestamp=None, custom_dimensions=None, custom_measurements=None, operation=None, session=None, user=None, cloud=None, ai=None, application=None, client=None, **kwargs) -> None: + super(EventsResultData, self).__init__(**kwargs) + self.id = id + self.count = count + self.timestamp = timestamp + self.custom_dimensions = custom_dimensions + self.custom_measurements = custom_measurements + self.operation = operation + self.session = session + self.user = user + self.cloud = cloud + self.ai = ai + self.application = application + self.client = client + self.type = None diff --git a/azure-applicationinsights-query/models/events_result_py3.py b/azure-applicationinsights-query/models/events_result_py3.py new file mode 100644 index 000000000000..a154e05aef55 --- /dev/null +++ b/azure-applicationinsights-query/models/events_result_py3.py @@ -0,0 +1,32 @@ +# coding=utf-8 +# -------------------------------------------------------------------------- +# Copyright (c) Microsoft Corporation. All rights reserved. +# Licensed under the MIT License. See License.txt in the project root for +# license information. +# +# Code generated by Microsoft (R) AutoRest Code Generator. +# Changes may cause incorrect behavior and will be lost if the code is +# regenerated. +# -------------------------------------------------------------------------- + +from msrest.serialization import Model + + +class EventsResult(Model): + """An event query result. + + :param aimessages: OData messages for this response. + :type aimessages: list[~azure.applicationinsights.query.models.ErrorInfo] + :param value: + :type value: ~azure.applicationinsights.query.models.EventsResultData + """ + + _attribute_map = { + 'aimessages': {'key': '@ai\\.messages', 'type': '[ErrorInfo]'}, + 'value': {'key': 'value', 'type': 'EventsResultData'}, + } + + def __init__(self, *, aimessages=None, value=None, **kwargs) -> None: + super(EventsResult, self).__init__(**kwargs) + self.aimessages = aimessages + self.value = value diff --git a/azure-applicationinsights-query/models/events_results.py b/azure-applicationinsights-query/models/events_results.py new file mode 100644 index 000000000000..8b9a2228d1b4 --- /dev/null +++ b/azure-applicationinsights-query/models/events_results.py @@ -0,0 +1,37 @@ +# coding=utf-8 +# -------------------------------------------------------------------------- +# Copyright (c) Microsoft Corporation. All rights reserved. +# Licensed under the MIT License. See License.txt in the project root for +# license information. +# +# Code generated by Microsoft (R) AutoRest Code Generator. +# Changes may cause incorrect behavior and will be lost if the code is +# regenerated. +# -------------------------------------------------------------------------- + +from msrest.serialization import Model + + +class EventsResults(Model): + """An events query result. + + :param odatacontext: OData context metadata endpoint for this response + :type odatacontext: str + :param aimessages: OData messages for this response. + :type aimessages: list[~azure.applicationinsights.query.models.ErrorInfo] + :param value: Contents of the events query result. + :type value: + list[~azure.applicationinsights.query.models.EventsResultData] + """ + + _attribute_map = { + 'odatacontext': {'key': '@odata\\.context', 'type': 'str'}, + 'aimessages': {'key': '@ai\\.messages', 'type': '[ErrorInfo]'}, + 'value': {'key': 'value', 'type': '[EventsResultData]'}, + } + + def __init__(self, **kwargs): + super(EventsResults, self).__init__(**kwargs) + self.odatacontext = kwargs.get('odatacontext', None) + self.aimessages = kwargs.get('aimessages', None) + self.value = kwargs.get('value', None) diff --git a/azure-applicationinsights-query/models/events_results_py3.py b/azure-applicationinsights-query/models/events_results_py3.py new file mode 100644 index 000000000000..65a22168d007 --- /dev/null +++ b/azure-applicationinsights-query/models/events_results_py3.py @@ -0,0 +1,37 @@ +# coding=utf-8 +# -------------------------------------------------------------------------- +# Copyright (c) Microsoft Corporation. All rights reserved. +# Licensed under the MIT License. See License.txt in the project root for +# license information. +# +# Code generated by Microsoft (R) AutoRest Code Generator. +# Changes may cause incorrect behavior and will be lost if the code is +# regenerated. +# -------------------------------------------------------------------------- + +from msrest.serialization import Model + + +class EventsResults(Model): + """An events query result. + + :param odatacontext: OData context metadata endpoint for this response + :type odatacontext: str + :param aimessages: OData messages for this response. + :type aimessages: list[~azure.applicationinsights.query.models.ErrorInfo] + :param value: Contents of the events query result. + :type value: + list[~azure.applicationinsights.query.models.EventsResultData] + """ + + _attribute_map = { + 'odatacontext': {'key': '@odata\\.context', 'type': 'str'}, + 'aimessages': {'key': '@ai\\.messages', 'type': '[ErrorInfo]'}, + 'value': {'key': 'value', 'type': '[EventsResultData]'}, + } + + def __init__(self, *, odatacontext: str=None, aimessages=None, value=None, **kwargs) -> None: + super(EventsResults, self).__init__(**kwargs) + self.odatacontext = odatacontext + self.aimessages = aimessages + self.value = value diff --git a/azure-applicationinsights-query/models/events_session_info.py b/azure-applicationinsights-query/models/events_session_info.py new file mode 100644 index 000000000000..9d4077762533 --- /dev/null +++ b/azure-applicationinsights-query/models/events_session_info.py @@ -0,0 +1,28 @@ +# coding=utf-8 +# -------------------------------------------------------------------------- +# Copyright (c) Microsoft Corporation. All rights reserved. +# Licensed under the MIT License. See License.txt in the project root for +# license information. +# +# Code generated by Microsoft (R) AutoRest Code Generator. +# Changes may cause incorrect behavior and will be lost if the code is +# regenerated. +# -------------------------------------------------------------------------- + +from msrest.serialization import Model + + +class EventsSessionInfo(Model): + """Session info for an event result. + + :param id: ID of the session + :type id: str + """ + + _attribute_map = { + 'id': {'key': 'id', 'type': 'str'}, + } + + def __init__(self, **kwargs): + super(EventsSessionInfo, self).__init__(**kwargs) + self.id = kwargs.get('id', None) diff --git a/azure-applicationinsights-query/models/events_session_info_py3.py b/azure-applicationinsights-query/models/events_session_info_py3.py new file mode 100644 index 000000000000..92a81d9668d1 --- /dev/null +++ b/azure-applicationinsights-query/models/events_session_info_py3.py @@ -0,0 +1,28 @@ +# coding=utf-8 +# -------------------------------------------------------------------------- +# Copyright (c) Microsoft Corporation. All rights reserved. +# Licensed under the MIT License. See License.txt in the project root for +# license information. +# +# Code generated by Microsoft (R) AutoRest Code Generator. +# Changes may cause incorrect behavior and will be lost if the code is +# regenerated. +# -------------------------------------------------------------------------- + +from msrest.serialization import Model + + +class EventsSessionInfo(Model): + """Session info for an event result. + + :param id: ID of the session + :type id: str + """ + + _attribute_map = { + 'id': {'key': 'id', 'type': 'str'}, + } + + def __init__(self, *, id: str=None, **kwargs) -> None: + super(EventsSessionInfo, self).__init__(**kwargs) + self.id = id diff --git a/azure-applicationinsights-query/models/events_trace_info.py b/azure-applicationinsights-query/models/events_trace_info.py new file mode 100644 index 000000000000..9eff63baf551 --- /dev/null +++ b/azure-applicationinsights-query/models/events_trace_info.py @@ -0,0 +1,32 @@ +# coding=utf-8 +# -------------------------------------------------------------------------- +# Copyright (c) Microsoft Corporation. All rights reserved. +# Licensed under the MIT License. See License.txt in the project root for +# license information. +# +# Code generated by Microsoft (R) AutoRest Code Generator. +# Changes may cause incorrect behavior and will be lost if the code is +# regenerated. +# -------------------------------------------------------------------------- + +from msrest.serialization import Model + + +class EventsTraceInfo(Model): + """The trace information. + + :param message: The trace message + :type message: str + :param severity_level: The trace severity level + :type severity_level: int + """ + + _attribute_map = { + 'message': {'key': 'message', 'type': 'str'}, + 'severity_level': {'key': 'severityLevel', 'type': 'int'}, + } + + def __init__(self, **kwargs): + super(EventsTraceInfo, self).__init__(**kwargs) + self.message = kwargs.get('message', None) + self.severity_level = kwargs.get('severity_level', None) diff --git a/azure-applicationinsights-query/models/events_trace_info_py3.py b/azure-applicationinsights-query/models/events_trace_info_py3.py new file mode 100644 index 000000000000..88956ebe1543 --- /dev/null +++ b/azure-applicationinsights-query/models/events_trace_info_py3.py @@ -0,0 +1,32 @@ +# coding=utf-8 +# -------------------------------------------------------------------------- +# Copyright (c) Microsoft Corporation. All rights reserved. +# Licensed under the MIT License. See License.txt in the project root for +# license information. +# +# Code generated by Microsoft (R) AutoRest Code Generator. +# Changes may cause incorrect behavior and will be lost if the code is +# regenerated. +# -------------------------------------------------------------------------- + +from msrest.serialization import Model + + +class EventsTraceInfo(Model): + """The trace information. + + :param message: The trace message + :type message: str + :param severity_level: The trace severity level + :type severity_level: int + """ + + _attribute_map = { + 'message': {'key': 'message', 'type': 'str'}, + 'severity_level': {'key': 'severityLevel', 'type': 'int'}, + } + + def __init__(self, *, message: str=None, severity_level: int=None, **kwargs) -> None: + super(EventsTraceInfo, self).__init__(**kwargs) + self.message = message + self.severity_level = severity_level diff --git a/azure-applicationinsights-query/models/events_trace_result.py b/azure-applicationinsights-query/models/events_trace_result.py new file mode 100644 index 000000000000..2d26495c9f82 --- /dev/null +++ b/azure-applicationinsights-query/models/events_trace_result.py @@ -0,0 +1,78 @@ +# coding=utf-8 +# -------------------------------------------------------------------------- +# Copyright (c) Microsoft Corporation. All rights reserved. +# Licensed under the MIT License. See License.txt in the project root for +# license information. +# +# Code generated by Microsoft (R) AutoRest Code Generator. +# Changes may cause incorrect behavior and will be lost if the code is +# regenerated. +# -------------------------------------------------------------------------- + +from .events_result_data import EventsResultData + + +class EventsTraceResult(EventsResultData): + """A trace result. + + All required parameters must be populated in order to send to Azure. + + :param id: The unique ID for this event. + :type id: str + :param count: Count of the event + :type count: long + :param timestamp: Timestamp of the event + :type timestamp: datetime + :param custom_dimensions: Custom dimensions of the event + :type custom_dimensions: + ~azure.applicationinsights.query.models.EventsResultDataCustomDimensions + :param custom_measurements: Custom measurements of the event + :type custom_measurements: + ~azure.applicationinsights.query.models.EventsResultDataCustomMeasurements + :param operation: Operation info of the event + :type operation: + ~azure.applicationinsights.query.models.EventsOperationInfo + :param session: Session info of the event + :type session: ~azure.applicationinsights.query.models.EventsSessionInfo + :param user: User info of the event + :type user: ~azure.applicationinsights.query.models.EventsUserInfo + :param cloud: Cloud info of the event + :type cloud: ~azure.applicationinsights.query.models.EventsCloudInfo + :param ai: AI info of the event + :type ai: ~azure.applicationinsights.query.models.EventsAiInfo + :param application: Application info of the event + :type application: + ~azure.applicationinsights.query.models.EventsApplicationInfo + :param client: Client info of the event + :type client: ~azure.applicationinsights.query.models.EventsClientInfo + :param type: Required. Constant filled by server. + :type type: str + :param trace: + :type trace: ~azure.applicationinsights.query.models.EventsTraceInfo + """ + + _validation = { + 'type': {'required': True}, + } + + _attribute_map = { + 'id': {'key': 'id', 'type': 'str'}, + 'count': {'key': 'count', 'type': 'long'}, + 'timestamp': {'key': 'timestamp', 'type': 'iso-8601'}, + 'custom_dimensions': {'key': 'customDimensions', 'type': 'EventsResultDataCustomDimensions'}, + 'custom_measurements': {'key': 'customMeasurements', 'type': 'EventsResultDataCustomMeasurements'}, + 'operation': {'key': 'operation', 'type': 'EventsOperationInfo'}, + 'session': {'key': 'session', 'type': 'EventsSessionInfo'}, + 'user': {'key': 'user', 'type': 'EventsUserInfo'}, + 'cloud': {'key': 'cloud', 'type': 'EventsCloudInfo'}, + 'ai': {'key': 'ai', 'type': 'EventsAiInfo'}, + 'application': {'key': 'application', 'type': 'EventsApplicationInfo'}, + 'client': {'key': 'client', 'type': 'EventsClientInfo'}, + 'type': {'key': 'type', 'type': 'str'}, + 'trace': {'key': 'trace', 'type': 'EventsTraceInfo'}, + } + + def __init__(self, **kwargs): + super(EventsTraceResult, self).__init__(**kwargs) + self.trace = kwargs.get('trace', None) + self.type = 'trace' diff --git a/azure-applicationinsights-query/models/events_trace_result_py3.py b/azure-applicationinsights-query/models/events_trace_result_py3.py new file mode 100644 index 000000000000..681f33d29018 --- /dev/null +++ b/azure-applicationinsights-query/models/events_trace_result_py3.py @@ -0,0 +1,78 @@ +# coding=utf-8 +# -------------------------------------------------------------------------- +# Copyright (c) Microsoft Corporation. All rights reserved. +# Licensed under the MIT License. See License.txt in the project root for +# license information. +# +# Code generated by Microsoft (R) AutoRest Code Generator. +# Changes may cause incorrect behavior and will be lost if the code is +# regenerated. +# -------------------------------------------------------------------------- + +from .events_result_data_py3 import EventsResultData + + +class EventsTraceResult(EventsResultData): + """A trace result. + + All required parameters must be populated in order to send to Azure. + + :param id: The unique ID for this event. + :type id: str + :param count: Count of the event + :type count: long + :param timestamp: Timestamp of the event + :type timestamp: datetime + :param custom_dimensions: Custom dimensions of the event + :type custom_dimensions: + ~azure.applicationinsights.query.models.EventsResultDataCustomDimensions + :param custom_measurements: Custom measurements of the event + :type custom_measurements: + ~azure.applicationinsights.query.models.EventsResultDataCustomMeasurements + :param operation: Operation info of the event + :type operation: + ~azure.applicationinsights.query.models.EventsOperationInfo + :param session: Session info of the event + :type session: ~azure.applicationinsights.query.models.EventsSessionInfo + :param user: User info of the event + :type user: ~azure.applicationinsights.query.models.EventsUserInfo + :param cloud: Cloud info of the event + :type cloud: ~azure.applicationinsights.query.models.EventsCloudInfo + :param ai: AI info of the event + :type ai: ~azure.applicationinsights.query.models.EventsAiInfo + :param application: Application info of the event + :type application: + ~azure.applicationinsights.query.models.EventsApplicationInfo + :param client: Client info of the event + :type client: ~azure.applicationinsights.query.models.EventsClientInfo + :param type: Required. Constant filled by server. + :type type: str + :param trace: + :type trace: ~azure.applicationinsights.query.models.EventsTraceInfo + """ + + _validation = { + 'type': {'required': True}, + } + + _attribute_map = { + 'id': {'key': 'id', 'type': 'str'}, + 'count': {'key': 'count', 'type': 'long'}, + 'timestamp': {'key': 'timestamp', 'type': 'iso-8601'}, + 'custom_dimensions': {'key': 'customDimensions', 'type': 'EventsResultDataCustomDimensions'}, + 'custom_measurements': {'key': 'customMeasurements', 'type': 'EventsResultDataCustomMeasurements'}, + 'operation': {'key': 'operation', 'type': 'EventsOperationInfo'}, + 'session': {'key': 'session', 'type': 'EventsSessionInfo'}, + 'user': {'key': 'user', 'type': 'EventsUserInfo'}, + 'cloud': {'key': 'cloud', 'type': 'EventsCloudInfo'}, + 'ai': {'key': 'ai', 'type': 'EventsAiInfo'}, + 'application': {'key': 'application', 'type': 'EventsApplicationInfo'}, + 'client': {'key': 'client', 'type': 'EventsClientInfo'}, + 'type': {'key': 'type', 'type': 'str'}, + 'trace': {'key': 'trace', 'type': 'EventsTraceInfo'}, + } + + def __init__(self, *, id: str=None, count: int=None, timestamp=None, custom_dimensions=None, custom_measurements=None, operation=None, session=None, user=None, cloud=None, ai=None, application=None, client=None, trace=None, **kwargs) -> None: + super(EventsTraceResult, self).__init__(id=id, count=count, timestamp=timestamp, custom_dimensions=custom_dimensions, custom_measurements=custom_measurements, operation=operation, session=session, user=user, cloud=cloud, ai=ai, application=application, client=client, **kwargs) + self.trace = trace + self.type = 'trace' diff --git a/azure-applicationinsights-query/models/events_user_info.py b/azure-applicationinsights-query/models/events_user_info.py new file mode 100644 index 000000000000..a5753b1a30ff --- /dev/null +++ b/azure-applicationinsights-query/models/events_user_info.py @@ -0,0 +1,36 @@ +# coding=utf-8 +# -------------------------------------------------------------------------- +# Copyright (c) Microsoft Corporation. All rights reserved. +# Licensed under the MIT License. See License.txt in the project root for +# license information. +# +# Code generated by Microsoft (R) AutoRest Code Generator. +# Changes may cause incorrect behavior and will be lost if the code is +# regenerated. +# -------------------------------------------------------------------------- + +from msrest.serialization import Model + + +class EventsUserInfo(Model): + """User info for an event result. + + :param id: ID of the user + :type id: str + :param account_id: Account ID of the user + :type account_id: str + :param authenticated_id: Authenticated ID of the user + :type authenticated_id: str + """ + + _attribute_map = { + 'id': {'key': 'id', 'type': 'str'}, + 'account_id': {'key': 'accountId', 'type': 'str'}, + 'authenticated_id': {'key': 'authenticatedId', 'type': 'str'}, + } + + def __init__(self, **kwargs): + super(EventsUserInfo, self).__init__(**kwargs) + self.id = kwargs.get('id', None) + self.account_id = kwargs.get('account_id', None) + self.authenticated_id = kwargs.get('authenticated_id', None) diff --git a/azure-applicationinsights-query/models/events_user_info_py3.py b/azure-applicationinsights-query/models/events_user_info_py3.py new file mode 100644 index 000000000000..910dbb4c3b3d --- /dev/null +++ b/azure-applicationinsights-query/models/events_user_info_py3.py @@ -0,0 +1,36 @@ +# coding=utf-8 +# -------------------------------------------------------------------------- +# Copyright (c) Microsoft Corporation. All rights reserved. +# Licensed under the MIT License. See License.txt in the project root for +# license information. +# +# Code generated by Microsoft (R) AutoRest Code Generator. +# Changes may cause incorrect behavior and will be lost if the code is +# regenerated. +# -------------------------------------------------------------------------- + +from msrest.serialization import Model + + +class EventsUserInfo(Model): + """User info for an event result. + + :param id: ID of the user + :type id: str + :param account_id: Account ID of the user + :type account_id: str + :param authenticated_id: Authenticated ID of the user + :type authenticated_id: str + """ + + _attribute_map = { + 'id': {'key': 'id', 'type': 'str'}, + 'account_id': {'key': 'accountId', 'type': 'str'}, + 'authenticated_id': {'key': 'authenticatedId', 'type': 'str'}, + } + + def __init__(self, *, id: str=None, account_id: str=None, authenticated_id: str=None, **kwargs) -> None: + super(EventsUserInfo, self).__init__(**kwargs) + self.id = id + self.account_id = account_id + self.authenticated_id = authenticated_id diff --git a/azure-applicationinsights-query/models/metrics_post_body_schema.py b/azure-applicationinsights-query/models/metrics_post_body_schema.py new file mode 100644 index 000000000000..130ecf0ba8c3 --- /dev/null +++ b/azure-applicationinsights-query/models/metrics_post_body_schema.py @@ -0,0 +1,42 @@ +# coding=utf-8 +# -------------------------------------------------------------------------- +# Copyright (c) Microsoft Corporation. All rights reserved. +# Licensed under the MIT License. See License.txt in the project root for +# license information. +# +# Code generated by Microsoft (R) AutoRest Code Generator. +# Changes may cause incorrect behavior and will be lost if the code is +# regenerated. +# -------------------------------------------------------------------------- + +from msrest.serialization import Model + + +class MetricsPostBodySchema(Model): + """A metric request. + + All required parameters must be populated in order to send to Azure. + + :param id: Required. An identifier for this query. Must be unique within + the post body of the request. This identifier will be the 'id' property + of the response object representing this query. + :type id: str + :param parameters: Required. The parameters for a single metrics query + :type parameters: + ~azure.applicationinsights.query.models.MetricsPostBodySchemaParameters + """ + + _validation = { + 'id': {'required': True}, + 'parameters': {'required': True}, + } + + _attribute_map = { + 'id': {'key': 'id', 'type': 'str'}, + 'parameters': {'key': 'parameters', 'type': 'MetricsPostBodySchemaParameters'}, + } + + def __init__(self, **kwargs): + super(MetricsPostBodySchema, self).__init__(**kwargs) + self.id = kwargs.get('id', None) + self.parameters = kwargs.get('parameters', None) diff --git a/azure-applicationinsights-query/models/metrics_post_body_schema_parameters.py b/azure-applicationinsights-query/models/metrics_post_body_schema_parameters.py new file mode 100644 index 000000000000..2431f9a36184 --- /dev/null +++ b/azure-applicationinsights-query/models/metrics_post_body_schema_parameters.py @@ -0,0 +1,82 @@ +# coding=utf-8 +# -------------------------------------------------------------------------- +# Copyright (c) Microsoft Corporation. All rights reserved. +# Licensed under the MIT License. See License.txt in the project root for +# license information. +# +# Code generated by Microsoft (R) AutoRest Code Generator. +# Changes may cause incorrect behavior and will be lost if the code is +# regenerated. +# -------------------------------------------------------------------------- + +from msrest.serialization import Model + + +class MetricsPostBodySchemaParameters(Model): + """The parameters for a single metrics query. + + All required parameters must be populated in order to send to Azure. + + :param metric_id: Required. Possible values include: 'requests/count', + 'requests/duration', 'requests/failed', 'users/count', + 'users/authenticated', 'pageViews/count', 'pageViews/duration', + 'client/processingDuration', 'client/receiveDuration', + 'client/networkDuration', 'client/sendDuration', 'client/totalDuration', + 'dependencies/count', 'dependencies/failed', 'dependencies/duration', + 'exceptions/count', 'exceptions/browser', 'exceptions/server', + 'sessions/count', 'performanceCounters/requestExecutionTime', + 'performanceCounters/requestsPerSecond', + 'performanceCounters/requestsInQueue', + 'performanceCounters/memoryAvailableBytes', + 'performanceCounters/exceptionsPerSecond', + 'performanceCounters/processCpuPercentage', + 'performanceCounters/processIOBytesPerSecond', + 'performanceCounters/processPrivateBytes', + 'performanceCounters/processorCpuPercentage', + 'availabilityResults/availabilityPercentage', + 'availabilityResults/duration', 'billing/telemetryCount', + 'customEvents/count' + :type metric_id: str or ~azure.applicationinsights.query.models.MetricId + :param timespan: + :type timespan: str + :param aggregation: + :type aggregation: list[str or + ~azure.applicationinsights.query.models.MetricsAggregation] + :param interval: + :type interval: timedelta + :param segment: + :type segment: list[str or + ~azure.applicationinsights.query.models.MetricsSegment] + :param top: + :type top: int + :param orderby: + :type orderby: str + :param filter: + :type filter: str + """ + + _validation = { + 'metric_id': {'required': True}, + } + + _attribute_map = { + 'metric_id': {'key': 'metricId', 'type': 'str'}, + 'timespan': {'key': 'timespan', 'type': 'str'}, + 'aggregation': {'key': 'aggregation', 'type': '[str]'}, + 'interval': {'key': 'interval', 'type': 'duration'}, + 'segment': {'key': 'segment', 'type': '[str]'}, + 'top': {'key': 'top', 'type': 'int'}, + 'orderby': {'key': 'orderby', 'type': 'str'}, + 'filter': {'key': 'filter', 'type': 'str'}, + } + + def __init__(self, **kwargs): + super(MetricsPostBodySchemaParameters, self).__init__(**kwargs) + self.metric_id = kwargs.get('metric_id', None) + self.timespan = kwargs.get('timespan', None) + self.aggregation = kwargs.get('aggregation', None) + self.interval = kwargs.get('interval', None) + self.segment = kwargs.get('segment', None) + self.top = kwargs.get('top', None) + self.orderby = kwargs.get('orderby', None) + self.filter = kwargs.get('filter', None) diff --git a/azure-applicationinsights-query/models/metrics_post_body_schema_parameters_py3.py b/azure-applicationinsights-query/models/metrics_post_body_schema_parameters_py3.py new file mode 100644 index 000000000000..7329e3052166 --- /dev/null +++ b/azure-applicationinsights-query/models/metrics_post_body_schema_parameters_py3.py @@ -0,0 +1,82 @@ +# coding=utf-8 +# -------------------------------------------------------------------------- +# Copyright (c) Microsoft Corporation. All rights reserved. +# Licensed under the MIT License. See License.txt in the project root for +# license information. +# +# Code generated by Microsoft (R) AutoRest Code Generator. +# Changes may cause incorrect behavior and will be lost if the code is +# regenerated. +# -------------------------------------------------------------------------- + +from msrest.serialization import Model + + +class MetricsPostBodySchemaParameters(Model): + """The parameters for a single metrics query. + + All required parameters must be populated in order to send to Azure. + + :param metric_id: Required. Possible values include: 'requests/count', + 'requests/duration', 'requests/failed', 'users/count', + 'users/authenticated', 'pageViews/count', 'pageViews/duration', + 'client/processingDuration', 'client/receiveDuration', + 'client/networkDuration', 'client/sendDuration', 'client/totalDuration', + 'dependencies/count', 'dependencies/failed', 'dependencies/duration', + 'exceptions/count', 'exceptions/browser', 'exceptions/server', + 'sessions/count', 'performanceCounters/requestExecutionTime', + 'performanceCounters/requestsPerSecond', + 'performanceCounters/requestsInQueue', + 'performanceCounters/memoryAvailableBytes', + 'performanceCounters/exceptionsPerSecond', + 'performanceCounters/processCpuPercentage', + 'performanceCounters/processIOBytesPerSecond', + 'performanceCounters/processPrivateBytes', + 'performanceCounters/processorCpuPercentage', + 'availabilityResults/availabilityPercentage', + 'availabilityResults/duration', 'billing/telemetryCount', + 'customEvents/count' + :type metric_id: str or ~azure.applicationinsights.query.models.MetricId + :param timespan: + :type timespan: str + :param aggregation: + :type aggregation: list[str or + ~azure.applicationinsights.query.models.MetricsAggregation] + :param interval: + :type interval: timedelta + :param segment: + :type segment: list[str or + ~azure.applicationinsights.query.models.MetricsSegment] + :param top: + :type top: int + :param orderby: + :type orderby: str + :param filter: + :type filter: str + """ + + _validation = { + 'metric_id': {'required': True}, + } + + _attribute_map = { + 'metric_id': {'key': 'metricId', 'type': 'str'}, + 'timespan': {'key': 'timespan', 'type': 'str'}, + 'aggregation': {'key': 'aggregation', 'type': '[str]'}, + 'interval': {'key': 'interval', 'type': 'duration'}, + 'segment': {'key': 'segment', 'type': '[str]'}, + 'top': {'key': 'top', 'type': 'int'}, + 'orderby': {'key': 'orderby', 'type': 'str'}, + 'filter': {'key': 'filter', 'type': 'str'}, + } + + def __init__(self, *, metric_id, timespan: str=None, aggregation=None, interval=None, segment=None, top: int=None, orderby: str=None, filter: str=None, **kwargs) -> None: + super(MetricsPostBodySchemaParameters, self).__init__(**kwargs) + self.metric_id = metric_id + self.timespan = timespan + self.aggregation = aggregation + self.interval = interval + self.segment = segment + self.top = top + self.orderby = orderby + self.filter = filter diff --git a/azure-applicationinsights-query/models/metrics_post_body_schema_py3.py b/azure-applicationinsights-query/models/metrics_post_body_schema_py3.py new file mode 100644 index 000000000000..0a4fe848984b --- /dev/null +++ b/azure-applicationinsights-query/models/metrics_post_body_schema_py3.py @@ -0,0 +1,42 @@ +# coding=utf-8 +# -------------------------------------------------------------------------- +# Copyright (c) Microsoft Corporation. All rights reserved. +# Licensed under the MIT License. See License.txt in the project root for +# license information. +# +# Code generated by Microsoft (R) AutoRest Code Generator. +# Changes may cause incorrect behavior and will be lost if the code is +# regenerated. +# -------------------------------------------------------------------------- + +from msrest.serialization import Model + + +class MetricsPostBodySchema(Model): + """A metric request. + + All required parameters must be populated in order to send to Azure. + + :param id: Required. An identifier for this query. Must be unique within + the post body of the request. This identifier will be the 'id' property + of the response object representing this query. + :type id: str + :param parameters: Required. The parameters for a single metrics query + :type parameters: + ~azure.applicationinsights.query.models.MetricsPostBodySchemaParameters + """ + + _validation = { + 'id': {'required': True}, + 'parameters': {'required': True}, + } + + _attribute_map = { + 'id': {'key': 'id', 'type': 'str'}, + 'parameters': {'key': 'parameters', 'type': 'MetricsPostBodySchemaParameters'}, + } + + def __init__(self, *, id: str, parameters, **kwargs) -> None: + super(MetricsPostBodySchema, self).__init__(**kwargs) + self.id = id + self.parameters = parameters diff --git a/azure-applicationinsights-query/models/metrics_result.py b/azure-applicationinsights-query/models/metrics_result.py new file mode 100644 index 000000000000..6c8de065aa0f --- /dev/null +++ b/azure-applicationinsights-query/models/metrics_result.py @@ -0,0 +1,28 @@ +# coding=utf-8 +# -------------------------------------------------------------------------- +# Copyright (c) Microsoft Corporation. All rights reserved. +# Licensed under the MIT License. See License.txt in the project root for +# license information. +# +# Code generated by Microsoft (R) AutoRest Code Generator. +# Changes may cause incorrect behavior and will be lost if the code is +# regenerated. +# -------------------------------------------------------------------------- + +from msrest.serialization import Model + + +class MetricsResult(Model): + """A metric result. + + :param value: + :type value: ~azure.applicationinsights.query.models.MetricsResultInfo + """ + + _attribute_map = { + 'value': {'key': 'value', 'type': 'MetricsResultInfo'}, + } + + def __init__(self, **kwargs): + super(MetricsResult, self).__init__(**kwargs) + self.value = kwargs.get('value', None) diff --git a/azure-applicationinsights-query/models/metrics_result_info.py b/azure-applicationinsights-query/models/metrics_result_info.py new file mode 100644 index 000000000000..69f9b4ca3861 --- /dev/null +++ b/azure-applicationinsights-query/models/metrics_result_info.py @@ -0,0 +1,46 @@ +# coding=utf-8 +# -------------------------------------------------------------------------- +# Copyright (c) Microsoft Corporation. All rights reserved. +# Licensed under the MIT License. See License.txt in the project root for +# license information. +# +# Code generated by Microsoft (R) AutoRest Code Generator. +# Changes may cause incorrect behavior and will be lost if the code is +# regenerated. +# -------------------------------------------------------------------------- + +from msrest.serialization import Model + + +class MetricsResultInfo(Model): + """A metric result data. + + :param additional_properties: Unmatched properties from the message are + deserialized this collection + :type additional_properties: dict[str, object] + :param start: Start time of the metric. + :type start: datetime + :param end: Start time of the metric. + :type end: datetime + :param interval: The interval used to segment the metric data. + :type interval: timedelta + :param segments: Segmented metric data (if segmented). + :type segments: + list[~azure.applicationinsights.query.models.MetricsSegmentInfo] + """ + + _attribute_map = { + 'additional_properties': {'key': '', 'type': '{object}'}, + 'start': {'key': 'start', 'type': 'iso-8601'}, + 'end': {'key': 'end', 'type': 'iso-8601'}, + 'interval': {'key': 'interval', 'type': 'duration'}, + 'segments': {'key': 'segments', 'type': '[MetricsSegmentInfo]'}, + } + + def __init__(self, **kwargs): + super(MetricsResultInfo, self).__init__(**kwargs) + self.additional_properties = kwargs.get('additional_properties', None) + self.start = kwargs.get('start', None) + self.end = kwargs.get('end', None) + self.interval = kwargs.get('interval', None) + self.segments = kwargs.get('segments', None) diff --git a/azure-applicationinsights-query/models/metrics_result_info_py3.py b/azure-applicationinsights-query/models/metrics_result_info_py3.py new file mode 100644 index 000000000000..e4005451e9b6 --- /dev/null +++ b/azure-applicationinsights-query/models/metrics_result_info_py3.py @@ -0,0 +1,46 @@ +# coding=utf-8 +# -------------------------------------------------------------------------- +# Copyright (c) Microsoft Corporation. All rights reserved. +# Licensed under the MIT License. See License.txt in the project root for +# license information. +# +# Code generated by Microsoft (R) AutoRest Code Generator. +# Changes may cause incorrect behavior and will be lost if the code is +# regenerated. +# -------------------------------------------------------------------------- + +from msrest.serialization import Model + + +class MetricsResultInfo(Model): + """A metric result data. + + :param additional_properties: Unmatched properties from the message are + deserialized this collection + :type additional_properties: dict[str, object] + :param start: Start time of the metric. + :type start: datetime + :param end: Start time of the metric. + :type end: datetime + :param interval: The interval used to segment the metric data. + :type interval: timedelta + :param segments: Segmented metric data (if segmented). + :type segments: + list[~azure.applicationinsights.query.models.MetricsSegmentInfo] + """ + + _attribute_map = { + 'additional_properties': {'key': '', 'type': '{object}'}, + 'start': {'key': 'start', 'type': 'iso-8601'}, + 'end': {'key': 'end', 'type': 'iso-8601'}, + 'interval': {'key': 'interval', 'type': 'duration'}, + 'segments': {'key': 'segments', 'type': '[MetricsSegmentInfo]'}, + } + + def __init__(self, *, additional_properties=None, start=None, end=None, interval=None, segments=None, **kwargs) -> None: + super(MetricsResultInfo, self).__init__(**kwargs) + self.additional_properties = additional_properties + self.start = start + self.end = end + self.interval = interval + self.segments = segments diff --git a/azure-applicationinsights-query/models/metrics_result_py3.py b/azure-applicationinsights-query/models/metrics_result_py3.py new file mode 100644 index 000000000000..caad749117bf --- /dev/null +++ b/azure-applicationinsights-query/models/metrics_result_py3.py @@ -0,0 +1,28 @@ +# coding=utf-8 +# -------------------------------------------------------------------------- +# Copyright (c) Microsoft Corporation. All rights reserved. +# Licensed under the MIT License. See License.txt in the project root for +# license information. +# +# Code generated by Microsoft (R) AutoRest Code Generator. +# Changes may cause incorrect behavior and will be lost if the code is +# regenerated. +# -------------------------------------------------------------------------- + +from msrest.serialization import Model + + +class MetricsResult(Model): + """A metric result. + + :param value: + :type value: ~azure.applicationinsights.query.models.MetricsResultInfo + """ + + _attribute_map = { + 'value': {'key': 'value', 'type': 'MetricsResultInfo'}, + } + + def __init__(self, *, value=None, **kwargs) -> None: + super(MetricsResult, self).__init__(**kwargs) + self.value = value diff --git a/azure-applicationinsights-query/models/metrics_results_item.py b/azure-applicationinsights-query/models/metrics_results_item.py new file mode 100644 index 000000000000..05367f7646cf --- /dev/null +++ b/azure-applicationinsights-query/models/metrics_results_item.py @@ -0,0 +1,44 @@ +# coding=utf-8 +# -------------------------------------------------------------------------- +# Copyright (c) Microsoft Corporation. All rights reserved. +# Licensed under the MIT License. See License.txt in the project root for +# license information. +# +# Code generated by Microsoft (R) AutoRest Code Generator. +# Changes may cause incorrect behavior and will be lost if the code is +# regenerated. +# -------------------------------------------------------------------------- + +from msrest.serialization import Model + + +class MetricsResultsItem(Model): + """MetricsResultsItem. + + All required parameters must be populated in order to send to Azure. + + :param id: Required. The specified ID for this metric. + :type id: str + :param status: Required. The HTTP status code of this metric query. + :type status: int + :param body: Required. The results of this metric query. + :type body: ~azure.applicationinsights.query.models.MetricsResult + """ + + _validation = { + 'id': {'required': True}, + 'status': {'required': True}, + 'body': {'required': True}, + } + + _attribute_map = { + 'id': {'key': 'id', 'type': 'str'}, + 'status': {'key': 'status', 'type': 'int'}, + 'body': {'key': 'body', 'type': 'MetricsResult'}, + } + + def __init__(self, **kwargs): + super(MetricsResultsItem, self).__init__(**kwargs) + self.id = kwargs.get('id', None) + self.status = kwargs.get('status', None) + self.body = kwargs.get('body', None) diff --git a/azure-applicationinsights-query/models/metrics_results_item_py3.py b/azure-applicationinsights-query/models/metrics_results_item_py3.py new file mode 100644 index 000000000000..69d079f49b10 --- /dev/null +++ b/azure-applicationinsights-query/models/metrics_results_item_py3.py @@ -0,0 +1,44 @@ +# coding=utf-8 +# -------------------------------------------------------------------------- +# Copyright (c) Microsoft Corporation. All rights reserved. +# Licensed under the MIT License. See License.txt in the project root for +# license information. +# +# Code generated by Microsoft (R) AutoRest Code Generator. +# Changes may cause incorrect behavior and will be lost if the code is +# regenerated. +# -------------------------------------------------------------------------- + +from msrest.serialization import Model + + +class MetricsResultsItem(Model): + """MetricsResultsItem. + + All required parameters must be populated in order to send to Azure. + + :param id: Required. The specified ID for this metric. + :type id: str + :param status: Required. The HTTP status code of this metric query. + :type status: int + :param body: Required. The results of this metric query. + :type body: ~azure.applicationinsights.query.models.MetricsResult + """ + + _validation = { + 'id': {'required': True}, + 'status': {'required': True}, + 'body': {'required': True}, + } + + _attribute_map = { + 'id': {'key': 'id', 'type': 'str'}, + 'status': {'key': 'status', 'type': 'int'}, + 'body': {'key': 'body', 'type': 'MetricsResult'}, + } + + def __init__(self, *, id: str, status: int, body, **kwargs) -> None: + super(MetricsResultsItem, self).__init__(**kwargs) + self.id = id + self.status = status + self.body = body diff --git a/azure-applicationinsights-query/models/metrics_segment_info.py b/azure-applicationinsights-query/models/metrics_segment_info.py new file mode 100644 index 000000000000..9fc5d23a86d1 --- /dev/null +++ b/azure-applicationinsights-query/models/metrics_segment_info.py @@ -0,0 +1,44 @@ +# coding=utf-8 +# -------------------------------------------------------------------------- +# Copyright (c) Microsoft Corporation. All rights reserved. +# Licensed under the MIT License. See License.txt in the project root for +# license information. +# +# Code generated by Microsoft (R) AutoRest Code Generator. +# Changes may cause incorrect behavior and will be lost if the code is +# regenerated. +# -------------------------------------------------------------------------- + +from msrest.serialization import Model + + +class MetricsSegmentInfo(Model): + """A metric segment. + + :param additional_properties: Unmatched properties from the message are + deserialized this collection + :type additional_properties: dict[str, object] + :param start: Start time of the metric segment (only when an interval was + specified). + :type start: datetime + :param end: Start time of the metric segment (only when an interval was + specified). + :type end: datetime + :param segments: Segmented metric data (if further segmented). + :type segments: + list[~azure.applicationinsights.query.models.MetricsSegmentInfo] + """ + + _attribute_map = { + 'additional_properties': {'key': '', 'type': '{object}'}, + 'start': {'key': 'start', 'type': 'iso-8601'}, + 'end': {'key': 'end', 'type': 'iso-8601'}, + 'segments': {'key': 'segments', 'type': '[MetricsSegmentInfo]'}, + } + + def __init__(self, **kwargs): + super(MetricsSegmentInfo, self).__init__(**kwargs) + self.additional_properties = kwargs.get('additional_properties', None) + self.start = kwargs.get('start', None) + self.end = kwargs.get('end', None) + self.segments = kwargs.get('segments', None) diff --git a/azure-applicationinsights-query/models/metrics_segment_info_py3.py b/azure-applicationinsights-query/models/metrics_segment_info_py3.py new file mode 100644 index 000000000000..0fa80b9df930 --- /dev/null +++ b/azure-applicationinsights-query/models/metrics_segment_info_py3.py @@ -0,0 +1,44 @@ +# coding=utf-8 +# -------------------------------------------------------------------------- +# Copyright (c) Microsoft Corporation. All rights reserved. +# Licensed under the MIT License. See License.txt in the project root for +# license information. +# +# Code generated by Microsoft (R) AutoRest Code Generator. +# Changes may cause incorrect behavior and will be lost if the code is +# regenerated. +# -------------------------------------------------------------------------- + +from msrest.serialization import Model + + +class MetricsSegmentInfo(Model): + """A metric segment. + + :param additional_properties: Unmatched properties from the message are + deserialized this collection + :type additional_properties: dict[str, object] + :param start: Start time of the metric segment (only when an interval was + specified). + :type start: datetime + :param end: Start time of the metric segment (only when an interval was + specified). + :type end: datetime + :param segments: Segmented metric data (if further segmented). + :type segments: + list[~azure.applicationinsights.query.models.MetricsSegmentInfo] + """ + + _attribute_map = { + 'additional_properties': {'key': '', 'type': '{object}'}, + 'start': {'key': 'start', 'type': 'iso-8601'}, + 'end': {'key': 'end', 'type': 'iso-8601'}, + 'segments': {'key': 'segments', 'type': '[MetricsSegmentInfo]'}, + } + + def __init__(self, *, additional_properties=None, start=None, end=None, segments=None, **kwargs) -> None: + super(MetricsSegmentInfo, self).__init__(**kwargs) + self.additional_properties = additional_properties + self.start = start + self.end = end + self.segments = segments diff --git a/azure-applicationinsights-query/models/query_body.py b/azure-applicationinsights-query/models/query_body.py new file mode 100644 index 000000000000..7c140d71d81d --- /dev/null +++ b/azure-applicationinsights-query/models/query_body.py @@ -0,0 +1,46 @@ +# coding=utf-8 +# -------------------------------------------------------------------------- +# Copyright (c) Microsoft Corporation. All rights reserved. +# Licensed under the MIT License. See License.txt in the project root for +# license information. +# +# Code generated by Microsoft (R) AutoRest Code Generator. +# Changes may cause incorrect behavior and will be lost if the code is +# regenerated. +# -------------------------------------------------------------------------- + +from msrest.serialization import Model + + +class QueryBody(Model): + """The Analytics query. Learn more about the [Analytics query + syntax](https://azure.microsoft.com/documentation/articles/app-insights-analytics-reference/). + + All required parameters must be populated in order to send to Azure. + + :param query: Required. The query to execute. + :type query: str + :param timespan: Optional. The timespan over which to query data. This is + an ISO8601 time period value. This timespan is applied in addition to any + that are specified in the query expression. + :type timespan: str + :param applications: A list of Application IDs for cross-application + queries. + :type applications: list[str] + """ + + _validation = { + 'query': {'required': True}, + } + + _attribute_map = { + 'query': {'key': 'query', 'type': 'str'}, + 'timespan': {'key': 'timespan', 'type': 'str'}, + 'applications': {'key': 'applications', 'type': '[str]'}, + } + + def __init__(self, **kwargs): + super(QueryBody, self).__init__(**kwargs) + self.query = kwargs.get('query', None) + self.timespan = kwargs.get('timespan', None) + self.applications = kwargs.get('applications', None) diff --git a/azure-applicationinsights-query/models/query_body_py3.py b/azure-applicationinsights-query/models/query_body_py3.py new file mode 100644 index 000000000000..4e718edc98a3 --- /dev/null +++ b/azure-applicationinsights-query/models/query_body_py3.py @@ -0,0 +1,46 @@ +# coding=utf-8 +# -------------------------------------------------------------------------- +# Copyright (c) Microsoft Corporation. All rights reserved. +# Licensed under the MIT License. See License.txt in the project root for +# license information. +# +# Code generated by Microsoft (R) AutoRest Code Generator. +# Changes may cause incorrect behavior and will be lost if the code is +# regenerated. +# -------------------------------------------------------------------------- + +from msrest.serialization import Model + + +class QueryBody(Model): + """The Analytics query. Learn more about the [Analytics query + syntax](https://azure.microsoft.com/documentation/articles/app-insights-analytics-reference/). + + All required parameters must be populated in order to send to Azure. + + :param query: Required. The query to execute. + :type query: str + :param timespan: Optional. The timespan over which to query data. This is + an ISO8601 time period value. This timespan is applied in addition to any + that are specified in the query expression. + :type timespan: str + :param applications: A list of Application IDs for cross-application + queries. + :type applications: list[str] + """ + + _validation = { + 'query': {'required': True}, + } + + _attribute_map = { + 'query': {'key': 'query', 'type': 'str'}, + 'timespan': {'key': 'timespan', 'type': 'str'}, + 'applications': {'key': 'applications', 'type': '[str]'}, + } + + def __init__(self, *, query: str, timespan: str=None, applications=None, **kwargs) -> None: + super(QueryBody, self).__init__(**kwargs) + self.query = query + self.timespan = timespan + self.applications = applications diff --git a/azure-applicationinsights-query/models/query_results.py b/azure-applicationinsights-query/models/query_results.py new file mode 100644 index 000000000000..e2f709b3bbb7 --- /dev/null +++ b/azure-applicationinsights-query/models/query_results.py @@ -0,0 +1,36 @@ +# coding=utf-8 +# -------------------------------------------------------------------------- +# Copyright (c) Microsoft Corporation. All rights reserved. +# Licensed under the MIT License. See License.txt in the project root for +# license information. +# +# Code generated by Microsoft (R) AutoRest Code Generator. +# Changes may cause incorrect behavior and will be lost if the code is +# regenerated. +# -------------------------------------------------------------------------- + +from msrest.serialization import Model + + +class QueryResults(Model): + """A query response. + + Contains the tables, columns & rows resulting from a query. + + All required parameters must be populated in order to send to Azure. + + :param tables: Required. The list of tables, columns and rows. + :type tables: list[~azure.applicationinsights.query.models.Table] + """ + + _validation = { + 'tables': {'required': True}, + } + + _attribute_map = { + 'tables': {'key': 'tables', 'type': '[Table]'}, + } + + def __init__(self, **kwargs): + super(QueryResults, self).__init__(**kwargs) + self.tables = kwargs.get('tables', None) diff --git a/azure-applicationinsights-query/models/query_results_py3.py b/azure-applicationinsights-query/models/query_results_py3.py new file mode 100644 index 000000000000..eb60942e72d9 --- /dev/null +++ b/azure-applicationinsights-query/models/query_results_py3.py @@ -0,0 +1,36 @@ +# coding=utf-8 +# -------------------------------------------------------------------------- +# Copyright (c) Microsoft Corporation. All rights reserved. +# Licensed under the MIT License. See License.txt in the project root for +# license information. +# +# Code generated by Microsoft (R) AutoRest Code Generator. +# Changes may cause incorrect behavior and will be lost if the code is +# regenerated. +# -------------------------------------------------------------------------- + +from msrest.serialization import Model + + +class QueryResults(Model): + """A query response. + + Contains the tables, columns & rows resulting from a query. + + All required parameters must be populated in order to send to Azure. + + :param tables: Required. The list of tables, columns and rows. + :type tables: list[~azure.applicationinsights.query.models.Table] + """ + + _validation = { + 'tables': {'required': True}, + } + + _attribute_map = { + 'tables': {'key': 'tables', 'type': '[Table]'}, + } + + def __init__(self, *, tables, **kwargs) -> None: + super(QueryResults, self).__init__(**kwargs) + self.tables = tables diff --git a/azure-applicationinsights-query/models/table.py b/azure-applicationinsights-query/models/table.py new file mode 100644 index 000000000000..8dfb68e9a880 --- /dev/null +++ b/azure-applicationinsights-query/models/table.py @@ -0,0 +1,46 @@ +# coding=utf-8 +# -------------------------------------------------------------------------- +# Copyright (c) Microsoft Corporation. All rights reserved. +# Licensed under the MIT License. See License.txt in the project root for +# license information. +# +# Code generated by Microsoft (R) AutoRest Code Generator. +# Changes may cause incorrect behavior and will be lost if the code is +# regenerated. +# -------------------------------------------------------------------------- + +from msrest.serialization import Model + + +class Table(Model): + """A query response table. + + Contains the columns and rows for one table in a query response. + + All required parameters must be populated in order to send to Azure. + + :param name: Required. The name of the table. + :type name: str + :param columns: Required. The list of columns in this table. + :type columns: list[~azure.applicationinsights.query.models.Column] + :param rows: Required. The resulting rows from this query. + :type rows: list[list[object]] + """ + + _validation = { + 'name': {'required': True}, + 'columns': {'required': True}, + 'rows': {'required': True}, + } + + _attribute_map = { + 'name': {'key': 'name', 'type': 'str'}, + 'columns': {'key': 'columns', 'type': '[Column]'}, + 'rows': {'key': 'rows', 'type': '[[object]]'}, + } + + def __init__(self, **kwargs): + super(Table, self).__init__(**kwargs) + self.name = kwargs.get('name', None) + self.columns = kwargs.get('columns', None) + self.rows = kwargs.get('rows', None) diff --git a/azure-applicationinsights-query/models/table_py3.py b/azure-applicationinsights-query/models/table_py3.py new file mode 100644 index 000000000000..d829ede6f2b1 --- /dev/null +++ b/azure-applicationinsights-query/models/table_py3.py @@ -0,0 +1,46 @@ +# coding=utf-8 +# -------------------------------------------------------------------------- +# Copyright (c) Microsoft Corporation. All rights reserved. +# Licensed under the MIT License. See License.txt in the project root for +# license information. +# +# Code generated by Microsoft (R) AutoRest Code Generator. +# Changes may cause incorrect behavior and will be lost if the code is +# regenerated. +# -------------------------------------------------------------------------- + +from msrest.serialization import Model + + +class Table(Model): + """A query response table. + + Contains the columns and rows for one table in a query response. + + All required parameters must be populated in order to send to Azure. + + :param name: Required. The name of the table. + :type name: str + :param columns: Required. The list of columns in this table. + :type columns: list[~azure.applicationinsights.query.models.Column] + :param rows: Required. The resulting rows from this query. + :type rows: list[list[object]] + """ + + _validation = { + 'name': {'required': True}, + 'columns': {'required': True}, + 'rows': {'required': True}, + } + + _attribute_map = { + 'name': {'key': 'name', 'type': 'str'}, + 'columns': {'key': 'columns', 'type': '[Column]'}, + 'rows': {'key': 'rows', 'type': '[[object]]'}, + } + + def __init__(self, *, name: str, columns, rows, **kwargs) -> None: + super(Table, self).__init__(**kwargs) + self.name = name + self.columns = columns + self.rows = rows diff --git a/azure-applicationinsights-query/operations/__init__.py b/azure-applicationinsights-query/operations/__init__.py new file mode 100644 index 000000000000..f7125d05cb08 --- /dev/null +++ b/azure-applicationinsights-query/operations/__init__.py @@ -0,0 +1,20 @@ +# coding=utf-8 +# -------------------------------------------------------------------------- +# Copyright (c) Microsoft Corporation. All rights reserved. +# Licensed under the MIT License. See License.txt in the project root for +# license information. +# +# Code generated by Microsoft (R) AutoRest Code Generator. +# Changes may cause incorrect behavior and will be lost if the code is +# regenerated. +# -------------------------------------------------------------------------- + +from .metrics_operations import MetricsOperations +from .events_operations import EventsOperations +from .query_operations import QueryOperations + +__all__ = [ + 'MetricsOperations', + 'EventsOperations', + 'QueryOperations', +] diff --git a/azure-applicationinsights-query/operations/events_operations.py b/azure-applicationinsights-query/operations/events_operations.py new file mode 100644 index 000000000000..a4e9050e661d --- /dev/null +++ b/azure-applicationinsights-query/operations/events_operations.py @@ -0,0 +1,273 @@ +# coding=utf-8 +# -------------------------------------------------------------------------- +# Copyright (c) Microsoft Corporation. All rights reserved. +# Licensed under the MIT License. See License.txt in the project root for +# license information. +# +# Code generated by Microsoft (R) AutoRest Code Generator. +# Changes may cause incorrect behavior and will be lost if the code is +# regenerated. +# -------------------------------------------------------------------------- + +from msrest.pipeline import ClientRawResponse + +from .. import models + + +class EventsOperations(object): + """EventsOperations operations. + + :param client: Client for service requests. + :param config: Configuration of service client. + :param serializer: An object model serializer. + :param deserializer: An object model deserializer. + """ + + models = models + + def __init__(self, client, config, serializer, deserializer): + + self._client = client + self._serialize = serializer + self._deserialize = deserializer + + self.config = config + + def get_by_type( + self, app_id, event_type, timespan=None, filter=None, search=None, orderby=None, select=None, skip=None, top=None, format=None, count=None, apply=None, custom_headers=None, raw=False, **operation_config): + """Execute OData query. + + Executes an OData query for events. + + :param app_id: ID of the application. This is Application ID from the + API Access settings blade in the Azure portal. + :type app_id: str + :param event_type: The type of events to query; either a standard + event type (`traces`, `customEvents`, `pageViews`, `requests`, + `dependencies`, `exceptions`, `availabilityResults`) or `$all` to + query across all event types. Possible values include: '$all', + 'traces', 'customEvents', 'pageViews', 'browserTimings', 'requests', + 'dependencies', 'exceptions', 'availabilityResults', + 'performanceCounters', 'customMetrics' + :type event_type: str or + ~azure.applicationinsights.query.models.EventType + :param timespan: Optional. The timespan over which to retrieve events. + This is an ISO8601 time period value. This timespan is applied in + addition to any that are specified in the Odata expression. + :type timespan: str + :param filter: An expression used to filter the returned events + :type filter: str + :param search: A free-text search expression to match for whether a + particular event should be returned + :type search: str + :param orderby: A comma-separated list of properties with \\"asc\\" + (the default) or \\"desc\\" to control the order of returned events + :type orderby: str + :param select: Limits the properties to just those requested on each + returned event + :type select: str + :param skip: The number of items to skip over before returning events + :type skip: int + :param top: The number of events to return + :type top: int + :param format: Format for the returned events + :type format: str + :param count: Request a count of matching items included with the + returned events + :type count: bool + :param apply: An expression used for aggregation over returned events + :type apply: str + :param dict custom_headers: headers that will be added to the request + :param bool raw: returns the direct response alongside the + deserialized response + :param operation_config: :ref:`Operation configuration + overrides`. + :return: EventsResults or ClientRawResponse if raw=true + :rtype: ~azure.applicationinsights.query.models.EventsResults or + ~msrest.pipeline.ClientRawResponse + :raises: + :class:`ErrorResponseException` + """ + # Construct URL + url = self.get_by_type.metadata['url'] + path_format_arguments = { + 'appId': self._serialize.url("app_id", app_id, 'str'), + 'eventType': self._serialize.url("event_type", event_type, 'str') + } + url = self._client.format_url(url, **path_format_arguments) + + # Construct parameters + query_parameters = {} + if timespan is not None: + query_parameters['timespan'] = self._serialize.query("timespan", timespan, 'str') + if filter is not None: + query_parameters['$filter'] = self._serialize.query("filter", filter, 'str') + if search is not None: + query_parameters['$search'] = self._serialize.query("search", search, 'str') + if orderby is not None: + query_parameters['$orderby'] = self._serialize.query("orderby", orderby, 'str') + if select is not None: + query_parameters['$select'] = self._serialize.query("select", select, 'str') + if skip is not None: + query_parameters['$skip'] = self._serialize.query("skip", skip, 'int') + if top is not None: + query_parameters['$top'] = self._serialize.query("top", top, 'int') + if format is not None: + query_parameters['$format'] = self._serialize.query("format", format, 'str') + if count is not None: + query_parameters['$count'] = self._serialize.query("count", count, 'bool') + if apply is not None: + query_parameters['$apply'] = self._serialize.query("apply", apply, 'str') + + # Construct headers + header_parameters = {} + header_parameters['Accept'] = 'application/json' + if custom_headers: + header_parameters.update(custom_headers) + + # Construct and send request + request = self._client.get(url, query_parameters, header_parameters) + response = self._client.send(request, stream=False, **operation_config) + + if response.status_code not in [200]: + raise models.ErrorResponseException(self._deserialize, response) + + deserialized = None + + if response.status_code == 200: + deserialized = self._deserialize('EventsResults', response) + + if raw: + client_raw_response = ClientRawResponse(deserialized, response) + return client_raw_response + + return deserialized + get_by_type.metadata = {'url': '/apps/{appId}/events/{eventType}'} + + def get( + self, app_id, event_type, event_id, timespan=None, custom_headers=None, raw=False, **operation_config): + """Get an event. + + Gets the data for a single event. + + :param app_id: ID of the application. This is Application ID from the + API Access settings blade in the Azure portal. + :type app_id: str + :param event_type: The type of events to query; either a standard + event type (`traces`, `customEvents`, `pageViews`, `requests`, + `dependencies`, `exceptions`, `availabilityResults`) or `$all` to + query across all event types. Possible values include: '$all', + 'traces', 'customEvents', 'pageViews', 'browserTimings', 'requests', + 'dependencies', 'exceptions', 'availabilityResults', + 'performanceCounters', 'customMetrics' + :type event_type: str or + ~azure.applicationinsights.query.models.EventType + :param event_id: ID of event. + :type event_id: str + :param timespan: Optional. The timespan over which to retrieve events. + This is an ISO8601 time period value. This timespan is applied in + addition to any that are specified in the Odata expression. + :type timespan: str + :param dict custom_headers: headers that will be added to the request + :param bool raw: returns the direct response alongside the + deserialized response + :param operation_config: :ref:`Operation configuration + overrides`. + :return: EventsResults or ClientRawResponse if raw=true + :rtype: ~azure.applicationinsights.query.models.EventsResults or + ~msrest.pipeline.ClientRawResponse + :raises: + :class:`ErrorResponseException` + """ + # Construct URL + url = self.get.metadata['url'] + path_format_arguments = { + 'appId': self._serialize.url("app_id", app_id, 'str'), + 'eventType': self._serialize.url("event_type", event_type, 'str'), + 'eventId': self._serialize.url("event_id", event_id, 'str') + } + url = self._client.format_url(url, **path_format_arguments) + + # Construct parameters + query_parameters = {} + if timespan is not None: + query_parameters['timespan'] = self._serialize.query("timespan", timespan, 'str') + + # Construct headers + header_parameters = {} + header_parameters['Accept'] = 'application/json' + if custom_headers: + header_parameters.update(custom_headers) + + # Construct and send request + request = self._client.get(url, query_parameters, header_parameters) + response = self._client.send(request, stream=False, **operation_config) + + if response.status_code not in [200]: + raise models.ErrorResponseException(self._deserialize, response) + + deserialized = None + + if response.status_code == 200: + deserialized = self._deserialize('EventsResults', response) + + if raw: + client_raw_response = ClientRawResponse(deserialized, response) + return client_raw_response + + return deserialized + get.metadata = {'url': '/apps/{appId}/events/{eventType}/{eventId}'} + + def get_odata_metadata( + self, app_id, custom_headers=None, raw=False, **operation_config): + """Get OData metadata. + + Gets OData EDMX metadata describing the event data model. + + :param app_id: ID of the application. This is Application ID from the + API Access settings blade in the Azure portal. + :type app_id: str + :param dict custom_headers: headers that will be added to the request + :param bool raw: returns the direct response alongside the + deserialized response + :param operation_config: :ref:`Operation configuration + overrides`. + :return: object or ClientRawResponse if raw=true + :rtype: object or ~msrest.pipeline.ClientRawResponse + :raises: + :class:`ErrorResponseException` + """ + # Construct URL + url = self.get_odata_metadata.metadata['url'] + path_format_arguments = { + 'appId': self._serialize.url("app_id", app_id, 'str') + } + url = self._client.format_url(url, **path_format_arguments) + + # Construct parameters + query_parameters = {} + + # Construct headers + header_parameters = {} + header_parameters['Accept'] = 'application/xml;charset=utf-8' + if custom_headers: + header_parameters.update(custom_headers) + + # Construct and send request + request = self._client.get(url, query_parameters, header_parameters) + response = self._client.send(request, stream=False, **operation_config) + + if response.status_code not in [200]: + raise models.ErrorResponseException(self._deserialize, response) + + deserialized = None + + if response.status_code == 200: + deserialized = self._deserialize('object', response) + + if raw: + client_raw_response = ClientRawResponse(deserialized, response) + return client_raw_response + + return deserialized + get_odata_metadata.metadata = {'url': '/apps/{appId}/events/$metadata'} diff --git a/azure-applicationinsights-query/operations/metrics_operations.py b/azure-applicationinsights-query/operations/metrics_operations.py new file mode 100644 index 000000000000..79eecf0a68fa --- /dev/null +++ b/azure-applicationinsights-query/operations/metrics_operations.py @@ -0,0 +1,282 @@ +# coding=utf-8 +# -------------------------------------------------------------------------- +# Copyright (c) Microsoft Corporation. All rights reserved. +# Licensed under the MIT License. See License.txt in the project root for +# license information. +# +# Code generated by Microsoft (R) AutoRest Code Generator. +# Changes may cause incorrect behavior and will be lost if the code is +# regenerated. +# -------------------------------------------------------------------------- + +from msrest.pipeline import ClientRawResponse + +from .. import models + + +class MetricsOperations(object): + """MetricsOperations operations. + + :param client: Client for service requests. + :param config: Configuration of service client. + :param serializer: An object model serializer. + :param deserializer: An object model deserializer. + """ + + models = models + + def __init__(self, client, config, serializer, deserializer): + + self._client = client + self._serialize = serializer + self._deserialize = deserializer + + self.config = config + + def get( + self, app_id, metric_id, timespan=None, interval=None, aggregation=None, segment=None, top=None, orderby=None, filter=None, custom_headers=None, raw=False, **operation_config): + """Retrieve metric data. + + Gets metric values for a single metric. + + :param app_id: ID of the application. This is Application ID from the + API Access settings blade in the Azure portal. + :type app_id: str + :param metric_id: ID of the metric. This is either a standard AI + metric, or an application-specific custom metric. Possible values + include: 'requests/count', 'requests/duration', 'requests/failed', + 'users/count', 'users/authenticated', 'pageViews/count', + 'pageViews/duration', 'client/processingDuration', + 'client/receiveDuration', 'client/networkDuration', + 'client/sendDuration', 'client/totalDuration', 'dependencies/count', + 'dependencies/failed', 'dependencies/duration', 'exceptions/count', + 'exceptions/browser', 'exceptions/server', 'sessions/count', + 'performanceCounters/requestExecutionTime', + 'performanceCounters/requestsPerSecond', + 'performanceCounters/requestsInQueue', + 'performanceCounters/memoryAvailableBytes', + 'performanceCounters/exceptionsPerSecond', + 'performanceCounters/processCpuPercentage', + 'performanceCounters/processIOBytesPerSecond', + 'performanceCounters/processPrivateBytes', + 'performanceCounters/processorCpuPercentage', + 'availabilityResults/availabilityPercentage', + 'availabilityResults/duration', 'billing/telemetryCount', + 'customEvents/count' + :type metric_id: str or + ~azure.applicationinsights.query.models.MetricId + :param timespan: The timespan over which to retrieve metric values. + This is an ISO8601 time period value. If timespan is omitted, a + default time range of `PT12H` ("last 12 hours") is used. The actual + timespan that is queried may be adjusted by the server based. In all + cases, the actual time span used for the query is included in the + response. + :type timespan: str + :param interval: The time interval to use when retrieving metric + values. This is an ISO8601 duration. If interval is omitted, the + metric value is aggregated across the entire timespan. If interval is + supplied, the server may adjust the interval to a more appropriate + size based on the timespan used for the query. In all cases, the + actual interval used for the query is included in the response. + :type interval: timedelta + :param aggregation: The aggregation to use when computing the metric + values. To retrieve more than one aggregation at a time, separate them + with a comma. If no aggregation is specified, then the default + aggregation for the metric is used. + :type aggregation: list[str or + ~azure.applicationinsights.query.models.MetricsAggregation] + :param segment: The name of the dimension to segment the metric values + by. This dimension must be applicable to the metric you are + retrieving. To segment by more than one dimension at a time, separate + them with a comma (,). In this case, the metric data will be segmented + in the order the dimensions are listed in the parameter. + :type segment: list[str or + ~azure.applicationinsights.query.models.MetricsSegment] + :param top: The number of segments to return. This value is only + valid when segment is specified. + :type top: int + :param orderby: The aggregation function and direction to sort the + segments by. This value is only valid when segment is specified. + :type orderby: str + :param filter: An expression used to filter the results. This value + should be a valid OData filter expression where the keys of each + clause should be applicable dimensions for the metric you are + retrieving. + :type filter: str + :param dict custom_headers: headers that will be added to the request + :param bool raw: returns the direct response alongside the + deserialized response + :param operation_config: :ref:`Operation configuration + overrides`. + :return: MetricsResult or ClientRawResponse if raw=true + :rtype: ~azure.applicationinsights.query.models.MetricsResult or + ~msrest.pipeline.ClientRawResponse + :raises: + :class:`ErrorResponseException` + """ + # Construct URL + url = self.get.metadata['url'] + path_format_arguments = { + 'appId': self._serialize.url("app_id", app_id, 'str'), + 'metricId': self._serialize.url("metric_id", metric_id, 'str') + } + url = self._client.format_url(url, **path_format_arguments) + + # Construct parameters + query_parameters = {} + if timespan is not None: + query_parameters['timespan'] = self._serialize.query("timespan", timespan, 'str') + if interval is not None: + query_parameters['interval'] = self._serialize.query("interval", interval, 'duration') + if aggregation is not None: + query_parameters['aggregation'] = self._serialize.query("aggregation", aggregation, '[str]', div=',', min_items=1) + if segment is not None: + query_parameters['segment'] = self._serialize.query("segment", segment, '[str]', div=',', min_items=1) + if top is not None: + query_parameters['top'] = self._serialize.query("top", top, 'int') + if orderby is not None: + query_parameters['orderby'] = self._serialize.query("orderby", orderby, 'str') + if filter is not None: + query_parameters['filter'] = self._serialize.query("filter", filter, 'str') + + # Construct headers + header_parameters = {} + header_parameters['Accept'] = 'application/json' + if custom_headers: + header_parameters.update(custom_headers) + + # Construct and send request + request = self._client.get(url, query_parameters, header_parameters) + response = self._client.send(request, stream=False, **operation_config) + + if response.status_code not in [200]: + raise models.ErrorResponseException(self._deserialize, response) + + deserialized = None + + if response.status_code == 200: + deserialized = self._deserialize('MetricsResult', response) + + if raw: + client_raw_response = ClientRawResponse(deserialized, response) + return client_raw_response + + return deserialized + get.metadata = {'url': '/apps/{appId}/metrics/{metricId}'} + + def get_multiple( + self, app_id, body, custom_headers=None, raw=False, **operation_config): + """Retrieve metric data. + + Gets metric values for multiple metrics. + + :param app_id: ID of the application. This is Application ID from the + API Access settings blade in the Azure portal. + :type app_id: str + :param body: The batched metrics query. + :type body: + list[~azure.applicationinsights.query.models.MetricsPostBodySchema] + :param dict custom_headers: headers that will be added to the request + :param bool raw: returns the direct response alongside the + deserialized response + :param operation_config: :ref:`Operation configuration + overrides`. + :return: list or ClientRawResponse if raw=true + :rtype: + list[~azure.applicationinsights.query.models.MetricsResultsItem] or + ~msrest.pipeline.ClientRawResponse + :raises: + :class:`ErrorResponseException` + """ + # Construct URL + url = self.get_multiple.metadata['url'] + path_format_arguments = { + 'appId': self._serialize.url("app_id", app_id, 'str') + } + url = self._client.format_url(url, **path_format_arguments) + + # Construct parameters + query_parameters = {} + + # Construct headers + header_parameters = {} + header_parameters['Accept'] = 'application/json' + header_parameters['Content-Type'] = 'application/json; charset=utf-8' + if custom_headers: + header_parameters.update(custom_headers) + + # Construct body + body_content = self._serialize.body(body, '[MetricsPostBodySchema]') + + # Construct and send request + request = self._client.post(url, query_parameters, header_parameters, body_content) + response = self._client.send(request, stream=False, **operation_config) + + if response.status_code not in [200]: + raise models.ErrorResponseException(self._deserialize, response) + + deserialized = None + + if response.status_code == 200: + deserialized = self._deserialize('[MetricsResultsItem]', response) + + if raw: + client_raw_response = ClientRawResponse(deserialized, response) + return client_raw_response + + return deserialized + get_multiple.metadata = {'url': '/apps/{appId}/metrics'} + + def get_metadata( + self, app_id, custom_headers=None, raw=False, **operation_config): + """Retrieve metric metatadata. + + Gets metadata describing the available metrics. + + :param app_id: ID of the application. This is Application ID from the + API Access settings blade in the Azure portal. + :type app_id: str + :param dict custom_headers: headers that will be added to the request + :param bool raw: returns the direct response alongside the + deserialized response + :param operation_config: :ref:`Operation configuration + overrides`. + :return: object or ClientRawResponse if raw=true + :rtype: object or ~msrest.pipeline.ClientRawResponse + :raises: + :class:`ErrorResponseException` + """ + # Construct URL + url = self.get_metadata.metadata['url'] + path_format_arguments = { + 'appId': self._serialize.url("app_id", app_id, 'str') + } + url = self._client.format_url(url, **path_format_arguments) + + # Construct parameters + query_parameters = {} + + # Construct headers + header_parameters = {} + header_parameters['Accept'] = 'application/json' + if custom_headers: + header_parameters.update(custom_headers) + + # Construct and send request + request = self._client.get(url, query_parameters, header_parameters) + response = self._client.send(request, stream=False, **operation_config) + + if response.status_code not in [200]: + raise models.ErrorResponseException(self._deserialize, response) + + deserialized = None + + if response.status_code == 200: + deserialized = self._deserialize('object', response) + + if raw: + client_raw_response = ClientRawResponse(deserialized, response) + return client_raw_response + + return deserialized + get_metadata.metadata = {'url': '/apps/{appId}/metrics/metadata'} diff --git a/azure-applicationinsights-query/operations/query_operations.py b/azure-applicationinsights-query/operations/query_operations.py new file mode 100644 index 000000000000..7250d777b407 --- /dev/null +++ b/azure-applicationinsights-query/operations/query_operations.py @@ -0,0 +1,99 @@ +# coding=utf-8 +# -------------------------------------------------------------------------- +# Copyright (c) Microsoft Corporation. All rights reserved. +# Licensed under the MIT License. See License.txt in the project root for +# license information. +# +# Code generated by Microsoft (R) AutoRest Code Generator. +# Changes may cause incorrect behavior and will be lost if the code is +# regenerated. +# -------------------------------------------------------------------------- + +from msrest.pipeline import ClientRawResponse + +from .. import models + + +class QueryOperations(object): + """QueryOperations operations. + + :param client: Client for service requests. + :param config: Configuration of service client. + :param serializer: An object model serializer. + :param deserializer: An object model deserializer. + """ + + models = models + + def __init__(self, client, config, serializer, deserializer): + + self._client = client + self._serialize = serializer + self._deserialize = deserializer + + self.config = config + + def execute( + self, app_id, body, custom_headers=None, raw=False, **operation_config): + """Execute an Analytics query. + + Executes an Analytics query for data. + [Here](https://dev.applicationinsights.io/documentation/Using-the-API/Query) + is an example for using POST with an Analytics query. + + :param app_id: ID of the application. This is Application ID from the + API Access settings blade in the Azure portal. + :type app_id: str + :param body: The Analytics query. Learn more about the [Analytics + query + syntax](https://azure.microsoft.com/documentation/articles/app-insights-analytics-reference/) + :type body: ~azure.applicationinsights.query.models.QueryBody + :param dict custom_headers: headers that will be added to the request + :param bool raw: returns the direct response alongside the + deserialized response + :param operation_config: :ref:`Operation configuration + overrides`. + :return: QueryResults or ClientRawResponse if raw=true + :rtype: ~azure.applicationinsights.query.models.QueryResults or + ~msrest.pipeline.ClientRawResponse + :raises: + :class:`ErrorResponseException` + """ + # Construct URL + url = self.execute.metadata['url'] + path_format_arguments = { + 'appId': self._serialize.url("app_id", app_id, 'str') + } + url = self._client.format_url(url, **path_format_arguments) + + # Construct parameters + query_parameters = {} + + # Construct headers + header_parameters = {} + header_parameters['Accept'] = 'application/json' + header_parameters['Content-Type'] = 'application/json; charset=utf-8' + if custom_headers: + header_parameters.update(custom_headers) + + # Construct body + body_content = self._serialize.body(body, 'QueryBody') + + # Construct and send request + request = self._client.post(url, query_parameters, header_parameters, body_content) + response = self._client.send(request, stream=False, **operation_config) + + if response.status_code not in [200]: + raise models.ErrorResponseException(self._deserialize, response) + + deserialized = None + + if response.status_code == 200: + deserialized = self._deserialize('QueryResults', response) + + if raw: + client_raw_response = ClientRawResponse(deserialized, response) + return client_raw_response + + return deserialized + execute.metadata = {'url': '/apps/{appId}/query'} diff --git a/azure-applicationinsights-query/sdk_packaging.toml b/azure-applicationinsights-query/sdk_packaging.toml new file mode 100644 index 000000000000..c681bde7b197 --- /dev/null +++ b/azure-applicationinsights-query/sdk_packaging.toml @@ -0,0 +1,7 @@ +[packaging] +package_name = "azure-applicationinsights-query" +package_nspkg = "azure-applicationinsights-nspkg" +package_pprint_name = "MyService Management" +package_doc_id = "" +is_stable = false +is_arm = true diff --git a/azure-applicationinsights-query/setup.cfg b/azure-applicationinsights-query/setup.cfg new file mode 100644 index 000000000000..3c6e79cf31da --- /dev/null +++ b/azure-applicationinsights-query/setup.cfg @@ -0,0 +1,2 @@ +[bdist_wheel] +universal=1 diff --git a/azure-applicationinsights-query/setup.py b/azure-applicationinsights-query/setup.py new file mode 100644 index 000000000000..83f8cc3c79f6 --- /dev/null +++ b/azure-applicationinsights-query/setup.py @@ -0,0 +1,87 @@ +#!/usr/bin/env python + +#------------------------------------------------------------------------- +# Copyright (c) Microsoft Corporation. All rights reserved. +# Licensed under the MIT License. See License.txt in the project root for +# license information. +#-------------------------------------------------------------------------- + +import re +import os.path +from io import open +from setuptools import find_packages, setup + +# Change the PACKAGE_NAME only to change folder and different name +PACKAGE_NAME = "azure-applicationinsights-query" +PACKAGE_PPRINT_NAME = "MyService Management" + +# a-b-c => a/b/c +package_folder_path = PACKAGE_NAME.replace('-', '/') +# a-b-c => a.b.c +namespace_name = PACKAGE_NAME.replace('-', '.') + +# azure v0.x is not compatible with this package +# azure v0.x used to have a __version__ attribute (newer versions don't) +try: + import azure + try: + ver = azure.__version__ + raise Exception( + 'This package is incompatible with azure=={}. '.format(ver) + + 'Uninstall it with "pip uninstall azure".' + ) + except AttributeError: + pass +except ImportError: + pass + +# Version extraction inspired from 'requests' +with open(os.path.join(package_folder_path, 'version.py'), 'r') as fd: + version = re.search(r'^VERSION\s*=\s*[\'"]([^\'"]*)[\'"]', + fd.read(), re.MULTILINE).group(1) + +if not version: + raise RuntimeError('Cannot find version information') + +with open('README.rst', encoding='utf-8') as f: + readme = f.read() +with open('HISTORY.rst', encoding='utf-8') as f: + history = f.read() + +setup( + name=PACKAGE_NAME, + version=version, + description='Microsoft Azure {} Client Library for Python'.format(PACKAGE_PPRINT_NAME), + long_description=readme + '\n\n' + history, + license='MIT License', + author='Microsoft Corporation', + author_email='azpysdkhelp@microsoft.com', + url='https://github.com/Azure/azure-sdk-for-python', + classifiers=[ + 'Development Status :: 4 - Beta', + 'Programming Language :: Python', + 'Programming Language :: Python :: 2', + 'Programming Language :: Python :: 2.7', + 'Programming Language :: Python :: 3', + 'Programming Language :: Python :: 3.4', + 'Programming Language :: Python :: 3.5', + 'Programming Language :: Python :: 3.6', + 'Programming Language :: Python :: 3.7', + 'License :: OSI Approved :: MIT License', + ], + zip_safe=False, + packages=find_packages(exclude=[ + 'tests', + # Exclude packages that will be covered by PEP420 or nspkg + 'azure', + 'azure.applicationinsights', + ]), + install_requires=[ + 'msrest>=0.5.0', + 'msrestazure>=0.4.32,<2.0.0', + 'azure-common~=1.1', + ], + extras_require={ + ":python_version<'3.0'": ['azure-applicationinsights-nspkg'], + } +) diff --git a/azure-applicationinsights-query/version.py b/azure-applicationinsights-query/version.py new file mode 100644 index 000000000000..e0ec669828cb --- /dev/null +++ b/azure-applicationinsights-query/version.py @@ -0,0 +1,13 @@ +# coding=utf-8 +# -------------------------------------------------------------------------- +# Copyright (c) Microsoft Corporation. All rights reserved. +# Licensed under the MIT License. See License.txt in the project root for +# license information. +# +# Code generated by Microsoft (R) AutoRest Code Generator. +# Changes may cause incorrect behavior and will be lost if the code is +# regenerated. +# -------------------------------------------------------------------------- + +VERSION = "0.1.0" + diff --git a/azure-applicationinsights/MANIFEST.in b/azure-applicationinsights/MANIFEST.in index bb37a2723dae..74c0ac7e42a1 100644 --- a/azure-applicationinsights/MANIFEST.in +++ b/azure-applicationinsights/MANIFEST.in @@ -1 +1,4 @@ +recursive-include tests *.py *.yaml include *.rst +include azure/__init__.py + diff --git a/azure-applicationinsights/README.rst b/azure-applicationinsights/README.rst index 01181cde9839..ccee0eb01be0 100644 --- a/azure-applicationinsights/README.rst +++ b/azure-applicationinsights/README.rst @@ -14,25 +14,6 @@ For the older Azure Service Management (ASM) libraries, see For a more complete set of Azure libraries, see the `azure `__ bundle package. -Compatibility -============= - -**IMPORTANT**: If you have an earlier version of the azure package -(version < 1.0), you should uninstall it before installing this package. - -You can check the version using pip: - -.. code:: shell - - pip freeze - -If you see azure==0.11.0 (or any version below 1.0), uninstall it first: - -.. code:: shell - - pip uninstall azure - - Usage ===== diff --git a/azure-applicationinsights/azure/applicationinsights/application_insights_data_client.py b/azure-applicationinsights/azure/applicationinsights/application_insights_data_client.py index 83328895f60f..27c449d23c94 100644 --- a/azure-applicationinsights/azure/applicationinsights/application_insights_data_client.py +++ b/azure-applicationinsights/azure/applicationinsights/application_insights_data_client.py @@ -39,7 +39,7 @@ def __init__( super(ApplicationInsightsDataClientConfiguration, self).__init__(base_url) - self.add_user_agent('azure-applicationinsights/{}'.format(VERSION)) + self.add_user_agent('azure-applicationinsights-query/{}'.format(VERSION)) self.credentials = credentials @@ -51,11 +51,11 @@ class ApplicationInsightsDataClient(SDKClient): :vartype config: ApplicationInsightsDataClientConfiguration :ivar metrics: Metrics operations - :vartype metrics: azure.applicationinsights.operations.MetricsOperations + :vartype metrics: azure.applicationinsights.query.operations.MetricsOperations :ivar events: Events operations - :vartype events: azure.applicationinsights.operations.EventsOperations + :vartype events: azure.applicationinsights.query.operations.EventsOperations :ivar query: Query operations - :vartype query: azure.applicationinsights.operations.QueryOperations + :vartype query: azure.applicationinsights.query.operations.QueryOperations :param credentials: Subscription credentials which uniquely identify client subscription. diff --git a/azure-applicationinsights/azure/applicationinsights/models/error_info.py b/azure-applicationinsights/azure/applicationinsights/models/error_info.py index 4e6ef3ba78fc..14f34f097774 100644 --- a/azure-applicationinsights/azure/applicationinsights/models/error_info.py +++ b/azure-applicationinsights/azure/applicationinsights/models/error_info.py @@ -22,9 +22,9 @@ class ErrorInfo(Model): :param message: Required. A human readable error message. :type message: str :param details: error details. - :type details: list[~azure.applicationinsights.models.ErrorDetail] + :type details: list[~azure.applicationinsights.query.models.ErrorDetail] :param innererror: Inner error details if they exist. - :type innererror: ~azure.applicationinsights.models.ErrorInfo + :type innererror: ~azure.applicationinsights.query.models.ErrorInfo :param additional_properties: :type additional_properties: object """ diff --git a/azure-applicationinsights/azure/applicationinsights/models/error_info_py3.py b/azure-applicationinsights/azure/applicationinsights/models/error_info_py3.py index ff3307147518..8d01ca19f1b8 100644 --- a/azure-applicationinsights/azure/applicationinsights/models/error_info_py3.py +++ b/azure-applicationinsights/azure/applicationinsights/models/error_info_py3.py @@ -22,9 +22,9 @@ class ErrorInfo(Model): :param message: Required. A human readable error message. :type message: str :param details: error details. - :type details: list[~azure.applicationinsights.models.ErrorDetail] + :type details: list[~azure.applicationinsights.query.models.ErrorDetail] :param innererror: Inner error details if they exist. - :type innererror: ~azure.applicationinsights.models.ErrorInfo + :type innererror: ~azure.applicationinsights.query.models.ErrorInfo :param additional_properties: :type additional_properties: object """ diff --git a/azure-applicationinsights/azure/applicationinsights/models/error_response.py b/azure-applicationinsights/azure/applicationinsights/models/error_response.py index 5a1e0b618bbe..4461869de892 100644 --- a/azure-applicationinsights/azure/applicationinsights/models/error_response.py +++ b/azure-applicationinsights/azure/applicationinsights/models/error_response.py @@ -21,7 +21,7 @@ class ErrorResponse(Model): All required parameters must be populated in order to send to Azure. :param error: Required. The error details. - :type error: ~azure.applicationinsights.models.ErrorInfo + :type error: ~azure.applicationinsights.query.models.ErrorInfo """ _validation = { diff --git a/azure-applicationinsights/azure/applicationinsights/models/error_response_py3.py b/azure-applicationinsights/azure/applicationinsights/models/error_response_py3.py index f239ac315377..af501a2f5965 100644 --- a/azure-applicationinsights/azure/applicationinsights/models/error_response_py3.py +++ b/azure-applicationinsights/azure/applicationinsights/models/error_response_py3.py @@ -21,7 +21,7 @@ class ErrorResponse(Model): All required parameters must be populated in order to send to Azure. :param error: Required. The error details. - :type error: ~azure.applicationinsights.models.ErrorInfo + :type error: ~azure.applicationinsights.query.models.ErrorInfo """ _validation = { diff --git a/azure-applicationinsights/azure/applicationinsights/models/events_availability_result_result.py b/azure-applicationinsights/azure/applicationinsights/models/events_availability_result_result.py index ab85901d2211..729504b268e8 100644 --- a/azure-applicationinsights/azure/applicationinsights/models/events_availability_result_result.py +++ b/azure-applicationinsights/azure/applicationinsights/models/events_availability_result_result.py @@ -25,29 +25,31 @@ class EventsAvailabilityResultResult(EventsResultData): :type timestamp: datetime :param custom_dimensions: Custom dimensions of the event :type custom_dimensions: - ~azure.applicationinsights.models.EventsResultDataCustomDimensions + ~azure.applicationinsights.query.models.EventsResultDataCustomDimensions :param custom_measurements: Custom measurements of the event :type custom_measurements: - ~azure.applicationinsights.models.EventsResultDataCustomMeasurements + ~azure.applicationinsights.query.models.EventsResultDataCustomMeasurements :param operation: Operation info of the event - :type operation: ~azure.applicationinsights.models.EventsOperationInfo + :type operation: + ~azure.applicationinsights.query.models.EventsOperationInfo :param session: Session info of the event - :type session: ~azure.applicationinsights.models.EventsSessionInfo + :type session: ~azure.applicationinsights.query.models.EventsSessionInfo :param user: User info of the event - :type user: ~azure.applicationinsights.models.EventsUserInfo + :type user: ~azure.applicationinsights.query.models.EventsUserInfo :param cloud: Cloud info of the event - :type cloud: ~azure.applicationinsights.models.EventsCloudInfo + :type cloud: ~azure.applicationinsights.query.models.EventsCloudInfo :param ai: AI info of the event - :type ai: ~azure.applicationinsights.models.EventsAiInfo + :type ai: ~azure.applicationinsights.query.models.EventsAiInfo :param application: Application info of the event - :type application: ~azure.applicationinsights.models.EventsApplicationInfo + :type application: + ~azure.applicationinsights.query.models.EventsApplicationInfo :param client: Client info of the event - :type client: ~azure.applicationinsights.models.EventsClientInfo + :type client: ~azure.applicationinsights.query.models.EventsClientInfo :param type: Required. Constant filled by server. :type type: str :param availability_result: :type availability_result: - ~azure.applicationinsights.models.EventsAvailabilityResultInfo + ~azure.applicationinsights.query.models.EventsAvailabilityResultInfo """ _validation = { diff --git a/azure-applicationinsights/azure/applicationinsights/models/events_availability_result_result_py3.py b/azure-applicationinsights/azure/applicationinsights/models/events_availability_result_result_py3.py index c1fd4fc00842..9a6da5a4488d 100644 --- a/azure-applicationinsights/azure/applicationinsights/models/events_availability_result_result_py3.py +++ b/azure-applicationinsights/azure/applicationinsights/models/events_availability_result_result_py3.py @@ -25,29 +25,31 @@ class EventsAvailabilityResultResult(EventsResultData): :type timestamp: datetime :param custom_dimensions: Custom dimensions of the event :type custom_dimensions: - ~azure.applicationinsights.models.EventsResultDataCustomDimensions + ~azure.applicationinsights.query.models.EventsResultDataCustomDimensions :param custom_measurements: Custom measurements of the event :type custom_measurements: - ~azure.applicationinsights.models.EventsResultDataCustomMeasurements + ~azure.applicationinsights.query.models.EventsResultDataCustomMeasurements :param operation: Operation info of the event - :type operation: ~azure.applicationinsights.models.EventsOperationInfo + :type operation: + ~azure.applicationinsights.query.models.EventsOperationInfo :param session: Session info of the event - :type session: ~azure.applicationinsights.models.EventsSessionInfo + :type session: ~azure.applicationinsights.query.models.EventsSessionInfo :param user: User info of the event - :type user: ~azure.applicationinsights.models.EventsUserInfo + :type user: ~azure.applicationinsights.query.models.EventsUserInfo :param cloud: Cloud info of the event - :type cloud: ~azure.applicationinsights.models.EventsCloudInfo + :type cloud: ~azure.applicationinsights.query.models.EventsCloudInfo :param ai: AI info of the event - :type ai: ~azure.applicationinsights.models.EventsAiInfo + :type ai: ~azure.applicationinsights.query.models.EventsAiInfo :param application: Application info of the event - :type application: ~azure.applicationinsights.models.EventsApplicationInfo + :type application: + ~azure.applicationinsights.query.models.EventsApplicationInfo :param client: Client info of the event - :type client: ~azure.applicationinsights.models.EventsClientInfo + :type client: ~azure.applicationinsights.query.models.EventsClientInfo :param type: Required. Constant filled by server. :type type: str :param availability_result: :type availability_result: - ~azure.applicationinsights.models.EventsAvailabilityResultInfo + ~azure.applicationinsights.query.models.EventsAvailabilityResultInfo """ _validation = { diff --git a/azure-applicationinsights/azure/applicationinsights/models/events_browser_timing_result.py b/azure-applicationinsights/azure/applicationinsights/models/events_browser_timing_result.py index d5183eb49d0e..15bada46f728 100644 --- a/azure-applicationinsights/azure/applicationinsights/models/events_browser_timing_result.py +++ b/azure-applicationinsights/azure/applicationinsights/models/events_browser_timing_result.py @@ -25,32 +25,34 @@ class EventsBrowserTimingResult(EventsResultData): :type timestamp: datetime :param custom_dimensions: Custom dimensions of the event :type custom_dimensions: - ~azure.applicationinsights.models.EventsResultDataCustomDimensions + ~azure.applicationinsights.query.models.EventsResultDataCustomDimensions :param custom_measurements: Custom measurements of the event :type custom_measurements: - ~azure.applicationinsights.models.EventsResultDataCustomMeasurements + ~azure.applicationinsights.query.models.EventsResultDataCustomMeasurements :param operation: Operation info of the event - :type operation: ~azure.applicationinsights.models.EventsOperationInfo + :type operation: + ~azure.applicationinsights.query.models.EventsOperationInfo :param session: Session info of the event - :type session: ~azure.applicationinsights.models.EventsSessionInfo + :type session: ~azure.applicationinsights.query.models.EventsSessionInfo :param user: User info of the event - :type user: ~azure.applicationinsights.models.EventsUserInfo + :type user: ~azure.applicationinsights.query.models.EventsUserInfo :param cloud: Cloud info of the event - :type cloud: ~azure.applicationinsights.models.EventsCloudInfo + :type cloud: ~azure.applicationinsights.query.models.EventsCloudInfo :param ai: AI info of the event - :type ai: ~azure.applicationinsights.models.EventsAiInfo + :type ai: ~azure.applicationinsights.query.models.EventsAiInfo :param application: Application info of the event - :type application: ~azure.applicationinsights.models.EventsApplicationInfo + :type application: + ~azure.applicationinsights.query.models.EventsApplicationInfo :param client: Client info of the event - :type client: ~azure.applicationinsights.models.EventsClientInfo + :type client: ~azure.applicationinsights.query.models.EventsClientInfo :param type: Required. Constant filled by server. :type type: str :param browser_timing: :type browser_timing: - ~azure.applicationinsights.models.EventsBrowserTimingInfo + ~azure.applicationinsights.query.models.EventsBrowserTimingInfo :param client_performance: :type client_performance: - ~azure.applicationinsights.models.EventsClientPerformanceInfo + ~azure.applicationinsights.query.models.EventsClientPerformanceInfo """ _validation = { diff --git a/azure-applicationinsights/azure/applicationinsights/models/events_browser_timing_result_py3.py b/azure-applicationinsights/azure/applicationinsights/models/events_browser_timing_result_py3.py index 0a65ce9632e2..9779c8903b85 100644 --- a/azure-applicationinsights/azure/applicationinsights/models/events_browser_timing_result_py3.py +++ b/azure-applicationinsights/azure/applicationinsights/models/events_browser_timing_result_py3.py @@ -25,32 +25,34 @@ class EventsBrowserTimingResult(EventsResultData): :type timestamp: datetime :param custom_dimensions: Custom dimensions of the event :type custom_dimensions: - ~azure.applicationinsights.models.EventsResultDataCustomDimensions + ~azure.applicationinsights.query.models.EventsResultDataCustomDimensions :param custom_measurements: Custom measurements of the event :type custom_measurements: - ~azure.applicationinsights.models.EventsResultDataCustomMeasurements + ~azure.applicationinsights.query.models.EventsResultDataCustomMeasurements :param operation: Operation info of the event - :type operation: ~azure.applicationinsights.models.EventsOperationInfo + :type operation: + ~azure.applicationinsights.query.models.EventsOperationInfo :param session: Session info of the event - :type session: ~azure.applicationinsights.models.EventsSessionInfo + :type session: ~azure.applicationinsights.query.models.EventsSessionInfo :param user: User info of the event - :type user: ~azure.applicationinsights.models.EventsUserInfo + :type user: ~azure.applicationinsights.query.models.EventsUserInfo :param cloud: Cloud info of the event - :type cloud: ~azure.applicationinsights.models.EventsCloudInfo + :type cloud: ~azure.applicationinsights.query.models.EventsCloudInfo :param ai: AI info of the event - :type ai: ~azure.applicationinsights.models.EventsAiInfo + :type ai: ~azure.applicationinsights.query.models.EventsAiInfo :param application: Application info of the event - :type application: ~azure.applicationinsights.models.EventsApplicationInfo + :type application: + ~azure.applicationinsights.query.models.EventsApplicationInfo :param client: Client info of the event - :type client: ~azure.applicationinsights.models.EventsClientInfo + :type client: ~azure.applicationinsights.query.models.EventsClientInfo :param type: Required. Constant filled by server. :type type: str :param browser_timing: :type browser_timing: - ~azure.applicationinsights.models.EventsBrowserTimingInfo + ~azure.applicationinsights.query.models.EventsBrowserTimingInfo :param client_performance: :type client_performance: - ~azure.applicationinsights.models.EventsClientPerformanceInfo + ~azure.applicationinsights.query.models.EventsClientPerformanceInfo """ _validation = { diff --git a/azure-applicationinsights/azure/applicationinsights/models/events_custom_event_result.py b/azure-applicationinsights/azure/applicationinsights/models/events_custom_event_result.py index 05fd0a74ec54..f8e3739c4ead 100644 --- a/azure-applicationinsights/azure/applicationinsights/models/events_custom_event_result.py +++ b/azure-applicationinsights/azure/applicationinsights/models/events_custom_event_result.py @@ -25,29 +25,31 @@ class EventsCustomEventResult(EventsResultData): :type timestamp: datetime :param custom_dimensions: Custom dimensions of the event :type custom_dimensions: - ~azure.applicationinsights.models.EventsResultDataCustomDimensions + ~azure.applicationinsights.query.models.EventsResultDataCustomDimensions :param custom_measurements: Custom measurements of the event :type custom_measurements: - ~azure.applicationinsights.models.EventsResultDataCustomMeasurements + ~azure.applicationinsights.query.models.EventsResultDataCustomMeasurements :param operation: Operation info of the event - :type operation: ~azure.applicationinsights.models.EventsOperationInfo + :type operation: + ~azure.applicationinsights.query.models.EventsOperationInfo :param session: Session info of the event - :type session: ~azure.applicationinsights.models.EventsSessionInfo + :type session: ~azure.applicationinsights.query.models.EventsSessionInfo :param user: User info of the event - :type user: ~azure.applicationinsights.models.EventsUserInfo + :type user: ~azure.applicationinsights.query.models.EventsUserInfo :param cloud: Cloud info of the event - :type cloud: ~azure.applicationinsights.models.EventsCloudInfo + :type cloud: ~azure.applicationinsights.query.models.EventsCloudInfo :param ai: AI info of the event - :type ai: ~azure.applicationinsights.models.EventsAiInfo + :type ai: ~azure.applicationinsights.query.models.EventsAiInfo :param application: Application info of the event - :type application: ~azure.applicationinsights.models.EventsApplicationInfo + :type application: + ~azure.applicationinsights.query.models.EventsApplicationInfo :param client: Client info of the event - :type client: ~azure.applicationinsights.models.EventsClientInfo + :type client: ~azure.applicationinsights.query.models.EventsClientInfo :param type: Required. Constant filled by server. :type type: str :param custom_event: :type custom_event: - ~azure.applicationinsights.models.EventsCustomEventInfo + ~azure.applicationinsights.query.models.EventsCustomEventInfo """ _validation = { diff --git a/azure-applicationinsights/azure/applicationinsights/models/events_custom_event_result_py3.py b/azure-applicationinsights/azure/applicationinsights/models/events_custom_event_result_py3.py index 0cc02be6bb95..56f817395111 100644 --- a/azure-applicationinsights/azure/applicationinsights/models/events_custom_event_result_py3.py +++ b/azure-applicationinsights/azure/applicationinsights/models/events_custom_event_result_py3.py @@ -25,29 +25,31 @@ class EventsCustomEventResult(EventsResultData): :type timestamp: datetime :param custom_dimensions: Custom dimensions of the event :type custom_dimensions: - ~azure.applicationinsights.models.EventsResultDataCustomDimensions + ~azure.applicationinsights.query.models.EventsResultDataCustomDimensions :param custom_measurements: Custom measurements of the event :type custom_measurements: - ~azure.applicationinsights.models.EventsResultDataCustomMeasurements + ~azure.applicationinsights.query.models.EventsResultDataCustomMeasurements :param operation: Operation info of the event - :type operation: ~azure.applicationinsights.models.EventsOperationInfo + :type operation: + ~azure.applicationinsights.query.models.EventsOperationInfo :param session: Session info of the event - :type session: ~azure.applicationinsights.models.EventsSessionInfo + :type session: ~azure.applicationinsights.query.models.EventsSessionInfo :param user: User info of the event - :type user: ~azure.applicationinsights.models.EventsUserInfo + :type user: ~azure.applicationinsights.query.models.EventsUserInfo :param cloud: Cloud info of the event - :type cloud: ~azure.applicationinsights.models.EventsCloudInfo + :type cloud: ~azure.applicationinsights.query.models.EventsCloudInfo :param ai: AI info of the event - :type ai: ~azure.applicationinsights.models.EventsAiInfo + :type ai: ~azure.applicationinsights.query.models.EventsAiInfo :param application: Application info of the event - :type application: ~azure.applicationinsights.models.EventsApplicationInfo + :type application: + ~azure.applicationinsights.query.models.EventsApplicationInfo :param client: Client info of the event - :type client: ~azure.applicationinsights.models.EventsClientInfo + :type client: ~azure.applicationinsights.query.models.EventsClientInfo :param type: Required. Constant filled by server. :type type: str :param custom_event: :type custom_event: - ~azure.applicationinsights.models.EventsCustomEventInfo + ~azure.applicationinsights.query.models.EventsCustomEventInfo """ _validation = { diff --git a/azure-applicationinsights/azure/applicationinsights/models/events_custom_metric_result.py b/azure-applicationinsights/azure/applicationinsights/models/events_custom_metric_result.py index 12c87e84ba55..d420605530a8 100644 --- a/azure-applicationinsights/azure/applicationinsights/models/events_custom_metric_result.py +++ b/azure-applicationinsights/azure/applicationinsights/models/events_custom_metric_result.py @@ -25,29 +25,31 @@ class EventsCustomMetricResult(EventsResultData): :type timestamp: datetime :param custom_dimensions: Custom dimensions of the event :type custom_dimensions: - ~azure.applicationinsights.models.EventsResultDataCustomDimensions + ~azure.applicationinsights.query.models.EventsResultDataCustomDimensions :param custom_measurements: Custom measurements of the event :type custom_measurements: - ~azure.applicationinsights.models.EventsResultDataCustomMeasurements + ~azure.applicationinsights.query.models.EventsResultDataCustomMeasurements :param operation: Operation info of the event - :type operation: ~azure.applicationinsights.models.EventsOperationInfo + :type operation: + ~azure.applicationinsights.query.models.EventsOperationInfo :param session: Session info of the event - :type session: ~azure.applicationinsights.models.EventsSessionInfo + :type session: ~azure.applicationinsights.query.models.EventsSessionInfo :param user: User info of the event - :type user: ~azure.applicationinsights.models.EventsUserInfo + :type user: ~azure.applicationinsights.query.models.EventsUserInfo :param cloud: Cloud info of the event - :type cloud: ~azure.applicationinsights.models.EventsCloudInfo + :type cloud: ~azure.applicationinsights.query.models.EventsCloudInfo :param ai: AI info of the event - :type ai: ~azure.applicationinsights.models.EventsAiInfo + :type ai: ~azure.applicationinsights.query.models.EventsAiInfo :param application: Application info of the event - :type application: ~azure.applicationinsights.models.EventsApplicationInfo + :type application: + ~azure.applicationinsights.query.models.EventsApplicationInfo :param client: Client info of the event - :type client: ~azure.applicationinsights.models.EventsClientInfo + :type client: ~azure.applicationinsights.query.models.EventsClientInfo :param type: Required. Constant filled by server. :type type: str :param custom_metric: :type custom_metric: - ~azure.applicationinsights.models.EventsCustomMetricInfo + ~azure.applicationinsights.query.models.EventsCustomMetricInfo """ _validation = { diff --git a/azure-applicationinsights/azure/applicationinsights/models/events_custom_metric_result_py3.py b/azure-applicationinsights/azure/applicationinsights/models/events_custom_metric_result_py3.py index fd67a16f53f3..1ee698b7826d 100644 --- a/azure-applicationinsights/azure/applicationinsights/models/events_custom_metric_result_py3.py +++ b/azure-applicationinsights/azure/applicationinsights/models/events_custom_metric_result_py3.py @@ -25,29 +25,31 @@ class EventsCustomMetricResult(EventsResultData): :type timestamp: datetime :param custom_dimensions: Custom dimensions of the event :type custom_dimensions: - ~azure.applicationinsights.models.EventsResultDataCustomDimensions + ~azure.applicationinsights.query.models.EventsResultDataCustomDimensions :param custom_measurements: Custom measurements of the event :type custom_measurements: - ~azure.applicationinsights.models.EventsResultDataCustomMeasurements + ~azure.applicationinsights.query.models.EventsResultDataCustomMeasurements :param operation: Operation info of the event - :type operation: ~azure.applicationinsights.models.EventsOperationInfo + :type operation: + ~azure.applicationinsights.query.models.EventsOperationInfo :param session: Session info of the event - :type session: ~azure.applicationinsights.models.EventsSessionInfo + :type session: ~azure.applicationinsights.query.models.EventsSessionInfo :param user: User info of the event - :type user: ~azure.applicationinsights.models.EventsUserInfo + :type user: ~azure.applicationinsights.query.models.EventsUserInfo :param cloud: Cloud info of the event - :type cloud: ~azure.applicationinsights.models.EventsCloudInfo + :type cloud: ~azure.applicationinsights.query.models.EventsCloudInfo :param ai: AI info of the event - :type ai: ~azure.applicationinsights.models.EventsAiInfo + :type ai: ~azure.applicationinsights.query.models.EventsAiInfo :param application: Application info of the event - :type application: ~azure.applicationinsights.models.EventsApplicationInfo + :type application: + ~azure.applicationinsights.query.models.EventsApplicationInfo :param client: Client info of the event - :type client: ~azure.applicationinsights.models.EventsClientInfo + :type client: ~azure.applicationinsights.query.models.EventsClientInfo :param type: Required. Constant filled by server. :type type: str :param custom_metric: :type custom_metric: - ~azure.applicationinsights.models.EventsCustomMetricInfo + ~azure.applicationinsights.query.models.EventsCustomMetricInfo """ _validation = { diff --git a/azure-applicationinsights/azure/applicationinsights/models/events_dependency_result.py b/azure-applicationinsights/azure/applicationinsights/models/events_dependency_result.py index eeece68c5cc1..f8fa5ff21abf 100644 --- a/azure-applicationinsights/azure/applicationinsights/models/events_dependency_result.py +++ b/azure-applicationinsights/azure/applicationinsights/models/events_dependency_result.py @@ -25,28 +25,31 @@ class EventsDependencyResult(EventsResultData): :type timestamp: datetime :param custom_dimensions: Custom dimensions of the event :type custom_dimensions: - ~azure.applicationinsights.models.EventsResultDataCustomDimensions + ~azure.applicationinsights.query.models.EventsResultDataCustomDimensions :param custom_measurements: Custom measurements of the event :type custom_measurements: - ~azure.applicationinsights.models.EventsResultDataCustomMeasurements + ~azure.applicationinsights.query.models.EventsResultDataCustomMeasurements :param operation: Operation info of the event - :type operation: ~azure.applicationinsights.models.EventsOperationInfo + :type operation: + ~azure.applicationinsights.query.models.EventsOperationInfo :param session: Session info of the event - :type session: ~azure.applicationinsights.models.EventsSessionInfo + :type session: ~azure.applicationinsights.query.models.EventsSessionInfo :param user: User info of the event - :type user: ~azure.applicationinsights.models.EventsUserInfo + :type user: ~azure.applicationinsights.query.models.EventsUserInfo :param cloud: Cloud info of the event - :type cloud: ~azure.applicationinsights.models.EventsCloudInfo + :type cloud: ~azure.applicationinsights.query.models.EventsCloudInfo :param ai: AI info of the event - :type ai: ~azure.applicationinsights.models.EventsAiInfo + :type ai: ~azure.applicationinsights.query.models.EventsAiInfo :param application: Application info of the event - :type application: ~azure.applicationinsights.models.EventsApplicationInfo + :type application: + ~azure.applicationinsights.query.models.EventsApplicationInfo :param client: Client info of the event - :type client: ~azure.applicationinsights.models.EventsClientInfo + :type client: ~azure.applicationinsights.query.models.EventsClientInfo :param type: Required. Constant filled by server. :type type: str :param dependency: - :type dependency: ~azure.applicationinsights.models.EventsDependencyInfo + :type dependency: + ~azure.applicationinsights.query.models.EventsDependencyInfo """ _validation = { diff --git a/azure-applicationinsights/azure/applicationinsights/models/events_dependency_result_py3.py b/azure-applicationinsights/azure/applicationinsights/models/events_dependency_result_py3.py index 363232fa0e2c..6e70948305d5 100644 --- a/azure-applicationinsights/azure/applicationinsights/models/events_dependency_result_py3.py +++ b/azure-applicationinsights/azure/applicationinsights/models/events_dependency_result_py3.py @@ -25,28 +25,31 @@ class EventsDependencyResult(EventsResultData): :type timestamp: datetime :param custom_dimensions: Custom dimensions of the event :type custom_dimensions: - ~azure.applicationinsights.models.EventsResultDataCustomDimensions + ~azure.applicationinsights.query.models.EventsResultDataCustomDimensions :param custom_measurements: Custom measurements of the event :type custom_measurements: - ~azure.applicationinsights.models.EventsResultDataCustomMeasurements + ~azure.applicationinsights.query.models.EventsResultDataCustomMeasurements :param operation: Operation info of the event - :type operation: ~azure.applicationinsights.models.EventsOperationInfo + :type operation: + ~azure.applicationinsights.query.models.EventsOperationInfo :param session: Session info of the event - :type session: ~azure.applicationinsights.models.EventsSessionInfo + :type session: ~azure.applicationinsights.query.models.EventsSessionInfo :param user: User info of the event - :type user: ~azure.applicationinsights.models.EventsUserInfo + :type user: ~azure.applicationinsights.query.models.EventsUserInfo :param cloud: Cloud info of the event - :type cloud: ~azure.applicationinsights.models.EventsCloudInfo + :type cloud: ~azure.applicationinsights.query.models.EventsCloudInfo :param ai: AI info of the event - :type ai: ~azure.applicationinsights.models.EventsAiInfo + :type ai: ~azure.applicationinsights.query.models.EventsAiInfo :param application: Application info of the event - :type application: ~azure.applicationinsights.models.EventsApplicationInfo + :type application: + ~azure.applicationinsights.query.models.EventsApplicationInfo :param client: Client info of the event - :type client: ~azure.applicationinsights.models.EventsClientInfo + :type client: ~azure.applicationinsights.query.models.EventsClientInfo :param type: Required. Constant filled by server. :type type: str :param dependency: - :type dependency: ~azure.applicationinsights.models.EventsDependencyInfo + :type dependency: + ~azure.applicationinsights.query.models.EventsDependencyInfo """ _validation = { diff --git a/azure-applicationinsights/azure/applicationinsights/models/events_exception_detail.py b/azure-applicationinsights/azure/applicationinsights/models/events_exception_detail.py index d51c5357a013..6a6547a733fd 100644 --- a/azure-applicationinsights/azure/applicationinsights/models/events_exception_detail.py +++ b/azure-applicationinsights/azure/applicationinsights/models/events_exception_detail.py @@ -27,7 +27,7 @@ class EventsExceptionDetail(Model): :type id: str :param parsed_stack: The parsed stack :type parsed_stack: - list[~azure.applicationinsights.models.EventsExceptionDetailsParsedStack] + list[~azure.applicationinsights.query.models.EventsExceptionDetailsParsedStack] """ _attribute_map = { diff --git a/azure-applicationinsights/azure/applicationinsights/models/events_exception_detail_py3.py b/azure-applicationinsights/azure/applicationinsights/models/events_exception_detail_py3.py index 875aae356549..0d1b2a90958e 100644 --- a/azure-applicationinsights/azure/applicationinsights/models/events_exception_detail_py3.py +++ b/azure-applicationinsights/azure/applicationinsights/models/events_exception_detail_py3.py @@ -27,7 +27,7 @@ class EventsExceptionDetail(Model): :type id: str :param parsed_stack: The parsed stack :type parsed_stack: - list[~azure.applicationinsights.models.EventsExceptionDetailsParsedStack] + list[~azure.applicationinsights.query.models.EventsExceptionDetailsParsedStack] """ _attribute_map = { diff --git a/azure-applicationinsights/azure/applicationinsights/models/events_exception_info.py b/azure-applicationinsights/azure/applicationinsights/models/events_exception_info.py index dac282869db6..986f82cbc365 100644 --- a/azure-applicationinsights/azure/applicationinsights/models/events_exception_info.py +++ b/azure-applicationinsights/azure/applicationinsights/models/events_exception_info.py @@ -47,7 +47,7 @@ class EventsExceptionInfo(Model): :type innermost_assembly: str :param details: The details of the exception :type details: - list[~azure.applicationinsights.models.EventsExceptionDetail] + list[~azure.applicationinsights.query.models.EventsExceptionDetail] """ _attribute_map = { diff --git a/azure-applicationinsights/azure/applicationinsights/models/events_exception_info_py3.py b/azure-applicationinsights/azure/applicationinsights/models/events_exception_info_py3.py index dc575c2c0f3f..8c77597625c2 100644 --- a/azure-applicationinsights/azure/applicationinsights/models/events_exception_info_py3.py +++ b/azure-applicationinsights/azure/applicationinsights/models/events_exception_info_py3.py @@ -47,7 +47,7 @@ class EventsExceptionInfo(Model): :type innermost_assembly: str :param details: The details of the exception :type details: - list[~azure.applicationinsights.models.EventsExceptionDetail] + list[~azure.applicationinsights.query.models.EventsExceptionDetail] """ _attribute_map = { diff --git a/azure-applicationinsights/azure/applicationinsights/models/events_exception_result.py b/azure-applicationinsights/azure/applicationinsights/models/events_exception_result.py index a1b2d90f062e..33c1ad89bf4a 100644 --- a/azure-applicationinsights/azure/applicationinsights/models/events_exception_result.py +++ b/azure-applicationinsights/azure/applicationinsights/models/events_exception_result.py @@ -25,28 +25,31 @@ class EventsExceptionResult(EventsResultData): :type timestamp: datetime :param custom_dimensions: Custom dimensions of the event :type custom_dimensions: - ~azure.applicationinsights.models.EventsResultDataCustomDimensions + ~azure.applicationinsights.query.models.EventsResultDataCustomDimensions :param custom_measurements: Custom measurements of the event :type custom_measurements: - ~azure.applicationinsights.models.EventsResultDataCustomMeasurements + ~azure.applicationinsights.query.models.EventsResultDataCustomMeasurements :param operation: Operation info of the event - :type operation: ~azure.applicationinsights.models.EventsOperationInfo + :type operation: + ~azure.applicationinsights.query.models.EventsOperationInfo :param session: Session info of the event - :type session: ~azure.applicationinsights.models.EventsSessionInfo + :type session: ~azure.applicationinsights.query.models.EventsSessionInfo :param user: User info of the event - :type user: ~azure.applicationinsights.models.EventsUserInfo + :type user: ~azure.applicationinsights.query.models.EventsUserInfo :param cloud: Cloud info of the event - :type cloud: ~azure.applicationinsights.models.EventsCloudInfo + :type cloud: ~azure.applicationinsights.query.models.EventsCloudInfo :param ai: AI info of the event - :type ai: ~azure.applicationinsights.models.EventsAiInfo + :type ai: ~azure.applicationinsights.query.models.EventsAiInfo :param application: Application info of the event - :type application: ~azure.applicationinsights.models.EventsApplicationInfo + :type application: + ~azure.applicationinsights.query.models.EventsApplicationInfo :param client: Client info of the event - :type client: ~azure.applicationinsights.models.EventsClientInfo + :type client: ~azure.applicationinsights.query.models.EventsClientInfo :param type: Required. Constant filled by server. :type type: str :param exception: - :type exception: ~azure.applicationinsights.models.EventsExceptionInfo + :type exception: + ~azure.applicationinsights.query.models.EventsExceptionInfo """ _validation = { diff --git a/azure-applicationinsights/azure/applicationinsights/models/events_exception_result_py3.py b/azure-applicationinsights/azure/applicationinsights/models/events_exception_result_py3.py index 6e908a1e8659..88ea880b0e72 100644 --- a/azure-applicationinsights/azure/applicationinsights/models/events_exception_result_py3.py +++ b/azure-applicationinsights/azure/applicationinsights/models/events_exception_result_py3.py @@ -25,28 +25,31 @@ class EventsExceptionResult(EventsResultData): :type timestamp: datetime :param custom_dimensions: Custom dimensions of the event :type custom_dimensions: - ~azure.applicationinsights.models.EventsResultDataCustomDimensions + ~azure.applicationinsights.query.models.EventsResultDataCustomDimensions :param custom_measurements: Custom measurements of the event :type custom_measurements: - ~azure.applicationinsights.models.EventsResultDataCustomMeasurements + ~azure.applicationinsights.query.models.EventsResultDataCustomMeasurements :param operation: Operation info of the event - :type operation: ~azure.applicationinsights.models.EventsOperationInfo + :type operation: + ~azure.applicationinsights.query.models.EventsOperationInfo :param session: Session info of the event - :type session: ~azure.applicationinsights.models.EventsSessionInfo + :type session: ~azure.applicationinsights.query.models.EventsSessionInfo :param user: User info of the event - :type user: ~azure.applicationinsights.models.EventsUserInfo + :type user: ~azure.applicationinsights.query.models.EventsUserInfo :param cloud: Cloud info of the event - :type cloud: ~azure.applicationinsights.models.EventsCloudInfo + :type cloud: ~azure.applicationinsights.query.models.EventsCloudInfo :param ai: AI info of the event - :type ai: ~azure.applicationinsights.models.EventsAiInfo + :type ai: ~azure.applicationinsights.query.models.EventsAiInfo :param application: Application info of the event - :type application: ~azure.applicationinsights.models.EventsApplicationInfo + :type application: + ~azure.applicationinsights.query.models.EventsApplicationInfo :param client: Client info of the event - :type client: ~azure.applicationinsights.models.EventsClientInfo + :type client: ~azure.applicationinsights.query.models.EventsClientInfo :param type: Required. Constant filled by server. :type type: str :param exception: - :type exception: ~azure.applicationinsights.models.EventsExceptionInfo + :type exception: + ~azure.applicationinsights.query.models.EventsExceptionInfo """ _validation = { diff --git a/azure-applicationinsights/azure/applicationinsights/models/events_page_view_result.py b/azure-applicationinsights/azure/applicationinsights/models/events_page_view_result.py index e8ccba7aa68e..c8f859844aad 100644 --- a/azure-applicationinsights/azure/applicationinsights/models/events_page_view_result.py +++ b/azure-applicationinsights/azure/applicationinsights/models/events_page_view_result.py @@ -25,28 +25,31 @@ class EventsPageViewResult(EventsResultData): :type timestamp: datetime :param custom_dimensions: Custom dimensions of the event :type custom_dimensions: - ~azure.applicationinsights.models.EventsResultDataCustomDimensions + ~azure.applicationinsights.query.models.EventsResultDataCustomDimensions :param custom_measurements: Custom measurements of the event :type custom_measurements: - ~azure.applicationinsights.models.EventsResultDataCustomMeasurements + ~azure.applicationinsights.query.models.EventsResultDataCustomMeasurements :param operation: Operation info of the event - :type operation: ~azure.applicationinsights.models.EventsOperationInfo + :type operation: + ~azure.applicationinsights.query.models.EventsOperationInfo :param session: Session info of the event - :type session: ~azure.applicationinsights.models.EventsSessionInfo + :type session: ~azure.applicationinsights.query.models.EventsSessionInfo :param user: User info of the event - :type user: ~azure.applicationinsights.models.EventsUserInfo + :type user: ~azure.applicationinsights.query.models.EventsUserInfo :param cloud: Cloud info of the event - :type cloud: ~azure.applicationinsights.models.EventsCloudInfo + :type cloud: ~azure.applicationinsights.query.models.EventsCloudInfo :param ai: AI info of the event - :type ai: ~azure.applicationinsights.models.EventsAiInfo + :type ai: ~azure.applicationinsights.query.models.EventsAiInfo :param application: Application info of the event - :type application: ~azure.applicationinsights.models.EventsApplicationInfo + :type application: + ~azure.applicationinsights.query.models.EventsApplicationInfo :param client: Client info of the event - :type client: ~azure.applicationinsights.models.EventsClientInfo + :type client: ~azure.applicationinsights.query.models.EventsClientInfo :param type: Required. Constant filled by server. :type type: str :param page_view: - :type page_view: ~azure.applicationinsights.models.EventsPageViewInfo + :type page_view: + ~azure.applicationinsights.query.models.EventsPageViewInfo """ _validation = { diff --git a/azure-applicationinsights/azure/applicationinsights/models/events_page_view_result_py3.py b/azure-applicationinsights/azure/applicationinsights/models/events_page_view_result_py3.py index 1d998146fbf8..c2d34a33f671 100644 --- a/azure-applicationinsights/azure/applicationinsights/models/events_page_view_result_py3.py +++ b/azure-applicationinsights/azure/applicationinsights/models/events_page_view_result_py3.py @@ -25,28 +25,31 @@ class EventsPageViewResult(EventsResultData): :type timestamp: datetime :param custom_dimensions: Custom dimensions of the event :type custom_dimensions: - ~azure.applicationinsights.models.EventsResultDataCustomDimensions + ~azure.applicationinsights.query.models.EventsResultDataCustomDimensions :param custom_measurements: Custom measurements of the event :type custom_measurements: - ~azure.applicationinsights.models.EventsResultDataCustomMeasurements + ~azure.applicationinsights.query.models.EventsResultDataCustomMeasurements :param operation: Operation info of the event - :type operation: ~azure.applicationinsights.models.EventsOperationInfo + :type operation: + ~azure.applicationinsights.query.models.EventsOperationInfo :param session: Session info of the event - :type session: ~azure.applicationinsights.models.EventsSessionInfo + :type session: ~azure.applicationinsights.query.models.EventsSessionInfo :param user: User info of the event - :type user: ~azure.applicationinsights.models.EventsUserInfo + :type user: ~azure.applicationinsights.query.models.EventsUserInfo :param cloud: Cloud info of the event - :type cloud: ~azure.applicationinsights.models.EventsCloudInfo + :type cloud: ~azure.applicationinsights.query.models.EventsCloudInfo :param ai: AI info of the event - :type ai: ~azure.applicationinsights.models.EventsAiInfo + :type ai: ~azure.applicationinsights.query.models.EventsAiInfo :param application: Application info of the event - :type application: ~azure.applicationinsights.models.EventsApplicationInfo + :type application: + ~azure.applicationinsights.query.models.EventsApplicationInfo :param client: Client info of the event - :type client: ~azure.applicationinsights.models.EventsClientInfo + :type client: ~azure.applicationinsights.query.models.EventsClientInfo :param type: Required. Constant filled by server. :type type: str :param page_view: - :type page_view: ~azure.applicationinsights.models.EventsPageViewInfo + :type page_view: + ~azure.applicationinsights.query.models.EventsPageViewInfo """ _validation = { diff --git a/azure-applicationinsights/azure/applicationinsights/models/events_performance_counter_result.py b/azure-applicationinsights/azure/applicationinsights/models/events_performance_counter_result.py index f57be3ebca70..d53b447a2f3c 100644 --- a/azure-applicationinsights/azure/applicationinsights/models/events_performance_counter_result.py +++ b/azure-applicationinsights/azure/applicationinsights/models/events_performance_counter_result.py @@ -25,29 +25,31 @@ class EventsPerformanceCounterResult(EventsResultData): :type timestamp: datetime :param custom_dimensions: Custom dimensions of the event :type custom_dimensions: - ~azure.applicationinsights.models.EventsResultDataCustomDimensions + ~azure.applicationinsights.query.models.EventsResultDataCustomDimensions :param custom_measurements: Custom measurements of the event :type custom_measurements: - ~azure.applicationinsights.models.EventsResultDataCustomMeasurements + ~azure.applicationinsights.query.models.EventsResultDataCustomMeasurements :param operation: Operation info of the event - :type operation: ~azure.applicationinsights.models.EventsOperationInfo + :type operation: + ~azure.applicationinsights.query.models.EventsOperationInfo :param session: Session info of the event - :type session: ~azure.applicationinsights.models.EventsSessionInfo + :type session: ~azure.applicationinsights.query.models.EventsSessionInfo :param user: User info of the event - :type user: ~azure.applicationinsights.models.EventsUserInfo + :type user: ~azure.applicationinsights.query.models.EventsUserInfo :param cloud: Cloud info of the event - :type cloud: ~azure.applicationinsights.models.EventsCloudInfo + :type cloud: ~azure.applicationinsights.query.models.EventsCloudInfo :param ai: AI info of the event - :type ai: ~azure.applicationinsights.models.EventsAiInfo + :type ai: ~azure.applicationinsights.query.models.EventsAiInfo :param application: Application info of the event - :type application: ~azure.applicationinsights.models.EventsApplicationInfo + :type application: + ~azure.applicationinsights.query.models.EventsApplicationInfo :param client: Client info of the event - :type client: ~azure.applicationinsights.models.EventsClientInfo + :type client: ~azure.applicationinsights.query.models.EventsClientInfo :param type: Required. Constant filled by server. :type type: str :param performance_counter: :type performance_counter: - ~azure.applicationinsights.models.EventsPerformanceCounterInfo + ~azure.applicationinsights.query.models.EventsPerformanceCounterInfo """ _validation = { diff --git a/azure-applicationinsights/azure/applicationinsights/models/events_performance_counter_result_py3.py b/azure-applicationinsights/azure/applicationinsights/models/events_performance_counter_result_py3.py index 6dd2a97f220d..81a891767c69 100644 --- a/azure-applicationinsights/azure/applicationinsights/models/events_performance_counter_result_py3.py +++ b/azure-applicationinsights/azure/applicationinsights/models/events_performance_counter_result_py3.py @@ -25,29 +25,31 @@ class EventsPerformanceCounterResult(EventsResultData): :type timestamp: datetime :param custom_dimensions: Custom dimensions of the event :type custom_dimensions: - ~azure.applicationinsights.models.EventsResultDataCustomDimensions + ~azure.applicationinsights.query.models.EventsResultDataCustomDimensions :param custom_measurements: Custom measurements of the event :type custom_measurements: - ~azure.applicationinsights.models.EventsResultDataCustomMeasurements + ~azure.applicationinsights.query.models.EventsResultDataCustomMeasurements :param operation: Operation info of the event - :type operation: ~azure.applicationinsights.models.EventsOperationInfo + :type operation: + ~azure.applicationinsights.query.models.EventsOperationInfo :param session: Session info of the event - :type session: ~azure.applicationinsights.models.EventsSessionInfo + :type session: ~azure.applicationinsights.query.models.EventsSessionInfo :param user: User info of the event - :type user: ~azure.applicationinsights.models.EventsUserInfo + :type user: ~azure.applicationinsights.query.models.EventsUserInfo :param cloud: Cloud info of the event - :type cloud: ~azure.applicationinsights.models.EventsCloudInfo + :type cloud: ~azure.applicationinsights.query.models.EventsCloudInfo :param ai: AI info of the event - :type ai: ~azure.applicationinsights.models.EventsAiInfo + :type ai: ~azure.applicationinsights.query.models.EventsAiInfo :param application: Application info of the event - :type application: ~azure.applicationinsights.models.EventsApplicationInfo + :type application: + ~azure.applicationinsights.query.models.EventsApplicationInfo :param client: Client info of the event - :type client: ~azure.applicationinsights.models.EventsClientInfo + :type client: ~azure.applicationinsights.query.models.EventsClientInfo :param type: Required. Constant filled by server. :type type: str :param performance_counter: :type performance_counter: - ~azure.applicationinsights.models.EventsPerformanceCounterInfo + ~azure.applicationinsights.query.models.EventsPerformanceCounterInfo """ _validation = { diff --git a/azure-applicationinsights/azure/applicationinsights/models/events_request_result.py b/azure-applicationinsights/azure/applicationinsights/models/events_request_result.py index 0df622bcb775..a57798516548 100644 --- a/azure-applicationinsights/azure/applicationinsights/models/events_request_result.py +++ b/azure-applicationinsights/azure/applicationinsights/models/events_request_result.py @@ -25,28 +25,30 @@ class EventsRequestResult(EventsResultData): :type timestamp: datetime :param custom_dimensions: Custom dimensions of the event :type custom_dimensions: - ~azure.applicationinsights.models.EventsResultDataCustomDimensions + ~azure.applicationinsights.query.models.EventsResultDataCustomDimensions :param custom_measurements: Custom measurements of the event :type custom_measurements: - ~azure.applicationinsights.models.EventsResultDataCustomMeasurements + ~azure.applicationinsights.query.models.EventsResultDataCustomMeasurements :param operation: Operation info of the event - :type operation: ~azure.applicationinsights.models.EventsOperationInfo + :type operation: + ~azure.applicationinsights.query.models.EventsOperationInfo :param session: Session info of the event - :type session: ~azure.applicationinsights.models.EventsSessionInfo + :type session: ~azure.applicationinsights.query.models.EventsSessionInfo :param user: User info of the event - :type user: ~azure.applicationinsights.models.EventsUserInfo + :type user: ~azure.applicationinsights.query.models.EventsUserInfo :param cloud: Cloud info of the event - :type cloud: ~azure.applicationinsights.models.EventsCloudInfo + :type cloud: ~azure.applicationinsights.query.models.EventsCloudInfo :param ai: AI info of the event - :type ai: ~azure.applicationinsights.models.EventsAiInfo + :type ai: ~azure.applicationinsights.query.models.EventsAiInfo :param application: Application info of the event - :type application: ~azure.applicationinsights.models.EventsApplicationInfo + :type application: + ~azure.applicationinsights.query.models.EventsApplicationInfo :param client: Client info of the event - :type client: ~azure.applicationinsights.models.EventsClientInfo + :type client: ~azure.applicationinsights.query.models.EventsClientInfo :param type: Required. Constant filled by server. :type type: str :param request: - :type request: ~azure.applicationinsights.models.EventsRequestInfo + :type request: ~azure.applicationinsights.query.models.EventsRequestInfo """ _validation = { diff --git a/azure-applicationinsights/azure/applicationinsights/models/events_request_result_py3.py b/azure-applicationinsights/azure/applicationinsights/models/events_request_result_py3.py index 1f6041d37ab7..972054958ce4 100644 --- a/azure-applicationinsights/azure/applicationinsights/models/events_request_result_py3.py +++ b/azure-applicationinsights/azure/applicationinsights/models/events_request_result_py3.py @@ -25,28 +25,30 @@ class EventsRequestResult(EventsResultData): :type timestamp: datetime :param custom_dimensions: Custom dimensions of the event :type custom_dimensions: - ~azure.applicationinsights.models.EventsResultDataCustomDimensions + ~azure.applicationinsights.query.models.EventsResultDataCustomDimensions :param custom_measurements: Custom measurements of the event :type custom_measurements: - ~azure.applicationinsights.models.EventsResultDataCustomMeasurements + ~azure.applicationinsights.query.models.EventsResultDataCustomMeasurements :param operation: Operation info of the event - :type operation: ~azure.applicationinsights.models.EventsOperationInfo + :type operation: + ~azure.applicationinsights.query.models.EventsOperationInfo :param session: Session info of the event - :type session: ~azure.applicationinsights.models.EventsSessionInfo + :type session: ~azure.applicationinsights.query.models.EventsSessionInfo :param user: User info of the event - :type user: ~azure.applicationinsights.models.EventsUserInfo + :type user: ~azure.applicationinsights.query.models.EventsUserInfo :param cloud: Cloud info of the event - :type cloud: ~azure.applicationinsights.models.EventsCloudInfo + :type cloud: ~azure.applicationinsights.query.models.EventsCloudInfo :param ai: AI info of the event - :type ai: ~azure.applicationinsights.models.EventsAiInfo + :type ai: ~azure.applicationinsights.query.models.EventsAiInfo :param application: Application info of the event - :type application: ~azure.applicationinsights.models.EventsApplicationInfo + :type application: + ~azure.applicationinsights.query.models.EventsApplicationInfo :param client: Client info of the event - :type client: ~azure.applicationinsights.models.EventsClientInfo + :type client: ~azure.applicationinsights.query.models.EventsClientInfo :param type: Required. Constant filled by server. :type type: str :param request: - :type request: ~azure.applicationinsights.models.EventsRequestInfo + :type request: ~azure.applicationinsights.query.models.EventsRequestInfo """ _validation = { diff --git a/azure-applicationinsights/azure/applicationinsights/models/events_result.py b/azure-applicationinsights/azure/applicationinsights/models/events_result.py index 4700fc598860..b84d8c770a35 100644 --- a/azure-applicationinsights/azure/applicationinsights/models/events_result.py +++ b/azure-applicationinsights/azure/applicationinsights/models/events_result.py @@ -16,9 +16,9 @@ class EventsResult(Model): """An event query result. :param aimessages: OData messages for this response. - :type aimessages: list[~azure.applicationinsights.models.ErrorInfo] + :type aimessages: list[~azure.applicationinsights.query.models.ErrorInfo] :param value: - :type value: ~azure.applicationinsights.models.EventsResultData + :type value: ~azure.applicationinsights.query.models.EventsResultData """ _attribute_map = { diff --git a/azure-applicationinsights/azure/applicationinsights/models/events_result_data.py b/azure-applicationinsights/azure/applicationinsights/models/events_result_data.py index 97d6cfb22070..c4cf3b6ebe09 100644 --- a/azure-applicationinsights/azure/applicationinsights/models/events_result_data.py +++ b/azure-applicationinsights/azure/applicationinsights/models/events_result_data.py @@ -32,24 +32,26 @@ class EventsResultData(Model): :type timestamp: datetime :param custom_dimensions: Custom dimensions of the event :type custom_dimensions: - ~azure.applicationinsights.models.EventsResultDataCustomDimensions + ~azure.applicationinsights.query.models.EventsResultDataCustomDimensions :param custom_measurements: Custom measurements of the event :type custom_measurements: - ~azure.applicationinsights.models.EventsResultDataCustomMeasurements + ~azure.applicationinsights.query.models.EventsResultDataCustomMeasurements :param operation: Operation info of the event - :type operation: ~azure.applicationinsights.models.EventsOperationInfo + :type operation: + ~azure.applicationinsights.query.models.EventsOperationInfo :param session: Session info of the event - :type session: ~azure.applicationinsights.models.EventsSessionInfo + :type session: ~azure.applicationinsights.query.models.EventsSessionInfo :param user: User info of the event - :type user: ~azure.applicationinsights.models.EventsUserInfo + :type user: ~azure.applicationinsights.query.models.EventsUserInfo :param cloud: Cloud info of the event - :type cloud: ~azure.applicationinsights.models.EventsCloudInfo + :type cloud: ~azure.applicationinsights.query.models.EventsCloudInfo :param ai: AI info of the event - :type ai: ~azure.applicationinsights.models.EventsAiInfo + :type ai: ~azure.applicationinsights.query.models.EventsAiInfo :param application: Application info of the event - :type application: ~azure.applicationinsights.models.EventsApplicationInfo + :type application: + ~azure.applicationinsights.query.models.EventsApplicationInfo :param client: Client info of the event - :type client: ~azure.applicationinsights.models.EventsClientInfo + :type client: ~azure.applicationinsights.query.models.EventsClientInfo :param type: Required. Constant filled by server. :type type: str """ diff --git a/azure-applicationinsights/azure/applicationinsights/models/events_result_data_py3.py b/azure-applicationinsights/azure/applicationinsights/models/events_result_data_py3.py index dd76e288e5d4..34ec898acd06 100644 --- a/azure-applicationinsights/azure/applicationinsights/models/events_result_data_py3.py +++ b/azure-applicationinsights/azure/applicationinsights/models/events_result_data_py3.py @@ -32,24 +32,26 @@ class EventsResultData(Model): :type timestamp: datetime :param custom_dimensions: Custom dimensions of the event :type custom_dimensions: - ~azure.applicationinsights.models.EventsResultDataCustomDimensions + ~azure.applicationinsights.query.models.EventsResultDataCustomDimensions :param custom_measurements: Custom measurements of the event :type custom_measurements: - ~azure.applicationinsights.models.EventsResultDataCustomMeasurements + ~azure.applicationinsights.query.models.EventsResultDataCustomMeasurements :param operation: Operation info of the event - :type operation: ~azure.applicationinsights.models.EventsOperationInfo + :type operation: + ~azure.applicationinsights.query.models.EventsOperationInfo :param session: Session info of the event - :type session: ~azure.applicationinsights.models.EventsSessionInfo + :type session: ~azure.applicationinsights.query.models.EventsSessionInfo :param user: User info of the event - :type user: ~azure.applicationinsights.models.EventsUserInfo + :type user: ~azure.applicationinsights.query.models.EventsUserInfo :param cloud: Cloud info of the event - :type cloud: ~azure.applicationinsights.models.EventsCloudInfo + :type cloud: ~azure.applicationinsights.query.models.EventsCloudInfo :param ai: AI info of the event - :type ai: ~azure.applicationinsights.models.EventsAiInfo + :type ai: ~azure.applicationinsights.query.models.EventsAiInfo :param application: Application info of the event - :type application: ~azure.applicationinsights.models.EventsApplicationInfo + :type application: + ~azure.applicationinsights.query.models.EventsApplicationInfo :param client: Client info of the event - :type client: ~azure.applicationinsights.models.EventsClientInfo + :type client: ~azure.applicationinsights.query.models.EventsClientInfo :param type: Required. Constant filled by server. :type type: str """ diff --git a/azure-applicationinsights/azure/applicationinsights/models/events_result_py3.py b/azure-applicationinsights/azure/applicationinsights/models/events_result_py3.py index 3c66e4efaf26..a154e05aef55 100644 --- a/azure-applicationinsights/azure/applicationinsights/models/events_result_py3.py +++ b/azure-applicationinsights/azure/applicationinsights/models/events_result_py3.py @@ -16,9 +16,9 @@ class EventsResult(Model): """An event query result. :param aimessages: OData messages for this response. - :type aimessages: list[~azure.applicationinsights.models.ErrorInfo] + :type aimessages: list[~azure.applicationinsights.query.models.ErrorInfo] :param value: - :type value: ~azure.applicationinsights.models.EventsResultData + :type value: ~azure.applicationinsights.query.models.EventsResultData """ _attribute_map = { diff --git a/azure-applicationinsights/azure/applicationinsights/models/events_results.py b/azure-applicationinsights/azure/applicationinsights/models/events_results.py index cc066b4b9d36..8b9a2228d1b4 100644 --- a/azure-applicationinsights/azure/applicationinsights/models/events_results.py +++ b/azure-applicationinsights/azure/applicationinsights/models/events_results.py @@ -18,9 +18,10 @@ class EventsResults(Model): :param odatacontext: OData context metadata endpoint for this response :type odatacontext: str :param aimessages: OData messages for this response. - :type aimessages: list[~azure.applicationinsights.models.ErrorInfo] + :type aimessages: list[~azure.applicationinsights.query.models.ErrorInfo] :param value: Contents of the events query result. - :type value: list[~azure.applicationinsights.models.EventsResultData] + :type value: + list[~azure.applicationinsights.query.models.EventsResultData] """ _attribute_map = { diff --git a/azure-applicationinsights/azure/applicationinsights/models/events_results_py3.py b/azure-applicationinsights/azure/applicationinsights/models/events_results_py3.py index 97e9c80082cd..65a22168d007 100644 --- a/azure-applicationinsights/azure/applicationinsights/models/events_results_py3.py +++ b/azure-applicationinsights/azure/applicationinsights/models/events_results_py3.py @@ -18,9 +18,10 @@ class EventsResults(Model): :param odatacontext: OData context metadata endpoint for this response :type odatacontext: str :param aimessages: OData messages for this response. - :type aimessages: list[~azure.applicationinsights.models.ErrorInfo] + :type aimessages: list[~azure.applicationinsights.query.models.ErrorInfo] :param value: Contents of the events query result. - :type value: list[~azure.applicationinsights.models.EventsResultData] + :type value: + list[~azure.applicationinsights.query.models.EventsResultData] """ _attribute_map = { diff --git a/azure-applicationinsights/azure/applicationinsights/models/events_trace_result.py b/azure-applicationinsights/azure/applicationinsights/models/events_trace_result.py index f71782577c5c..2d26495c9f82 100644 --- a/azure-applicationinsights/azure/applicationinsights/models/events_trace_result.py +++ b/azure-applicationinsights/azure/applicationinsights/models/events_trace_result.py @@ -25,28 +25,30 @@ class EventsTraceResult(EventsResultData): :type timestamp: datetime :param custom_dimensions: Custom dimensions of the event :type custom_dimensions: - ~azure.applicationinsights.models.EventsResultDataCustomDimensions + ~azure.applicationinsights.query.models.EventsResultDataCustomDimensions :param custom_measurements: Custom measurements of the event :type custom_measurements: - ~azure.applicationinsights.models.EventsResultDataCustomMeasurements + ~azure.applicationinsights.query.models.EventsResultDataCustomMeasurements :param operation: Operation info of the event - :type operation: ~azure.applicationinsights.models.EventsOperationInfo + :type operation: + ~azure.applicationinsights.query.models.EventsOperationInfo :param session: Session info of the event - :type session: ~azure.applicationinsights.models.EventsSessionInfo + :type session: ~azure.applicationinsights.query.models.EventsSessionInfo :param user: User info of the event - :type user: ~azure.applicationinsights.models.EventsUserInfo + :type user: ~azure.applicationinsights.query.models.EventsUserInfo :param cloud: Cloud info of the event - :type cloud: ~azure.applicationinsights.models.EventsCloudInfo + :type cloud: ~azure.applicationinsights.query.models.EventsCloudInfo :param ai: AI info of the event - :type ai: ~azure.applicationinsights.models.EventsAiInfo + :type ai: ~azure.applicationinsights.query.models.EventsAiInfo :param application: Application info of the event - :type application: ~azure.applicationinsights.models.EventsApplicationInfo + :type application: + ~azure.applicationinsights.query.models.EventsApplicationInfo :param client: Client info of the event - :type client: ~azure.applicationinsights.models.EventsClientInfo + :type client: ~azure.applicationinsights.query.models.EventsClientInfo :param type: Required. Constant filled by server. :type type: str :param trace: - :type trace: ~azure.applicationinsights.models.EventsTraceInfo + :type trace: ~azure.applicationinsights.query.models.EventsTraceInfo """ _validation = { diff --git a/azure-applicationinsights/azure/applicationinsights/models/events_trace_result_py3.py b/azure-applicationinsights/azure/applicationinsights/models/events_trace_result_py3.py index d322f2e104b9..681f33d29018 100644 --- a/azure-applicationinsights/azure/applicationinsights/models/events_trace_result_py3.py +++ b/azure-applicationinsights/azure/applicationinsights/models/events_trace_result_py3.py @@ -25,28 +25,30 @@ class EventsTraceResult(EventsResultData): :type timestamp: datetime :param custom_dimensions: Custom dimensions of the event :type custom_dimensions: - ~azure.applicationinsights.models.EventsResultDataCustomDimensions + ~azure.applicationinsights.query.models.EventsResultDataCustomDimensions :param custom_measurements: Custom measurements of the event :type custom_measurements: - ~azure.applicationinsights.models.EventsResultDataCustomMeasurements + ~azure.applicationinsights.query.models.EventsResultDataCustomMeasurements :param operation: Operation info of the event - :type operation: ~azure.applicationinsights.models.EventsOperationInfo + :type operation: + ~azure.applicationinsights.query.models.EventsOperationInfo :param session: Session info of the event - :type session: ~azure.applicationinsights.models.EventsSessionInfo + :type session: ~azure.applicationinsights.query.models.EventsSessionInfo :param user: User info of the event - :type user: ~azure.applicationinsights.models.EventsUserInfo + :type user: ~azure.applicationinsights.query.models.EventsUserInfo :param cloud: Cloud info of the event - :type cloud: ~azure.applicationinsights.models.EventsCloudInfo + :type cloud: ~azure.applicationinsights.query.models.EventsCloudInfo :param ai: AI info of the event - :type ai: ~azure.applicationinsights.models.EventsAiInfo + :type ai: ~azure.applicationinsights.query.models.EventsAiInfo :param application: Application info of the event - :type application: ~azure.applicationinsights.models.EventsApplicationInfo + :type application: + ~azure.applicationinsights.query.models.EventsApplicationInfo :param client: Client info of the event - :type client: ~azure.applicationinsights.models.EventsClientInfo + :type client: ~azure.applicationinsights.query.models.EventsClientInfo :param type: Required. Constant filled by server. :type type: str :param trace: - :type trace: ~azure.applicationinsights.models.EventsTraceInfo + :type trace: ~azure.applicationinsights.query.models.EventsTraceInfo """ _validation = { diff --git a/azure-applicationinsights/azure/applicationinsights/models/metrics_post_body_schema.py b/azure-applicationinsights/azure/applicationinsights/models/metrics_post_body_schema.py index cacd7e4b3f1d..130ecf0ba8c3 100644 --- a/azure-applicationinsights/azure/applicationinsights/models/metrics_post_body_schema.py +++ b/azure-applicationinsights/azure/applicationinsights/models/metrics_post_body_schema.py @@ -23,7 +23,7 @@ class MetricsPostBodySchema(Model): :type id: str :param parameters: Required. The parameters for a single metrics query :type parameters: - ~azure.applicationinsights.models.MetricsPostBodySchemaParameters + ~azure.applicationinsights.query.models.MetricsPostBodySchemaParameters """ _validation = { diff --git a/azure-applicationinsights/azure/applicationinsights/models/metrics_post_body_schema_parameters.py b/azure-applicationinsights/azure/applicationinsights/models/metrics_post_body_schema_parameters.py index 79965b86de8f..2431f9a36184 100644 --- a/azure-applicationinsights/azure/applicationinsights/models/metrics_post_body_schema_parameters.py +++ b/azure-applicationinsights/azure/applicationinsights/models/metrics_post_body_schema_parameters.py @@ -36,17 +36,17 @@ class MetricsPostBodySchemaParameters(Model): 'availabilityResults/availabilityPercentage', 'availabilityResults/duration', 'billing/telemetryCount', 'customEvents/count' - :type metric_id: str or ~azure.applicationinsights.models.MetricId + :type metric_id: str or ~azure.applicationinsights.query.models.MetricId :param timespan: :type timespan: str :param aggregation: :type aggregation: list[str or - ~azure.applicationinsights.models.MetricsAggregation] + ~azure.applicationinsights.query.models.MetricsAggregation] :param interval: :type interval: timedelta :param segment: :type segment: list[str or - ~azure.applicationinsights.models.MetricsSegment] + ~azure.applicationinsights.query.models.MetricsSegment] :param top: :type top: int :param orderby: @@ -62,7 +62,7 @@ class MetricsPostBodySchemaParameters(Model): _attribute_map = { 'metric_id': {'key': 'metricId', 'type': 'str'}, 'timespan': {'key': 'timespan', 'type': 'str'}, - 'aggregation': {'key': 'aggregation', 'type': '[MetricsAggregation]'}, + 'aggregation': {'key': 'aggregation', 'type': '[str]'}, 'interval': {'key': 'interval', 'type': 'duration'}, 'segment': {'key': 'segment', 'type': '[str]'}, 'top': {'key': 'top', 'type': 'int'}, diff --git a/azure-applicationinsights/azure/applicationinsights/models/metrics_post_body_schema_parameters_py3.py b/azure-applicationinsights/azure/applicationinsights/models/metrics_post_body_schema_parameters_py3.py index 1643e880ee2e..7329e3052166 100644 --- a/azure-applicationinsights/azure/applicationinsights/models/metrics_post_body_schema_parameters_py3.py +++ b/azure-applicationinsights/azure/applicationinsights/models/metrics_post_body_schema_parameters_py3.py @@ -36,17 +36,17 @@ class MetricsPostBodySchemaParameters(Model): 'availabilityResults/availabilityPercentage', 'availabilityResults/duration', 'billing/telemetryCount', 'customEvents/count' - :type metric_id: str or ~azure.applicationinsights.models.MetricId + :type metric_id: str or ~azure.applicationinsights.query.models.MetricId :param timespan: :type timespan: str :param aggregation: :type aggregation: list[str or - ~azure.applicationinsights.models.MetricsAggregation] + ~azure.applicationinsights.query.models.MetricsAggregation] :param interval: :type interval: timedelta :param segment: :type segment: list[str or - ~azure.applicationinsights.models.MetricsSegment] + ~azure.applicationinsights.query.models.MetricsSegment] :param top: :type top: int :param orderby: @@ -62,7 +62,7 @@ class MetricsPostBodySchemaParameters(Model): _attribute_map = { 'metric_id': {'key': 'metricId', 'type': 'str'}, 'timespan': {'key': 'timespan', 'type': 'str'}, - 'aggregation': {'key': 'aggregation', 'type': '[MetricsAggregation]'}, + 'aggregation': {'key': 'aggregation', 'type': '[str]'}, 'interval': {'key': 'interval', 'type': 'duration'}, 'segment': {'key': 'segment', 'type': '[str]'}, 'top': {'key': 'top', 'type': 'int'}, diff --git a/azure-applicationinsights/azure/applicationinsights/models/metrics_post_body_schema_py3.py b/azure-applicationinsights/azure/applicationinsights/models/metrics_post_body_schema_py3.py index 971b301e1c9d..0a4fe848984b 100644 --- a/azure-applicationinsights/azure/applicationinsights/models/metrics_post_body_schema_py3.py +++ b/azure-applicationinsights/azure/applicationinsights/models/metrics_post_body_schema_py3.py @@ -23,7 +23,7 @@ class MetricsPostBodySchema(Model): :type id: str :param parameters: Required. The parameters for a single metrics query :type parameters: - ~azure.applicationinsights.models.MetricsPostBodySchemaParameters + ~azure.applicationinsights.query.models.MetricsPostBodySchemaParameters """ _validation = { diff --git a/azure-applicationinsights/azure/applicationinsights/models/metrics_result.py b/azure-applicationinsights/azure/applicationinsights/models/metrics_result.py index 9f7ba4cb04d9..6c8de065aa0f 100644 --- a/azure-applicationinsights/azure/applicationinsights/models/metrics_result.py +++ b/azure-applicationinsights/azure/applicationinsights/models/metrics_result.py @@ -16,7 +16,7 @@ class MetricsResult(Model): """A metric result. :param value: - :type value: ~azure.applicationinsights.models.MetricsResultInfo + :type value: ~azure.applicationinsights.query.models.MetricsResultInfo """ _attribute_map = { diff --git a/azure-applicationinsights/azure/applicationinsights/models/metrics_result_info.py b/azure-applicationinsights/azure/applicationinsights/models/metrics_result_info.py index 62cb46940985..69f9b4ca3861 100644 --- a/azure-applicationinsights/azure/applicationinsights/models/metrics_result_info.py +++ b/azure-applicationinsights/azure/applicationinsights/models/metrics_result_info.py @@ -25,7 +25,8 @@ class MetricsResultInfo(Model): :param interval: The interval used to segment the metric data. :type interval: timedelta :param segments: Segmented metric data (if segmented). - :type segments: list[~azure.applicationinsights.models.MetricsSegmentInfo] + :type segments: + list[~azure.applicationinsights.query.models.MetricsSegmentInfo] """ _attribute_map = { diff --git a/azure-applicationinsights/azure/applicationinsights/models/metrics_result_info_py3.py b/azure-applicationinsights/azure/applicationinsights/models/metrics_result_info_py3.py index 816274f7d803..e4005451e9b6 100644 --- a/azure-applicationinsights/azure/applicationinsights/models/metrics_result_info_py3.py +++ b/azure-applicationinsights/azure/applicationinsights/models/metrics_result_info_py3.py @@ -25,7 +25,8 @@ class MetricsResultInfo(Model): :param interval: The interval used to segment the metric data. :type interval: timedelta :param segments: Segmented metric data (if segmented). - :type segments: list[~azure.applicationinsights.models.MetricsSegmentInfo] + :type segments: + list[~azure.applicationinsights.query.models.MetricsSegmentInfo] """ _attribute_map = { diff --git a/azure-applicationinsights/azure/applicationinsights/models/metrics_result_py3.py b/azure-applicationinsights/azure/applicationinsights/models/metrics_result_py3.py index eb4095d987b1..caad749117bf 100644 --- a/azure-applicationinsights/azure/applicationinsights/models/metrics_result_py3.py +++ b/azure-applicationinsights/azure/applicationinsights/models/metrics_result_py3.py @@ -16,7 +16,7 @@ class MetricsResult(Model): """A metric result. :param value: - :type value: ~azure.applicationinsights.models.MetricsResultInfo + :type value: ~azure.applicationinsights.query.models.MetricsResultInfo """ _attribute_map = { diff --git a/azure-applicationinsights/azure/applicationinsights/models/metrics_results_item.py b/azure-applicationinsights/azure/applicationinsights/models/metrics_results_item.py index 41d359351403..05367f7646cf 100644 --- a/azure-applicationinsights/azure/applicationinsights/models/metrics_results_item.py +++ b/azure-applicationinsights/azure/applicationinsights/models/metrics_results_item.py @@ -22,7 +22,7 @@ class MetricsResultsItem(Model): :param status: Required. The HTTP status code of this metric query. :type status: int :param body: Required. The results of this metric query. - :type body: ~azure.applicationinsights.models.MetricsResult + :type body: ~azure.applicationinsights.query.models.MetricsResult """ _validation = { diff --git a/azure-applicationinsights/azure/applicationinsights/models/metrics_results_item_py3.py b/azure-applicationinsights/azure/applicationinsights/models/metrics_results_item_py3.py index f5c311907771..69d079f49b10 100644 --- a/azure-applicationinsights/azure/applicationinsights/models/metrics_results_item_py3.py +++ b/azure-applicationinsights/azure/applicationinsights/models/metrics_results_item_py3.py @@ -22,7 +22,7 @@ class MetricsResultsItem(Model): :param status: Required. The HTTP status code of this metric query. :type status: int :param body: Required. The results of this metric query. - :type body: ~azure.applicationinsights.models.MetricsResult + :type body: ~azure.applicationinsights.query.models.MetricsResult """ _validation = { diff --git a/azure-applicationinsights/azure/applicationinsights/models/metrics_segment_info.py b/azure-applicationinsights/azure/applicationinsights/models/metrics_segment_info.py index 2b59be2e86dc..9fc5d23a86d1 100644 --- a/azure-applicationinsights/azure/applicationinsights/models/metrics_segment_info.py +++ b/azure-applicationinsights/azure/applicationinsights/models/metrics_segment_info.py @@ -25,7 +25,8 @@ class MetricsSegmentInfo(Model): specified). :type end: datetime :param segments: Segmented metric data (if further segmented). - :type segments: list[~azure.applicationinsights.models.MetricsSegmentInfo] + :type segments: + list[~azure.applicationinsights.query.models.MetricsSegmentInfo] """ _attribute_map = { diff --git a/azure-applicationinsights/azure/applicationinsights/models/metrics_segment_info_py3.py b/azure-applicationinsights/azure/applicationinsights/models/metrics_segment_info_py3.py index c9b91967b630..0fa80b9df930 100644 --- a/azure-applicationinsights/azure/applicationinsights/models/metrics_segment_info_py3.py +++ b/azure-applicationinsights/azure/applicationinsights/models/metrics_segment_info_py3.py @@ -25,7 +25,8 @@ class MetricsSegmentInfo(Model): specified). :type end: datetime :param segments: Segmented metric data (if further segmented). - :type segments: list[~azure.applicationinsights.models.MetricsSegmentInfo] + :type segments: + list[~azure.applicationinsights.query.models.MetricsSegmentInfo] """ _attribute_map = { diff --git a/azure-applicationinsights/azure/applicationinsights/models/query_results.py b/azure-applicationinsights/azure/applicationinsights/models/query_results.py index cd70e17383b3..e2f709b3bbb7 100644 --- a/azure-applicationinsights/azure/applicationinsights/models/query_results.py +++ b/azure-applicationinsights/azure/applicationinsights/models/query_results.py @@ -20,7 +20,7 @@ class QueryResults(Model): All required parameters must be populated in order to send to Azure. :param tables: Required. The list of tables, columns and rows. - :type tables: list[~azure.applicationinsights.models.Table] + :type tables: list[~azure.applicationinsights.query.models.Table] """ _validation = { diff --git a/azure-applicationinsights/azure/applicationinsights/models/query_results_py3.py b/azure-applicationinsights/azure/applicationinsights/models/query_results_py3.py index a1ff010ef1d3..eb60942e72d9 100644 --- a/azure-applicationinsights/azure/applicationinsights/models/query_results_py3.py +++ b/azure-applicationinsights/azure/applicationinsights/models/query_results_py3.py @@ -20,7 +20,7 @@ class QueryResults(Model): All required parameters must be populated in order to send to Azure. :param tables: Required. The list of tables, columns and rows. - :type tables: list[~azure.applicationinsights.models.Table] + :type tables: list[~azure.applicationinsights.query.models.Table] """ _validation = { diff --git a/azure-applicationinsights/azure/applicationinsights/models/table.py b/azure-applicationinsights/azure/applicationinsights/models/table.py index 8acce07b8fa5..8dfb68e9a880 100644 --- a/azure-applicationinsights/azure/applicationinsights/models/table.py +++ b/azure-applicationinsights/azure/applicationinsights/models/table.py @@ -22,7 +22,7 @@ class Table(Model): :param name: Required. The name of the table. :type name: str :param columns: Required. The list of columns in this table. - :type columns: list[~azure.applicationinsights.models.Column] + :type columns: list[~azure.applicationinsights.query.models.Column] :param rows: Required. The resulting rows from this query. :type rows: list[list[object]] """ diff --git a/azure-applicationinsights/azure/applicationinsights/models/table_py3.py b/azure-applicationinsights/azure/applicationinsights/models/table_py3.py index b6e86d86036f..d829ede6f2b1 100644 --- a/azure-applicationinsights/azure/applicationinsights/models/table_py3.py +++ b/azure-applicationinsights/azure/applicationinsights/models/table_py3.py @@ -22,7 +22,7 @@ class Table(Model): :param name: Required. The name of the table. :type name: str :param columns: Required. The list of columns in this table. - :type columns: list[~azure.applicationinsights.models.Column] + :type columns: list[~azure.applicationinsights.query.models.Column] :param rows: Required. The resulting rows from this query. :type rows: list[list[object]] """ diff --git a/azure-applicationinsights/azure/applicationinsights/operations/events_operations.py b/azure-applicationinsights/azure/applicationinsights/operations/events_operations.py index 08a70504d336..a4e9050e661d 100644 --- a/azure-applicationinsights/azure/applicationinsights/operations/events_operations.py +++ b/azure-applicationinsights/azure/applicationinsights/operations/events_operations.py @@ -49,7 +49,8 @@ def get_by_type( 'traces', 'customEvents', 'pageViews', 'browserTimings', 'requests', 'dependencies', 'exceptions', 'availabilityResults', 'performanceCounters', 'customMetrics' - :type event_type: str or ~azure.applicationinsights.models.EventType + :type event_type: str or + ~azure.applicationinsights.query.models.EventType :param timespan: Optional. The timespan over which to retrieve events. This is an ISO8601 time period value. This timespan is applied in addition to any that are specified in the Odata expression. @@ -82,10 +83,10 @@ def get_by_type( :param operation_config: :ref:`Operation configuration overrides`. :return: EventsResults or ClientRawResponse if raw=true - :rtype: ~azure.applicationinsights.models.EventsResults or + :rtype: ~azure.applicationinsights.query.models.EventsResults or ~msrest.pipeline.ClientRawResponse :raises: - :class:`ErrorResponseException` + :class:`ErrorResponseException` """ # Construct URL url = self.get_by_type.metadata['url'] @@ -159,7 +160,8 @@ def get( 'traces', 'customEvents', 'pageViews', 'browserTimings', 'requests', 'dependencies', 'exceptions', 'availabilityResults', 'performanceCounters', 'customMetrics' - :type event_type: str or ~azure.applicationinsights.models.EventType + :type event_type: str or + ~azure.applicationinsights.query.models.EventType :param event_id: ID of event. :type event_id: str :param timespan: Optional. The timespan over which to retrieve events. @@ -172,10 +174,10 @@ def get( :param operation_config: :ref:`Operation configuration overrides`. :return: EventsResults or ClientRawResponse if raw=true - :rtype: ~azure.applicationinsights.models.EventsResults or + :rtype: ~azure.applicationinsights.query.models.EventsResults or ~msrest.pipeline.ClientRawResponse :raises: - :class:`ErrorResponseException` + :class:`ErrorResponseException` """ # Construct URL url = self.get.metadata['url'] @@ -233,7 +235,7 @@ def get_odata_metadata( :return: object or ClientRawResponse if raw=true :rtype: object or ~msrest.pipeline.ClientRawResponse :raises: - :class:`ErrorResponseException` + :class:`ErrorResponseException` """ # Construct URL url = self.get_odata_metadata.metadata['url'] diff --git a/azure-applicationinsights/azure/applicationinsights/operations/metrics_operations.py b/azure-applicationinsights/azure/applicationinsights/operations/metrics_operations.py index 82a011e0601e..79eecf0a68fa 100644 --- a/azure-applicationinsights/azure/applicationinsights/operations/metrics_operations.py +++ b/azure-applicationinsights/azure/applicationinsights/operations/metrics_operations.py @@ -63,7 +63,8 @@ def get( 'availabilityResults/availabilityPercentage', 'availabilityResults/duration', 'billing/telemetryCount', 'customEvents/count' - :type metric_id: str or ~azure.applicationinsights.models.MetricId + :type metric_id: str or + ~azure.applicationinsights.query.models.MetricId :param timespan: The timespan over which to retrieve metric values. This is an ISO8601 time period value. If timespan is omitted, a default time range of `PT12H` ("last 12 hours") is used. The actual @@ -83,14 +84,14 @@ def get( with a comma. If no aggregation is specified, then the default aggregation for the metric is used. :type aggregation: list[str or - ~azure.applicationinsights.models.MetricsAggregation] + ~azure.applicationinsights.query.models.MetricsAggregation] :param segment: The name of the dimension to segment the metric values by. This dimension must be applicable to the metric you are retrieving. To segment by more than one dimension at a time, separate them with a comma (,). In this case, the metric data will be segmented in the order the dimensions are listed in the parameter. :type segment: list[str or - ~azure.applicationinsights.models.MetricsSegment] + ~azure.applicationinsights.query.models.MetricsSegment] :param top: The number of segments to return. This value is only valid when segment is specified. :type top: int @@ -108,10 +109,10 @@ def get( :param operation_config: :ref:`Operation configuration overrides`. :return: MetricsResult or ClientRawResponse if raw=true - :rtype: ~azure.applicationinsights.models.MetricsResult or + :rtype: ~azure.applicationinsights.query.models.MetricsResult or ~msrest.pipeline.ClientRawResponse :raises: - :class:`ErrorResponseException` + :class:`ErrorResponseException` """ # Construct URL url = self.get.metadata['url'] @@ -128,7 +129,7 @@ def get( if interval is not None: query_parameters['interval'] = self._serialize.query("interval", interval, 'duration') if aggregation is not None: - query_parameters['aggregation'] = self._serialize.query("aggregation", aggregation, '[MetricsAggregation]', div=',', min_items=1) + query_parameters['aggregation'] = self._serialize.query("aggregation", aggregation, '[str]', div=',', min_items=1) if segment is not None: query_parameters['segment'] = self._serialize.query("segment", segment, '[str]', div=',', min_items=1) if top is not None: @@ -174,17 +175,18 @@ def get_multiple( :type app_id: str :param body: The batched metrics query. :type body: - list[~azure.applicationinsights.models.MetricsPostBodySchema] + list[~azure.applicationinsights.query.models.MetricsPostBodySchema] :param dict custom_headers: headers that will be added to the request :param bool raw: returns the direct response alongside the deserialized response :param operation_config: :ref:`Operation configuration overrides`. :return: list or ClientRawResponse if raw=true - :rtype: list[~azure.applicationinsights.models.MetricsResultsItem] or + :rtype: + list[~azure.applicationinsights.query.models.MetricsResultsItem] or ~msrest.pipeline.ClientRawResponse :raises: - :class:`ErrorResponseException` + :class:`ErrorResponseException` """ # Construct URL url = self.get_multiple.metadata['url'] @@ -242,7 +244,7 @@ def get_metadata( :return: object or ClientRawResponse if raw=true :rtype: object or ~msrest.pipeline.ClientRawResponse :raises: - :class:`ErrorResponseException` + :class:`ErrorResponseException` """ # Construct URL url = self.get_metadata.metadata['url'] diff --git a/azure-applicationinsights/azure/applicationinsights/operations/query_operations.py b/azure-applicationinsights/azure/applicationinsights/operations/query_operations.py index f08c7f7ffe6c..7250d777b407 100644 --- a/azure-applicationinsights/azure/applicationinsights/operations/query_operations.py +++ b/azure-applicationinsights/azure/applicationinsights/operations/query_operations.py @@ -47,17 +47,17 @@ def execute( :param body: The Analytics query. Learn more about the [Analytics query syntax](https://azure.microsoft.com/documentation/articles/app-insights-analytics-reference/) - :type body: ~azure.applicationinsights.models.QueryBody + :type body: ~azure.applicationinsights.query.models.QueryBody :param dict custom_headers: headers that will be added to the request :param bool raw: returns the direct response alongside the deserialized response :param operation_config: :ref:`Operation configuration overrides`. :return: QueryResults or ClientRawResponse if raw=true - :rtype: ~azure.applicationinsights.models.QueryResults or + :rtype: ~azure.applicationinsights.query.models.QueryResults or ~msrest.pipeline.ClientRawResponse :raises: - :class:`ErrorResponseException` + :class:`ErrorResponseException` """ # Construct URL url = self.execute.metadata['url'] diff --git a/azure-applicationinsights/setup.py b/azure-applicationinsights/setup.py index 80142e19f197..7b3261463154 100644 --- a/azure-applicationinsights/setup.py +++ b/azure-applicationinsights/setup.py @@ -77,6 +77,7 @@ ]), install_requires=[ 'msrest>=0.5.0', + 'msrestazure>=0.4.32,<2.0.0', 'azure-common~=1.1', ], extras_require={ diff --git a/azure-loganalytics/MANIFEST.in b/azure-loganalytics/MANIFEST.in index bb37a2723dae..74c0ac7e42a1 100644 --- a/azure-loganalytics/MANIFEST.in +++ b/azure-loganalytics/MANIFEST.in @@ -1 +1,4 @@ +recursive-include tests *.py *.yaml include *.rst +include azure/__init__.py + diff --git a/azure-loganalytics/README.rst b/azure-loganalytics/README.rst index 874a0adc79f2..284d3fc9cedc 100644 --- a/azure-loganalytics/README.rst +++ b/azure-loganalytics/README.rst @@ -8,25 +8,6 @@ This package has been tested with Python 2.7, 3.4, 3.5, 3.6 and 3.7. For a more complete set of Azure libraries, see the `azure `__ bundle package. -Compatibility -============= - -**IMPORTANT**: If you have an earlier version of the azure package -(version < 1.0), you should uninstall it before installing this package. - -You can check the version using pip: - -.. code:: shell - - pip freeze - -If you see azure==0.11.0 (or any version below 1.0), uninstall it first: - -.. code:: shell - - pip uninstall azure - - Usage ===== diff --git a/azure-loganalytics/azure/loganalytics/log_analytics_data_client.py b/azure-loganalytics/azure/loganalytics/log_analytics_data_client.py index 75521bb6886b..fed0faf2737c 100644 --- a/azure-loganalytics/azure/loganalytics/log_analytics_data_client.py +++ b/azure-loganalytics/azure/loganalytics/log_analytics_data_client.py @@ -12,7 +12,7 @@ from msrest.service_client import SDKClient from msrest import Configuration, Serializer, Deserializer from .version import VERSION -from msrest.pipeline import ClientRawResponse +from .operations.query_operations import QueryOperations from . import models @@ -48,6 +48,9 @@ class LogAnalyticsDataClient(SDKClient): :ivar config: Configuration for client. :vartype config: LogAnalyticsDataClientConfiguration + :ivar query: Query operations + :vartype query: azure.loganalytics.operations.QueryOperations + :param credentials: Subscription credentials which uniquely identify client subscription. :type credentials: None @@ -65,68 +68,5 @@ def __init__( self._serialize = Serializer(client_models) self._deserialize = Deserializer(client_models) - - def query( - self, workspace_id, body, custom_headers=None, raw=False, **operation_config): - """Execute an Analytics query. - - Executes an Analytics query for data. - [Here](https://dev.loganalytics.io/documentation/Using-the-API) is an - example for using POST with an Analytics query. - - :param workspace_id: ID of the workspace. This is Workspace ID from - the Properties blade in the Azure portal. - :type workspace_id: str - :param body: The Analytics query. Learn more about the [Analytics - query - syntax](https://azure.microsoft.com/documentation/articles/app-insights-analytics-reference/) - :type body: ~azure.loganalytics.models.QueryBody - :param dict custom_headers: headers that will be added to the request - :param bool raw: returns the direct response alongside the - deserialized response - :param operation_config: :ref:`Operation configuration - overrides`. - :return: QueryResults or ClientRawResponse if raw=true - :rtype: ~azure.loganalytics.models.QueryResults or - ~msrest.pipeline.ClientRawResponse - :raises: - :class:`ErrorResponseException` - """ - # Construct URL - url = self.query.metadata['url'] - path_format_arguments = { - 'workspaceId': self._serialize.url("workspace_id", workspace_id, 'str') - } - url = self._client.format_url(url, **path_format_arguments) - - # Construct parameters - query_parameters = {} - - # Construct headers - header_parameters = {} - header_parameters['Content-Type'] = 'application/json; charset=utf-8' - if custom_headers: - header_parameters.update(custom_headers) - - # Construct body - body_content = self._serialize.body(body, 'QueryBody') - - # Construct and send request - request = self._client.post(url, query_parameters) - response = self._client.send( - request, header_parameters, body_content, stream=False, **operation_config) - - if response.status_code not in [200]: - raise models.ErrorResponseException(self._deserialize, response) - - deserialized = None - - if response.status_code == 200: - deserialized = self._deserialize('QueryResults', response) - - if raw: - client_raw_response = ClientRawResponse(deserialized, response) - return client_raw_response - - return deserialized - query.metadata = {'url': '/workspaces/{workspaceId}/query'} + self.query = QueryOperations( + self._client, self.config, self._serialize, self._deserialize) diff --git a/azure-loganalytics/azure/loganalytics/operations/__init__.py b/azure-loganalytics/azure/loganalytics/operations/__init__.py new file mode 100644 index 000000000000..4a2f82a9b381 --- /dev/null +++ b/azure-loganalytics/azure/loganalytics/operations/__init__.py @@ -0,0 +1,16 @@ +# coding=utf-8 +# -------------------------------------------------------------------------- +# Copyright (c) Microsoft Corporation. All rights reserved. +# Licensed under the MIT License. See License.txt in the project root for +# license information. +# +# Code generated by Microsoft (R) AutoRest Code Generator. +# Changes may cause incorrect behavior and will be lost if the code is +# regenerated. +# -------------------------------------------------------------------------- + +from .query_operations import QueryOperations + +__all__ = [ + 'QueryOperations', +] diff --git a/azure-loganalytics/azure/loganalytics/operations/query_operations.py b/azure-loganalytics/azure/loganalytics/operations/query_operations.py new file mode 100644 index 000000000000..d958d70d4e7e --- /dev/null +++ b/azure-loganalytics/azure/loganalytics/operations/query_operations.py @@ -0,0 +1,99 @@ +# coding=utf-8 +# -------------------------------------------------------------------------- +# Copyright (c) Microsoft Corporation. All rights reserved. +# Licensed under the MIT License. See License.txt in the project root for +# license information. +# +# Code generated by Microsoft (R) AutoRest Code Generator. +# Changes may cause incorrect behavior and will be lost if the code is +# regenerated. +# -------------------------------------------------------------------------- + +from msrest.pipeline import ClientRawResponse + +from .. import models + + +class QueryOperations(object): + """QueryOperations operations. + + :param client: Client for service requests. + :param config: Configuration of service client. + :param serializer: An object model serializer. + :param deserializer: An object model deserializer. + """ + + models = models + + def __init__(self, client, config, serializer, deserializer): + + self._client = client + self._serialize = serializer + self._deserialize = deserializer + + self.config = config + + def execute( + self, workspace_id, body, custom_headers=None, raw=False, **operation_config): + """Execute an Analytics query. + + Executes an Analytics query for data. + [Here](https://dev.loganalytics.io/documentation/Using-the-API) is an + example for using POST with an Analytics query. + + :param workspace_id: ID of the workspace. This is Workspace ID from + the Properties blade in the Azure portal. + :type workspace_id: str + :param body: The Analytics query. Learn more about the [Analytics + query + syntax](https://azure.microsoft.com/documentation/articles/app-insights-analytics-reference/) + :type body: ~azure.loganalytics.models.QueryBody + :param dict custom_headers: headers that will be added to the request + :param bool raw: returns the direct response alongside the + deserialized response + :param operation_config: :ref:`Operation configuration + overrides`. + :return: QueryResults or ClientRawResponse if raw=true + :rtype: ~azure.loganalytics.models.QueryResults or + ~msrest.pipeline.ClientRawResponse + :raises: + :class:`ErrorResponseException` + """ + # Construct URL + url = self.execute.metadata['url'] + path_format_arguments = { + 'workspaceId': self._serialize.url("workspace_id", workspace_id, 'str') + } + url = self._client.format_url(url, **path_format_arguments) + + # Construct parameters + query_parameters = {} + + # Construct headers + header_parameters = {} + header_parameters['Accept'] = 'application/json' + header_parameters['Content-Type'] = 'application/json; charset=utf-8' + if custom_headers: + header_parameters.update(custom_headers) + + # Construct body + body_content = self._serialize.body(body, 'QueryBody') + + # Construct and send request + request = self._client.post(url, query_parameters, header_parameters, body_content) + response = self._client.send(request, stream=False, **operation_config) + + if response.status_code not in [200]: + raise models.ErrorResponseException(self._deserialize, response) + + deserialized = None + + if response.status_code == 200: + deserialized = self._deserialize('QueryResults', response) + + if raw: + client_raw_response = ClientRawResponse(deserialized, response) + return client_raw_response + + return deserialized + execute.metadata = {'url': '/workspaces/{workspaceId}/query'} diff --git a/azure-loganalytics/setup.py b/azure-loganalytics/setup.py index 87ff80807710..d3d7639aa0f2 100644 --- a/azure-loganalytics/setup.py +++ b/azure-loganalytics/setup.py @@ -77,6 +77,7 @@ ]), install_requires=[ 'msrest>=0.5.0', + 'msrestazure>=0.4.32,<2.0.0', 'azure-common~=1.1', ], extras_require={