Near Protocol Contract
Contract Address
Contract interface
Interact with contract interface
transfer_in
Transfer from Mapo to Near based on the proof data and event. Must attach enough NEAR funds to cover for storage of the proof.
input parameters
transfer_out_token
Transfer out tokens to other blockchain.
input parameters
transfer_out_native
Transfer out native token to other blockchain.
input parameters
deposit_out_native
Deposit out native token to MAP blockchain.
input parameters
Management Interface
init
Initialize the contract with configuration parameters.
input parameters
version
Get the version info of the current MCS contract.
deploy_mcs_token
Deploy MCS token contract. The deployed token can be minted/burnt by MCS contract.
input parameters
is_used_event
Check if the event is ussed or not.
input parameters
output parameters
set_metadata
Get the record information( validators, threshold and epoch) for the epecified epoch.
input parameters
controller
Get the controller of the MCS contract.
output parameters
set_controller
Set the controller of the MCS contract.
input parameters
controller_or_self
Check if the predecessor is controller or self.
output parameters
get_mcs_tokens
Get all deployed MCS tokens and their target chains.
output parameters
get_fungible_tokens
Get all registered fungible tokens and their target chains.
output parameters
get_native_token_to_chains
Get all registered native token target chains.
output parameters
add_native_to_chain
Add target chain for native token.
input parameters
remove_native_to_chain
Remove target chain for native token.
input parameters
add_mcs_token_to_chain
Allow the MCS token to be transfered to the target chain.
input parameters
remove_mcs_token_to_chain
Remove the target chain id from the allow list of the MCS token.
input parameters
valid_mcs_token_out
Check if the MCS token is allowed to be transfered to the target chain.
input parameters
output parameters
add_fungible_token_to_chain
Allow the fungible token to be transfered to the target chain.
input parameters
remove_fungible_token_to_chain
Remove the target chain id from the allow list of the fungible token.
input parameters
valid_fungible_token_out
Check if the fungible token is allowed to be transfered to the target chain.
input parameters
output parameters
Data structure
Here are some main data structure for map light client contract.
MapCrossChainService is the map cross chain service contract.
ReceiptProof includes the proof and the receipt to prove.
Last updated