This is a Next.js project bootstrapped with create-next-app
.
First, run the development server:
npm run dev
# or
yarn dev
# or
pnpm dev
# or
bun dev
Open http://localhost:3000 with your browser to see the result.
You can start editing the page by modifying app/page.tsx
. The page auto-updates as you edit the file.
This project uses next/font
to automatically optimize and load Geist, a new font family for Vercel.
To learn more about Next.js, take a look at the following resources:
- Next.js Documentation - learn about Next.js features and API.
- Learn Next.js - an interactive Next.js tutorial.
You can check out the Next.js GitHub repository - your feedback and contributions are welcome!
The easiest way to deploy your Next.js app is to use the Vercel Platform from the creators of Next.js.
Check out our Next.js deployment documentation for more details.
This project exposes Cardano blockchain tools to AI agents and apps using the Model Context Protocol (MCP) and wraps the Blockfrost API for seamless Cardano blockchain data access.
Live demo: The MCP server is also deployed at https://mesh-mcp.vercel.app — you can use this URL directly in your MCP client (like Cursor) to try it out without running locally.
- Provides an MCP server endpoint at
/mcp
- Wraps the Blockfrost API to provide Cardano blockchain data
- Lets AI clients (like Cursor) call Cardano tools such as:
Address Tools
getAddressBalance
: Get the balance of an addressgetAddressUtxos
: Get the UTXOs for an addressgetAddressTransactions
: Get the transactions for an addressgetAddressExtended
: Get extended information for an addressgetAddressTotal
: Get total information for an addressgetAddressUtxosByAsset
: Get the UTXOs for an address and asset
Account Tools
getAccount
: Get the account info for a stake addressgetAccountRewards
: Get the rewards for a stake addressgetAccountHistory
: Get the history for a stake addressgetAccountDelegations
: Get the delegations for a stake addressgetAccountRegistrations
: Get the registrations for a stake addressgetAccountWithdrawals
: Get the withdrawals for a stake addressgetAccountMirs
: Get the MIRs (Move Instantaneous Rewards) for a stake addressgetAccountAddresses
: Get the addresses associated with a stake addressgetAccountAddressesAssets
: Get the assets for addresses associated with a stake addressgetAccountAddressesTotal
: Get the total balance for addresses associated with a stake addressgetAccountUtxos
: Get the UTXOs for a stake address
Asset Tools
getAssets
: Get a list of assetsgetAsset
: Get information about a specific assetgetAssetHistory
: Get the mint/burn history for a specific assetgetAssetTransactions
: Get the transaction history for a specific assetgetAssetAddresses
: Get the list of addresses holding a specific assetgetAssetsByPolicy
: Get the list of assets under a specific policy
Block Tools
getLatestBlock
: Get the latest blockgetLatestBlockTxs
: Get the transactions in the latest blockgetLatestBlockTxsCbor
: Get the CBOR of transactions in the latest blockgetBlock
: Get a block by hash or numbergetBlockNext
: Get the next block(s) after a given block hash or numbergetBlockPrevious
: Get the previous block(s) before a given block hash or numbergetBlockBySlot
: Get a block by slot numbergetBlockByEpochSlot
: Get a block by epoch number and slot numbergetBlockTxs
: Get the transactions in a block by hash or numbergetBlockTxsCbor
: Get the CBOR of transactions in a block by hash or numbergetBlockAddresses
: Get the addresses in a block by hash or number
Epoch Tools
getLatestEpoch
: Get the latest epochgetLatestEpochParameters
: Get the latest epoch parametersgetEpoch
: Get an epoch by numbergetEpochNext
: Get the next epoch(s) after a given epoch numbergetEpochPrevious
: Get the previous epoch(s) before a given epoch numbergetEpochStakes
: Get the stakes for a given epoch numbergetEpochStakesByPool
: Get the stakes for a given epoch number and pool IDgetEpochBlocks
: Get the blocks for a given epoch numbergetEpochBlocksByPool
: Get the blocks for a given epoch number and pool IDgetEpochParameters
: Get the parameters for a given epoch number
Governance Tools
getGovernanceDreps
: Get all DRepsgetGovernanceDrep
: Get a DRep by IDgetGovernanceDrepDelegators
: Get delegators for a DRep by IDgetGovernanceDrepMetadata
: Get metadata for a DRep by IDgetGovernanceDrepUpdates
: Get updates for a DRep by IDgetGovernanceDrepVotes
: Get votes for a DRep by IDgetGovernanceProposals
: Get all governance proposalsgetGovernanceProposal
: Get a governance proposal by tx_hash and cert_indexgetGovernanceProposalParameters
: Get parameters for a governance proposal by tx_hash and cert_indexgetGovernanceProposalWithdrawals
: Get withdrawals for a governance proposal by tx_hash and cert_indexgetGovernanceProposalVotes
: Get votes for a governance proposal by tx_hash and cert_indexgetGovernanceProposalMetadata
: Get metadata for a governance proposal by tx_hash and cert_index
Mempool Tools
getMempool
: Get the list of mempool transactionsgetMempoolByHash
: Get a mempool transaction by hashgetMempoolByAddress
: Get mempool transactions for an address
Metadata Tools
getMetadataTxsLabels
: Get all transaction metadata labelsgetMetadataTxsLabelsByLabel
: Get transaction metadata for a specific labelgetMetadataTxsLabelsByLabelCbor
: Get CBOR metadata for a specific label
Network Tools
getNetwork
: Get network informationgetNetworkEras
: Get network eras information
Pool Tools
getPools
: Get a list of poolsgetPoolsExtended
: Get a list of extended poolsgetPoolsRetired
: Get a list of retired poolsgetPoolsRetiring
: Get a list of retiring poolsgetPool
: Get information about a specific pool by pool_idgetPoolHistory
: Get the history for a specific pool by pool_idgetPoolMetadata
: Get the metadata for a specific pool by pool_idgetPoolRelays
: Get the relays for a specific pool by pool_idgetPoolDelegators
: Get the delegators for a specific pool by pool_idgetPoolBlocks
: Get the blocks for a specific pool by pool_idgetPoolUpdates
: Get the updates for a specific pool by pool_idgetPoolVotes
: Get the votes for a specific pool by pool_id
Script Tools
getScripts
: Get a list of scriptsgetScript
: Get information about a specific script by script_hashgetScriptJson
: Get the JSON for a specific script by script_hashgetScriptCbor
: Get the CBOR for a specific script by script_hashgetScriptRedeemers
: Get the redeemers for a specific script by script_hashgetScriptDatum
: Get the datum for a specific datum_hashgetScriptDatumCbor
: Get the CBOR for a specific datum_hash
Transaction Tools
getTx
: Get information about a transaction by hashgetTxUtxos
: Get UTXOs for a transaction by hashgetTxStakes
: Get stakes for a transaction by hashgetTxDelegations
: Get delegations for a transaction by hashgetTxWithdrawals
: Get withdrawals for a transaction by hashgetTxMirs
: Get MIRs for a transaction by hashgetTxPoolUpdates
: Get pool updates for a transaction by hashgetTxPoolRetires
: Get pool retires for a transaction by hashgetTxMetadata
: Get metadata for a transaction by hashgetTxMetadataCbor
: Get CBOR metadata for a transaction by hashgetTxRedeemers
: Get redeemers for a transaction by hashgetTxRequiredSigners
: Get required signers for a transaction by hashgetTxCbor
: Get CBOR for a transaction by hash
- Rapid prototyping: Instantly expose Blockfrost API functions to AI tools and chat agents for quick testing and iteration
- AI-powered automation: Use AI assistants (like Cursor) to automate Cardano queries, wallet checks, and data extraction in your dev workflow
- Tool integration: Connect your Cardano backend to any MCP-compatible client, making it easy to build, test, or demo blockchain features interactively
- Blockfrost integration: Leverage the comprehensive Blockfrost API through a simple MCP interface without managing API keys directly in your AI tools
Add this to your Cursor MCP config:
{
"mcpServers": {
"cardano-blockfrost": {
"url": "https://mesh-mcp.vercel.app/mcp"
}
}
}
Now you can ask Cursor to get Cardano balances, UTXOs, transactions, and staking data via the Blockfrost API!
- Start the server:
npm run dev
- MCP endpoint:
http://localhost:3000/mcp
- Configure your Blockfrost API keys in the environment variables:
NEXT_PUBLIC_BLOCKFROST_API_KEY_MAINNET
for mainnetNEXT_PUBLIC_BLOCKFROST_API_KEY_PREPROD
for preprod testnet
For more information, see:
app/[transport]/route.ts
- MCP server implementationapp/_utils/blockfrost.ts
- Blockfrost API wrapper functions- Blockfrost API Documentation - Complete API reference