Facet Transactions

Facet Transaction Format

Facet Transactions are similar to ordinary EIP-1559 Ethereum transactions as well as Optimism's Deposit transactions. Facet transactions have the EIP-2718 transaction type 0x46 (70 in base 10) and have the following fields:

  • chain_id: distinguishes the payload as being relevant only to Facet

    • mainnet chain_id will be 0x0face7

    • testnet chain_id will be 0x0face7a

  • to: L2 recipient's address, be it an EOA or L2 contract. Blank for contract creations.

  • value: amount of FCT being transferred in the transaction

  • max_fee_per_gas: max fee user is willing to pay per unit of gas for transaction inclusion in a block

  • gas_limit: The gas limit of the L2 transaction

  • data: EVM input data, i.e., ABI encoded contract call or contract creation code.

  • extra_data (optional): Appended data that increases payload size to increase FCT mint (see below).

Facet transactions have no signature field. Their "from" is inferred from the properties of the Ethereum transaction in which they are delivered.

Facet transactions must be serialized in this format for Facet nodes to process them:

0x46 ++ rlp_encode([chain_id, to, value, max_gas_fee, gas_limit, data, extra_data])

Sending Facet Transactions

There are two ways to make a Facet transaction reach a Facet node for inclusion in a block:

1

From EOA: Include the encoded Facet transaction in the calldata of an Ethereum L1 transaction sent to the Facet inbox address.

2

From L1 Smart Contract: Include the encoded Facet transaction in the non-indexed data of an Ethereum log whose first and only topic is the Facet event signature.

Last updated