Bridge Contract
The bridge contract is used for submitting bridging intents. The contract accepts both encrypted and non-encrypted intents. The main entrypoint of this contract is thebridge function.
Bridge Function (Public)
sender- The original owner of the input funds. This address authorizes locking of tokens into escrow.
receiver- The address that will receive assets on the destination chain once the solver executes the intent.
relayer- The solver selected by the user. Only this address will be eligible to claim repayment after fulfillment.
inputToken- The token being locked on the source chain.
outputToken- The token expected on the destination chain.
inputAmount- The quantity of tokens transferred into escrow.
outputAmount- The amount the solver has committed to deliver on the destination chain.
destinationChainId- The identifier of the chain where execution will occur.
Bridge Function (Private)
bridge function differs from the public variant by supporting encrypted data types. These types do not store plaintext values directly on-chain. Rather, they act as references (handles) to encrypted data that is maintained and processed through a fully homomorphic encryption (FHE) system.