The app tells Hellosign to send a document to one or more people for signature using an API call
Hellosign sends the document in the sequence that it needs to
Throughout the process it sends webhooks/events to our application, letting it know what's happening (someone viewed document, someone signed document, etc.).
When the document is signed we can allow users to download it by making an API call to Hellosign and retrieving a download link for it
Here's how to set it up:
Copy the Hellosign API Connector into your app.
Create a template in Hellosign and add all of the fields required into the template. Make sure that fields that the signer needs to fill out are assigned to them and fields that are automatically filled out are assigned to 'Sender'.
Modify the 'Send Contract' API call per the documentation, with the token for the account, the template ID, signer information, merge fields, etc. You should now be able to initiate the signature process.
Copy two webhooks ('hellosign1' and 'hellosign2') into your application. The reason for two webhooks is that Hellosign sends their event JSON as a single text field, which means we need to receive that field and then send the contents to another webhook, which will receive it as a JSON.
Also copy the 'This app' API Connector into your app - this is used to hit the 'hellosign2' webhook. Make sure to modify the URL and token parameter with the ones for this application.
Add the 'hellosign1' webhook URL to Hellosign, so that it starts sending events to the application.
Modify the logic in 'hellosign2' to do whatever it needs to do upon receiving a certain kind of event. the full event list can be found here.
You can also use the 'Retrieve files' call within the API connector to allow users to download completed PDFs.