...

/

Inter-Contract Execution

Inter-Contract Execution

Learn how Solidity smart contracts can interact with each other.

Native interoperability

A major advantage of blockchain development is that smart contracts can natively call each other's functions. Combined with the transparency of the blockchain, this makes Ethereum applications interoperable out of the box. Anyone can build new applications on top of existing ones, even if we don't know their source code.

Application binary interface (ABI)

Ethereum uses a standard format called the application binary interface (ABI) as a lower-level representation of compiled contracts. Just like an application programming interface (API), in traditional web development, it is a lower-level representation of a software’s interface. Using this representation, we can unambiguously refer to the methods and data structures in a contract, in a format that the EVM understands. This way, any deployed contracts can be called both from outside the blockchain (by Web3 clients) and for inter-contract code execution.

Calling external code

Since code execution in Solidity must be initiated by a transaction, we have to use an external ...