Document Classifiers - List Classifiers

List all document classifiers.

GET {endpoint}/documentintelligence/documentClassifiers?api-version=2024-02-29-preview

URI Parameters

Name In Required Type Description
endpoint
path True

string

The Document Intelligence service endpoint.

api-version
query True

string

The API version to use for this operation.

Request Header

Name Required Type Description
x-ms-client-request-id

string

uuid

An opaque, globally-unique, client-generated string identifier for the request.

Responses

Name Type Description
200 OK

PagedDocumentClassifierDetails

The request has succeeded.

Headers

x-ms-client-request-id: string

Other Status Codes

ErrorResponse

An unexpected error response.

Security

Ocp-Apim-Subscription-Key

Type: apiKey
In: header

OAuth2Auth

Type: oauth2
Flow: accessCode
Authorization URL: https://login.microsoftonline.com/common/oauth2/authorize
Token URL: https://login.microsoftonline.com/common/oauth2/token

Scopes

Name Description
https://cognitiveservices.azure.com/.default

Examples

Get Document Classifiers

Sample Request

GET https://myendpoint.cognitiveservices.azure.com/documentintelligence/documentClassifiers?api-version=2024-02-29-preview

Sample Response

{
  "value": [
    {
      "classifierId": "classifier1",
      "description": "Classifier1 description",
      "createdDateTime": "2022-07-30T00:00:00Z",
      "expirationDateTime": "2023-01-01T00:00:00Z",
      "apiVersion": "2024-02-29-preview",
      "docTypes": {
        "formA": {
          "azureBlobSource": {
            "containerUrl": "https://myStorageAccount.blob.core.windows.net/myContainer",
            "prefix": "formADocs/"
          }
        },
        "formB": {
          "azureBlobSource": {
            "containerUrl": "https://myStorageAccount.blob.core.windows.net/myContainer",
            "prefix": "formBDocs/"
          }
        }
      }
    },
    {
      "classifierId": "classifier2",
      "description": "Classifier2 description",
      "createdDateTime": "2022-07-30T00:00:00Z",
      "expirationDateTime": "2023-01-01T00:00:00Z",
      "apiVersion": "2024-02-29-preview",
      "docTypes": {
        "formB": {
          "azureBlobSource": {
            "containerUrl": "https://myStorageAccount.blob.core.windows.net/myContainer",
            "prefix": "formBDocs/"
          }
        },
        "formC": {
          "azureBlobSource": {
            "containerUrl": "https://myStorageAccount.blob.core.windows.net/myContainer",
            "prefix": "formCDocs/"
          }
        }
      }
    }
  ],
  "nextLink": "https://myendpoint.cognitiveservices.azure.com/documentintelligence/documentClassifiers?nextLink=nextLinkData"
}

Definitions

Name Description
AzureBlobContentSource

Azure Blob Storage content.

AzureBlobFileListContentSource

File list in Azure Blob Storage.

ClassifierDocumentTypeDetails

Classifier document type info.

ContentSourceKind

Type of content source.

DocumentClassifierDetails

Document classifier info.

Error

The error object.

ErrorResponse

Error response object.

InnerError

An object containing more specific information about the error.

PagedDocumentClassifierDetails

Paged collection of DocumentClassifierDetails items

Warning

The error object.

AzureBlobContentSource

Azure Blob Storage content.

Name Type Description
containerUrl

string

Azure Blob Storage container URL.

prefix

string

Blob name prefix.

AzureBlobFileListContentSource

File list in Azure Blob Storage.

Name Type Description
containerUrl

string

Azure Blob Storage container URL.

fileList

string

Path to a JSONL file within the container specifying a subset of documents.

ClassifierDocumentTypeDetails

Classifier document type info.

Name Type Description
azureBlobFileListSource

AzureBlobFileListContentSource

Azure Blob Storage file list specifying the training data for a classifier document type. Either azureBlobSource or azureBlobFileListSource must be specified.

azureBlobSource

AzureBlobContentSource

Azure Blob Storage location containing the training data for a classifier document type. Either azureBlobSource or azureBlobFileListSource must be specified.

sourceKind

ContentSourceKind

Type of training data source.

ContentSourceKind

Type of content source.

Name Type Description
azureBlob

string

Files in a path within an Azure Blob Storage container.

azureBlobFileList

string

A file list specifying individual files in an Azure Blob Storage container.

base64

string

Content represented via Base64 encoding.

url

string

Content at a specific URL.

DocumentClassifierDetails

Document classifier info.

Name Type Description
apiVersion

string

API version used to create this document classifier.

baseClassifierId

string

Base classifierId on top of which the classifier was trained.

classifierId

string

Unique document classifier name.

createdDateTime

string

Date and time (UTC) when the document classifier was created.

description

string

Document classifier description.

docTypes

<string,  ClassifierDocumentTypeDetails>

List of document types to classify against.

expirationDateTime

string

Date and time (UTC) when the document classifier will expire.

warnings

Warning[]

List of warnings encountered while building the classifier.

Error

The error object.

Name Type Description
code

string

One of a server-defined set of error codes.

details

Error[]

An array of details about specific errors that led to this reported error.

innererror

InnerError

An object containing more specific information than the current object about the error.

message

string

A human-readable representation of the error.

target

string

The target of the error.

ErrorResponse

Error response object.

Name Type Description
error

Error

Error info.

InnerError

An object containing more specific information about the error.

Name Type Description
code

string

One of a server-defined set of error codes.

innererror

InnerError

Inner error.

message

string

A human-readable representation of the error.

PagedDocumentClassifierDetails

Paged collection of DocumentClassifierDetails items

Name Type Description
nextLink

string

The link to the next page of items

value

DocumentClassifierDetails[]

The DocumentClassifierDetails items on this page

Warning

The error object.

Name Type Description
code

string

One of a server-defined set of warning codes.

message

string

A human-readable representation of the warning.

target

string

The target of the error.