forked from Azure/azure-sdk-for-python
-
Notifications
You must be signed in to change notification settings - Fork 2
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
CodeGen from PR 13146 in Azure/azure-rest-api-specs
[Datadog] Swagger correctness (Azure#13146)
- Loading branch information
SDKAuto
committed
Feb 25, 2021
1 parent
73315fe
commit a63cce1
Showing
24 changed files
with
4,312 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,5 @@ | ||
# Release History | ||
|
||
## 0.1.0 (1970-01-01) | ||
|
||
* Initial Release |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,5 @@ | ||
recursive-include tests *.py *.yaml | ||
include *.md | ||
include azure/__init__.py | ||
include azure/mgmt/__init__.py | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,21 @@ | ||
# Microsoft Azure SDK for Python | ||
|
||
This is the Microsoft Azure MyService Management Client Library. | ||
This package has been tested with Python 2.7, 3.5, 3.6, 3.7 and 3.8. | ||
For a more complete view of Azure libraries, see the [azure sdk python release](https://aka.ms/azsdk/python/all). | ||
|
||
|
||
# Usage | ||
|
||
For code examples, see [MyService Management](https://docs.microsoft.com/python/api/overview/azure/) | ||
on docs.microsoft.com. | ||
|
||
|
||
# Provide Feedback | ||
|
||
If you encounter any bugs or have suggestions, please file an issue in the | ||
[Issues](https://github.com/Azure/azure-sdk-for-python/issues) | ||
section of the project. | ||
|
||
|
||
![Impressions](https://azure-sdk-impressions.azurewebsites.net/api/impressions/azure-sdk-for-python%2Fazure-mgmt-datadog%2FREADME.png) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
__path__ = __import__('pkgutil').extend_path(__path__, __name__) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
__path__ = __import__('pkgutil').extend_path(__path__, __name__) |
19 changes: 19 additions & 0 deletions
19
sdk/datadog/azure-mgmt-datadog/azure/mgmt/datadog/__init__.py
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,19 @@ | ||
# 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 ._configuration import MicrosoftDatadogClientConfiguration | ||
from ._microsoft_datadog_client import MicrosoftDatadogClient | ||
__all__ = ['MicrosoftDatadogClient', 'MicrosoftDatadogClientConfiguration'] | ||
|
||
from .version import VERSION | ||
|
||
__version__ = VERSION | ||
|
48 changes: 48 additions & 0 deletions
48
sdk/datadog/azure-mgmt-datadog/azure/mgmt/datadog/_configuration.py
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -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 msrestazure import AzureConfiguration | ||
|
||
from .version import VERSION | ||
|
||
|
||
class MicrosoftDatadogClientConfiguration(AzureConfiguration): | ||
"""Configuration for MicrosoftDatadogClient | ||
Note that all parameters used to create this instance are saved as instance | ||
attributes. | ||
:param credentials: Credentials needed for the client to connect to Azure. | ||
:type credentials: :mod:`A msrestazure Credentials | ||
object<msrestazure.azure_active_directory>` | ||
:param subscription_id: The Microsoft Azure subscription ID. | ||
:type subscription_id: str | ||
:param str base_url: Service URL | ||
""" | ||
|
||
def __init__( | ||
self, credentials, subscription_id, base_url=None): | ||
|
||
if credentials is None: | ||
raise ValueError("Parameter 'credentials' must not be None.") | ||
if subscription_id is None: | ||
raise ValueError("Parameter 'subscription_id' must not be None.") | ||
if not base_url: | ||
base_url = 'https://management.azure.com' | ||
|
||
super(MicrosoftDatadogClientConfiguration, self).__init__(base_url) | ||
|
||
# Starting Autorest.Python 4.0.64, make connection pool activated by default | ||
self.keep_alive = True | ||
|
||
self.add_user_agent('azure-mgmt-datadog/{}'.format(VERSION)) | ||
self.add_user_agent('Azure-SDK-For-Python') | ||
|
||
self.credentials = credentials | ||
self.subscription_id = subscription_id |
69 changes: 69 additions & 0 deletions
69
sdk/datadog/azure-mgmt-datadog/azure/mgmt/datadog/_microsoft_datadog_client.py
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,69 @@ | ||
# 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 Serializer, Deserializer | ||
|
||
from ._configuration import MicrosoftDatadogClientConfiguration | ||
from .operations import MarketplaceAgreementsOperations | ||
from .operations import MonitorsOperations | ||
from .operations import Operations | ||
from .operations import TagRulesOperations | ||
from .operations import SingleSignOnConfigurationsOperations | ||
from . import models | ||
|
||
|
||
class MicrosoftDatadogClient(SDKClient): | ||
"""MicrosoftDatadogClient | ||
:ivar config: Configuration for client. | ||
:vartype config: MicrosoftDatadogClientConfiguration | ||
:ivar marketplace_agreements: MarketplaceAgreements operations | ||
:vartype marketplace_agreements: azure.mgmt.datadog.operations.MarketplaceAgreementsOperations | ||
:ivar monitors: Monitors operations | ||
:vartype monitors: azure.mgmt.datadog.operations.MonitorsOperations | ||
:ivar operations: Operations operations | ||
:vartype operations: azure.mgmt.datadog.operations.Operations | ||
:ivar tag_rules: TagRules operations | ||
:vartype tag_rules: azure.mgmt.datadog.operations.TagRulesOperations | ||
:ivar single_sign_on_configurations: SingleSignOnConfigurations operations | ||
:vartype single_sign_on_configurations: azure.mgmt.datadog.operations.SingleSignOnConfigurationsOperations | ||
:param credentials: Credentials needed for the client to connect to Azure. | ||
:type credentials: :mod:`A msrestazure Credentials | ||
object<msrestazure.azure_active_directory>` | ||
:param subscription_id: The Microsoft Azure subscription ID. | ||
:type subscription_id: str | ||
:param str base_url: Service URL | ||
""" | ||
|
||
def __init__( | ||
self, credentials, subscription_id, base_url=None): | ||
|
||
self.config = MicrosoftDatadogClientConfiguration(credentials, subscription_id, base_url) | ||
super(MicrosoftDatadogClient, 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 = '2020-02-01-preview' | ||
self._serialize = Serializer(client_models) | ||
self._deserialize = Deserializer(client_models) | ||
|
||
self.marketplace_agreements = MarketplaceAgreementsOperations( | ||
self._client, self.config, self._serialize, self._deserialize) | ||
self.monitors = MonitorsOperations( | ||
self._client, self.config, self._serialize, self._deserialize) | ||
self.operations = Operations( | ||
self._client, self.config, self._serialize, self._deserialize) | ||
self.tag_rules = TagRulesOperations( | ||
self._client, self.config, self._serialize, self._deserialize) | ||
self.single_sign_on_configurations = SingleSignOnConfigurationsOperations( | ||
self._client, self.config, self._serialize, self._deserialize) |
137 changes: 137 additions & 0 deletions
137
sdk/datadog/azure-mgmt-datadog/azure/mgmt/datadog/models/__init__.py
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,137 @@ | ||
# 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 ._models_py3 import DatadogAgreementProperties | ||
from ._models_py3 import DatadogAgreementResource | ||
from ._models_py3 import DatadogApiKey | ||
from ._models_py3 import DatadogHost | ||
from ._models_py3 import DatadogHostMetadata | ||
from ._models_py3 import DatadogInstallMethod | ||
from ._models_py3 import DatadogLogsAgent | ||
from ._models_py3 import DatadogMonitorResource | ||
from ._models_py3 import DatadogMonitorResourceUpdateParameters | ||
from ._models_py3 import DatadogOrganizationProperties | ||
from ._models_py3 import DatadogSetPasswordLink | ||
from ._models_py3 import DatadogSingleSignOnProperties | ||
from ._models_py3 import DatadogSingleSignOnResource | ||
from ._models_py3 import ErrorResponseBody | ||
from ._models_py3 import FilteringTag | ||
from ._models_py3 import IdentityProperties | ||
from ._models_py3 import LinkedResource | ||
from ._models_py3 import LogRules | ||
from ._models_py3 import MetricRules | ||
from ._models_py3 import MonitoredResource | ||
from ._models_py3 import MonitoringTagRules | ||
from ._models_py3 import MonitoringTagRulesProperties | ||
from ._models_py3 import MonitorProperties | ||
from ._models_py3 import MonitorUpdateProperties | ||
from ._models_py3 import OperationDisplay | ||
from ._models_py3 import OperationResult | ||
from ._models_py3 import ResourceProviderDefaultErrorResponse, ResourceProviderDefaultErrorResponseException | ||
from ._models_py3 import ResourceSku | ||
from ._models_py3 import UserInfo | ||
except (SyntaxError, ImportError): | ||
from ._models import DatadogAgreementProperties | ||
from ._models import DatadogAgreementResource | ||
from ._models import DatadogApiKey | ||
from ._models import DatadogHost | ||
from ._models import DatadogHostMetadata | ||
from ._models import DatadogInstallMethod | ||
from ._models import DatadogLogsAgent | ||
from ._models import DatadogMonitorResource | ||
from ._models import DatadogMonitorResourceUpdateParameters | ||
from ._models import DatadogOrganizationProperties | ||
from ._models import DatadogSetPasswordLink | ||
from ._models import DatadogSingleSignOnProperties | ||
from ._models import DatadogSingleSignOnResource | ||
from ._models import ErrorResponseBody | ||
from ._models import FilteringTag | ||
from ._models import IdentityProperties | ||
from ._models import LinkedResource | ||
from ._models import LogRules | ||
from ._models import MetricRules | ||
from ._models import MonitoredResource | ||
from ._models import MonitoringTagRules | ||
from ._models import MonitoringTagRulesProperties | ||
from ._models import MonitorProperties | ||
from ._models import MonitorUpdateProperties | ||
from ._models import OperationDisplay | ||
from ._models import OperationResult | ||
from ._models import ResourceProviderDefaultErrorResponse, ResourceProviderDefaultErrorResponseException | ||
from ._models import ResourceSku | ||
from ._models import UserInfo | ||
from ._paged_models import DatadogAgreementResourcePaged | ||
from ._paged_models import DatadogApiKeyPaged | ||
from ._paged_models import DatadogHostPaged | ||
from ._paged_models import DatadogMonitorResourcePaged | ||
from ._paged_models import DatadogSingleSignOnResourcePaged | ||
from ._paged_models import LinkedResourcePaged | ||
from ._paged_models import MonitoredResourcePaged | ||
from ._paged_models import MonitoringTagRulesPaged | ||
from ._paged_models import OperationResultPaged | ||
from ._microsoft_datadog_client_enums import ( | ||
ProvisioningState, | ||
MonitoringStatus, | ||
MarketplaceSubscriptionStatus, | ||
LiftrResourceCategories, | ||
ManagedIdentityTypes, | ||
TagAction, | ||
SingleSignOnStates, | ||
) | ||
|
||
__all__ = [ | ||
'DatadogAgreementProperties', | ||
'DatadogAgreementResource', | ||
'DatadogApiKey', | ||
'DatadogHost', | ||
'DatadogHostMetadata', | ||
'DatadogInstallMethod', | ||
'DatadogLogsAgent', | ||
'DatadogMonitorResource', | ||
'DatadogMonitorResourceUpdateParameters', | ||
'DatadogOrganizationProperties', | ||
'DatadogSetPasswordLink', | ||
'DatadogSingleSignOnProperties', | ||
'DatadogSingleSignOnResource', | ||
'ErrorResponseBody', | ||
'FilteringTag', | ||
'IdentityProperties', | ||
'LinkedResource', | ||
'LogRules', | ||
'MetricRules', | ||
'MonitoredResource', | ||
'MonitoringTagRules', | ||
'MonitoringTagRulesProperties', | ||
'MonitorProperties', | ||
'MonitorUpdateProperties', | ||
'OperationDisplay', | ||
'OperationResult', | ||
'ResourceProviderDefaultErrorResponse', 'ResourceProviderDefaultErrorResponseException', | ||
'ResourceSku', | ||
'UserInfo', | ||
'DatadogAgreementResourcePaged', | ||
'DatadogApiKeyPaged', | ||
'DatadogHostPaged', | ||
'LinkedResourcePaged', | ||
'MonitoredResourcePaged', | ||
'DatadogMonitorResourcePaged', | ||
'OperationResultPaged', | ||
'MonitoringTagRulesPaged', | ||
'DatadogSingleSignOnResourcePaged', | ||
'ProvisioningState', | ||
'MonitoringStatus', | ||
'MarketplaceSubscriptionStatus', | ||
'LiftrResourceCategories', | ||
'ManagedIdentityTypes', | ||
'TagAction', | ||
'SingleSignOnStates', | ||
] |
65 changes: 65 additions & 0 deletions
65
sdk/datadog/azure-mgmt-datadog/azure/mgmt/datadog/models/_microsoft_datadog_client_enums.py
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,65 @@ | ||
# 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 ProvisioningState(str, Enum): | ||
|
||
accepted = "Accepted" | ||
creating = "Creating" | ||
updating = "Updating" | ||
deleting = "Deleting" | ||
succeeded = "Succeeded" | ||
failed = "Failed" | ||
canceled = "Canceled" | ||
deleted = "Deleted" | ||
not_specified = "NotSpecified" | ||
|
||
|
||
class MonitoringStatus(str, Enum): | ||
|
||
enabled = "Enabled" | ||
disabled = "Disabled" | ||
|
||
|
||
class MarketplaceSubscriptionStatus(str, Enum): | ||
|
||
provisioning = "Provisioning" | ||
active = "Active" | ||
suspended = "Suspended" | ||
unsubscribed = "Unsubscribed" | ||
|
||
|
||
class LiftrResourceCategories(str, Enum): | ||
|
||
unknown = "Unknown" | ||
monitor_logs = "MonitorLogs" | ||
|
||
|
||
class ManagedIdentityTypes(str, Enum): | ||
|
||
system_assigned = "SystemAssigned" | ||
user_assigned = "UserAssigned" | ||
|
||
|
||
class TagAction(str, Enum): | ||
|
||
include = "Include" | ||
exclude = "Exclude" | ||
|
||
|
||
class SingleSignOnStates(str, Enum): | ||
|
||
initial = "Initial" | ||
enable = "Enable" | ||
disable = "Disable" | ||
existing = "Existing" |
Oops, something went wrong.