omnicore: RPC method 'omni_listtransactions' skip parameter doesn't work
Hi there!
After my previous issue, I’ve realized that ‘omni_listtransactions’ method works with OPTIONAL parameters those described here https://github.com/OmniLayer/omnicore/blob/master/src/omnicore/doc/rpc-api.md#omni_listtransactions.
Now, running a command
curl -H 'Content-Type: application/json' --user 'user:passsord' -X POST --data-binary '{"jsonrpc": "2.0", "id":"omni_test", "method": "omni_listtransactions", "params": ["*", 10, 0, 0, 1289313]}' http://127.0.0.1:14873
I have result:
{"result":[{"txid":"629294792bafc31d74ac6f85361251892ed8fd23d7c710429deae5a9085a4676","fee":"0.00000271","sendingaddress":"miYN8oirbN3QAUcpD3MkKuwDyJ78f6DRu5","referenceaddress":"mg6xzhkUYLvReRuezdPcPmHydFsx2wKzGz","ismine":true,"version":0,"type_int":0,"type":"Simple Send","propertyid":1,"divisible":true,"amount":"5.00000000","valid":true,"blockhash":"00000000c1e5052a9f02c70c089388b3623f0cc9e6fdd0b03baa0a7b193f211e","blocktime":1522141663,"positioninblock":122,"block":1289297,"confirmations":20},{"txid":"b6266aef71c62f239a2e497e5ef9a2d63241b0962d987316beb988a43d68a067","fee":"0.00005146","sendingaddress":"miYN8oirbN3QAUcpD3MkKuwDyJ78f6DRu5","referenceaddress":"mg6xzhkUYLvReRuezdPcPmHydFsx2wKzGz","ismine":true,"version":0,"type_int":0,"type":"Simple Send","propertyid":2,"divisible":true,"amount":"80.00000000","valid":true,"blockhash":"0000000006a0b349a8c2ce92ce55370fe6eefc01ca2f90135a2069a480f06772","blocktime":1522075184,"positioninblock":54,"block":1289234,"confirmations":83},{"txid":"6620b047f61f11a5a3babc4adc8042016206567fafbdbb1d772d63af2e566cee","fee":"0.00004823","sendingaddress":"miYN8oirbN3QAUcpD3MkKuwDyJ78f6DRu5","referenceaddress":"mg6xzhkUYLvReRuezdPcPmHydFsx2wKzGz","ismine":true,"version":0,"type_int":0,"type":"Simple Send","propertyid":2,"divisible":true,"amount":"5.00000000","valid":true,"blockhash":"0000000051a9d604ae61f2168734d456e7e145f6f63a46e915a4118920688fa3","blocktime":1522073983,"positioninblock":387,"block":1289233,"confirmations":84},{"txid":"c1b84248dfc0ab1aab1e35072e51d35fd919b990f7c6677585fdff303ffbab9f","fee":"0.00010253","sendingaddress":"miYN8oirbN3QAUcpD3MkKuwDyJ78f6DRu5","referenceaddress":"mhY9hnCHdewUCftuREXDFWNeHAkE4THiSF","ismine":true,"version":0,"type_int":0,"type":"Simple Send","propertyid":2,"divisible":true,"amount":"13.00000000","valid":true,"blockhash":"000000007fd32cdd8b2de9fd2c12e4c6b8c9da33b3d42a438ce734d20f3ed227","blocktime":1522057809,"positioninblock":76,"block":1289218,"confirmations":99}],"error":null,"id":"omni_test"}
There are 4 transactions here.
But, when I want to skip some transactions(for example 2) I got the same 4 transactions. The command and result are below:
curl -H 'Content-Type: application/json' --user 'user:password' -X POST --data-binary '{"jsonrpc": "2.0", "id":"omni_test", "method": "omni_listtransactions", "params": ["*", 10, 2, 0, 1289313]}' http://127.0.0.1:14873
Please, pay attention to the third parameter 2!!!
{"result":[{"txid":"629294792bafc31d74ac6f85361251892ed8fd23d7c710429deae5a9085a4676","fee":"0.00000271","sendingaddress":"miYN8oirbN3QAUcpD3MkKuwDyJ78f6DRu5","referenceaddress":"mg6xzhkUYLvReRuezdPcPmHydFsx2wKzGz","ismine":true,"version":0,"type_int":0,"type":"Simple Send","propertyid":1,"divisible":true,"amount":"5.00000000","valid":true,"blockhash":"00000000c1e5052a9f02c70c089388b3623f0cc9e6fdd0b03baa0a7b193f211e","blocktime":1522141663,"positioninblock":122,"block":1289297,"confirmations":21},{"txid":"b6266aef71c62f239a2e497e5ef9a2d63241b0962d987316beb988a43d68a067","fee":"0.00005146","sendingaddress":"miYN8oirbN3QAUcpD3MkKuwDyJ78f6DRu5","referenceaddress":"mg6xzhkUYLvReRuezdPcPmHydFsx2wKzGz","ismine":true,"version":0,"type_int":0,"type":"Simple Send","propertyid":2,"divisible":true,"amount":"80.00000000","valid":true,"blockhash":"0000000006a0b349a8c2ce92ce55370fe6eefc01ca2f90135a2069a480f06772","blocktime":1522075184,"positioninblock":54,"block":1289234,"confirmations":84},{"txid":"6620b047f61f11a5a3babc4adc8042016206567fafbdbb1d772d63af2e566cee","fee":"0.00004823","sendingaddress":"miYN8oirbN3QAUcpD3MkKuwDyJ78f6DRu5","referenceaddress":"mg6xzhkUYLvReRuezdPcPmHydFsx2wKzGz","ismine":true,"version":0,"type_int":0,"type":"Simple Send","propertyid":2,"divisible":true,"amount":"5.00000000","valid":true,"blockhash":"0000000051a9d604ae61f2168734d456e7e145f6f63a46e915a4118920688fa3","blocktime":1522073983,"positioninblock":387,"block":1289233,"confirmations":85},{"txid":"c1b84248dfc0ab1aab1e35072e51d35fd919b990f7c6677585fdff303ffbab9f","fee":"0.00010253","sendingaddress":"miYN8oirbN3QAUcpD3MkKuwDyJ78f6DRu5","referenceaddress":"mhY9hnCHdewUCftuREXDFWNeHAkE4THiSF","ismine":true,"version":0,"type_int":0,"type":"Simple Send","propertyid":2,"divisible":true,"amount":"13.00000000","valid":true,"blockhash":"000000007fd32cdd8b2de9fd2c12e4c6b8c9da33b3d42a438ce734d20f3ed227","blocktime":1522057809,"positioninblock":76,"block":1289218,"confirmations":100}],"error":null,"id":"omni_test"}
Guys, what am I doing wrong? Thank a lot for any help!
About this issue
- Original URL
- State: closed
- Created 6 years ago
- Comments: 26 (14 by maintainers)
@dexX7 I can’t find information in documentation. Does omni_listtransactions return all transactions that are received to wallet? or it returns all transactions that have been sent from and received to wallet? How I can identify if it’s output or input? Thanks!