Skip to content

Commit 938ead0

Browse files
authored
[AutoPR recoveryservices/resource-manager] Added Swagger details for CheckNameAvailability API (#4706)
* Generated from 1c52533609d5a8a806f616702ab45f6b8c514b68 Changed operationId for checkNameAvailability from CheckResourceNameAvailability_Post to RecoveryServices_CheckNameAvailability * Packaging update of azure-mgmt-recoveryservices * Generated from 2edb73566dac3446f8b8a54399b9f14650c32e36 Renaming ResourceNameAvailabilityResponse to ResourceNameAvailabilityResult * Generated from f97eae58835c2bcc143d6c854a183830f257dda0 Renaming ResourceNameAvailabilityResult to CheckNameAvailabilityResult and changing GCed to GC'ed in swagger API summary * Generated from cc6ecf84a7e767b9299aa77868b43817d17bde4c Renaming ResourceNameAvailabilityParameters to CheckNameAvailabilityParameters
1 parent 760a709 commit 938ead0

12 files changed

+384
-19
lines changed

azure-mgmt-recoveryservices/MANIFEST.in

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,4 @@
1+
recursive-include tests *.py *.yaml
12
include *.rst
23
include azure/__init__.py
34
include azure/mgmt/__init__.py

azure-mgmt-recoveryservices/README.rst

Lines changed: 3 additions & 19 deletions
Original file line numberDiff line numberDiff line change
@@ -14,25 +14,6 @@ For the older Azure Service Management (ASM) libraries, see
1414
For a more complete set of Azure libraries, see the `azure <https://pypi.python.org/pypi/azure>`__ bundle package.
1515

1616

17-
Compatibility
18-
=============
19-
20-
**IMPORTANT**: If you have an earlier version of the azure package
21-
(version < 1.0), you should uninstall it before installing this package.
22-
23-
You can check the version using pip:
24-
25-
.. code:: shell
26-
27-
pip freeze
28-
29-
If you see azure==0.11.0 (or any version below 1.0), uninstall it first:
30-
31-
.. code:: shell
32-
33-
pip uninstall azure
34-
35-
3617
Usage
3718
=====
3819

@@ -47,3 +28,6 @@ Provide Feedback
4728
If you encounter any bugs or have suggestions, please file an issue in the
4829
`Issues <https://github.com/Azure/azure-sdk-for-python/issues>`__
4930
section of the project.
31+
32+
33+
.. image:: https://azure-sdk-impressions.azurewebsites.net/api/impressions/azure-sdk-for-python%2Fazure-mgmt-recoveryservices%2FREADME.png

azure-mgmt-recoveryservices/azure/mgmt/recoveryservices/models/__init__.py

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -19,6 +19,9 @@
1919
from .jobs_summary_py3 import JobsSummary
2020
from .monitoring_summary_py3 import MonitoringSummary
2121
from .replication_usage_py3 import ReplicationUsage
22+
from .check_name_availability_parameters_py3 import CheckNameAvailabilityParameters
23+
from .check_name_availability_result_py3 import CheckNameAvailabilityResult
24+
from .check_name_availability_result_resource_py3 import CheckNameAvailabilityResultResource
2225
from .client_discovery_display_py3 import ClientDiscoveryDisplay
2326
from .client_discovery_for_log_specification_py3 import ClientDiscoveryForLogSpecification
2427
from .client_discovery_for_service_specification_py3 import ClientDiscoveryForServiceSpecification
@@ -45,6 +48,9 @@
4548
from .jobs_summary import JobsSummary
4649
from .monitoring_summary import MonitoringSummary
4750
from .replication_usage import ReplicationUsage
51+
from .check_name_availability_parameters import CheckNameAvailabilityParameters
52+
from .check_name_availability_result import CheckNameAvailabilityResult
53+
from .check_name_availability_result_resource import CheckNameAvailabilityResultResource
4854
from .client_discovery_display import ClientDiscoveryDisplay
4955
from .client_discovery_for_log_specification import ClientDiscoveryForLogSpecification
5056
from .client_discovery_for_service_specification import ClientDiscoveryForServiceSpecification
@@ -83,6 +89,9 @@
8389
'JobsSummary',
8490
'MonitoringSummary',
8591
'ReplicationUsage',
92+
'CheckNameAvailabilityParameters',
93+
'CheckNameAvailabilityResult',
94+
'CheckNameAvailabilityResultResource',
8695
'ClientDiscoveryDisplay',
8796
'ClientDiscoveryForLogSpecification',
8897
'ClientDiscoveryForServiceSpecification',
Lines changed: 34 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,34 @@
1+
# coding=utf-8
2+
# --------------------------------------------------------------------------
3+
# Copyright (c) Microsoft Corporation. All rights reserved.
4+
# Licensed under the MIT License. See License.txt in the project root for
5+
# license information.
6+
#
7+
# Code generated by Microsoft (R) AutoRest Code Generator.
8+
# Changes may cause incorrect behavior and will be lost if the code is
9+
# regenerated.
10+
# --------------------------------------------------------------------------
11+
12+
from msrest.serialization import Model
13+
14+
15+
class CheckNameAvailabilityParameters(Model):
16+
"""Resource Name availability input parameters - Resource type and resource
17+
name.
18+
19+
:param type: Describes the Resource type:
20+
Microsoft.RecoveryServices/Vaults
21+
:type type: str
22+
:param name: Resource name for which availability needs to be checked
23+
:type name: str
24+
"""
25+
26+
_attribute_map = {
27+
'type': {'key': 'type', 'type': 'str'},
28+
'name': {'key': 'name', 'type': 'str'},
29+
}
30+
31+
def __init__(self, **kwargs):
32+
super(CheckNameAvailabilityParameters, self).__init__(**kwargs)
33+
self.type = kwargs.get('type', None)
34+
self.name = kwargs.get('name', None)
Lines changed: 34 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,34 @@
1+
# coding=utf-8
2+
# --------------------------------------------------------------------------
3+
# Copyright (c) Microsoft Corporation. All rights reserved.
4+
# Licensed under the MIT License. See License.txt in the project root for
5+
# license information.
6+
#
7+
# Code generated by Microsoft (R) AutoRest Code Generator.
8+
# Changes may cause incorrect behavior and will be lost if the code is
9+
# regenerated.
10+
# --------------------------------------------------------------------------
11+
12+
from msrest.serialization import Model
13+
14+
15+
class CheckNameAvailabilityParameters(Model):
16+
"""Resource Name availability input parameters - Resource type and resource
17+
name.
18+
19+
:param type: Describes the Resource type:
20+
Microsoft.RecoveryServices/Vaults
21+
:type type: str
22+
:param name: Resource name for which availability needs to be checked
23+
:type name: str
24+
"""
25+
26+
_attribute_map = {
27+
'type': {'key': 'type', 'type': 'str'},
28+
'name': {'key': 'name', 'type': 'str'},
29+
}
30+
31+
def __init__(self, *, type: str=None, name: str=None, **kwargs) -> None:
32+
super(CheckNameAvailabilityParameters, self).__init__(**kwargs)
33+
self.type = type
34+
self.name = name
Lines changed: 37 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,37 @@
1+
# coding=utf-8
2+
# --------------------------------------------------------------------------
3+
# Copyright (c) Microsoft Corporation. All rights reserved.
4+
# Licensed under the MIT License. See License.txt in the project root for
5+
# license information.
6+
#
7+
# Code generated by Microsoft (R) AutoRest Code Generator.
8+
# Changes may cause incorrect behavior and will be lost if the code is
9+
# regenerated.
10+
# --------------------------------------------------------------------------
11+
12+
from msrest.serialization import Model
13+
14+
15+
class CheckNameAvailabilityResult(Model):
16+
"""Response for check name availability API. Resource provider will set
17+
availability as true | false.
18+
19+
:param name_available:
20+
:type name_available: bool
21+
:param reason:
22+
:type reason: str
23+
:param message:
24+
:type message: str
25+
"""
26+
27+
_attribute_map = {
28+
'name_available': {'key': 'nameAvailable', 'type': 'bool'},
29+
'reason': {'key': 'reason', 'type': 'str'},
30+
'message': {'key': 'message', 'type': 'str'},
31+
}
32+
33+
def __init__(self, **kwargs):
34+
super(CheckNameAvailabilityResult, self).__init__(**kwargs)
35+
self.name_available = kwargs.get('name_available', None)
36+
self.reason = kwargs.get('reason', None)
37+
self.message = kwargs.get('message', None)
Lines changed: 37 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,37 @@
1+
# coding=utf-8
2+
# --------------------------------------------------------------------------
3+
# Copyright (c) Microsoft Corporation. All rights reserved.
4+
# Licensed under the MIT License. See License.txt in the project root for
5+
# license information.
6+
#
7+
# Code generated by Microsoft (R) AutoRest Code Generator.
8+
# Changes may cause incorrect behavior and will be lost if the code is
9+
# regenerated.
10+
# --------------------------------------------------------------------------
11+
12+
from msrest.serialization import Model
13+
14+
15+
class CheckNameAvailabilityResult(Model):
16+
"""Response for check name availability API. Resource provider will set
17+
availability as true | false.
18+
19+
:param name_available:
20+
:type name_available: bool
21+
:param reason:
22+
:type reason: str
23+
:param message:
24+
:type message: str
25+
"""
26+
27+
_attribute_map = {
28+
'name_available': {'key': 'nameAvailable', 'type': 'bool'},
29+
'reason': {'key': 'reason', 'type': 'str'},
30+
'message': {'key': 'message', 'type': 'str'},
31+
}
32+
33+
def __init__(self, *, name_available: bool=None, reason: str=None, message: str=None, **kwargs) -> None:
34+
super(CheckNameAvailabilityResult, self).__init__(**kwargs)
35+
self.name_available = name_available
36+
self.reason = reason
37+
self.message = message
Lines changed: 52 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,52 @@
1+
# coding=utf-8
2+
# --------------------------------------------------------------------------
3+
# Copyright (c) Microsoft Corporation. All rights reserved.
4+
# Licensed under the MIT License. See License.txt in the project root for
5+
# license information.
6+
#
7+
# Code generated by Microsoft (R) AutoRest Code Generator.
8+
# Changes may cause incorrect behavior and will be lost if the code is
9+
# regenerated.
10+
# --------------------------------------------------------------------------
11+
12+
from .resource import Resource
13+
14+
15+
class CheckNameAvailabilityResultResource(Resource):
16+
"""Response for check name availability API. Resource provider will set
17+
availability as true | false.
18+
19+
Variables are only populated by the server, and will be ignored when
20+
sending a request.
21+
22+
:ivar id: Resource Id represents the complete path to the resource.
23+
:vartype id: str
24+
:ivar name: Resource name associated with the resource.
25+
:vartype name: str
26+
:ivar type: Resource type represents the complete path of the form
27+
Namespace/ResourceType/ResourceType/...
28+
:vartype type: str
29+
:param e_tag: Optional ETag.
30+
:type e_tag: str
31+
:param properties: CheckNameAvailabilityResultResource properties
32+
:type properties:
33+
~azure.mgmt.recoveryservices.models.CheckNameAvailabilityResult
34+
"""
35+
36+
_validation = {
37+
'id': {'readonly': True},
38+
'name': {'readonly': True},
39+
'type': {'readonly': True},
40+
}
41+
42+
_attribute_map = {
43+
'id': {'key': 'id', 'type': 'str'},
44+
'name': {'key': 'name', 'type': 'str'},
45+
'type': {'key': 'type', 'type': 'str'},
46+
'e_tag': {'key': 'eTag', 'type': 'str'},
47+
'properties': {'key': 'properties', 'type': 'CheckNameAvailabilityResult'},
48+
}
49+
50+
def __init__(self, **kwargs):
51+
super(CheckNameAvailabilityResultResource, self).__init__(**kwargs)
52+
self.properties = kwargs.get('properties', None)
Lines changed: 52 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,52 @@
1+
# coding=utf-8
2+
# --------------------------------------------------------------------------
3+
# Copyright (c) Microsoft Corporation. All rights reserved.
4+
# Licensed under the MIT License. See License.txt in the project root for
5+
# license information.
6+
#
7+
# Code generated by Microsoft (R) AutoRest Code Generator.
8+
# Changes may cause incorrect behavior and will be lost if the code is
9+
# regenerated.
10+
# --------------------------------------------------------------------------
11+
12+
from .resource_py3 import Resource
13+
14+
15+
class CheckNameAvailabilityResultResource(Resource):
16+
"""Response for check name availability API. Resource provider will set
17+
availability as true | false.
18+
19+
Variables are only populated by the server, and will be ignored when
20+
sending a request.
21+
22+
:ivar id: Resource Id represents the complete path to the resource.
23+
:vartype id: str
24+
:ivar name: Resource name associated with the resource.
25+
:vartype name: str
26+
:ivar type: Resource type represents the complete path of the form
27+
Namespace/ResourceType/ResourceType/...
28+
:vartype type: str
29+
:param e_tag: Optional ETag.
30+
:type e_tag: str
31+
:param properties: CheckNameAvailabilityResultResource properties
32+
:type properties:
33+
~azure.mgmt.recoveryservices.models.CheckNameAvailabilityResult
34+
"""
35+
36+
_validation = {
37+
'id': {'readonly': True},
38+
'name': {'readonly': True},
39+
'type': {'readonly': True},
40+
}
41+
42+
_attribute_map = {
43+
'id': {'key': 'id', 'type': 'str'},
44+
'name': {'key': 'name', 'type': 'str'},
45+
'type': {'key': 'type', 'type': 'str'},
46+
'e_tag': {'key': 'eTag', 'type': 'str'},
47+
'properties': {'key': 'properties', 'type': 'CheckNameAvailabilityResult'},
48+
}
49+
50+
def __init__(self, *, e_tag: str=None, properties=None, **kwargs) -> None:
51+
super(CheckNameAvailabilityResultResource, self).__init__(e_tag=e_tag, **kwargs)
52+
self.properties = properties

azure-mgmt-recoveryservices/azure/mgmt/recoveryservices/operations/__init__.py

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -12,6 +12,7 @@
1212
from .vault_certificates_operations import VaultCertificatesOperations
1313
from .registered_identities_operations import RegisteredIdentitiesOperations
1414
from .replication_usages_operations import ReplicationUsagesOperations
15+
from .recovery_services_operations import RecoveryServicesOperations
1516
from .vaults_operations import VaultsOperations
1617
from .operations import Operations
1718
from .vault_extended_info_operations import VaultExtendedInfoOperations
@@ -21,6 +22,7 @@
2122
'VaultCertificatesOperations',
2223
'RegisteredIdentitiesOperations',
2324
'ReplicationUsagesOperations',
25+
'RecoveryServicesOperations',
2426
'VaultsOperations',
2527
'Operations',
2628
'VaultExtendedInfoOperations',

0 commit comments

Comments
 (0)