Create a Bridge

Attention

The XRPL EVM compatible sidechain implementation is a proof of concept extension to the XRP Ledger protocol and is for development purposes only. There is no official amendment currently and it is not available on the production Mainnet. The EVM compatible sidechain bridge is connected to the XRP Ledger Devnet. Do not send transactions in Mainnet.

The bridge create command enables you to set up a bridge.

Create a Config File

Create a JSON config file in this format:

{
    "lockingChain": {
        "type": "evm",
        "url": "https://rpc-evm-sidechain.peersyst.tech",
        "fundingPrivateKey": "****",
        "witnesses": [
            "0x96329A50d10a3F69311E4f4E108672926c51c474"
        ],
        "tokenCode": "USD",
        "tokenAddress": "0x92AE4ba2305F6c64E9715b60CF774784079C463B"
    },
    "issuingChain": {
        "type": "xrp",
        "url": "wss://sidechain-net1.devnet.rippletest.net",
        "fundingPrivateKey": "****",
        "witnesses": [
            "rpSspP5yYyomcSrgsohyKMCnu5oJsTMkYP"
        ]
    },
    "threshold": 1,
    "minRewardAmount": 1,
    "minCreateAmount": 20
}
KeyValue TypeRequiredDescriptionExample
lockingChainobjectYesThe locking chain information.
lockingChain.typestringYes"xrp" or "evm""xrp"
lockingChain.urlstringYesThe node URL of the locking chain."wss://sidechain-net1.devnet.rippletest.net"
lockingChain.fundingPrivateKeystringYesA private key that has enough balance in the locking chain to pay fees and activate witness accounts."0000000000000000000000000000000000000000000000000000000000000000"
lockingChain.witnessesarrayYesA set of locking chain addresses that will be bridge witnesses.["rpSspP5yYyomcSrgsohyKMCnu5oJsTMkYP"]
lockingChain.tokenCodestringYesThe token code in the locking chain. If the token code is "XRP", the bridge will use the native XRP currency."USD"
lockingChain.tokenAddressstringNoThe token issuer if XRPL, or the token address if EVM. Only required if the token code isn't XRP."rpSspP5yYyomcSrgsohyKMCnu5oJsTMkYP"
lockingChain.safeAddressstringNoOnly used if the locking chain is EVM, and the safe is already activated."0x0000000000000000000000000000000000000000"
issuingChainobjectYesThe issuing chain information.
issuingChain.typestringYes"xrp" or "evm""evm"
issuingChain.urlstringYesThe node URL of the locking chain."https://rpc-evm-sidechain.peersyst.tech"
issuingChain.fundingPrivateKeystringYesA private key that has enough balance in the issuing chain to pay fees and activate witness accounts."0000000000000000000000000000000000000000000000000000000000000000"
issuingChain.witnessesarrayYesA set of issuing chain addresses that will be bridge witnesses.["0x96329A50d10a3F69311E4f4E108672926c51c474"]
issuingChain.safeAddressstringNoOnly used if the issuing chain is EVM, and the safe is already activated."0x0000000000000000000000000000000000000000"
thresholdnumberYesThe amount of witness attestations needed in order to perform one bridge operation.1
minRewardAmountnumberYesThe minimum amount rewarded to the witnesses that perform attestations.1
minCreateAmountnumberYesThe minimum amount needed to perform a create account operation.50

Create the Bridge

Run the bridge create command:

evmcli bridge create -c config.json -e $PWD/usd-bridge.json