For Relay
API groups provided for Relay use
get_hashlock
Brief Description
API for obtaining hashlock.
Request URL
POST /evm-client-{config.system_chain_id}/relay/get_hashlock
Request Method
POST
Request Example
json
{
"preimage": "0x3e64b809cf89aa6b60ab3deefdc6532ca21bd939b4f9ec95f530eb0fe3c7855b"
}Successful Return Example
json
{
"code": 200,
"hashlock": "your_generated_hashlock_here"
}get_system_fee
Brief Description
API for obtaining the system fee rate.
Request URL
POST /evm-client-9006/relay/get_system_fee
Request Method
POST
Request Example
json
{}Successful Return Example
json
{
"code": 200,
"fee": 0
}Explanation of Parameters in Successful Return Example
code: Status codefee: Returned information
get_signer_from_eip712
Brief Description
API to obtain the signer's address based on the EIP712 signature.
Request URL
/evm-client-${config.system_chain_id}/relay/get_signer_from_eip712
Request Method
POST
Request Example
json
{
"signature": "0x6c5380dcb2fa9b42110e172d9bca2e5099e69a5b0b1f476302c46accf6611d7b4ce6753480fcede6e10097558350f4497a88cbacad0416f475e64e40484043dc1c",
"value": {
"src_chain_id": 501,
"src_address": "2JPAxkrtXnJpc1SQUsRxHk8n4beCkDPb9k6ZVbWYCXdM",
"src_token": "0xc6fa7af3bedbad3a3d65f36aabc97431b1bbe4c2d2f6e0e47ca60203452f5d61",
"src_amount": "20332189",
"dst_chain_id": 9006,
"dst_address": "0x28623BF8E872FFAE6e2955a176dFCd10B97a09b3",
"dst_token": "0x55d398326f99059fF775485246999027B3197955",
"dst_amount": "20271192430000000000",
"dst_native_amount": "0",
"requestor": "7DEUEDxXmKcirJifrTqKeV6ApchffyH15bh4CaxmJX1W",
"lp_id": "maximilianus.myterminus.com",
"agreement_reached_time": 1732065997,
"expected_single_step_time": 120,
"tolerant_single_step_time": 240,
"earliest_refund_time": 1732067078
}
}Successful Return Example
json
{
"code": 200,
"address": "0x..." // actual returned address value
}Explanation of Parameters in Successful Return Example
code: Status codeaddress: Signer's address
confirm_out
Brief Description
API to confirm the transfer out.
Request URL
/evm-client-${config.system_chain_id}/relay/behalf/confirm_out
Request Method
POST
Request Example
json
{
"transaction_type": "LOCAL_PADDING",
"command_transfer_confirm": {
"uuid": "0x476088fddc9be69aa528afc3843d059cc2f75357381a821a7b6c009cc2d25445",
"sender": "0x28623BF8E872FFAE6e2955a176dFCd10B97a09b3",
"user_receiver_address": "0xC62a61B0C801A92CCfc1f90C49528ae4B0E160e6",
"token": "0x55d398326f99059fF775485246999027B3197955",
"token_amount": "20393369000000000000",
"eth_amount": "0",
"hash_lock": "0xc5f1e0e629b6a0eb3c44b608f06ba831adf6f0e9ad47efa9cc0a3f01114e40a4",
"agreement_reached_time": 1732013956,
"expected_single_step_time": 60,
"tolerant_single_step_time": 120,
"earliest_refund_time": 1732014497,
"preimage": "0xbfe5609640c523dc8b72b1feffb568e18ff7bd8b9a40350dfa99173358df5549",
"append_information": "{\"user_account_id\":\"0x5c48523b82474e6a95e2fd4afc64deb470d1239d997d38ea332227eef84107dd\"}",
"transfer_id": "0xa938aefc63bd402bccc2caab7274328016ab572c3d4885dbac89946df43dc6e8"
},
"gas": {
"gas_price": "STANDARD"
}
}Successful Return Example
json
{
"code": 200,
"message": "Command received"
}Explanation of Parameters in Successful Return Example
code: Status codemessage: Message reception status
confirm_in
Brief Description
- Called by Relay when the LP fails to confirm in time
Request URL
/evm-client-${config.system_chain_id}/relay/behalf/confirm_in
Request Method
- POST
Request Example
json
{
"transaction_type": "LOCAL_PADDING",
"command_transfer_confirm": {
"bid": "0xf8a17fe9f1fd9a9e002a8409a8742eb6cbe10983db872ab724dfbce911070b97",
"uuid": "0x0fb1db9c040a75ed98dbb8a5b808bafc8a529792640f428584002fca69a59ab8",
"sender_wallet_name": "bscmainnet",
"user_receiver_address": "230550328186284554982703328169495403777670908339",
"token": "489982930986835137684486657990555633941558688085",
"token_amount": "20271192430000000000",
"eth_amount": "0",
"hash_lock": "0xb2f3ebd6bd2ce7ec8987ac50261398876b53c7f055cd88460f5b05da79918bf1",
"agreement_reached_time": 1732074277,
"expected_single_step_time": 120,
"tolerant_single_step_time": 240,
"earliest_refund_time": 1732075358,
"preimage": "0x411d00bbb1634425407705a186f25f4952705663f6ff05044d83afbe75f6772f",
"append_information": "{\"user_account_id\":\"0x28623BF8E872FFAE6e2955a176dFCd10B97a09b3\"}",
"transfer_id": "0x0fb1db9c040a75ed98dbb8a5b808bafc8a529792640f428584002fca69a59ab8"
},
"gas": {
"gas_price": "STANDARD"
}
}Successful Return Example
json
{
"code": 200,
"message": "Command received"
}Explanation of Parameters in Successful Return Example
code: Status codemessage: Message reception status