Signing transactions

Developers can sign blockchain transactions using their API keys and the wallets they have access to.

📘

This feature is only available for EVM and Solana based blockchains.

Required Scopes

  • WALLET_TRANSACTION_SIGN

How to sign a transaction

Here's an example curl snippet to show how to send the request:

curl "https://staging.crossmint.com/api/v1-alpha1/wallets/ethereum:0x7e3c09cB46A351Db7834c0E0Bc0CB0cD79A/transactions/signatures" \
  -H "X-PROJECT-ID: your_project_id" \
  -H "X-CLIENT-SECRET: your_client_secret" \
  -H 'Content-Type: application/json' \
  --data '
  {
    "transaction": {
      "nonce": 32168,
      "gasPrice": "34329341655",
      "gasLimit": 21000,
      "to": "0x4675c7e5baafbffbca748158becba61ef3b03",
      "value": "37821945100437496",
      "data": "",
      "from": "0x199d5ed7f45f4ee35960cf22eade205b253f"
    }
  }
'

Transaction parameters explained:

ParameterTypeDescription
tostringThe destination address.
valuestringThe amount of Ether to send, in wei.
gasLimitnumberThe maximum amount of gas to be used.
gasPricestringThe price of gas in Gwei.
noncenumberThe transaction nonce.
chainIdstringThe ID of the chain (e.g., 1 for the Ethereum mainnet).
datastringAny additional data to be included in the transaction.