Skip to main content
Kofax

API to return available document types

3029594

Question / Problem: 

Is there an API to return available document types?

Answer / Solution: 

Yes, the API function GetDocumentTypeIdentities is available on the CaptureDocumentService as of KTA 7.8.0.7+ and KTA 7.9.0.2+.  The 7.8.0.7 readme documents the following:

1618152 Case 26233609: Provide an API that returns list of valid document types

A new method was added to the Capture Document Service:

public Agility.Sdk.Model.Capture.DocumentTypeIdentityCollection GetDocumentTypeIdentities
    (string sessionId, Agility.Sdk.Model.Capture.ClassificationGroupIdentityCollection classificationGroups)
Member of Agility.Sdk.Services.CaptureDocumentService

Summary:
Get all the non-root document types in all the document groups referenced by the given classification groups. 
"Root" document types are for internal use only. If multiple classification groups reference the same document group, 
there will be duplicate entries

Parameters:
sessionId: A string that uniquely identifies the Session for the current logged on user. 
If the SessionId is invalid then an exception will be raised.
classificationGroups: A collection of ClassificationGroupIdentity objects

Returns:
A collection of DocumentTypeIdentity objects

KTA Package: DocumentTypesAPI.zip

As an example of the API, import the attached package and navigate to DocumentTypesAPI.form.  It allows you to provide the name of a Classification Group and return the document types available within it.

DocumentTypesAPIForm.png

View the form in the Designer to see how the API is called.

GetDocumentTypeIdentitiesConfig.png

 

Applies to:  

Product Version
KTA 7.8+

 

 

  • Was this article helpful?