Attaching a Hook to a Thread
Every Hook that depends on previous stages in a Workflow must use the match_thread
function. This is how the Hook matches the incoming information to a thread waiting in that Stage.
Consider a Workflow for contract signature with four stages:
Fill Contract
- filling the necessary information with a FormSend Contract
- generating the document and sending it to the clientAwait Signature
- awaiting for the document to be sent backSend Confirmation
- notifying the people involved that the process has been completed
After the Fill Contract
and Send Contract
stages, threads stay waiting in the Await Signature
stage until the Hook acknowledges a contract has been signed to resume the process. To do so, use the match_thread
function.
info
Don't forget to check out the SDK reference.