Skip to main content

Guide to on-chain Transactions

Overview

The on-chain Transactions capability in Cortex enables seamless interaction with blockchain networks directly through the Cortex interface. This powerful feature allows users to draft, analyze, and execute transactions across multiple chains without leaving the chat.

At its most advanced level, Cortex can help formulate complex multi-step transaction sequences spanning several protocols and blockchains abstracting away much of the technical complexity – all in one place.

Key Features:

  • Multi-chain Transaction Support: Create transactions across Ethereum, Solana, Polygon, Arbitrum, Optimism, and other major networks
  • Smart Contract Interaction: Generate function calls to interact with various DeFi protocols and dApps
  • Transaction Simulation: Preview transaction outcomes before execution
  • Transaction Monitoring: Track and report on transaction status post-submission
  • Batch Transaction Building: Construct complex multi-step transaction sequences

Good vs. Bad Prompts: Good transaction prompts specify the exact action intended, the blockchain network and token amounts. Bad prompts are ambiguous about the action type, lack specific token amounts, or fail to specify which network the transaction should occur on.

Prompt Library:

Prompt ExamplePurposeExpected Output
"Swap 0.5 ETH for USDC on Uniswap V3 (Ethereum mainnet) with maximum 0.5% slippage."Basic DEX swap transactionPrepared swap transaction ready for wallet signature, with gas estimates and expected output amount
"Swap 0.5 ETH for USDC on Uniswap V3 (Ethereum mainnet) with maximum 0.5% slippage, then bridge that USDC to the Base Blockchain to purchase VIRTUAL"Multi-step DeFi interactionSeries of transactions (swap, bridge) with appropriate gas settings and confirmation requirements
"Please sell all of my alt coins on the Ethereum blockchain and consolidate them into USDC"Complex transaction sequenceConstruct an entire transaction sequence in a natural language interface, with the model understanding the entire sequence and the implications of each step

Supported Transaction Types

Today, Cortex Protocol supports a wide variety of transaction types across multiple blockchains:

  • Token Transfers: Direct sending of native coins and tokens between addresses
  • Token Swaps: Exchange between different tokens using DEX protocols
  • Cross-chain Operations: Bridging assets between different blockchain networks
  • Batch Transactions: Multiple operations executed in sequence or bundled together

Soon:

  • Liquidity Operations: Adding, removing, or adjusting liquidity positions in AMMs and pools
  • Lending Interactions: Supplying, borrowing, repaying, or liquidating positions on lending platforms
  • Staking Operations: Delegation, staking, and unstaking of assets in PoS networks
  • Governance Actions: Voting, proposal submission, and delegation in DAO ecosystems
  • NFT Transactions: Minting, purchasing, listing, and transferring NFTs