Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[AutoPR track2_azure-mgmt-apimanagement] wiki for apis and products #2203

Closed
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
The table of contents is too big for display.
Diff view
Diff view
  •  
  •  
  •  
6 changes: 3 additions & 3 deletions sdk/apimanagement/azure-mgmt-apimanagement/_meta.json
Original file line number Diff line number Diff line change
@@ -1,11 +1,11 @@
{
"commit": "a2da92ad78961529a087f9d0e65394174ac50794",
"commit": "fa1f1f9c0bb7eb5513405dac9e397502357b2251",
"repository_url": "https://github.com/Azure/azure-rest-api-specs",
"autorest": "3.9.2",
"use": [
"@autorest/python@6.2.1",
"@autorest/python@6.2.7",
"@autorest/modelerfour@4.24.3"
],
"autorest_command": "autorest specification/apimanagement/resource-manager/readme.md --generate-sample=True --include-x-ms-examples-original-file=True --python --python-sdks-folder=/home/vsts/work/1/azure-sdk-for-python/sdk --use=@autorest/python@6.2.1 --use=@autorest/modelerfour@4.24.3 --version=3.9.2 --version-tolerant=False",
"autorest_command": "autorest specification/apimanagement/resource-manager/readme.md --generate-sample=True --include-x-ms-examples-original-file=True --python --python-sdks-folder=/mnt/vss/_work/1/s/azure-sdk-for-python/sdk --use=@autorest/python@6.2.7 --use=@autorest/modelerfour@4.24.3 --version=3.9.2 --version-tolerant=False",
"readme": "specification/apimanagement/resource-manager/readme.md"
}
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@

try:
from ._patch import __all__ as _patch_all
from ._patch import * # type: ignore # pylint: disable=unused-wildcard-import
from ._patch import * # pylint: disable=unused-wildcard-import
except ImportError:
_patch_all = []
from ._patch import patch_sdk as _patch_sdk
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@
from azure.core.rest import HttpRequest, HttpResponse
from azure.mgmt.core import ARMPipelineClient

