Skip to main content

Add document action

POST 

/documents/:documentId/actions

Add one or more actions to a document; this appends actions and does not replace previous actions

Each action type supports a different set of parameters as shown in the table below:

Action Parameters

ActionTypeParameterDescriptionExample
OCRocrParseTypesOcr Parsing strategy to useTEXT, FORMS, TABLES
OCRocrEngineOcr Engine to usetesseract or textract
OCRocrOutputTypeConvert OCR result to an Output format (textract table only)true
OCRocrNumberOfPagesNumber of pages to OCR (from start)-1
OCRaddPdfDetectedCharactersAsTextPDF Documents convert images to texttrue or false
FULLTEXTcharacterMaxMaximum number of characters to add to Fulltext destination-1
DOCUMENTTAGGINGengineTagging Engine to usechatgpt
DOCUMENTTAGGINGtagsComma-deliminted list of keywordsauthor,title,description
WEBHOOKurlWebhook URLhttps://yourdomain.com/webhook-endpoint
NOTIFICATIONnotificationTypeType of Notificationemail
NOTIFICATIONnotificationToCcNotification Carbon Copyemail@yourdomain.com
NOTIFICATIONnotificationToBccNotification Blind Carbon Copyemail@yourdomain.com
NOTIFICATIONnotificationSubjectNotification SubjectEmail Subject
NOTIFICATIONnotificationTextNotification as TextEmail Text
NOTIFICATIONnotificationHtmlNotification as HtmlEmail HTML Text
QUEUEqueueIdId of Queue
IDPmappingIdId of Mapping
EVENTBRIDGEeventBusNameThe name or ARN of the Amazon EventBridge to receive the event.

Request

Path Parameters

    documentId stringrequired

    Document Identifier

Query Parameters

    siteId string

    Site Identifier

Body

    actions

    object[]

    List of Actions

  • Array [

  • type DocumentActionType (string)required

    Type of the Document Action

    Possible values: [ANTIVIRUS, DOCUMENTTAGGING, FULLTEXT, NOTIFICATION, OCR, QUEUE, WEBHOOK, IDP, PUBLISH, PDFEXPORT, EVENTBRIDGE]

    parameters

    object

    ocrParseTypes string

    OCR: Parse types - TEXT, FORMS, TABLES

    ocrEngine OcrEngine (string)

    Type of OCR Engine to use

    Possible values: [TESSERACT, TEXTRACT]

    ocrOutputType OcrOutputType (string)

    OCR Engine output format (textract table only)

    Possible values: [CSV]

    ocrNumberOfPages string

    Number of pages to OCR (from start) (-1 all)

    addPdfDetectedCharactersAsText string

    OCR: For the rewriting of the PDF document, converting any image text to searchable text

    url string

    Webhook: Callback URL

    characterMax string

    Fulltext: Maximum number of characters (-1 unlimited, Typesense defaults to 2048 characters)

    engine string

    DocumentTagging: Engine to use for document tagging generation

    Possible values: [chatgpt]

    notificationType string

    Notification Type

    Possible values: [email]

    notificationToCc string

    Who to carbon copy on the notification to (comma-delimited list)

    notificationToBcc string

    Who to blind carbon copy on the notification to (comma-delimited list)

    notificationSubject string

    Subject of the notification

    notificationText string

    Text of the notification

    notificationHtml string

    Html of the notification

    tags string

    DocumentTagging: Comma-deliminted list of keywords to generate tags for

    mappingId string

    Id of Mapping

    eventBusName string

    The name or ARN of the event bus to receive the event

    queueId string

    Id of Queue

  • ]

Responses

200 OK

Response Headers

  • Access-Control-Allow-Origin

    string

  • Access-Control-Allow-Methods

    string

  • Access-Control-Allow-Headers

    string

Schema

    message string

    Document Action message

Loading...