POST
/
{custom-url}
curl -X POST \
--url 'https://custom-url/example-callback' \
--data '{
      "type":"sign_start",
      "trans_id":432,
      "request_id":"0000000003",
      "pending_round":false,
      "from":"0xc70d1eebb7c687ec8d56bead73f104d41e6e0bda",
      "to":"0x5EDc9177997Bf6B4db559A5C184051858B3B3704",
      "amount":0,
      "main_chain_symbol":"HECO",
      "input_data":"0xca718c65",
      "interactive_contract":"0xe012F3957226894B1a2a44b3ef5070417a069dC2",
      "txid":"",
}'

Co-Signer签名前回调客户系统确认Web3交易是否正常。

Content-Type application/json;charset=UTF-8

回调参数格式

Param类型是否必须说明
typeString回调类型,sign_start签名开始,sign_success签名成功
trans_idInteger交易ID
request_idString发起交易唯一标识
pending_roundBoolean加速状态,true是,false否(普通交易)
fromString交易from地址
toString交易to地址
amountDecimal交易金额。-1表示无穷大
main_chain_symbolString主链币币名(唯一标识),例:ETH
input_dataString交易币种唯一标识
interactive_contractString交互合约
txidString交易hash,签名成功返回txid
curl -X POST \
--url 'https://custom-url/example-callback' \
--data '{
      "type":"sign_start",
      "trans_id":432,
      "request_id":"0000000003",
      "pending_round":false,
      "from":"0xc70d1eebb7c687ec8d56bead73f104d41e6e0bda",
      "to":"0x5EDc9177997Bf6B4db559A5C184051858B3B3704",
      "amount":0,
      "main_chain_symbol":"HECO",
      "input_data":"0xca718c65",
      "interactive_contract":"0xe012F3957226894B1a2a44b3ef5070417a069dC2",
      "txid":"",
}'

回调响应参数格式

返回字符串:

  • SUCCESS表示成功: Co-Signer对交易进行签名;
  • FAILURE表示失败: Co-Signer将忽略交易不进行签名。