Documentation
Core Concepts
Instantiate Evolution

Instantiating Lucid Evolution

Lucid Evolution is a transaction building framework for Cardano which provides flexible off-chain development patterns. The library is designed with modularity in mind, allowing you to:

  • Build and simulate transactions
  • Work with different Cardano networks (Mainnet, Preprod, Preview, or Custom networks)
  • Choose from multiple provider options for blockchain interaction

Provider

To interact with the Cardano blockchain (querying UTxOs, datums, or protocol parameters), you'll need to configure a provider. Providers are chain indexing services that offer API access to blockchain data. Lucid Evolution supports several providers:

While a provider is required for blockchain queries, you can still use Lucid Evolution's transaction building features without one.

Provider selection

You can choose one of the following providers to use with Lucid Evolution

import { Lucid, Blockfrost } from "@lucid-evolution/lucid";
 
const lucid = await Lucid(
  new Blockfrost("https://cardano-preprod.blockfrost.io/api/v0", "<blockfrost-api-key>"),
  "Preprod"
);

Common Queries

By abstracting away the provider calls, Evolution library provides different methods to query on-chain data:

UTxOs (Unspent Transaction Outputs) are building blocks of Cardano's eUTxO model. A nuance from account-based models is that your wallet's balance is the sum of all UTxOs at your address.

const utxos = await lucid.utxosAt("addr_test...");