OmniCore RPC API文档

交易创建API
omni_send omni_senddexsell omni_senddexaccept omni_sendissuancecrowdsale omni_sendissuancefixed omni_sendissuancemanaged omni_sendsto omni_sendgrant omni_sendrevoke omni_sendclosecrowdsale omni_sendtrade omni_sendcanceltradesbyprice omni_sendcanceltradesbypair omni_sendcancelalltrades omni_sendchangeissuer omni_sendall omni_sendenablefreezing omni_senddisablefreezing omni_sendfreeze omni_sendunfreeze omni_sendrawtx omni_funded_send omni_funded_sendall
数据查询API
omni_getinfo omni_getbalance omni_getallbalancesforid omni_getallbalancesforaddress omni_getwalletbalances omni_getwalletaddressbalances omni_gettransaction omni_listtransactions omni_listblocktransactions omni_listpendingtransactions omni_getactivedexsells omni_listproperties omni_getproperty omni_getactivecrowdsales omni_getcrowdsale omni_getgrants omni_getsto omni_gettrade omni_getorderbook omni_gettradehistoryforpair omni_gettradehistoryforaddress omni_getactivations omni_getpayload omni_getseedblocks omni_getcurrentconsensushash
裸交易API
omni_decodetransaction omni_createrawtx_opreturn omni_createrawtx_multisig omni_createrawtx_input omni_createrawtx_reference omni_createrawtx_change omni_createpayload_simplesend omni_createpayload_sendall omni_createpayload_dexsell omni_createpayload_dexaccept omni_createpayload_sto omni_createpayload_issuancefixed omni_createpayload_issuancecrowdsale omni_createpayload_issuancemanaged omni_createpayload_closecrowdsale omni_createpayload_grant omni_createpayload_revoke omni_createpayload_changeissuer omni_createpayload_trade omni_createpayload_canceltradesbyprice omni_createpayload_canceltradesbypair omni_createpayload_cancelalltrades omni_createpayload_enablefreezing omni_createpayload_disablefreezing omni_createpayload_freeze omni_createpayload_unfreeze
手续费API
omni_getfeecache omni_getfeetrigger omni_getfeeshare omni_getfeedistribution omni_getfeedistributions
内核配置API
omni_setautocommit

omni_funded_send

omni_funded_send调用创建并发送一个简单充值交易。

发送方发出的所有比特币都将被消耗掉,如果比特币来自指定的手续费 来源,那么找零将返回该来源地址。

调用参数

  • fromaddress:发送地址,字符串,必需
  • toaddress:接收地址,字符串,必需
  • propertyid:代币ID,数值,必需
  • amount:代币数量,字符串,必需
  • feeaddress:支付手续费的地址,字符串,必需

返回结果

omni_funded_send调用返回16进制编码的交易哈希。

示例代码

$ omnicore-cli "omni_funded_send" "1DFa5bT6KMEr6ta29QJouainsjaNBsJQhH" \
    "15cWrfuvMxyxGst2FisrQcvcpF48x6sXoH" 1 "100.0" \
    "15Jhzz4omEXEyFKbdcccJwuVPea5LqsKM1"