from . import models
from . import models as _models
from ._configuration import ApiManagementClientConfiguration
from ._serialization import Deserializer, Serializer
from .operations import (
Expand All @@ -36,6 +36,11 @@
ApiSchemaOperations,
ApiTagDescriptionOperations,
ApiVersionSetOperations,
ApiWikiOperations,
AuthorizationAccessPolicyOperations,
AuthorizationLoginLinksOperations,
AuthorizationOperations,
AuthorizationProviderOperations,
AuthorizationServerOperations,
BackendOperations,
CacheOperations,
Expand All @@ -45,6 +50,7 @@
DelegationSettingsOperations,
DeletedServicesOperations,
DiagnosticOperations,
DocumentationOperations,
EmailTemplateOperations,
GatewayApiOperations,
GatewayCertificateAuthorityOperations,
Expand All @@ -65,7 +71,9 @@
OperationOperations,
OutboundNetworkDependenciesEndpointsOperations,
PolicyDescriptionOperations,
PolicyFragmentOperations,
PolicyOperations,
PortalConfigOperations,
PortalRevisionOperations,
PortalSettingsOperations,
PrivateEndpointConnectionOperations,
Expand All @@ -74,6 +82,7 @@
ProductOperations,
ProductPolicyOperations,
ProductSubscriptionsOperations,
ProductWikiOperations,
QuotaByCounterKeysOperations,
QuotaByPeriodKeysOperations,
RegionOperations,
Expand Down Expand Up @@ -134,13 +143,26 @@ class ApiManagementClient(
:vartype api_tag_description: azure.mgmt.apimanagement.operations.ApiTagDescriptionOperations
:ivar operation: OperationOperations operations
:vartype operation: azure.mgmt.apimanagement.operations.OperationOperations
:ivar api_wiki: ApiWikiOperations operations
:vartype api_wiki: azure.mgmt.apimanagement.operations.ApiWikiOperations
:ivar api_export: ApiExportOperations operations
:vartype api_export: azure.mgmt.apimanagement.operations.ApiExportOperations
:ivar api_version_set: ApiVersionSetOperations operations
:vartype api_version_set: azure.mgmt.apimanagement.operations.ApiVersionSetOperations
:ivar authorization_server: AuthorizationServerOperations operations
:vartype authorization_server:
azure.mgmt.apimanagement.operations.AuthorizationServerOperations
:ivar authorization_provider: AuthorizationProviderOperations operations
:vartype authorization_provider:
azure.mgmt.apimanagement.operations.AuthorizationProviderOperations
:ivar authorization: AuthorizationOperations operations
:vartype authorization: azure.mgmt.apimanagement.operations.AuthorizationOperations
:ivar authorization_login_links: AuthorizationLoginLinksOperations operations
:vartype authorization_login_links:
azure.mgmt.apimanagement.operations.AuthorizationLoginLinksOperations
:ivar authorization_access_policy: AuthorizationAccessPolicyOperations operations
:vartype authorization_access_policy:
azure.mgmt.apimanagement.operations.AuthorizationAccessPolicyOperations
:ivar backend: BackendOperations operations
:vartype backend: azure.mgmt.apimanagement.operations.BackendOperations
:ivar cache: CacheOperations operations
Expand Down Expand Up @@ -209,6 +231,10 @@ class ApiManagementClient(
:vartype policy: azure.mgmt.apimanagement.operations.PolicyOperations
:ivar policy_description: PolicyDescriptionOperations operations
:vartype policy_description: azure.mgmt.apimanagement.operations.PolicyDescriptionOperations
:ivar policy_fragment: PolicyFragmentOperations operations
:vartype policy_fragment: azure.mgmt.apimanagement.operations.PolicyFragmentOperations
:ivar portal_config: PortalConfigOperations operations
:vartype portal_config: azure.mgmt.apimanagement.operations.PortalConfigOperations
:ivar portal_revision: PortalRevisionOperations operations
:vartype portal_revision: azure.mgmt.apimanagement.operations.PortalRevisionOperations
:ivar portal_settings: PortalSettingsOperations operations
Expand All @@ -233,6 +259,8 @@ class ApiManagementClient(
azure.mgmt.apimanagement.operations.ProductSubscriptionsOperations
:ivar product_policy: ProductPolicyOperations operations
:vartype product_policy: azure.mgmt.apimanagement.operations.ProductPolicyOperations
:ivar product_wiki: ProductWikiOperations operations
:vartype product_wiki: azure.mgmt.apimanagement.operations.ProductWikiOperations
:ivar quota_by_counter_keys: QuotaByCounterKeysOperations operations
:vartype quota_by_counter_keys:
azure.mgmt.apimanagement.operations.QuotaByCounterKeysOperations
Expand Down Expand Up @@ -270,14 +298,15 @@ class ApiManagementClient(
:ivar user_confirmation_password: UserConfirmationPasswordOperations operations
:vartype user_confirmation_password:
azure.mgmt.apimanagement.operations.UserConfirmationPasswordOperations
:ivar documentation: DocumentationOperations operations
:vartype documentation: azure.mgmt.apimanagement.operations.DocumentationOperations
:param credential: Credential needed for the client to connect to Azure. Required.
:type credential: ~azure.core.credentials.TokenCredential
:param subscription_id: Subscription credentials which uniquely identify Microsoft Azure
subscription. The subscription ID forms part of the URI for every service call. Required.
:param subscription_id: The ID of the target subscription. Required.
:type subscription_id: str
:param base_url: Service URL. Default value is "https://management.azure.com".
:type base_url: str
:keyword api_version: Api Version. Default value is "2021-08-01". Note that overriding this
:keyword api_version: Api Version. Default value is "2022-08-01". Note that overriding this
default value may result in unsupported behavior.
:paramtype api_version: str
:keyword int polling_interval: Default waiting time between two polls for LRO operations if no
Expand All @@ -296,7 +325,7 @@ def __init__(
)
self._client = ARMPipelineClient(base_url=base_url, config=self._config, **kwargs)

client_models = {k: v for k, v in models.__dict__.items() if isinstance(v, type)}
client_models = {k: v for k, v in _models.__dict__.items() if isinstance(v, type)}
self._serialize = Serializer(client_models)
self._deserialize = Deserializer(client_models)
self._serialize.client_side_validation = False
Expand All @@ -323,11 +352,22 @@ def __init__(
self._client, self._config, self._serialize, self._deserialize
)
self.operation = OperationOperations(self._client, self._config, self._serialize, self._deserialize)
self.api_wiki = ApiWikiOperations(self._client, self._config, self._serialize, self._deserialize)
self.api_export = ApiExportOperations(self._client, self._config, self._serialize, self._deserialize)
self.api_version_set = ApiVersionSetOperations(self._client, self._config, self._serialize, self._deserialize)
self.authorization_server = AuthorizationServerOperations(
self._client, self._config, self._serialize, self._deserialize
)
self.authorization_provider = AuthorizationProviderOperations(
self._client, self._config, self._serialize, self._deserialize
)
self.authorization = AuthorizationOperations(self._client, self._config, self._serialize, self._deserialize)
self.authorization_login_links = AuthorizationLoginLinksOperations(
self._client, self._config, self._serialize, self._deserialize
)
self.authorization_access_policy = AuthorizationAccessPolicyOperations(
self._client, self._config, self._serialize, self._deserialize
)
self.backend = BackendOperations(self._client, self._config, self._serialize, self._deserialize)
self.cache = CacheOperations(self._client, self._config, self._serialize, self._deserialize)
self.certificate = CertificateOperations(self._client, self._config, self._serialize, self._deserialize)
Expand Down Expand Up @@ -381,6 +421,8 @@ def __init__(
self.policy_description = PolicyDescriptionOperations(
self._client, self._config, self._serialize, self._deserialize
)
self.policy_fragment = PolicyFragmentOperations(self._client, self._config, self._serialize, self._deserialize)
self.portal_config = PortalConfigOperations(self._client, self._config, self._serialize, self._deserialize)
self.portal_revision = PortalRevisionOperations(self._client, self._config, self._serialize, self._deserialize)
self.portal_settings = PortalSettingsOperations(self._client, self._config, self._serialize, self._deserialize)
self.sign_in_settings = SignInSettingsOperations(self._client, self._config, self._serialize, self._deserialize)
Expand All @@ -398,6 +440,7 @@ def __init__(
self._client, self._config, self._serialize, self._deserialize
)
self.product_policy = ProductPolicyOperations(self._client, self._config, self._serialize, self._deserialize)
self.product_wiki = ProductWikiOperations(self._client, self._config, self._serialize, self._deserialize)
self.quota_by_counter_keys = QuotaByCounterKeysOperations(
self._client, self._config, self._serialize, self._deserialize
)
Expand Down Expand Up @@ -429,6 +472,7 @@ def __init__(
self.user_confirmation_password = UserConfirmationPasswordOperations(
self._client, self._config, self._serialize, self._deserialize
)
self.documentation = DocumentationOperations(self._client, self._config, self._serialize, self._deserialize)

def _send_request(self, request: HttpRequest, **kwargs: Any) -> HttpResponse:
"""Runs the network request through the client's chained policies.
Expand All @@ -452,15 +496,12 @@ def _send_request(self, request: HttpRequest, **kwargs: Any) -> HttpResponse:
request_copy.url = self._client.format_url(request_copy.url)
return self._client.send_request(request_copy, **kwargs)

def close(self):
# type: () -> None
def close(self) -> None:
self._client.close()

def __enter__(self):
# type: () -> ApiManagementClient
def __enter__(self) -> "ApiManagementClient":
self._client.__enter__()
return self

def __exit__(self, *exc_details):
# type: (Any) -> None
def __exit__(self, *exc_details) -> None:
self._client.__exit__(*exc_details)
Original file line number Diff line number Diff line change
Expand Up @@ -33,17 +33,16 @@ class ApiManagementClientConfiguration(Configuration): # pylint: disable=too-ma

:param credential: Credential needed for the client to connect to Azure. Required.
:type credential: ~azure.core.credentials.TokenCredential
:param subscription_id: Subscription credentials which uniquely identify Microsoft Azure
subscription. The subscription ID forms part of the URI for every service call. Required.
:param subscription_id: The ID of the target subscription. Required.
:type subscription_id: str
:keyword api_version: Api Version. Default value is "2021-08-01". Note that overriding this
:keyword api_version: Api Version. Default value is "2022-08-01". Note that overriding this
default value may result in unsupported behavior.
:paramtype api_version: str
"""

def __init__(self, credential: "TokenCredential", subscription_id: str, **kwargs: Any) -> None:
super(ApiManagementClientConfiguration, self).__init__(**kwargs)
api_version = kwargs.pop("api_version", "2021-08-01") # type: Literal["2021-08-01"]
api_version: Literal["2022-08-01"] = kwargs.pop("api_version", "2022-08-01")

if credential is None:
raise ValueError("Parameter 'credential' must not be None.")
Expand All @@ -57,10 +56,7 @@ def __init__(self, credential: "TokenCredential", subscription_id: str, **kwargs
kwargs.setdefault("sdk_moniker", "mgmt-apimanagement/{}".format(VERSION))
self._configure(**kwargs)

def _configure(
self, **kwargs # type: Any
):
# type: (...) -> None
def _configure(self, **kwargs: Any) -> None:
self.user_agent_policy = kwargs.get("user_agent_policy") or policies.UserAgentPolicy(**kwargs)
self.headers_policy = kwargs.get("headers_policy") or policies.HeadersPolicy(**kwargs)
self.proxy_policy = kwargs.get("proxy_policy") or policies.ProxyPolicy(**kwargs)
Expand Down
Loading