Microsoft Cognitive Language Service - Text Analysis (preview:2025-05-15)

2025/04/16 • 4 new methods

AnalyzeText (new)
Description Request text analysis over a collection of documents.
Reference Link ¶

⚼ Request

POST:  /:analyze-text
{
api-version: string ,
showStats: boolean ,
body:
{
kind: enum ,
}
,
}

⚐ Response (200)

{
kind: enum ,
}

⚐ Response (default)

{
$headers:
{
x-ms-error-code: string ,
}
,
$schema:
{
error:
{
code: enum ,
message: string ,
target: string ,
details:
[
string ,
]
,
innererror:
{
code: enum ,
message: string ,
details: object ,
target: string ,
innererror: string ,
}
,
}
,
}
,
}
AnalyzeTextSubmitJob (new)
Description Submit a collection of text documents for analysis. Specify one or more unique tasks to be executed as a long-running operation.
Reference Link ¶

⚼ Request

POST:  /analyze-text/jobs
{
api-version: string ,
body:
{
displayName: string ,
analysisInput:
{
documents:
[
{
id: string ,
text: string ,
language: string ,
}
,
]
,
}
,
tasks:
[
{
taskName: string ,
kind: enum ,
}
,
]
,
defaultLanguage: string ,
cancelAfter: number ,
}
,
}

⚐ Response (202)

{
operation-location: string ,
}

⚐ Response (default)

{
$headers:
{
x-ms-error-code: string ,
}
,
$schema:
{
error:
{
code: enum ,
message: string ,
target: string ,
details:
[
string ,
]
,
innererror:
{
code: enum ,
message: string ,
details: object ,
target: string ,
innererror: string ,
}
,
}
,
}
,
}
AnalyzeTextJobStatus (new)
Description Get the status of an analysis job. A job can consist of one or more tasks. After all tasks succeed, the job transitions to the succeeded state and results are available for each task.
Reference Link ¶

⚼ Request

GET:  /analyze-text/jobs/{jobId}
{
api-version: string ,
jobId: string ,
showStats: boolean ,
top: integer ,
skip: integer ,
}

⚐ Response (200)

{
displayName: string ,
createdDateTime: string ,
expirationDateTime: string ,
jobId: string ,
lastUpdatedDateTime: string ,
status: enum ,
errors:
[
{
code: enum ,
message: string ,
target: string ,
details:
[
string ,
]
,
innererror:
{
code: enum ,
message: string ,
details: object ,
target: string ,
innererror: string ,
}
,
}
,
]
,
nextLink: string ,
tasks:
{
completed: integer ,
failed: integer ,
inProgress: integer ,
total: integer ,
items:
[
{
lastUpdateDateTime: string ,
status: enum ,
taskName: string ,
kind: enum ,
}
,
]
,
}
,
statistics:
{
documentsCount: integer ,
validDocumentsCount: integer ,
erroneousDocumentsCount: integer ,
transactionsCount: integer ,
}
,
}

⚐ Response (default)

{
$headers:
{
x-ms-error-code: string ,
}
,
$schema:
{
error:
{
code: enum ,
message: string ,
target: string ,
details:
[
string ,
]
,
innererror:
{
code: enum ,
message: string ,
details: object ,
target: string ,
innererror: string ,
}
,
}
,
}
,
}
AnalyzeTextCancelJob (new)
Description Cancel a long-running Text Analysis job.
Reference Link ¶

⚼ Request

POST:  /analyze-text/jobs/{jobId}:cancel
{
api-version: string ,
jobId: string ,
}

⚐ Response (202)

{
operation-location: string ,
}

⚐ Response (default)

{
$headers:
{
x-ms-error-code: string ,
}
,
$schema:
{
error:
{
code: enum ,
message: string ,
target: string ,
details:
[
string ,
]
,
innererror:
{
code: enum ,
message: string ,
details: object ,
target: string ,
innererror: string ,
}
,
}
,
}
,
}