Node.js Example launcher with 14 examples
We've just released a new collection of Node.js examples for the eSignature REST API that will execute in your browser.
Table of contents
The Docusign DevCenter team has now published a new set of code examples for Node.js that demonstrate how to implement several common workflows in a web application using the Express web framework and the Passport authentication middleware.
You can view the examples in the eg-03-node-auth-code-grant Github repository. The Readme file for the repository provides step-by-step instructions for installing and running the software on your development machine.
The example software implementation demonstrates the following workflows:
Authentication Example The software demonstrates how to use OAuth Authorization Code Grant to authenticate with Docusign. The software uses the popular Passport middleware and the Docusign-Passport strategy library to smoothly handle the details of the OAuth authentication.
Embedded Signing Ceremony
Sends an envelope and uses an embedded signing ceremony for the first signer. With embedded signing, the Docusign signing ceremony is initiated from your website.
API methods used: Envelopes::create and EnvelopeViews::createRecipient.
Send an envelope with a remote (email) signer and cc recipient
The envelope sent in this example includes a pdf, Word, and HTML document. Anchor text (AutoPlace) is used to position the signing fields in the documents.
API method used: Envelopes::create.
List envelopes in the user's account
Lists the envelopes created in the last 30 days.
API method used: Envelopes::listStatusChanges.
Get an envelope's basic information and status
Lists the basic information about a specific envelope, including its overall status. Additional API/SDK methods may be used to get additional information about the envelope, its documents, recipients, or other properties.
API method used: Envelopes::get.
List an envelope's recipients and their status
Lists the envelope's recipients and their current status.
API method used: EnvelopeRecipients::list.
List an envelope's documents
Lists each document contained in a specified envelope.
API method used: EnvelopeDocuments::list.
Download a document from an envelope
Downloads a document or a set of documents from an envelope. An envelope's documents can be downloaded one by one or as a complete set.
API method used: EnvelopeDocuments::get.
Create a template
Programmatically creates a template with two roles, signer, and cc.
API methods used: Templates::list, Templates::create.
Send an envelope using a template
Send an envelope using binary document transfer
Embedded sending
Embedded Docusign web tool
Embedded Signing Ceremony from a template with an added document
Send an envelope with an order form, including a payment field.
Node.js Promises
The examples also demonstrate how the Node.js util.promisify method may be used with the Node.js SDK and modern promise software patterns.
Try it out
If you’re a Node.js developer, try out the software and let us know your comments via developers@docusign.com.
We’re in the process of porting the software to our other SDKs, so stay tuned for further announcements!
Larry Kluger has over 40 years of tech industry experience as a software developer, developer advocate, entrepreneur, and product manager. An award-winning speaker prominent StackOverflow contributor, he enjoys giving talks and helping the ISV and developer communities.
Twitter: @larrykluger
LinkedIn: https://www.linkedin.com/in/larrykluger/
Related posts