Skip to content
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -69,7 +69,8 @@ Uri endpoint = new Uri("<endpoint>");
AzureKeyCredential credential = new AzureKeyCredential("<key>");
DocumentIntelligenceClient client = new DocumentIntelligenceClient(endpoint, credential);

Operation<AnalyzeResult> operation = await client.AnalyzeDocumentAsync(WaitUntil.Completed, "prebuilt-layout");
AnalyzeDocumentOptions analyzeRequest = new AnalyzeDocumentOptions();
Operation<AnalyzeResult> operation = await client.AnalyzeDocumentAsync(WaitUntil.Completed, "prebuilt-layout", analyzeRequest);
AnalyzeResult responseData = operation.Value;
]]></code>
This sample shows how to call AnalyzeDocumentAsync.
Expand All @@ -78,7 +79,8 @@ Uri endpoint = new Uri("<endpoint>");
AzureKeyCredential credential = new AzureKeyCredential("<key>");
DocumentIntelligenceClient client = new DocumentIntelligenceClient(endpoint, credential);

Operation<AnalyzeResult> operation = await client.AnalyzeDocumentAsync(WaitUntil.Completed, "customModel");
AnalyzeDocumentOptions analyzeRequest = new AnalyzeDocumentOptions();
Operation<AnalyzeResult> operation = await client.AnalyzeDocumentAsync(WaitUntil.Completed, "customModel", analyzeRequest);
AnalyzeResult responseData = operation.Value;
]]></code></example>
</member>
Expand All @@ -90,7 +92,8 @@ Uri endpoint = new Uri("<endpoint>");
AzureKeyCredential credential = new AzureKeyCredential("<key>");
DocumentIntelligenceClient client = new DocumentIntelligenceClient(endpoint, credential);

Operation<AnalyzeResult> operation = client.AnalyzeDocument(WaitUntil.Completed, "prebuilt-layout");
AnalyzeDocumentOptions analyzeRequest = new AnalyzeDocumentOptions();
Operation<AnalyzeResult> operation = client.AnalyzeDocument(WaitUntil.Completed, "prebuilt-layout", analyzeRequest);
AnalyzeResult responseData = operation.Value;
]]></code>
This sample shows how to call AnalyzeDocument.
Expand All @@ -99,7 +102,8 @@ Uri endpoint = new Uri("<endpoint>");
AzureKeyCredential credential = new AzureKeyCredential("<key>");
DocumentIntelligenceClient client = new DocumentIntelligenceClient(endpoint, credential);

Operation<AnalyzeResult> operation = client.AnalyzeDocument(WaitUntil.Completed, "customModel");
AnalyzeDocumentOptions analyzeRequest = new AnalyzeDocumentOptions();
Operation<AnalyzeResult> operation = client.AnalyzeDocument(WaitUntil.Completed, "customModel", analyzeRequest);
AnalyzeResult responseData = operation.Value;
]]></code></example>
</member>
Expand Down Expand Up @@ -205,7 +209,12 @@ Uri endpoint = new Uri("<endpoint>");
AzureKeyCredential credential = new AzureKeyCredential("<key>");
DocumentIntelligenceClient client = new DocumentIntelligenceClient(endpoint, credential);

Operation<AnalyzeBatchResult> operation = await client.AnalyzeBatchDocumentsAsync(WaitUntil.Completed, "customModel");
AnalyzeBatchDocumentsOptions analyzeBatchRequest = new AnalyzeBatchDocumentsOptions(new Uri("https://myStorageAccount.blob.core.windows.net/myOutputContainer?mySasToken"))
{
ResultPrefix = "trainingDocsResult/",
OverwriteExisting = true,
};
Operation<AnalyzeBatchResult> operation = await client.AnalyzeBatchDocumentsAsync(WaitUntil.Completed, "customModel", analyzeBatchRequest);
AnalyzeBatchResult responseData = operation.Value;
]]></code></example>
</member>
Expand All @@ -217,7 +226,12 @@ Uri endpoint = new Uri("<endpoint>");
AzureKeyCredential credential = new AzureKeyCredential("<key>");
DocumentIntelligenceClient client = new DocumentIntelligenceClient(endpoint, credential);

Operation<AnalyzeBatchResult> operation = client.AnalyzeBatchDocuments(WaitUntil.Completed, "customModel");
AnalyzeBatchDocumentsOptions analyzeBatchRequest = new AnalyzeBatchDocumentsOptions(new Uri("https://myStorageAccount.blob.core.windows.net/myOutputContainer?mySasToken"))
{
ResultPrefix = "trainingDocsResult/",
OverwriteExisting = true,
};
Operation<AnalyzeBatchResult> operation = client.AnalyzeBatchDocuments(WaitUntil.Completed, "customModel", analyzeBatchRequest);
AnalyzeBatchResult responseData = operation.Value;
]]></code></example>
</member>
Expand Down

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
directory: specification/ai/DocumentIntelligence
commit: 1caf268a55260f68057065bd2c37a83d2c000db5
commit: d1b33701d3d8bffd84d314913e26617896ec8606
repo: Azure/azure-rest-api-specs
additionalDirectories:
Loading