Prerequisites & Setup: MetaMask, DocuSeal, and Infura

Before we can build our backend or deploy the smart contract, we need to set up a few essential tools and services. This guide will walk you through configuring your MetaMask wallet, preparing a document template in DocuSeal, and getting an API key from Infura.

MetaMask

This guide will not cover the basics of MetaMask in detail. It is assumed that you have already set up a MetaMask wallet and know how to switch to the Sepolia test network.

If not, here are some useful links to get you started:

(Choose the browser extension, as we will need it for deploying our contract.)

(You will need this to select the Sepolia testnet.)

(Use this to fund your wallet with test ETH, which is required for deploying the contract and sending transactions.)

DocuSeal

Go to https://docuseal.com/ and create a free account. DocuSeal provides an API for document signing that we will use in this project.

After registration, you will see your dashboard.

  1. Click on “Upload New Document” and upload the document you want to be signed.

  2. Once uploaded, you will see your document with an instrument panel on the right. Click the “Signature” button.

  3. Next, draw a signature field in the desired location on your document, like so:

  4. That's all that's needed for the field setup. Now, save the template by clicking the "Save" button.

  5. After saving, you will be taken to the document submissions window. From here, we need to get a link to the template. Click the “Link” button.

  6. A window will appear with a shareable link.

We don't need the entire link, only the template's slug. The link follows this structure: https://docuseal.com/d/<TEMPLATE_SLUG>.

In this example, the slug is aRN94eep7Dbr5x.

💡
We will use this TEMPLATE_SLUG in a later step when we configure our backend. Make sure to save it.

That's all we need from DocuSeal for now.

Infura

Next, we need to set up a node provider. Since our Rust program won’t be running in a wallet or browser, it needs a direct connection to an Ethereum node. This means giving it a JSON-RPC endpoint from a service like Infura, Alchemy, or a local node, so it knows where to send transactions and get blockchain data.

For this guide, we will use Infura.

  1. Go to https://www.infura.io/ and create a free account.

  2. Once registered, create a new API key.

We will use this API key for Sepolia endpoint: wss://sepolia.infura.io/ws/v3/<YOUR_API_KEY>.

We will use this URL to connect our Rust application to the Ethereum blockchain.

0
Subscribe to my newsletter

Read articles from Yelyzaveta Dymchenko directly inside your inbox. Subscribe to the newsletter, and don't miss out.

Written by

Yelyzaveta Dymchenko
Yelyzaveta Dymchenko