Command-line tools for Cardano blockchain interactions and Masumi payment system integration.
bun installCreate a .env file with:
# Blockfrost API keys
BLOCKFROST_API_KEY_MAINNET=your_mainnet_api_key
BLOCKFROST_API_KEY_PREPROD=your_preprod_api_key
BLOCKFROST_API_KEY_PREVIEW=your_preview_api_key
# Optional network selection (defaults to preprod)
NETWORK=preprod
# Masumi payment service configuration
MASUMI_PAYMENT_SERVICE_URL=https://masumi-payment-service.up.railway.app/api/v1
MASUMI_API_KEY=your_admin_key
MASUMI_AGENT_IDENTIFIER=your_agent_identifier
MASUMI_SELLER_VKEY=your_seller_verification_key
MASUMI_NETWORK=PreprodCheck ADA balance for any Cardano address:
bun run check-balance --address addr_test1qz... --network preprodGenerate new Cardano wallets compatible with standard wallets:
bun run create-wallet --name my_wallet --network preprodCreates timestamped files:
.mnemonic- 24-word recovery phrase.addr- Cardano address.vkey- Verification key hash
Transfer ADA between wallets:
bun run send-ada --recipient addr_test1qz... --amount 5.0 --mnemonic ./wallet.mnemonic --network preprodTools for interacting with the Masumi decentralized payment system for AI agents.
bun run masumi-payment-create --input-data '{"task": "analysis"}' --output-file payment.jsonbun run masumi-payment-check --file payment.jsonPayment States:
FundsLocked- ✅ Payment confirmedResultSubmitted- ✅ Work completednull/pending- ⏳ ProcessingRefundRequested- ❌ Failed
bun run masumi-purchase-create --file payment.jsonComplete workflow for agent payments:
# 1. Create payment request
bun run masumi-payment-create \
--input-data '{"service": "document analysis", "pages": 10}' \
--output-file doc-payment.json
# 2. Lock funds
bun run masumi-purchase-create --file doc-payment.json
# 3. Monitor until FundsLocked
bun run masumi-payment-check --file doc-payment.json
# Payment confirmed when status shows "FundsLocked"The Masumi system enables:
- Decentralized AI agent payments on Cardano blockchain
- Trustless escrow with smart contracts
- Agent discovery and hiring through payment service
- Result delivery with payment confirmation
Agents register with the Masumi registry, users create payment requests, lock funds through purchases, and receive work results once payments are confirmed on-chain.