Skip to content

Commit cdb802e

Browse files
authored
Merge pull request #114091 from PatrickFarley/formre-track2-sdk
[cog serv] Formre track2 sdk
2 parents d01147d + d2e10fc commit cdb802e

16 files changed

+2038
-208
lines changed

.openpublishing.redirection.json

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -48505,6 +48505,11 @@
4850548505
"redirect_url": "/azure/cognitive-services/form-recognizer/quickstarts/python-receipts",
4850648506
"redirect_document_id": false
4850748507
},
48508+
{
48509+
"source_path": "articles/cognitive-services/form-recognizer/quickstarts/dotnet-sdk.md",
48510+
"redirect_url": "/azure/cognitive-services/form-recognizer/quickstarts/client-library?pivots=programming-language-csharp",
48511+
"redirect_document_id": false
48512+
},
4850848513
{
4850948514
"source_path": "articles/cognitive-services/Content-Moderator/Review-Tool-User-Guide/Upload-Images.md",
4851048515
"redirect_url": "/azure/cognitive-services/content-moderator",

articles/cognitive-services/form-recognizer/includes/create-resource.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,7 @@ Go to the Azure portal and <a href="https://ms.portal.azure.com/#create/Microsof
1717
| **Pricing tier** | The cost of your resource depends on the pricing tier you choose and your usage. For more information, see the API [pricing details](https://azure.microsoft.com/pricing/details/cognitive-services/).
1818
| **Resource group** | The [Azure resource group](https://docs.microsoft.com/azure/cloud-adoption-framework/govern/resource-consistency/resource-access-management#what-is-an-azure-resource-group) that will contain your resource. You can create a new group or add it to a pre-existing group. |
1919

20-
> [!IMPORTANT]
20+
> [!NOTE]
2121
> Normally when you create a Cognitive Service resource in the Azure portal, you have the option to create a multi-service subscription key (used across multiple cognitive services) or a single-service subscription key (used only with a specific cognitive service). However, because Form Recognizer is a preview release, it is not included in the multi-service subscription, and you cannot create the single-service subscription unless you use the link provided in the Welcome email.
2222
23-
When your Form Recognizer resource finishes deploying, find and select it from the **All resources** list in the portal. Then select the **Quick start** tab to view your subscription data. Save the values of **Key1** and **Endpoint** to a temporary location. You'll use them in the following steps.
23+
When your Form Recognizer resource finishes deploying, find and select it from the **All resources** list in the portal. Your key and endpoint will be located on the resource's key and endpoint page, under resource management. Save both of these to a temporary location before going forward.
Lines changed: 53 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,53 @@
1+
---
2+
title: "Environment variables"
3+
description: set environment variables
4+
services: cognitive-services
5+
author: PatrickFarley
6+
manager: nitinme
7+
ms.service: cognitive-services
8+
ms.subservice: forms-recognizer
9+
ms.topic: include
10+
ms.date: 05/06/2020
11+
ms.author: pafarley
12+
---
13+
14+
Using your key and endpoint from the resource you created, create two environment variables for authentication:
15+
16+
* `FORM_RECOGNIZER_KEY` - The resource key for authenticating your requests.
17+
* `FORM_RECOGNIZER_ENDPOINT` - The resource endpoint for sending API requests. It will look like this:
18+
* `https://<your-custom-subdomain>.api.cognitive.microsoft.com`
19+
20+
>[!NOTE]
21+
> The endpoints for non-trial resources created after July 1, 2019 use the custom subdomain format shown below. For more information and a complete list of regional endpoints, see [Custom subdomain names for Cognitive Services](https://docs.microsoft.com/azure/cognitive-services/cognitive-services-custom-subdomains).
22+
23+
Use the following instructions to set environment variables on your operating system.
24+
25+
#### [Windows](#tab/windows)
26+
27+
```console
28+
setx FORM_RECOGNIZER_KEY <replace-with-your-form-recognizer-key>
29+
setx FORM_RECOGNIZER_ENDPOINT <replace-with-your-form-recognizer-endpoint>
30+
```
31+
32+
After you add the environment variables, close and reopen the console window.
33+
34+
#### [Linux](#tab/linux)
35+
36+
```bash
37+
export FORM_RECOGNIZER_KEY=<replace-with-your-product-name-key>
38+
export FORM_RECOGNIZER_ENDPOINT=<replace-with-your-product-name-endpoint>
39+
```
40+
41+
After you add the environment variable, run `source ~/.bashrc` from your console window to make the changes effective.
42+
43+
#### [macOS](#tab/unix)
44+
45+
Edit your `.bash_profile`, and add the environment variable:
46+
47+
```bash
48+
export FORM_RECOGNIZER_KEY=<replace-with-your-product-name-key>
49+
export FORM_RECOGNIZER_ENDPOINT=<replace-with-your-product-name-endpoint>
50+
```
51+
52+
After you add the environment variables, run `source .bash_profile` from your console window to make the changes effective.
53+
***

0 commit comments

Comments
 (0)