Workflow Activities

This page lists the public workflow activities that are available in the platform.

Create Document Type From Interaction Run
createDocumentTypeFromInteractionRun
Parameters
CreateDocumentTypeFromInteractionRunParams
run
ExecutionRun
The execution run object to use. Required. Not required in params since it is usually fetched
updateObjectId
optionalstring
If defined then update the object type with the created type
Returns
void
Create Or Update Document From Interaction Run
createOrUpdateDocumentFromInteractionRun
Parameters
CreateOrUpdateObjectFromInteractionRunParams
run_id
optionalstring
The execution run object to use. Required. Not required in params since it is usually fetched
object_type
optionalstring
The document type to use. Required if update_existing_id is false. Not required in params since it is usually fetched
update_existing_id
optionalstring
The id of the document to update. If not provided, a new document will be created
fallback_name
optionalstring
parent
optionalstring
Returns
void
Update Document From Interaction Run
updateDocumentFromInteractionRun
Parameters
UpdateDocumentFromInteractionRunParams
run
optionalExecutionRun
The execution run object to use. Required. Not required in params since it is usually fetched
Returns
void
Chunk Document
chunkDocument
Parameters
ChunkDocumentParams
force
optionalboolean
interactionName
optionalstring
docPartType
optionalstring
Returns
Promise<ChunkDocumentResult>
Create Pdf Document From Source
createPdfDocumentFromSource
Create a new PDF by extrracting pages from a source PDF @returns
Parameters
CreatePdfDocumentFromSourceParams
target_object_type
string
title
string
filename
optionalstring
pages
number[]
parent
optionalstring
Returns
void
Execute Interaction
executeInteraction
Parameters
ExecuteInteractionParams
interactionName
string
prompt_data
Record<string, any>
truncate
optionalRecord<string, number | inline object>
Returns
void
Extract Document Text
extractDocumentText
Parameters
ExtractDocumentTextParams
Returns
Promise<TextExtractionResult>
Generate Document Properties
generateDocumentProperties
Parameters
GenerateDocumentPropertiesParams
typesHint
optionalstring[]
truncate
optionalnumber | inline object
truncate the input doc text to the specified max_tokens
interactionName
optionalstring
use_vision
optionalboolean
Returns
void
Generate Embeddings
generateEmbeddings
Parameters
GenerateEmbeddingsParams
model
optionalstring
environment
optionalstring
force
optionalboolean
type
SupportedEmbeddingTypes
textimageproperties
Returns
void
Generate Image Rendition
generateImageRendition
Parameters
GenerateImageRenditionParams
max_hw
number
format
Keyof FormatEnum
avifdzfitsgifheifinputjpegjpgjp2jxlmagickopenslidepdfpngppmrawsvgtifftifvwebp
multi_page
optionalboolean
Returns
void
Generate Or Assign Content Type
generateOrAssignContentType
Parameters
GenerateOrAssignContentTypeParams
typesHint
optionalstring[]
truncate
optionalnumber | inline object
truncate the input doc text to the specified max_tokens
interactionNames
optionalinline object
The name of the interaction to execute @default SelectDocumentType
Returns
void
Notify Webhook
notifyWebhook
Parameters
NotifyWebhookParams
target_url
string
method
GET | POST
payload
Record<string, any>
headers
optionalRecord<string, string>
Returns
void
Set Document Status
setDocumentStatus
We are using a union type for the status parameter since typescript enumbs breaks the workflow code generation @param objectId @param status
Parameters
SetDocumentStatusParams
status
ContentObjectStatus
createdprocessingcompletedfailedarchived
Returns
void

Was this page helpful?