diff --git a/azure-graphrbac/azure/graphrbac/operations/oauth2_operations.py b/azure-graphrbac/azure/graphrbac/operations/oauth2_operations.py index c5cd91d69a44..8461996ffef6 100644 --- a/azure-graphrbac/azure/graphrbac/operations/oauth2_operations.py +++ b/azure-graphrbac/azure/graphrbac/operations/oauth2_operations.py @@ -98,7 +98,7 @@ def get( return deserialized get.metadata = {'url': '/{tenantID}/oauth2PermissionGrants'} - def post( + def grant( self, body=None, custom_headers=None, raw=False, **operation_config): """Grants OAuth2 permissions for the relevant resource Ids of an app. @@ -116,7 +116,7 @@ def post( :raises: :class:`CloudError` """ # Construct URL - url = self.post.metadata['url'] + url = self.grant.metadata['url'] path_format_arguments = { 'tenantID': self._serialize.url("self.config.tenant_id", self.config.tenant_id, 'str') } @@ -162,4 +162,4 @@ def post( return client_raw_response return deserialized - post.metadata = {'url': '/{tenantID}/oauth2PermissionGrants'} + grant.metadata = {'url': '/{tenantID}/oauth2PermissionGrants'}