Endpoint /documentprocessing/document/info

POST https://example.com/documentprocessing/document/info

POST

Returns information about the document and document content.

Authorization

This endpoint supports the OAuth authorization method:

OAuth

DS Server implements OAuth as the authorization method. Two flows are supported:

  • Authorization Code
  • Client Credentials

In order to use the Client Credentials flow, this method must be explicitly enabled in the admin portal of DS Server.

In both cases, a valid access token returned from the OAuth endpoints must be passed in a Bearer Authorization Header or as a Query Parameter.

Authorization Header

Header Field Description
Authorization

A Bearer authorization header (also called token authentication) contains the OAuth access token. The authorization method and a space i.e. "Bearer " is then put before your valid access token. For example:

Authorization: Bearer 4796E23054E64BC773CACBCAF24AD179DE9A3

Query Parameter

Query Parameter Description
access_token

The access token is passed directly in the endpoint URL as a query string. For example:

?access_token=4796E23054E64BC773CACBCAF24AD179DE9A3

Request Payload

Type Value
String The document encoded as a Base64 string.

Success Response

Status Type Description
200 DocumentInfo On success, the HTTP status code in the response header is 200 (OK). The response body contains a DocumentInfo object.

DocumentInfo

Name Type Value Optional
userDocumentProperties Dictionary<string, object> Contains all user defined document properties. yes
mergeBlocks MergeBlock Contains all merge blocks in the document. yes
mergeFields MergeField Contains all merge fields in the document. yes
documentKeywords String[] The document's keywords. The property value is null, if there are no keywords saved in the document. yes
author String The document's author. yes
creationDate DateTime The document's creation date. yes
creatorApplication String The application name that created the document. yes
documentSubject String The document's subject string. yes
documentTitle String The document's title string. yes
lastModificationDate DateTime The date the document has last been modified on. yes

MergeBlock

Name Type Value Optional
name String The name of the MergeBlock. yes
mergeBlocks MergeBlock[] Contains all merge blocks inside of the merge block (excluding blocks inside of nested merge blocks). yes
mergeFields MergeField[] Contains all merge fields inside of the merge block (excluding fields inside of nested merge blocks). yes

MergeField

Name Type Value Optional
dateTimeFormat String Specifies a string format which is applied to date / time values. yes
name String Gets and sets the name of the field. yes
numericFormat String Specifies a string format which is applied to numeric values. yes
preserveFormatting Boolean Specifies whether the formatting is preserved. yes
text String Gets and sets the text of the field. yes
textAfter String Gets and sets the text after the field. yes
textBefore String Gets and sets the text before the field. yes

Error Response

Status Description
401 A 401 (Unauthorized) is returned, if the user is not authorized.
400 A 400 (Bad Request) is returned, if DS Server is not licensed or the license is invalid.
400 A 400 (Bad Request) is returned, if no document was found in the body.
400 A 400 (Bad Request) is returned, if the uploaded document is not valid.