QueryKeysOperations Class
Warning
DO NOT instantiate this class directly.
Instead, you should access the following operations through
<xref:query_keys> attribute.
Constructor
QueryKeysOperations(*args, **kwargs)
Methods
| create |
Generates a new query key for the specified search service. You can create up to 50 query keys per service. |
| delete |
Deletes the specified query key. Unlike admin keys, query keys are not regenerated. The process for regenerating a query key is to delete and then recreate it. |
| list_by_search_service |
Returns the list of query API keys for the given Azure AI Search service. |
create
Generates a new query key for the specified search service. You can create up to 50 query keys per service.
create(resource_group_name: str, search_service_name: str, name: str, search_management_request_options: SearchManagementRequestOptions | None = None, **kwargs: Any) -> QueryKey
Parameters
| Name | Description |
|---|---|
|
resource_group_name
Required
|
The name of the resource group within the current subscription. You can obtain this value from the Azure Resource Manager API or the portal. Required. |
|
search_service_name
Required
|
The name of the Azure AI Search service associated with the specified resource group. Required. |
|
name
Required
|
The name of the new query API key. Required. |
|
search_management_request_options
|
Parameter group. Default value is None. Default value: None
|
Returns
| Type | Description |
|---|---|
|
QueryKey or the result of cls(response) |
Exceptions
| Type | Description |
|---|---|
- See also
delete
Deletes the specified query key. Unlike admin keys, query keys are not regenerated. The process for regenerating a query key is to delete and then recreate it.
delete(resource_group_name: str, search_service_name: str, key: str, search_management_request_options: SearchManagementRequestOptions | None = None, **kwargs: Any) -> None
Parameters
| Name | Description |
|---|---|
|
resource_group_name
Required
|
The name of the resource group within the current subscription. You can obtain this value from the Azure Resource Manager API or the portal. Required. |
|
search_service_name
Required
|
The name of the Azure AI Search service associated with the specified resource group. Required. |
|
key
Required
|
The query key to be deleted. Query keys are identified by value, not by name. Required. |
|
search_management_request_options
|
Parameter group. Default value is None. Default value: None
|
Returns
| Type | Description |
|---|---|
|
None or the result of cls(response) |
Exceptions
| Type | Description |
|---|---|
- See also
list_by_search_service
Returns the list of query API keys for the given Azure AI Search service.
list_by_search_service(resource_group_name: str, search_service_name: str, search_management_request_options: SearchManagementRequestOptions | None = None, **kwargs: Any) -> Iterable[QueryKey]
Parameters
| Name | Description |
|---|---|
|
resource_group_name
Required
|
The name of the resource group within the current subscription. You can obtain this value from the Azure Resource Manager API or the portal. Required. |
|
search_service_name
Required
|
The name of the Azure AI Search service associated with the specified resource group. Required. |
|
search_management_request_options
|
Parameter group. Default value is None. Default value: None
|
Returns
| Type | Description |
|---|---|
|
An iterator like instance of either QueryKey or the result of cls(response) |
Exceptions
| Type | Description |
|---|---|
- See also
Attributes
models
models = <module 'azure.mgmt.search.models' from 'C:\\ToolCache\\Python\\3.11.9\\x64\\Lib\\site-packages\\py2docfx\\venv\\venv211\\Lib\\site-packages\\azure\\mgmt\\search\\models\\__init__.py'>