Overview

With Crossmint’s Wallets API, you can create an MPC-secured EOA custodial wallet. This means that:

  • Wallets are managed by a secure, institutional-grade system for key management
  • Transactions are approved automatically, eliminating the need for users to handle gas fees or complex approvals

This quickstart demonstrates how to create such wallets and send transactions from them on any environment.

1. Create and Configure a Crossmint Project

To get started, create a developer account in the Crossmint Staging Console. Open that link, sign in, and accept the dialog to continue.

Crossmint offers two consoles: staging, for development and testing, and www, for production.

2. Get an API Key

Once you log in to the console, the next step is to create an API key.

  • Navigate to project Integrate > API Keys, and click the “Create new key” button in the “Server-side keys” section
  • Under the Wallets API category, select the scopes wallets.create, wallets.read, wallets.fund, wallets:nfts.read, wallets:transactions.create and wallets:transactions.read
  • Click “Create server key” to save the key for the next step

3. Create Your Wallet

To create a new custodial EOA wallet, make a POST request to the Create Wallet endpoint:

4. Use Your Wallet

Now that your wallet is created, it can interact with contracts such as deployed NFT collections to mint NFTs.

For the purposes of this quickstart, you will work with an NFT collection already deployed by Crossmint on polygon-amoy.

The NFT collection’s contract address is 0x5c030a01e9d2c4bb78212d06f88b7724b494b755 and you can see it here.

A. Prepare Transaction

The contract’s ABI (Application Binary Interface), which acts as a standardized interface for interacting with the NFT collection’s contract, contains a mintTo function that can be used to mint NFTs.

To perform the transaction, we first need to generate the transaction data needed to call the mintTo function.

B. Create Transaction

Now the encoded transaction data can be passed to the Create Transaction endpoint along with the contract’s address.

The transaction is pending, and will be confirmed onchain after a few seconds. Crossmint automatically broadcasts the transaction onchain.

5. Monitor Transaction Status

To monitor the transaction status, you can call the Get Transaction endpoint.

The API will return the full transaction, including it’s status, which can be one of the following:

  • pending: Broadcasting transaction onchain
  • success: Transaction successfully executed onchain
  • failed: Transaction failed during execution

6. Fetch the NFT

To ensure that the NFT has been minted to your wallet, call the Get NFTs from Wallet endpoint.