Skip to content

Commit e7b29d2

Browse files
authored
Merge pull request #202942 from eric-urban/patch-2
JWT access token
2 parents 3ca055b + 196f87a commit e7b29d2

File tree

1 file changed

+9
-9
lines changed

1 file changed

+9
-9
lines changed

articles/cognitive-services/authentication.md

Lines changed: 9 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,7 @@ ms.author: pafarley
1616
Each request to an Azure Cognitive Service must include an authentication header. This header passes along a subscription key or access token, which is used to validate your subscription for a service or group of services. In this article, you'll learn about three ways to authenticate a request and the requirements for each.
1717

1818
* Authenticate with a [single-service](#authenticate-with-a-single-service-subscription-key) or [multi-service](#authenticate-with-a-multi-service-subscription-key) subscription key
19-
* Authenticate with a [token](#authenticate-with-an-authentication-token)
19+
* Authenticate with a [token](#authenticate-with-an-access-token)
2020
* Authenticate with [Azure Active Directory (AAD)](#authenticate-with-azure-active-directory)
2121

2222
## Prerequisites
@@ -33,7 +33,7 @@ Let's quickly review the authentication headers available for use with Azure Cog
3333
|--------|-------------|
3434
| Ocp-Apim-Subscription-Key | Use this header to authenticate with a subscription key for a specific service or a multi-service subscription key. |
3535
| Ocp-Apim-Subscription-Region | This header is only required when using a multi-service subscription key with the [Translator service](./Translator/reference/v3-0-reference.md). Use this header to specify the subscription region. |
36-
| Authorization | Use this header if you are using an authentication token. The steps to perform a token exchange are detailed in the following sections. The value provided follows this format: `Bearer <TOKEN>`. |
36+
| Authorization | Use this header if you are using an access token. The steps to perform a token exchange are detailed in the following sections. The value provided follows this format: `Bearer <TOKEN>`. |
3737

3838
## Authenticate with a single-service subscription key
3939

@@ -118,9 +118,9 @@ curl -X POST 'https://api.cognitive.microsofttranslator.com/translate?api-versio
118118
--data-raw '[{ "text": "How much for the cup of coffee?" }]' | json_pp
119119
```
120120

121-
## Authenticate with an authentication token
121+
## Authenticate with an access token
122122

123-
Some Azure Cognitive Services accept, and in some cases require, an authentication token. Currently, these services support authentication tokens:
123+
Some Azure Cognitive Services accept, and in some cases require, an access token. Currently, these services support access tokens:
124124

125125
* Text Translation API
126126
* Speech Services: Speech-to-text REST API
@@ -130,15 +130,15 @@ Some Azure Cognitive Services accept, and in some cases require, an authenticati
130130
> QnA Maker also uses the Authorization header, but requires an endpoint key. For more information, see [QnA Maker: Get answer from knowledge base](./qnamaker/quickstarts/get-answer-from-knowledge-base-using-url-tool.md).
131131
132132
>[!WARNING]
133-
> The services that support authentication tokens may change over time, please check the API reference for a service before using this authentication method.
133+
> The services that support access tokens may change over time, please check the API reference for a service before using this authentication method.
134134
135-
Both single service and multi-service subscription keys can be exchanged for authentication tokens. Authentication tokens are valid for 10 minutes.
135+
Both single service and multi-service subscription keys can be exchanged for access tokens in JSON Web Token (JWT) format. Access tokens are valid for 10 minutes.
136136

137-
Authentication tokens are included in a request as the `Authorization` header. The token value provided must be preceded by `Bearer`, for example: `Bearer YOUR_AUTH_TOKEN`.
137+
Access tokens are included in a request as the `Authorization` header. The token value provided must be preceded by `Bearer`, for example: `Bearer YOUR_AUTH_TOKEN`.
138138

139139
### Sample requests
140140

141-
Use this URL to exchange a subscription key for an authentication token: `https://YOUR-REGION.api.cognitive.microsoft.com/sts/v1.0/issueToken`.
141+
Use this URL to exchange a subscription key for an access token: `https://YOUR-REGION.api.cognitive.microsoft.com/sts/v1.0/issueToken`.
142142

143143
```cURL
144144
curl -v -X POST \
@@ -166,7 +166,7 @@ These multi-service regions support token exchange:
166166
- `westus`
167167
- `westus2`
168168

169-
After you get an authentication token, you'll need to pass it in each request as the `Authorization` header. This is a sample call to the Translator service:
169+
After you get an access token, you'll need to pass it in each request as the `Authorization` header. This is a sample call to the Translator service:
170170

171171
```cURL
172172
curl -X POST 'https://api.cognitive.microsofttranslator.com/translate?api-version=3.0&from=en&to=de' \

0 commit comments

Comments
 (0)