你当前正在访问 Microsoft Azure Global Edition 技术文档网站。 如果需要访问由世纪互联运营的 Microsoft Azure 中国技术文档网站,请访问 https://docs.azure.cn

SearchServiceResource.RegenerateAdminKey 方法

定义

重新生成主要或辅助管理 API 密钥。 每次你只能重新生成一个密钥。

  • 请求路径/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Search/searchServices/{searchServiceName}/regenerateAdminKey/{keyKind}
  • 操作IdAdminKeys_Regenerate
public virtual Azure.Response<Azure.ResourceManager.Search.Models.SearchServiceAdminKeyResult> RegenerateAdminKey (Azure.ResourceManager.Search.Models.SearchServiceAdminKeyKind keyKind, Azure.ResourceManager.Search.Models.SearchManagementRequestOptions searchManagementRequestOptions = default, System.Threading.CancellationToken cancellationToken = default);
abstract member RegenerateAdminKey : Azure.ResourceManager.Search.Models.SearchServiceAdminKeyKind * Azure.ResourceManager.Search.Models.SearchManagementRequestOptions * System.Threading.CancellationToken -> Azure.Response<Azure.ResourceManager.Search.Models.SearchServiceAdminKeyResult>
override this.RegenerateAdminKey : Azure.ResourceManager.Search.Models.SearchServiceAdminKeyKind * Azure.ResourceManager.Search.Models.SearchManagementRequestOptions * System.Threading.CancellationToken -> Azure.Response<Azure.ResourceManager.Search.Models.SearchServiceAdminKeyResult>
Public Overridable Function RegenerateAdminKey (keyKind As SearchServiceAdminKeyKind, Optional searchManagementRequestOptions As SearchManagementRequestOptions = Nothing, Optional cancellationToken As CancellationToken = Nothing) As Response(Of SearchServiceAdminKeyResult)

参数

keyKind
SearchServiceAdminKeyKind

指定要重新生成哪个密钥。 有效值包括“primary”和“secondary”。

searchManagementRequestOptions
SearchManagementRequestOptions

参数组。

cancellationToken
CancellationToken

要使用的取消标记。

返回

适用于