diff --git a/sdk/confluent/azure-mgmt-confluent/azure/mgmt/confluent/__init__.py b/sdk/confluent/azure-mgmt-confluent/azure/mgmt/confluent/__init__.py new file mode 100644 index 000000000000..57524f6a364f --- /dev/null +++ b/sdk/confluent/azure-mgmt-confluent/azure/mgmt/confluent/__init__.py @@ -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 ConfluentManagementClientConfiguration +from ._confluent_management_client import ConfluentManagementClient +__all__ = ['ConfluentManagementClient', 'ConfluentManagementClientConfiguration'] + +from .version import VERSION + +__version__ = VERSION + diff --git a/sdk/confluent/azure-mgmt-confluent/azure/mgmt/confluent/_configuration.py b/sdk/confluent/azure-mgmt-confluent/azure/mgmt/confluent/_configuration.py new file mode 100644 index 000000000000..de13678e2568 --- /dev/null +++ b/sdk/confluent/azure-mgmt-confluent/azure/mgmt/confluent/_configuration.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 msrestazure import AzureConfiguration + +from .version import VERSION + + +class ConfluentManagementClientConfiguration(AzureConfiguration): + """Configuration for ConfluentManagementClient + 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` + :param subscription_id: 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(ConfluentManagementClientConfiguration, 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-confluent/{}'.format(VERSION)) + self.add_user_agent('Azure-SDK-For-Python') + + self.credentials = credentials + self.subscription_id = subscription_id diff --git a/sdk/confluent/azure-mgmt-confluent/azure/mgmt/confluent/_confluent_management_client.py b/sdk/confluent/azure-mgmt-confluent/azure/mgmt/confluent/_confluent_management_client.py new file mode 100644 index 000000000000..484d95a43bfd --- /dev/null +++ b/sdk/confluent/azure-mgmt-confluent/azure/mgmt/confluent/_confluent_management_client.py @@ -0,0 +1,59 @@ +# 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 ConfluentManagementClientConfiguration +from .operations import MarketplaceAgreementsOperations +from .operations import OrganizationOperations +from .operations import OrganizationOperationsOperations +from . import models + + +class ConfluentManagementClient(SDKClient): + """ConfluentManagementClient + + :ivar config: Configuration for client. + :vartype config: ConfluentManagementClientConfiguration + + :ivar marketplace_agreements: MarketplaceAgreements operations + :vartype marketplace_agreements: azure.mgmt.confluent.operations.MarketplaceAgreementsOperations + :ivar organization_operations: OrganizationOperations operations + :vartype organization_operations: azure.mgmt.confluent.operations.OrganizationOperations + :ivar organization: Organization operations + :vartype organization: azure.mgmt.confluent.operations.OrganizationOperationsOperations + + :param credentials: Credentials needed for the client to connect to Azure. + :type credentials: :mod:`A msrestazure Credentials + object` + :param subscription_id: 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 = ConfluentManagementClientConfiguration(credentials, subscription_id, base_url) + super(ConfluentManagementClient, 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-03-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.organization_operations = OrganizationOperations( + self._client, self.config, self._serialize, self._deserialize) + self.organization = OrganizationOperationsOperations( + self._client, self.config, self._serialize, self._deserialize) diff --git a/sdk/confluent/azure-mgmt-confluent/azure/mgmt/confluent/models/__init__.py b/sdk/confluent/azure-mgmt-confluent/azure/mgmt/confluent/models/__init__.py new file mode 100644 index 000000000000..f7fbacb43811 --- /dev/null +++ b/sdk/confluent/azure-mgmt-confluent/azure/mgmt/confluent/models/__init__.py @@ -0,0 +1,67 @@ +# 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 ConfluentAgreementProperties + from ._models_py3 import ConfluentAgreementResource + from ._models_py3 import ErrorResponseBody + from ._models_py3 import OfferDetail + from ._models_py3 import OperationDisplay + from ._models_py3 import OperationResult + from ._models_py3 import OrganizationResource + from ._models_py3 import OrganizationResourceProperties + from ._models_py3 import OrganizationResourcePropertiesOfferDetail + from ._models_py3 import OrganizationResourcePropertiesUserDetail + from ._models_py3 import OrganizationResourceUpdate + from ._models_py3 import ResourceProviderDefaultErrorResponse, ResourceProviderDefaultErrorResponseException + from ._models_py3 import UserDetail +except (SyntaxError, ImportError): + from ._models import ConfluentAgreementProperties + from ._models import ConfluentAgreementResource + from ._models import ErrorResponseBody + from ._models import OfferDetail + from ._models import OperationDisplay + from ._models import OperationResult + from ._models import OrganizationResource + from ._models import OrganizationResourceProperties + from ._models import OrganizationResourcePropertiesOfferDetail + from ._models import OrganizationResourcePropertiesUserDetail + from ._models import OrganizationResourceUpdate + from ._models import ResourceProviderDefaultErrorResponse, ResourceProviderDefaultErrorResponseException + from ._models import UserDetail +from ._paged_models import ConfluentAgreementResourcePaged +from ._paged_models import OperationResultPaged +from ._paged_models import OrganizationResourcePaged +from ._confluent_management_client_enums import ( + ProvisionState, + SaaSOfferStatus, +) + +__all__ = [ + 'ConfluentAgreementProperties', + 'ConfluentAgreementResource', + 'ErrorResponseBody', + 'OfferDetail', + 'OperationDisplay', + 'OperationResult', + 'OrganizationResource', + 'OrganizationResourceProperties', + 'OrganizationResourcePropertiesOfferDetail', + 'OrganizationResourcePropertiesUserDetail', + 'OrganizationResourceUpdate', + 'ResourceProviderDefaultErrorResponse', 'ResourceProviderDefaultErrorResponseException', + 'UserDetail', + 'ConfluentAgreementResourcePaged', + 'OperationResultPaged', + 'OrganizationResourcePaged', + 'ProvisionState', + 'SaaSOfferStatus', +] diff --git a/sdk/confluent/azure-mgmt-confluent/azure/mgmt/confluent/models/_confluent_management_client_enums.py b/sdk/confluent/azure-mgmt-confluent/azure/mgmt/confluent/models/_confluent_management_client_enums.py new file mode 100644 index 000000000000..35229395cc3c --- /dev/null +++ b/sdk/confluent/azure-mgmt-confluent/azure/mgmt/confluent/models/_confluent_management_client_enums.py @@ -0,0 +1,39 @@ +# 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 ProvisionState(str, Enum): + + accepted = "Accepted" + creating = "Creating" + updating = "Updating" + deleting = "Deleting" + succeeded = "Succeeded" + failed = "Failed" + canceled = "Canceled" + deleted = "Deleted" + not_specified = "NotSpecified" + + +class SaaSOfferStatus(str, Enum): + + started = "Started" + pending_fulfillment_start = "PendingFulfillmentStart" + in_progress = "InProgress" + subscribed = "Subscribed" + suspended = "Suspended" + reinstated = "Reinstated" + succeeded = "Succeeded" + failed = "Failed" + unsubscribed = "Unsubscribed" + updating = "Updating" diff --git a/sdk/confluent/azure-mgmt-confluent/azure/mgmt/confluent/models/_models.py b/sdk/confluent/azure-mgmt-confluent/azure/mgmt/confluent/models/_models.py new file mode 100644 index 000000000000..57251b0a9b56 --- /dev/null +++ b/sdk/confluent/azure-mgmt-confluent/azure/mgmt/confluent/models/_models.py @@ -0,0 +1,513 @@ +# 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 CloudError(Model): + """CloudError. + """ + + _attribute_map = { + } + + +class ConfluentAgreementProperties(Model): + """Terms properties for Marketplace and Confluent. + + :param publisher: Publisher identifier string. + :type publisher: str + :param product: Product identifier string. + :type product: str + :param plan: Plan identifier string. + :type plan: str + :param license_text_link: Link to HTML with Microsoft and Publisher terms. + :type license_text_link: str + :param privacy_policy_link: Link to the privacy policy of the publisher. + :type privacy_policy_link: str + :param retrieve_datetime: Date and time in UTC of when the terms were + accepted. This is empty if Accepted is false. + :type retrieve_datetime: datetime + :param signature: Terms signature. + :type signature: str + :param accepted: If any version of the terms have been accepted, otherwise + false. + :type accepted: bool + """ + + _attribute_map = { + 'publisher': {'key': 'publisher', 'type': 'str'}, + 'product': {'key': 'product', 'type': 'str'}, + 'plan': {'key': 'plan', 'type': 'str'}, + 'license_text_link': {'key': 'licenseTextLink', 'type': 'str'}, + 'privacy_policy_link': {'key': 'privacyPolicyLink', 'type': 'str'}, + 'retrieve_datetime': {'key': 'retrieveDatetime', 'type': 'iso-8601'}, + 'signature': {'key': 'signature', 'type': 'str'}, + 'accepted': {'key': 'accepted', 'type': 'bool'}, + } + + def __init__(self, **kwargs): + super(ConfluentAgreementProperties, self).__init__(**kwargs) + self.publisher = kwargs.get('publisher', None) + self.product = kwargs.get('product', None) + self.plan = kwargs.get('plan', None) + self.license_text_link = kwargs.get('license_text_link', None) + self.privacy_policy_link = kwargs.get('privacy_policy_link', None) + self.retrieve_datetime = kwargs.get('retrieve_datetime', None) + self.signature = kwargs.get('signature', None) + self.accepted = kwargs.get('accepted', None) + + +class ConfluentAgreementResource(Model): + """Agreement Terms definition. + + Variables are only populated by the server, and will be ignored when + sending a request. + + :ivar id: The ARM id of the resource. + :vartype id: str + :ivar name: The name of the agreement. + :vartype name: str + :ivar type: The type of the agreement. + :vartype type: str + :param properties: Represents the properties of the resource. + :type properties: + ~azure.mgmt.confluent.models.ConfluentAgreementProperties + """ + + _validation = { + 'id': {'readonly': True}, + 'name': {'readonly': True}, + 'type': {'readonly': True}, + } + + _attribute_map = { + 'id': {'key': 'id', 'type': 'str'}, + 'name': {'key': 'name', 'type': 'str'}, + 'type': {'key': 'type', 'type': 'str'}, + 'properties': {'key': 'properties', 'type': 'ConfluentAgreementProperties'}, + } + + def __init__(self, **kwargs): + super(ConfluentAgreementResource, self).__init__(**kwargs) + self.id = None + self.name = None + self.type = None + self.properties = kwargs.get('properties', None) + + +class ErrorResponseBody(Model): + """ErrorResponseBody. + + Response body of Error. + + Variables are only populated by the server, and will be ignored when + sending a request. + + :ivar code: Error code + :vartype code: str + :ivar message: Error message + :vartype message: str + :ivar target: Error target + :vartype target: str + :ivar details: Error detail + :vartype details: list[~azure.mgmt.confluent.models.ErrorResponseBody] + """ + + _validation = { + 'code': {'readonly': True}, + 'message': {'readonly': True}, + 'target': {'readonly': True}, + 'details': {'readonly': True}, + } + + _attribute_map = { + 'code': {'key': 'code', 'type': 'str'}, + 'message': {'key': 'message', 'type': 'str'}, + 'target': {'key': 'target', 'type': 'str'}, + 'details': {'key': 'details', 'type': '[ErrorResponseBody]'}, + } + + def __init__(self, **kwargs): + super(ErrorResponseBody, self).__init__(**kwargs) + self.code = None + self.message = None + self.target = None + self.details = None + + +class OfferDetail(Model): + """Confluent Offer detail. + + :param publisher_id: Publisher Id + :type publisher_id: str + :param id: Offer Id + :type id: str + :param plan_id: Offer Plan Id + :type plan_id: str + :param plan_name: Offer Plan Name + :type plan_name: str + :param term_unit: Offer Plan Term unit + :type term_unit: str + :param status: SaaS Offer Status. Possible values include: 'Started', + 'PendingFulfillmentStart', 'InProgress', 'Subscribed', 'Suspended', + 'Reinstated', 'Succeeded', 'Failed', 'Unsubscribed', 'Updating' + :type status: str or ~azure.mgmt.confluent.models.SaaSOfferStatus + """ + + _validation = { + 'publisher_id': {'max_length': 50}, + 'id': {'max_length': 50}, + 'plan_id': {'max_length': 50}, + 'plan_name': {'max_length': 50}, + 'term_unit': {'max_length': 25}, + } + + _attribute_map = { + 'publisher_id': {'key': 'publisherId', 'type': 'str'}, + 'id': {'key': 'id', 'type': 'str'}, + 'plan_id': {'key': 'planId', 'type': 'str'}, + 'plan_name': {'key': 'planName', 'type': 'str'}, + 'term_unit': {'key': 'termUnit', 'type': 'str'}, + 'status': {'key': 'status', 'type': 'str'}, + } + + def __init__(self, **kwargs): + super(OfferDetail, self).__init__(**kwargs) + self.publisher_id = kwargs.get('publisher_id', None) + self.id = kwargs.get('id', None) + self.plan_id = kwargs.get('plan_id', None) + self.plan_name = kwargs.get('plan_name', None) + self.term_unit = kwargs.get('term_unit', None) + self.status = kwargs.get('status', None) + + +class OperationDisplay(Model): + """The object that represents the operation. + + :param provider: Service provider: Microsoft.Confluent + :type provider: str + :param resource: Type on which the operation is performed, e.g., + 'clusters'. + :type resource: str + :param operation: Operation type, e.g., read, write, delete, etc. + :type operation: str + :param description: Description of the operation, e.g., 'Write confluent'. + :type description: str + """ + + _attribute_map = { + 'provider': {'key': 'provider', 'type': 'str'}, + 'resource': {'key': 'resource', 'type': 'str'}, + 'operation': {'key': 'operation', 'type': 'str'}, + 'description': {'key': 'description', 'type': 'str'}, + } + + def __init__(self, **kwargs): + super(OperationDisplay, self).__init__(**kwargs) + self.provider = kwargs.get('provider', None) + self.resource = kwargs.get('resource', None) + self.operation = kwargs.get('operation', None) + self.description = kwargs.get('description', None) + + +class OperationResult(Model): + """An Confluent REST API operation. + + :param name: Operation name: {provider}/{resource}/{operation} + :type name: str + :param display: The object that represents the operation. + :type display: ~azure.mgmt.confluent.models.OperationDisplay + """ + + _attribute_map = { + 'name': {'key': 'name', 'type': 'str'}, + 'display': {'key': 'display', 'type': 'OperationDisplay'}, + } + + def __init__(self, **kwargs): + super(OperationResult, self).__init__(**kwargs) + self.name = kwargs.get('name', None) + self.display = kwargs.get('display', None) + + +class OrganizationResource(Model): + """Organization resource. + + Variables are only populated by the server, and will be ignored when + sending a request. + + :ivar id: The ARM id of the resource. + :vartype id: str + :ivar name: The name of the resource. + :vartype name: str + :ivar type: The type of the resource. + :vartype type: str + :ivar created_time: The creation time of the resource. + :vartype created_time: datetime + :param provisioning_state: Provision states for confluent RP. Possible + values include: 'Accepted', 'Creating', 'Updating', 'Deleting', + 'Succeeded', 'Failed', 'Canceled', 'Deleted', 'NotSpecified' + :type provisioning_state: str or + ~azure.mgmt.confluent.models.ProvisionState + :ivar organization_id: Id of the Confluent organization. + :vartype organization_id: str + :ivar sso_url: SSO url for the Confluent organization. + :vartype sso_url: str + :param offer_detail: Confluent offer detail + :type offer_detail: + ~azure.mgmt.confluent.models.OrganizationResourcePropertiesOfferDetail + :param user_detail: Subscriber detail + :type user_detail: + ~azure.mgmt.confluent.models.OrganizationResourcePropertiesUserDetail + :param tags: Organization resource tags + :type tags: dict[str, str] + :param location: Location of Organization resource + :type location: str + """ + + _validation = { + 'id': {'readonly': True}, + 'name': {'readonly': True}, + 'type': {'readonly': True}, + 'created_time': {'readonly': True}, + 'organization_id': {'readonly': True}, + 'sso_url': {'readonly': True}, + } + + _attribute_map = { + 'id': {'key': 'id', 'type': 'str'}, + 'name': {'key': 'name', 'type': 'str'}, + 'type': {'key': 'type', 'type': 'str'}, + 'created_time': {'key': 'properties.createdTime', 'type': 'iso-8601'}, + 'provisioning_state': {'key': 'properties.provisioningState', 'type': 'str'}, + 'organization_id': {'key': 'properties.organizationId', 'type': 'str'}, + 'sso_url': {'key': 'properties.ssoUrl', 'type': 'str'}, + 'offer_detail': {'key': 'properties.offerDetail', 'type': 'OrganizationResourcePropertiesOfferDetail'}, + 'user_detail': {'key': 'properties.userDetail', 'type': 'OrganizationResourcePropertiesUserDetail'}, + 'tags': {'key': 'tags', 'type': '{str}'}, + 'location': {'key': 'location', 'type': 'str'}, + } + + def __init__(self, **kwargs): + super(OrganizationResource, self).__init__(**kwargs) + self.id = None + self.name = None + self.type = None + self.created_time = None + self.provisioning_state = kwargs.get('provisioning_state', None) + self.organization_id = None + self.sso_url = None + self.offer_detail = kwargs.get('offer_detail', None) + self.user_detail = kwargs.get('user_detail', None) + self.tags = kwargs.get('tags', None) + self.location = kwargs.get('location', None) + + +class OrganizationResourceProperties(Model): + """Organization resource property. + + Variables are only populated by the server, and will be ignored when + sending a request. + + :ivar created_time: The creation time of the resource. + :vartype created_time: datetime + :param provisioning_state: Provision states for confluent RP. Possible + values include: 'Accepted', 'Creating', 'Updating', 'Deleting', + 'Succeeded', 'Failed', 'Canceled', 'Deleted', 'NotSpecified' + :type provisioning_state: str or + ~azure.mgmt.confluent.models.ProvisionState + :ivar organization_id: Id of the Confluent organization. + :vartype organization_id: str + :ivar sso_url: SSO url for the Confluent organization. + :vartype sso_url: str + :param offer_detail: Confluent offer detail + :type offer_detail: + ~azure.mgmt.confluent.models.OrganizationResourcePropertiesOfferDetail + :param user_detail: Subscriber detail + :type user_detail: + ~azure.mgmt.confluent.models.OrganizationResourcePropertiesUserDetail + """ + + _validation = { + 'created_time': {'readonly': True}, + 'organization_id': {'readonly': True}, + 'sso_url': {'readonly': True}, + } + + _attribute_map = { + 'created_time': {'key': 'createdTime', 'type': 'iso-8601'}, + 'provisioning_state': {'key': 'provisioningState', 'type': 'str'}, + 'organization_id': {'key': 'organizationId', 'type': 'str'}, + 'sso_url': {'key': 'ssoUrl', 'type': 'str'}, + 'offer_detail': {'key': 'offerDetail', 'type': 'OrganizationResourcePropertiesOfferDetail'}, + 'user_detail': {'key': 'userDetail', 'type': 'OrganizationResourcePropertiesUserDetail'}, + } + + def __init__(self, **kwargs): + super(OrganizationResourceProperties, self).__init__(**kwargs) + self.created_time = None + self.provisioning_state = kwargs.get('provisioning_state', None) + self.organization_id = None + self.sso_url = None + self.offer_detail = kwargs.get('offer_detail', None) + self.user_detail = kwargs.get('user_detail', None) + + +class OrganizationResourcePropertiesOfferDetail(OfferDetail): + """Confluent offer detail. + + :param publisher_id: Publisher Id + :type publisher_id: str + :param id: Offer Id + :type id: str + :param plan_id: Offer Plan Id + :type plan_id: str + :param plan_name: Offer Plan Name + :type plan_name: str + :param term_unit: Offer Plan Term unit + :type term_unit: str + :param status: SaaS Offer Status. Possible values include: 'Started', + 'PendingFulfillmentStart', 'InProgress', 'Subscribed', 'Suspended', + 'Reinstated', 'Succeeded', 'Failed', 'Unsubscribed', 'Updating' + :type status: str or ~azure.mgmt.confluent.models.SaaSOfferStatus + """ + + _validation = { + 'publisher_id': {'max_length': 50}, + 'id': {'max_length': 50}, + 'plan_id': {'max_length': 50}, + 'plan_name': {'max_length': 50}, + 'term_unit': {'max_length': 25}, + } + + _attribute_map = { + 'publisher_id': {'key': 'publisherId', 'type': 'str'}, + 'id': {'key': 'id', 'type': 'str'}, + 'plan_id': {'key': 'planId', 'type': 'str'}, + 'plan_name': {'key': 'planName', 'type': 'str'}, + 'term_unit': {'key': 'termUnit', 'type': 'str'}, + 'status': {'key': 'status', 'type': 'str'}, + } + + def __init__(self, **kwargs): + super(OrganizationResourcePropertiesOfferDetail, self).__init__(**kwargs) + + +class UserDetail(Model): + """Subscriber detail. + + :param first_name: First name + :type first_name: str + :param last_name: Last name + :type last_name: str + :param email_address: Email address + :type email_address: str + """ + + _validation = { + 'first_name': {'max_length': 50}, + 'last_name': {'max_length': 50}, + 'email_address': {'pattern': r'^\S+@\S+\.\S+$'}, + } + + _attribute_map = { + 'first_name': {'key': 'firstName', 'type': 'str'}, + 'last_name': {'key': 'lastName', 'type': 'str'}, + 'email_address': {'key': 'emailAddress', 'type': 'str'}, + } + + def __init__(self, **kwargs): + super(UserDetail, self).__init__(**kwargs) + self.first_name = kwargs.get('first_name', None) + self.last_name = kwargs.get('last_name', None) + self.email_address = kwargs.get('email_address', None) + + +class OrganizationResourcePropertiesUserDetail(UserDetail): + """Subscriber detail. + + :param first_name: First name + :type first_name: str + :param last_name: Last name + :type last_name: str + :param email_address: Email address + :type email_address: str + """ + + _validation = { + 'first_name': {'max_length': 50}, + 'last_name': {'max_length': 50}, + 'email_address': {'pattern': r'^\S+@\S+\.\S+$'}, + } + + _attribute_map = { + 'first_name': {'key': 'firstName', 'type': 'str'}, + 'last_name': {'key': 'lastName', 'type': 'str'}, + 'email_address': {'key': 'emailAddress', 'type': 'str'}, + } + + def __init__(self, **kwargs): + super(OrganizationResourcePropertiesUserDetail, self).__init__(**kwargs) + + +class OrganizationResourceUpdate(Model): + """Organization Resource update. + + :param tags: ARM resource tags + :type tags: dict[str, str] + """ + + _attribute_map = { + 'tags': {'key': 'tags', 'type': '{str}'}, + } + + def __init__(self, **kwargs): + super(OrganizationResourceUpdate, self).__init__(**kwargs) + self.tags = kwargs.get('tags', None) + + +class ResourceProviderDefaultErrorResponse(Model): + """ResourceProviderDefaultErrorResponse. + + Default error response for resource provider. + + Variables are only populated by the server, and will be ignored when + sending a request. + + :ivar error: Response body of Error + :vartype error: ~azure.mgmt.confluent.models.ErrorResponseBody + """ + + _validation = { + 'error': {'readonly': True}, + } + + _attribute_map = { + 'error': {'key': 'error', 'type': 'ErrorResponseBody'}, + } + + def __init__(self, **kwargs): + super(ResourceProviderDefaultErrorResponse, self).__init__(**kwargs) + self.error = None + + +class ResourceProviderDefaultErrorResponseException(HttpOperationError): + """Server responsed with exception of type: 'ResourceProviderDefaultErrorResponse'. + + :param deserialize: A deserializer + :param response: Server response to be deserialized. + """ + + def __init__(self, deserialize, response, *args): + + super(ResourceProviderDefaultErrorResponseException, self).__init__(deserialize, response, 'ResourceProviderDefaultErrorResponse', *args) diff --git a/sdk/confluent/azure-mgmt-confluent/azure/mgmt/confluent/models/_models_py3.py b/sdk/confluent/azure-mgmt-confluent/azure/mgmt/confluent/models/_models_py3.py new file mode 100644 index 000000000000..1b90e1ca29de --- /dev/null +++ b/sdk/confluent/azure-mgmt-confluent/azure/mgmt/confluent/models/_models_py3.py @@ -0,0 +1,513 @@ +# 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 CloudError(Model): + """CloudError. + """ + + _attribute_map = { + } + + +class ConfluentAgreementProperties(Model): + """Terms properties for Marketplace and Confluent. + + :param publisher: Publisher identifier string. + :type publisher: str + :param product: Product identifier string. + :type product: str + :param plan: Plan identifier string. + :type plan: str + :param license_text_link: Link to HTML with Microsoft and Publisher terms. + :type license_text_link: str + :param privacy_policy_link: Link to the privacy policy of the publisher. + :type privacy_policy_link: str + :param retrieve_datetime: Date and time in UTC of when the terms were + accepted. This is empty if Accepted is false. + :type retrieve_datetime: datetime + :param signature: Terms signature. + :type signature: str + :param accepted: If any version of the terms have been accepted, otherwise + false. + :type accepted: bool + """ + + _attribute_map = { + 'publisher': {'key': 'publisher', 'type': 'str'}, + 'product': {'key': 'product', 'type': 'str'}, + 'plan': {'key': 'plan', 'type': 'str'}, + 'license_text_link': {'key': 'licenseTextLink', 'type': 'str'}, + 'privacy_policy_link': {'key': 'privacyPolicyLink', 'type': 'str'}, + 'retrieve_datetime': {'key': 'retrieveDatetime', 'type': 'iso-8601'}, + 'signature': {'key': 'signature', 'type': 'str'}, + 'accepted': {'key': 'accepted', 'type': 'bool'}, + } + + def __init__(self, *, publisher: str=None, product: str=None, plan: str=None, license_text_link: str=None, privacy_policy_link: str=None, retrieve_datetime=None, signature: str=None, accepted: bool=None, **kwargs) -> None: + super(ConfluentAgreementProperties, self).__init__(**kwargs) + self.publisher = publisher + self.product = product + self.plan = plan + self.license_text_link = license_text_link + self.privacy_policy_link = privacy_policy_link + self.retrieve_datetime = retrieve_datetime + self.signature = signature + self.accepted = accepted + + +class ConfluentAgreementResource(Model): + """Agreement Terms definition. + + Variables are only populated by the server, and will be ignored when + sending a request. + + :ivar id: The ARM id of the resource. + :vartype id: str + :ivar name: The name of the agreement. + :vartype name: str + :ivar type: The type of the agreement. + :vartype type: str + :param properties: Represents the properties of the resource. + :type properties: + ~azure.mgmt.confluent.models.ConfluentAgreementProperties + """ + + _validation = { + 'id': {'readonly': True}, + 'name': {'readonly': True}, + 'type': {'readonly': True}, + } + + _attribute_map = { + 'id': {'key': 'id', 'type': 'str'}, + 'name': {'key': 'name', 'type': 'str'}, + 'type': {'key': 'type', 'type': 'str'}, + 'properties': {'key': 'properties', 'type': 'ConfluentAgreementProperties'}, + } + + def __init__(self, *, properties=None, **kwargs) -> None: + super(ConfluentAgreementResource, self).__init__(**kwargs) + self.id = None + self.name = None + self.type = None + self.properties = properties + + +class ErrorResponseBody(Model): + """ErrorResponseBody. + + Response body of Error. + + Variables are only populated by the server, and will be ignored when + sending a request. + + :ivar code: Error code + :vartype code: str + :ivar message: Error message + :vartype message: str + :ivar target: Error target + :vartype target: str + :ivar details: Error detail + :vartype details: list[~azure.mgmt.confluent.models.ErrorResponseBody] + """ + + _validation = { + 'code': {'readonly': True}, + 'message': {'readonly': True}, + 'target': {'readonly': True}, + 'details': {'readonly': True}, + } + + _attribute_map = { + 'code': {'key': 'code', 'type': 'str'}, + 'message': {'key': 'message', 'type': 'str'}, + 'target': {'key': 'target', 'type': 'str'}, + 'details': {'key': 'details', 'type': '[ErrorResponseBody]'}, + } + + def __init__(self, **kwargs) -> None: + super(ErrorResponseBody, self).__init__(**kwargs) + self.code = None + self.message = None + self.target = None + self.details = None + + +class OfferDetail(Model): + """Confluent Offer detail. + + :param publisher_id: Publisher Id + :type publisher_id: str + :param id: Offer Id + :type id: str + :param plan_id: Offer Plan Id + :type plan_id: str + :param plan_name: Offer Plan Name + :type plan_name: str + :param term_unit: Offer Plan Term unit + :type term_unit: str + :param status: SaaS Offer Status. Possible values include: 'Started', + 'PendingFulfillmentStart', 'InProgress', 'Subscribed', 'Suspended', + 'Reinstated', 'Succeeded', 'Failed', 'Unsubscribed', 'Updating' + :type status: str or ~azure.mgmt.confluent.models.SaaSOfferStatus + """ + + _validation = { + 'publisher_id': {'max_length': 50}, + 'id': {'max_length': 50}, + 'plan_id': {'max_length': 50}, + 'plan_name': {'max_length': 50}, + 'term_unit': {'max_length': 25}, + } + + _attribute_map = { + 'publisher_id': {'key': 'publisherId', 'type': 'str'}, + 'id': {'key': 'id', 'type': 'str'}, + 'plan_id': {'key': 'planId', 'type': 'str'}, + 'plan_name': {'key': 'planName', 'type': 'str'}, + 'term_unit': {'key': 'termUnit', 'type': 'str'}, + 'status': {'key': 'status', 'type': 'str'}, + } + + def __init__(self, *, publisher_id: str=None, id: str=None, plan_id: str=None, plan_name: str=None, term_unit: str=None, status=None, **kwargs) -> None: + super(OfferDetail, self).__init__(**kwargs) + self.publisher_id = publisher_id + self.id = id + self.plan_id = plan_id + self.plan_name = plan_name + self.term_unit = term_unit + self.status = status + + +class OperationDisplay(Model): + """The object that represents the operation. + + :param provider: Service provider: Microsoft.Confluent + :type provider: str + :param resource: Type on which the operation is performed, e.g., + 'clusters'. + :type resource: str + :param operation: Operation type, e.g., read, write, delete, etc. + :type operation: str + :param description: Description of the operation, e.g., 'Write confluent'. + :type description: str + """ + + _attribute_map = { + 'provider': {'key': 'provider', 'type': 'str'}, + 'resource': {'key': 'resource', 'type': 'str'}, + 'operation': {'key': 'operation', 'type': 'str'}, + 'description': {'key': 'description', 'type': 'str'}, + } + + def __init__(self, *, provider: str=None, resource: str=None, operation: str=None, description: str=None, **kwargs) -> None: + super(OperationDisplay, self).__init__(**kwargs) + self.provider = provider + self.resource = resource + self.operation = operation + self.description = description + + +class OperationResult(Model): + """An Confluent REST API operation. + + :param name: Operation name: {provider}/{resource}/{operation} + :type name: str + :param display: The object that represents the operation. + :type display: ~azure.mgmt.confluent.models.OperationDisplay + """ + + _attribute_map = { + 'name': {'key': 'name', 'type': 'str'}, + 'display': {'key': 'display', 'type': 'OperationDisplay'}, + } + + def __init__(self, *, name: str=None, display=None, **kwargs) -> None: + super(OperationResult, self).__init__(**kwargs) + self.name = name + self.display = display + + +class OrganizationResource(Model): + """Organization resource. + + Variables are only populated by the server, and will be ignored when + sending a request. + + :ivar id: The ARM id of the resource. + :vartype id: str + :ivar name: The name of the resource. + :vartype name: str + :ivar type: The type of the resource. + :vartype type: str + :ivar created_time: The creation time of the resource. + :vartype created_time: datetime + :param provisioning_state: Provision states for confluent RP. Possible + values include: 'Accepted', 'Creating', 'Updating', 'Deleting', + 'Succeeded', 'Failed', 'Canceled', 'Deleted', 'NotSpecified' + :type provisioning_state: str or + ~azure.mgmt.confluent.models.ProvisionState + :ivar organization_id: Id of the Confluent organization. + :vartype organization_id: str + :ivar sso_url: SSO url for the Confluent organization. + :vartype sso_url: str + :param offer_detail: Confluent offer detail + :type offer_detail: + ~azure.mgmt.confluent.models.OrganizationResourcePropertiesOfferDetail + :param user_detail: Subscriber detail + :type user_detail: + ~azure.mgmt.confluent.models.OrganizationResourcePropertiesUserDetail + :param tags: Organization resource tags + :type tags: dict[str, str] + :param location: Location of Organization resource + :type location: str + """ + + _validation = { + 'id': {'readonly': True}, + 'name': {'readonly': True}, + 'type': {'readonly': True}, + 'created_time': {'readonly': True}, + 'organization_id': {'readonly': True}, + 'sso_url': {'readonly': True}, + } + + _attribute_map = { + 'id': {'key': 'id', 'type': 'str'}, + 'name': {'key': 'name', 'type': 'str'}, + 'type': {'key': 'type', 'type': 'str'}, + 'created_time': {'key': 'properties.createdTime', 'type': 'iso-8601'}, + 'provisioning_state': {'key': 'properties.provisioningState', 'type': 'str'}, + 'organization_id': {'key': 'properties.organizationId', 'type': 'str'}, + 'sso_url': {'key': 'properties.ssoUrl', 'type': 'str'}, + 'offer_detail': {'key': 'properties.offerDetail', 'type': 'OrganizationResourcePropertiesOfferDetail'}, + 'user_detail': {'key': 'properties.userDetail', 'type': 'OrganizationResourcePropertiesUserDetail'}, + 'tags': {'key': 'tags', 'type': '{str}'}, + 'location': {'key': 'location', 'type': 'str'}, + } + + def __init__(self, *, provisioning_state=None, offer_detail=None, user_detail=None, tags=None, location: str=None, **kwargs) -> None: + super(OrganizationResource, self).__init__(**kwargs) + self.id = None + self.name = None + self.type = None + self.created_time = None + self.provisioning_state = provisioning_state + self.organization_id = None + self.sso_url = None + self.offer_detail = offer_detail + self.user_detail = user_detail + self.tags = tags + self.location = location + + +class OrganizationResourceProperties(Model): + """Organization resource property. + + Variables are only populated by the server, and will be ignored when + sending a request. + + :ivar created_time: The creation time of the resource. + :vartype created_time: datetime + :param provisioning_state: Provision states for confluent RP. Possible + values include: 'Accepted', 'Creating', 'Updating', 'Deleting', + 'Succeeded', 'Failed', 'Canceled', 'Deleted', 'NotSpecified' + :type provisioning_state: str or + ~azure.mgmt.confluent.models.ProvisionState + :ivar organization_id: Id of the Confluent organization. + :vartype organization_id: str + :ivar sso_url: SSO url for the Confluent organization. + :vartype sso_url: str + :param offer_detail: Confluent offer detail + :type offer_detail: + ~azure.mgmt.confluent.models.OrganizationResourcePropertiesOfferDetail + :param user_detail: Subscriber detail + :type user_detail: + ~azure.mgmt.confluent.models.OrganizationResourcePropertiesUserDetail + """ + + _validation = { + 'created_time': {'readonly': True}, + 'organization_id': {'readonly': True}, + 'sso_url': {'readonly': True}, + } + + _attribute_map = { + 'created_time': {'key': 'createdTime', 'type': 'iso-8601'}, + 'provisioning_state': {'key': 'provisioningState', 'type': 'str'}, + 'organization_id': {'key': 'organizationId', 'type': 'str'}, + 'sso_url': {'key': 'ssoUrl', 'type': 'str'}, + 'offer_detail': {'key': 'offerDetail', 'type': 'OrganizationResourcePropertiesOfferDetail'}, + 'user_detail': {'key': 'userDetail', 'type': 'OrganizationResourcePropertiesUserDetail'}, + } + + def __init__(self, *, provisioning_state=None, offer_detail=None, user_detail=None, **kwargs) -> None: + super(OrganizationResourceProperties, self).__init__(**kwargs) + self.created_time = None + self.provisioning_state = provisioning_state + self.organization_id = None + self.sso_url = None + self.offer_detail = offer_detail + self.user_detail = user_detail + + +class OrganizationResourcePropertiesOfferDetail(OfferDetail): + """Confluent offer detail. + + :param publisher_id: Publisher Id + :type publisher_id: str + :param id: Offer Id + :type id: str + :param plan_id: Offer Plan Id + :type plan_id: str + :param plan_name: Offer Plan Name + :type plan_name: str + :param term_unit: Offer Plan Term unit + :type term_unit: str + :param status: SaaS Offer Status. Possible values include: 'Started', + 'PendingFulfillmentStart', 'InProgress', 'Subscribed', 'Suspended', + 'Reinstated', 'Succeeded', 'Failed', 'Unsubscribed', 'Updating' + :type status: str or ~azure.mgmt.confluent.models.SaaSOfferStatus + """ + + _validation = { + 'publisher_id': {'max_length': 50}, + 'id': {'max_length': 50}, + 'plan_id': {'max_length': 50}, + 'plan_name': {'max_length': 50}, + 'term_unit': {'max_length': 25}, + } + + _attribute_map = { + 'publisher_id': {'key': 'publisherId', 'type': 'str'}, + 'id': {'key': 'id', 'type': 'str'}, + 'plan_id': {'key': 'planId', 'type': 'str'}, + 'plan_name': {'key': 'planName', 'type': 'str'}, + 'term_unit': {'key': 'termUnit', 'type': 'str'}, + 'status': {'key': 'status', 'type': 'str'}, + } + + def __init__(self, *, publisher_id: str=None, id: str=None, plan_id: str=None, plan_name: str=None, term_unit: str=None, status=None, **kwargs) -> None: + super(OrganizationResourcePropertiesOfferDetail, self).__init__(publisher_id=publisher_id, id=id, plan_id=plan_id, plan_name=plan_name, term_unit=term_unit, status=status, **kwargs) + + +class UserDetail(Model): + """Subscriber detail. + + :param first_name: First name + :type first_name: str + :param last_name: Last name + :type last_name: str + :param email_address: Email address + :type email_address: str + """ + + _validation = { + 'first_name': {'max_length': 50}, + 'last_name': {'max_length': 50}, + 'email_address': {'pattern': r'^\S+@\S+\.\S+$'}, + } + + _attribute_map = { + 'first_name': {'key': 'firstName', 'type': 'str'}, + 'last_name': {'key': 'lastName', 'type': 'str'}, + 'email_address': {'key': 'emailAddress', 'type': 'str'}, + } + + def __init__(self, *, first_name: str=None, last_name: str=None, email_address: str=None, **kwargs) -> None: + super(UserDetail, self).__init__(**kwargs) + self.first_name = first_name + self.last_name = last_name + self.email_address = email_address + + +class OrganizationResourcePropertiesUserDetail(UserDetail): + """Subscriber detail. + + :param first_name: First name + :type first_name: str + :param last_name: Last name + :type last_name: str + :param email_address: Email address + :type email_address: str + """ + + _validation = { + 'first_name': {'max_length': 50}, + 'last_name': {'max_length': 50}, + 'email_address': {'pattern': r'^\S+@\S+\.\S+$'}, + } + + _attribute_map = { + 'first_name': {'key': 'firstName', 'type': 'str'}, + 'last_name': {'key': 'lastName', 'type': 'str'}, + 'email_address': {'key': 'emailAddress', 'type': 'str'}, + } + + def __init__(self, *, first_name: str=None, last_name: str=None, email_address: str=None, **kwargs) -> None: + super(OrganizationResourcePropertiesUserDetail, self).__init__(first_name=first_name, last_name=last_name, email_address=email_address, **kwargs) + + +class OrganizationResourceUpdate(Model): + """Organization Resource update. + + :param tags: ARM resource tags + :type tags: dict[str, str] + """ + + _attribute_map = { + 'tags': {'key': 'tags', 'type': '{str}'}, + } + + def __init__(self, *, tags=None, **kwargs) -> None: + super(OrganizationResourceUpdate, self).__init__(**kwargs) + self.tags = tags + + +class ResourceProviderDefaultErrorResponse(Model): + """ResourceProviderDefaultErrorResponse. + + Default error response for resource provider. + + Variables are only populated by the server, and will be ignored when + sending a request. + + :ivar error: Response body of Error + :vartype error: ~azure.mgmt.confluent.models.ErrorResponseBody + """ + + _validation = { + 'error': {'readonly': True}, + } + + _attribute_map = { + 'error': {'key': 'error', 'type': 'ErrorResponseBody'}, + } + + def __init__(self, **kwargs) -> None: + super(ResourceProviderDefaultErrorResponse, self).__init__(**kwargs) + self.error = None + + +class ResourceProviderDefaultErrorResponseException(HttpOperationError): + """Server responsed with exception of type: 'ResourceProviderDefaultErrorResponse'. + + :param deserialize: A deserializer + :param response: Server response to be deserialized. + """ + + def __init__(self, deserialize, response, *args): + + super(ResourceProviderDefaultErrorResponseException, self).__init__(deserialize, response, 'ResourceProviderDefaultErrorResponse', *args) diff --git a/sdk/confluent/azure-mgmt-confluent/azure/mgmt/confluent/models/_paged_models.py b/sdk/confluent/azure-mgmt-confluent/azure/mgmt/confluent/models/_paged_models.py new file mode 100644 index 000000000000..1b350bb1e884 --- /dev/null +++ b/sdk/confluent/azure-mgmt-confluent/azure/mgmt/confluent/models/_paged_models.py @@ -0,0 +1,53 @@ +# 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.paging import Paged + + +class ConfluentAgreementResourcePaged(Paged): + """ + A paging container for iterating over a list of :class:`ConfluentAgreementResource ` object + """ + + _attribute_map = { + 'next_link': {'key': 'nextLink', 'type': 'str'}, + 'current_page': {'key': 'value', 'type': '[ConfluentAgreementResource]'} + } + + def __init__(self, *args, **kwargs): + + super(ConfluentAgreementResourcePaged, self).__init__(*args, **kwargs) +class OperationResultPaged(Paged): + """ + A paging container for iterating over a list of :class:`OperationResult ` object + """ + + _attribute_map = { + 'next_link': {'key': 'nextLink', 'type': 'str'}, + 'current_page': {'key': 'value', 'type': '[OperationResult]'} + } + + def __init__(self, *args, **kwargs): + + super(OperationResultPaged, self).__init__(*args, **kwargs) +class OrganizationResourcePaged(Paged): + """ + A paging container for iterating over a list of :class:`OrganizationResource ` object + """ + + _attribute_map = { + 'next_link': {'key': 'nextLink', 'type': 'str'}, + 'current_page': {'key': 'value', 'type': '[OrganizationResource]'} + } + + def __init__(self, *args, **kwargs): + + super(OrganizationResourcePaged, self).__init__(*args, **kwargs) diff --git a/sdk/confluent/azure-mgmt-confluent/azure/mgmt/confluent/operations/__init__.py b/sdk/confluent/azure-mgmt-confluent/azure/mgmt/confluent/operations/__init__.py new file mode 100644 index 000000000000..122f4f8ee827 --- /dev/null +++ b/sdk/confluent/azure-mgmt-confluent/azure/mgmt/confluent/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 ._marketplace_agreements_operations import MarketplaceAgreementsOperations +from ._organization_operations import OrganizationOperations +from ._organization_operations_operations import OrganizationOperationsOperations + +__all__ = [ + 'MarketplaceAgreementsOperations', + 'OrganizationOperations', + 'OrganizationOperationsOperations', +] diff --git a/sdk/confluent/azure-mgmt-confluent/azure/mgmt/confluent/operations/_marketplace_agreements_operations.py b/sdk/confluent/azure-mgmt-confluent/azure/mgmt/confluent/operations/_marketplace_agreements_operations.py new file mode 100644 index 000000000000..de1da06a5f13 --- /dev/null +++ b/sdk/confluent/azure-mgmt-confluent/azure/mgmt/confluent/operations/_marketplace_agreements_operations.py @@ -0,0 +1,168 @@ +# 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. +# -------------------------------------------------------------------------- + +import uuid +from msrest.pipeline import ClientRawResponse + +from .. import models + + +class MarketplaceAgreementsOperations(object): + """MarketplaceAgreementsOperations operations. + + You should not instantiate directly this class, but create a Client instance that will create it for you and attach it as attribute. + + :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 list( + self, custom_headers=None, raw=False, **operation_config): + """List Confluent marketplace agreements in the subscription. + + :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: An iterator like instance of ConfluentAgreementResource + :rtype: + ~azure.mgmt.confluent.models.ConfluentAgreementResourcePaged[~azure.mgmt.confluent.models.ConfluentAgreementResource] + :raises: + :class:`ResourceProviderDefaultErrorResponseException` + """ + def prepare_request(next_link=None): + if not next_link: + # Construct URL + url = self.list.metadata['url'] + path_format_arguments = { + 'subscriptionId': self._serialize.url("self.config.subscription_id", self.config.subscription_id, 'str') + } + url = self._client.format_url(url, **path_format_arguments) + + # Construct parameters + query_parameters = {} + + else: + url = next_link + query_parameters = {} + + # Construct headers + header_parameters = {} + header_parameters['Accept'] = 'application/json' + if self.config.generate_client_request_id: + header_parameters['x-ms-client-request-id'] = str(uuid.uuid1()) + if custom_headers: + header_parameters.update(custom_headers) + if self.config.accept_language is not None: + header_parameters['accept-language'] = self._serialize.header("self.config.accept_language", self.config.accept_language, 'str') + + # Construct and send request + request = self._client.get(url, query_parameters, header_parameters) + return request + + def internal_paging(next_link=None): + request = prepare_request(next_link) + + response = self._client.send(request, stream=False, **operation_config) + + if response.status_code not in [200]: + raise models.ResourceProviderDefaultErrorResponseException(self._deserialize, response) + + return response + + # Deserialize response + header_dict = None + if raw: + header_dict = {} + deserialized = models.ConfluentAgreementResourcePaged(internal_paging, self._deserialize.dependencies, header_dict) + + return deserialized + list.metadata = {'url': '/subscriptions/{subscriptionId}/providers/Microsoft.Confluent/agreements'} + + def create( + self, properties=None, custom_headers=None, raw=False, **operation_config): + """Create Confluent Marketplace agreement in the subscription. + + :param properties: Represents the properties of the resource. + :type properties: + ~azure.mgmt.confluent.models.ConfluentAgreementProperties + :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: ConfluentAgreementResource or ClientRawResponse if raw=true + :rtype: ~azure.mgmt.confluent.models.ConfluentAgreementResource or + ~msrest.pipeline.ClientRawResponse + :raises: + :class:`ResourceProviderDefaultErrorResponseException` + """ + body = None + if properties is not None: + body = models.ConfluentAgreementResource(properties=properties) + + # Construct URL + url = self.create.metadata['url'] + path_format_arguments = { + 'subscriptionId': self._serialize.url("self.config.subscription_id", self.config.subscription_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 self.config.generate_client_request_id: + header_parameters['x-ms-client-request-id'] = str(uuid.uuid1()) + if custom_headers: + header_parameters.update(custom_headers) + if self.config.accept_language is not None: + header_parameters['accept-language'] = self._serialize.header("self.config.accept_language", self.config.accept_language, 'str') + + # Construct body + if body is not None: + body_content = self._serialize.body(body, 'ConfluentAgreementResource') + else: + body_content = None + + # Construct and send request + request = self._client.put(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.ResourceProviderDefaultErrorResponseException(self._deserialize, response) + + deserialized = None + if response.status_code == 200: + deserialized = self._deserialize('ConfluentAgreementResource', response) + + if raw: + client_raw_response = ClientRawResponse(deserialized, response) + return client_raw_response + + return deserialized + create.metadata = {'url': '/subscriptions/{subscriptionId}/providers/Microsoft.Confluent/agreements/default'} diff --git a/sdk/confluent/azure-mgmt-confluent/azure/mgmt/confluent/operations/_organization_operations.py b/sdk/confluent/azure-mgmt-confluent/azure/mgmt/confluent/operations/_organization_operations.py new file mode 100644 index 000000000000..69f90fbd638e --- /dev/null +++ b/sdk/confluent/azure-mgmt-confluent/azure/mgmt/confluent/operations/_organization_operations.py @@ -0,0 +1,100 @@ +# 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. +# -------------------------------------------------------------------------- + +import uuid +from msrest.pipeline import ClientRawResponse + +from .. import models + + +class OrganizationOperations(object): + """OrganizationOperations operations. + + You should not instantiate directly this class, but create a Client instance that will create it for you and attach it as attribute. + + :param client: Client for service requests. + :param config: Configuration of service client. + :param serializer: An object model serializer. + :param deserializer: An object model deserializer. + :ivar api_version: Client Api Version. Constant value: "2020-03-01-preview". + """ + + models = models + + def __init__(self, client, config, serializer, deserializer): + + self._client = client + self._serialize = serializer + self._deserialize = deserializer + self.api_version = "2020-03-01-preview" + + self.config = config + + def list( + self, custom_headers=None, raw=False, **operation_config): + """List all operations provided by Microsoft.Confluent. + + :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: An iterator like instance of OperationResult + :rtype: + ~azure.mgmt.confluent.models.OperationResultPaged[~azure.mgmt.confluent.models.OperationResult] + :raises: + :class:`ResourceProviderDefaultErrorResponseException` + """ + def prepare_request(next_link=None): + if not next_link: + # Construct URL + url = self.list.metadata['url'] + + # Construct parameters + query_parameters = {} + query_parameters['api-version'] = self._serialize.query("self.api_version", self.api_version, 'str') + + else: + url = next_link + query_parameters = {} + + # Construct headers + header_parameters = {} + header_parameters['Accept'] = 'application/json' + if self.config.generate_client_request_id: + header_parameters['x-ms-client-request-id'] = str(uuid.uuid1()) + if custom_headers: + header_parameters.update(custom_headers) + if self.config.accept_language is not None: + header_parameters['accept-language'] = self._serialize.header("self.config.accept_language", self.config.accept_language, 'str') + + # Construct and send request + request = self._client.get(url, query_parameters, header_parameters) + return request + + def internal_paging(next_link=None): + request = prepare_request(next_link) + + response = self._client.send(request, stream=False, **operation_config) + + if response.status_code not in [200]: + raise models.ResourceProviderDefaultErrorResponseException(self._deserialize, response) + + return response + + # Deserialize response + header_dict = None + if raw: + header_dict = {} + deserialized = models.OperationResultPaged(internal_paging, self._deserialize.dependencies, header_dict) + + return deserialized + list.metadata = {'url': '/providers/Microsoft.Confluent/operations'} diff --git a/sdk/confluent/azure-mgmt-confluent/azure/mgmt/confluent/operations/_organization_operations_operations.py b/sdk/confluent/azure-mgmt-confluent/azure/mgmt/confluent/operations/_organization_operations_operations.py new file mode 100644 index 000000000000..bee69bd67776 --- /dev/null +++ b/sdk/confluent/azure-mgmt-confluent/azure/mgmt/confluent/operations/_organization_operations_operations.py @@ -0,0 +1,489 @@ +# 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. +# -------------------------------------------------------------------------- + +import uuid +from msrest.pipeline import ClientRawResponse +from msrest.polling import LROPoller, NoPolling +from msrestazure.polling.arm_polling import ARMPolling + +from .. import models + + +class OrganizationOperationsOperations(object): + """OrganizationOperationsOperations operations. + + You should not instantiate directly this class, but create a Client instance that will create it for you and attach it as attribute. + + :param client: Client for service requests. + :param config: Configuration of service client. + :param serializer: An object model serializer. + :param deserializer: An object model deserializer. + :ivar api_version: Client Api Version. Constant value: "2020-03-01-preview". + """ + + models = models + + def __init__(self, client, config, serializer, deserializer): + + self._client = client + self._serialize = serializer + self._deserialize = deserializer + self.api_version = "2020-03-01-preview" + + self.config = config + + def list_by_subscription( + self, custom_headers=None, raw=False, **operation_config): + """List all organizations under the specified subscription. + + :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: An iterator like instance of OrganizationResource + :rtype: + ~azure.mgmt.confluent.models.OrganizationResourcePaged[~azure.mgmt.confluent.models.OrganizationResource] + :raises: + :class:`ResourceProviderDefaultErrorResponseException` + """ + def prepare_request(next_link=None): + if not next_link: + # Construct URL + url = self.list_by_subscription.metadata['url'] + path_format_arguments = { + 'subscriptionId': self._serialize.url("self.config.subscription_id", self.config.subscription_id, 'str') + } + url = self._client.format_url(url, **path_format_arguments) + + # Construct parameters + query_parameters = {} + query_parameters['api-version'] = self._serialize.query("self.api_version", self.api_version, 'str') + + else: + url = next_link + query_parameters = {} + + # Construct headers + header_parameters = {} + header_parameters['Accept'] = 'application/json' + if self.config.generate_client_request_id: + header_parameters['x-ms-client-request-id'] = str(uuid.uuid1()) + if custom_headers: + header_parameters.update(custom_headers) + if self.config.accept_language is not None: + header_parameters['accept-language'] = self._serialize.header("self.config.accept_language", self.config.accept_language, 'str') + + # Construct and send request + request = self._client.get(url, query_parameters, header_parameters) + return request + + def internal_paging(next_link=None): + request = prepare_request(next_link) + + response = self._client.send(request, stream=False, **operation_config) + + if response.status_code not in [200]: + raise models.ResourceProviderDefaultErrorResponseException(self._deserialize, response) + + return response + + # Deserialize response + header_dict = None + if raw: + header_dict = {} + deserialized = models.OrganizationResourcePaged(internal_paging, self._deserialize.dependencies, header_dict) + + return deserialized + list_by_subscription.metadata = {'url': '/subscriptions/{subscriptionId}/providers/Microsoft.Confluent/organizations'} + + def list_by_resource_group( + self, resource_group_name, custom_headers=None, raw=False, **operation_config): + """List all Organizations under the specified resource group. + + :param resource_group_name: Resource group name + :type resource_group_name: 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: An iterator like instance of OrganizationResource + :rtype: + ~azure.mgmt.confluent.models.OrganizationResourcePaged[~azure.mgmt.confluent.models.OrganizationResource] + :raises: + :class:`ResourceProviderDefaultErrorResponseException` + """ + def prepare_request(next_link=None): + if not next_link: + # Construct URL + url = self.list_by_resource_group.metadata['url'] + path_format_arguments = { + 'subscriptionId': self._serialize.url("self.config.subscription_id", self.config.subscription_id, 'str'), + 'resourceGroupName': self._serialize.url("resource_group_name", resource_group_name, 'str') + } + url = self._client.format_url(url, **path_format_arguments) + + # Construct parameters + query_parameters = {} + query_parameters['api-version'] = self._serialize.query("self.api_version", self.api_version, 'str') + + else: + url = next_link + query_parameters = {} + + # Construct headers + header_parameters = {} + header_parameters['Accept'] = 'application/json' + if self.config.generate_client_request_id: + header_parameters['x-ms-client-request-id'] = str(uuid.uuid1()) + if custom_headers: + header_parameters.update(custom_headers) + if self.config.accept_language is not None: + header_parameters['accept-language'] = self._serialize.header("self.config.accept_language", self.config.accept_language, 'str') + + # Construct and send request + request = self._client.get(url, query_parameters, header_parameters) + return request + + def internal_paging(next_link=None): + request = prepare_request(next_link) + + response = self._client.send(request, stream=False, **operation_config) + + if response.status_code not in [200]: + raise models.ResourceProviderDefaultErrorResponseException(self._deserialize, response) + + return response + + # Deserialize response + header_dict = None + if raw: + header_dict = {} + deserialized = models.OrganizationResourcePaged(internal_paging, self._deserialize.dependencies, header_dict) + + return deserialized + list_by_resource_group.metadata = {'url': '/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Confluent/organizations'} + + def get( + self, resource_group_name, organization_name, custom_headers=None, raw=False, **operation_config): + """Get the properties of a specific Organization resource. + + :param resource_group_name: Resource group name + :type resource_group_name: str + :param organization_name: Organization resource name + :type organization_name: 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: OrganizationResource or ClientRawResponse if raw=true + :rtype: ~azure.mgmt.confluent.models.OrganizationResource or + ~msrest.pipeline.ClientRawResponse + :raises: + :class:`ResourceProviderDefaultErrorResponseException` + """ + # Construct URL + url = self.get.metadata['url'] + path_format_arguments = { + 'subscriptionId': self._serialize.url("self.config.subscription_id", self.config.subscription_id, 'str'), + 'resourceGroupName': self._serialize.url("resource_group_name", resource_group_name, 'str'), + 'organizationName': self._serialize.url("organization_name", organization_name, 'str') + } + url = self._client.format_url(url, **path_format_arguments) + + # Construct parameters + query_parameters = {} + query_parameters['api-version'] = self._serialize.query("self.api_version", self.api_version, 'str') + + # Construct headers + header_parameters = {} + header_parameters['Accept'] = 'application/json' + if self.config.generate_client_request_id: + header_parameters['x-ms-client-request-id'] = str(uuid.uuid1()) + if custom_headers: + header_parameters.update(custom_headers) + if self.config.accept_language is not None: + header_parameters['accept-language'] = self._serialize.header("self.config.accept_language", self.config.accept_language, 'str') + + # 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.ResourceProviderDefaultErrorResponseException(self._deserialize, response) + + deserialized = None + if response.status_code == 200: + deserialized = self._deserialize('OrganizationResource', response) + + if raw: + client_raw_response = ClientRawResponse(deserialized, response) + return client_raw_response + + return deserialized + get.metadata = {'url': '/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Confluent/organizations/{organizationName}'} + + + def _create_initial( + self, resource_group_name, organization_name, body=None, custom_headers=None, raw=False, **operation_config): + # Construct URL + url = self.create.metadata['url'] + path_format_arguments = { + 'subscriptionId': self._serialize.url("self.config.subscription_id", self.config.subscription_id, 'str'), + 'resourceGroupName': self._serialize.url("resource_group_name", resource_group_name, 'str'), + 'organizationName': self._serialize.url("organization_name", organization_name, 'str') + } + url = self._client.format_url(url, **path_format_arguments) + + # Construct parameters + query_parameters = {} + query_parameters['api-version'] = self._serialize.query("self.api_version", self.api_version, 'str') + + # Construct headers + header_parameters = {} + header_parameters['Accept'] = 'application/json' + header_parameters['Content-Type'] = 'application/json; charset=utf-8' + if self.config.generate_client_request_id: + header_parameters['x-ms-client-request-id'] = str(uuid.uuid1()) + if custom_headers: + header_parameters.update(custom_headers) + if self.config.accept_language is not None: + header_parameters['accept-language'] = self._serialize.header("self.config.accept_language", self.config.accept_language, 'str') + + # Construct body + if body is not None: + body_content = self._serialize.body(body, 'OrganizationResource') + else: + body_content = None + + # Construct and send request + request = self._client.put(url, query_parameters, header_parameters, body_content) + response = self._client.send(request, stream=False, **operation_config) + + if response.status_code not in [200, 201]: + raise models.ResourceProviderDefaultErrorResponseException(self._deserialize, response) + + deserialized = None + + if response.status_code == 200: + deserialized = self._deserialize('OrganizationResource', response) + if response.status_code == 201: + deserialized = self._deserialize('OrganizationResource', response) + + if raw: + client_raw_response = ClientRawResponse(deserialized, response) + return client_raw_response + + return deserialized + + def create( + self, resource_group_name, organization_name, body=None, custom_headers=None, raw=False, polling=True, **operation_config): + """Create Organization resource. + + :param resource_group_name: Resource group name + :type resource_group_name: str + :param organization_name: Organization resource name + :type organization_name: str + :param body: Organization resource model + :type body: ~azure.mgmt.confluent.models.OrganizationResource + :param dict custom_headers: headers that will be added to the request + :param bool raw: The poller return type is ClientRawResponse, the + direct response alongside the deserialized response + :param polling: True for ARMPolling, False for no polling, or a + polling object for personal polling strategy + :return: An instance of LROPoller that returns OrganizationResource or + ClientRawResponse if raw==True + :rtype: + ~msrestazure.azure_operation.AzureOperationPoller[~azure.mgmt.confluent.models.OrganizationResource] + or + ~msrestazure.azure_operation.AzureOperationPoller[~msrest.pipeline.ClientRawResponse[~azure.mgmt.confluent.models.OrganizationResource]] + :raises: + :class:`ResourceProviderDefaultErrorResponseException` + """ + raw_result = self._create_initial( + resource_group_name=resource_group_name, + organization_name=organization_name, + body=body, + custom_headers=custom_headers, + raw=True, + **operation_config + ) + + def get_long_running_output(response): + deserialized = self._deserialize('OrganizationResource', response) + + if raw: + client_raw_response = ClientRawResponse(deserialized, response) + return client_raw_response + + return deserialized + + lro_delay = operation_config.get( + 'long_running_operation_timeout', + self.config.long_running_operation_timeout) + if polling is True: polling_method = ARMPolling(lro_delay, **operation_config) + elif polling is False: polling_method = NoPolling() + else: polling_method = polling + return LROPoller(self._client, raw_result, get_long_running_output, polling_method) + create.metadata = {'url': '/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Confluent/organizations/{organizationName}'} + + def update( + self, resource_group_name, organization_name, tags=None, custom_headers=None, raw=False, **operation_config): + """Update Organization resource. + + :param resource_group_name: Resource group name + :type resource_group_name: str + :param organization_name: Organization resource name + :type organization_name: str + :param tags: ARM resource tags + :type tags: dict[str, 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: OrganizationResource or ClientRawResponse if raw=true + :rtype: ~azure.mgmt.confluent.models.OrganizationResource or + ~msrest.pipeline.ClientRawResponse + :raises: + :class:`ResourceProviderDefaultErrorResponseException` + """ + body = None + if tags is not None: + body = models.OrganizationResourceUpdate(tags=tags) + + # Construct URL + url = self.update.metadata['url'] + path_format_arguments = { + 'subscriptionId': self._serialize.url("self.config.subscription_id", self.config.subscription_id, 'str'), + 'resourceGroupName': self._serialize.url("resource_group_name", resource_group_name, 'str'), + 'organizationName': self._serialize.url("organization_name", organization_name, 'str') + } + url = self._client.format_url(url, **path_format_arguments) + + # Construct parameters + query_parameters = {} + query_parameters['api-version'] = self._serialize.query("self.api_version", self.api_version, 'str') + + # Construct headers + header_parameters = {} + header_parameters['Accept'] = 'application/json' + header_parameters['Content-Type'] = 'application/json; charset=utf-8' + if self.config.generate_client_request_id: + header_parameters['x-ms-client-request-id'] = str(uuid.uuid1()) + if custom_headers: + header_parameters.update(custom_headers) + if self.config.accept_language is not None: + header_parameters['accept-language'] = self._serialize.header("self.config.accept_language", self.config.accept_language, 'str') + + # Construct body + if body is not None: + body_content = self._serialize.body(body, 'OrganizationResourceUpdate') + else: + body_content = None + + # Construct and send request + request = self._client.patch(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.ResourceProviderDefaultErrorResponseException(self._deserialize, response) + + deserialized = None + if response.status_code == 200: + deserialized = self._deserialize('OrganizationResource', response) + + if raw: + client_raw_response = ClientRawResponse(deserialized, response) + return client_raw_response + + return deserialized + update.metadata = {'url': '/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Confluent/organizations/{organizationName}'} + + + def _delete_initial( + self, resource_group_name, organization_name, custom_headers=None, raw=False, **operation_config): + # Construct URL + url = self.delete.metadata['url'] + path_format_arguments = { + 'subscriptionId': self._serialize.url("self.config.subscription_id", self.config.subscription_id, 'str'), + 'resourceGroupName': self._serialize.url("resource_group_name", resource_group_name, 'str'), + 'organizationName': self._serialize.url("organization_name", organization_name, 'str') + } + url = self._client.format_url(url, **path_format_arguments) + + # Construct parameters + query_parameters = {} + query_parameters['api-version'] = self._serialize.query("self.api_version", self.api_version, 'str') + + # Construct headers + header_parameters = {} + if self.config.generate_client_request_id: + header_parameters['x-ms-client-request-id'] = str(uuid.uuid1()) + if custom_headers: + header_parameters.update(custom_headers) + if self.config.accept_language is not None: + header_parameters['accept-language'] = self._serialize.header("self.config.accept_language", self.config.accept_language, 'str') + + # Construct and send request + request = self._client.delete(url, query_parameters, header_parameters) + response = self._client.send(request, stream=False, **operation_config) + + if response.status_code not in [200, 202, 204]: + raise models.ResourceProviderDefaultErrorResponseException(self._deserialize, response) + + if raw: + client_raw_response = ClientRawResponse(None, response) + return client_raw_response + + def delete( + self, resource_group_name, organization_name, custom_headers=None, raw=False, polling=True, **operation_config): + """Delete Organization resource. + + :param resource_group_name: Resource group name + :type resource_group_name: str + :param organization_name: Organization resource name + :type organization_name: str + :param dict custom_headers: headers that will be added to the request + :param bool raw: The poller return type is ClientRawResponse, the + direct response alongside the deserialized response + :param polling: True for ARMPolling, False for no polling, or a + polling object for personal polling strategy + :return: An instance of LROPoller that returns None or + ClientRawResponse if raw==True + :rtype: ~msrestazure.azure_operation.AzureOperationPoller[None] or + ~msrestazure.azure_operation.AzureOperationPoller[~msrest.pipeline.ClientRawResponse[None]] + :raises: + :class:`ResourceProviderDefaultErrorResponseException` + """ + raw_result = self._delete_initial( + resource_group_name=resource_group_name, + organization_name=organization_name, + custom_headers=custom_headers, + raw=True, + **operation_config + ) + + def get_long_running_output(response): + if raw: + client_raw_response = ClientRawResponse(None, response) + return client_raw_response + + lro_delay = operation_config.get( + 'long_running_operation_timeout', + self.config.long_running_operation_timeout) + if polling is True: polling_method = ARMPolling(lro_delay, **operation_config) + elif polling is False: polling_method = NoPolling() + else: polling_method = polling + return LROPoller(self._client, raw_result, get_long_running_output, polling_method) + delete.metadata = {'url': '/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Confluent/organizations/{organizationName}'} diff --git a/sdk/confluent/azure-mgmt-confluent/azure/mgmt/confluent/version.py b/sdk/confluent/azure-mgmt-confluent/azure/mgmt/confluent/version.py new file mode 100644 index 000000000000..affaef0c987e --- /dev/null +++ b/sdk/confluent/azure-mgmt-confluent/azure/mgmt/confluent/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 = "1.0.0b1" +