Skip to content

Commit e0c4f18

Browse files
committed
misc edits to new content
1 parent 88699f4 commit e0c4f18

File tree

2 files changed

+6
-8
lines changed

2 files changed

+6
-8
lines changed

articles/search/cognitive-search-custom-skill-interface.md

Lines changed: 4 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@ author: gmndrg
77
ms.author: gimondra
88
ms.service: cognitive-search
99
ms.topic: how-to
10-
ms.date: 03/18/2022
10+
ms.date: 03/25/2022
1111
---
1212

1313
# Add a custom skill to an Azure Cognitive Search enrichment pipeline
@@ -34,17 +34,15 @@ The interface for a custom skill is specified through the [Custom Web API skill]
3434
"timeout": "PT230S",
3535
```
3636

37-
The URI is the HTTPS endpoint of your function or app. If your code is hosted in an Azure function app, the URI should include an [API key in the header or as a URI parameter](../azure-functions/functions-bindings-http-webhook-trigger.md#api-key-authorization) to authorize the request.
37+
The URI is the HTTPS endpoint of your function or app. When setting the URI, make sure the URI is secure (HTTPS). If your code is hosted in an Azure function app, the URI should include an [API key in the header or as a URI parameter](../azure-functions/functions-bindings-http-webhook-trigger.md#api-key-authorization) to authorize the request.
3838

39-
Alternatively, if your function or app is accessed through Azure managed identities and Azure roles, the custom skill can include an authentication token on the request if you set "authResourceId" in the [custom skill definition](cognitive-search-custom-skill-web-api.md):
39+
If instead your function or app uses Azure managed identities and Azure roles for authentication and authorization, the custom skill can include an authentication token on the request. The following points describe the requirements for this approach:
4040

4141
+ The search service, which sends the request on the indexer's behalf, must be [configured to use a managed identity](search-howto-managed-identities-data-sources.md) (either system or user-assigned) so that the caller can be authenticated by Azure Active Directory.
4242

4343
+ Your function or app must be [configured for Azure Active Directory](../app-service/configure-authentication-provider-aad.md).
4444

45-
+ " authResourceId" takes an application (client) ID, in a [supported format](../active-directory/develop/security-best-practices-for-app-registration.md#appid-uri-configuration): `api://<appId>`
46-
47-
When setting the URI, make sure the URI is secure (HTTPS).
45+
+ Your [custom skill definition](cognitive-search-custom-skill-web-api.md) must include an "authResourceId" property. This property takes an application (client) ID, in a [supported format](../active-directory/develop/security-best-practices-for-app-registration.md#appid-uri-configuration): `api://<appId>`.
4846

4947
By default, the connection to the endpoint will time out if a response is not returned within a 30-second window. The indexing pipeline is synchronous and indexing will produce a timeout error if a response is not received in that time frame. You can increase the interval to a maximum value of 230 seconds by setting the timeout parameter:
5048

articles/search/cognitive-search-custom-skill-web-api.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@ author: gmndrg
77
ms.author: gimondra
88
ms.service: cognitive-search
99
ms.topic: conceptual
10-
ms.date: 03/18/2022
10+
ms.date: 03/25/2022
1111
---
1212

1313
# Custom Web API skill in an Azure Cognitive Search enrichment pipeline
@@ -33,7 +33,7 @@ Parameters are case-sensitive.
3333
| Parameter name | Description |
3434
|--------------------|-------------|
3535
| `uri` | The URI of the Web API to which the JSON payload will be sent. Only **https** URI scheme is allowed |
36-
| `authResourceId` | (Optional) A string that if set, indicates that this skill should use a managed identity on the connection to the function or app hosting the code. The value of this property is the application (client) ID of the function or app's registration in Azure Active Directory. This value will be used to scope the authentication token retrieved by the indexer, and will be sent along with the custom Web skill API request to the function or app. Setting this property requires that your search service is [configured for managed identity](search-howto-managed-identities-data-sources.md) and your Azure function app is [configured for Azure Active Directory](../app-service/configure-authentication-provider-aad.md). |
36+
| `authResourceId` | (Optional) A string that if set, indicates that this skill should use a managed identity on the connection to the function or app hosting the code. The value of this property is the application (client) ID of the function or app's registration in Azure Active Directory. This value will be used to scope the authentication token retrieved by the indexer, and will be sent along with the custom Web skill API request to the function or app. Setting this property requires that your search service is [configured for managed identity](search-howto-managed-identities-data-sources.md) and your Azure function app is [configured for an Azure AD login](../app-service/configure-authentication-provider-aad.md). |
3737
| `httpMethod` | The method to use while sending the payload. Allowed methods are `PUT` or `POST` |
3838
| `httpHeaders` | A collection of key-value pairs where the keys represent header names and values represent header values that will be sent to your Web API along with the payload. The following headers are prohibited from being in this collection: `Accept`, `Accept-Charset`, `Accept-Encoding`, `Content-Length`, `Content-Type`, `Cookie`, `Host`, `TE`, `Upgrade`, `Via`. |
3939
| `timeout` | (Optional) When specified, indicates the timeout for the http client making the API call. It must be formatted as an XSD "dayTimeDuration" value (a restricted subset of an [ISO 8601 duration](https://www.w3.org/TR/xmlschema11-2/#dayTimeDuration) value). For example, `PT60S` for 60 seconds. If not set, a default value of 30 seconds is chosen. The timeout can be set to a maximum of 230 seconds and a minimum of 1 second. |

0 commit comments

Comments
 (0)