This is an example full stack Node / Express / React web app showcasing the Anvil Etch e-sign API implemented with the node-anvil client.
This project is hosted at esign-demo.useanvil.com so you can try it without setting up the example app locally.
Anvil provides easy APIs for all things paperwork.
- PDF filling API - fill out a PDF template with a web request and structured JSON data.
- PDF generation API - send markdown or HTML and Anvil will render it to a PDF.
- Etch e-sign with API - customizable, embeddable, e-signature platform with an API to control the signing process end-to-end.
- Anvil Workflows (w/ API) - Webforms + PDF + e-sign with a powerful no-code builder. Easily collect structured data, generate PDFs, and request signatures.
Learn more on our Anvil developer page.
The Anvil Etch E-Signature API allows you to collect e-signatures from within your app. Send a signature packet including multiple PDFs, images, and other uploads to one or more signers. Templatize your common PDFs then fill them with your user's information before sending out the signature packet.
The app will create Signature Packets with up to two signers on two PDFs: both a templatized IRS W-4 PDF, and an adhoc NDA PDF that is uploaded for each new packet.
Data input by the user will be used to fill both PDFs before signing. Then the user will go through the signing process via email or the embedded signing process.
- The meat of the integration is on the server in src/server/routes/index.js
- The majority of an example
createEtchPacket
payload is in src/server/apiVariables.js
Clone this repo and set it up locally to create signature packets on your own Anvil account via the API.
- First create your own Anvil account
- The app will ask you to verify your email before continuing
- View your organization settings by clicking the building icon in the bottom left followed by the settings icon.
- Click API Settings in your organization navigation bar.
- Click "Add an API Key"
Now you are ready to set this example up!
# Fork this project + clone your fork, or just clone this repo
git clone https://github.com/...
cd anvil-e-signature-api-node-example
- Save a copy of
.env.example
at the root of this project as.env
. - Copy the development API key from your API settings page, then paste it in your
.env
file. - Start the app!
yarn install # Get all the deps
yarn dev # Start the server and client in dev mode
Visit http://localhost:8080
Watch the server logs. The logs will show pertinent JSON payloads being sent & received via the API.
If you have questions, email us at hello@useanvil.com.
# Build the production dist
yarn build
# Start production server
yarn start
# Run the linter, server tests, and client tests
yarn test
yarn lint # Only the linter
yarn test:server # Only the server tests
yarn test:client # Only the client tests