🔀Router Contract
Contract
Used to initiate cross-chain transactions with us within your contract.

Methods
transferToken
The ERC20 token of the chain where the contract is located cross-chain
transfer
Cross-chain native main currency of the chain where the contract is located
Introduction to Data extended parameters
parameters
key
value
required
c
Security code, vc parameter obtained through routers interface, if the amount has a mantissa, it does not need to be passed here.
false
t
Target link receiving address (can be passed when ToStarknet and cross-address)
false
app
Your dapp name(short name), for statistics
false
format rule
url encode: param1=value1¶m2=value2
example:
c=9002&t=0xEFc6089224068b20197156A91D50132b2A47b908&app=YourAppName
hexadecimal encoding: Utils
ABI
[
{
"anonymous": false,
"inputs": [
{
"indexed": true,
"internalType": "address",
"name": "to",
"type": "address"
},
{
"indexed": false,
"internalType": "uint256",
"name": "amount",
"type": "uint256"
}
],
"name": "Transfer",
"type": "event"
},
{
"inputs": [
{
"internalType": "address",
"name": "to",
"type": "address"
},
{
"internalType": "bytes",
"name": "data",
"type": "bytes"
}
],
"name": "transfer",
"outputs": [
],
"stateMutability": "payable",
"type": "function"
},
{
"inputs": [
{
"internalType": "contract IERC20",
"name": "token",
"type": "address"
},
{
"internalType": "address",
"name": "to",
"type": "address"
},
{
"internalType": "uint256",
"name": "value",
"type": "uint256"
},
{
"internalType": "bytes",
"name": "data",
"type": "bytes"
}
],
"name": "transferToken",
"outputs": [
],
"stateMutability": "payable",
"type": "function"
},
{
"inputs": [
{
"internalType": "contract IERC20",
"name": "token",
"type": "address"
},
{
"internalType": "address[]",
"name": "tos",
"type": "address[]"
},
{
"internalType": "uint256[]",
"name": "values",
"type": "uint256[]"
}
],
"name": "transferTokens",
"outputs": [
],
"stateMutability": "payable",
"type": "function"
},
{
"inputs": [
{
"internalType": "address[]",
"name": "tos",
"type": "address[]"
},
{
"internalType": "uint256[]",
"name": "values",
"type": "uint256[]"
}
],
"name": "transfers",
"outputs": [
],
"stateMutability": "payable",
"type": "function"
}
]
open source
Last updated
Was this helpful?