Skip to content
Snippets Groups Projects
Commit defbb825 authored by Mahdi Yari's avatar Mahdi Yari
Browse files

add getPostDiscussionsByPayout

parent 514eb73e
No related branches found
No related tags found
1 merge request!17update readme
......@@ -431,6 +431,38 @@ Return Example:
{ /* ommited for simplicity */ } ]
```
### Get Post Discussions By Payout
Gets the recent posts ordered by their pending payout.
```js
hive.api.getPostDiscussionsByPayout(query, callback);
```
|Parameter|Datatype|Description|
|---------|--------|-----------|
|query|object|an object containing different options for querying, like 'limit' and 'tag'|
|callback|function|function(err, data) {/*code*/}|
Call Example:
```js
var query = { limit : 3, tag : "collorchallenge" };
hive.api.getPostDiscussionsByPayout(query, function(err, data) {
console.log(err, data);
});
// NOTE! The default limit is 0. Not setting a limit will get you an empty result.
```
Return Example:
```js
// the result is an array of big objects representing the comments
[ { /* ommited for simplicity */ },
{ /* ommited for simplicity */ },
{ /* ommited for simplicity */ } ]
```
## Blocks and transactions
### Get Block Header
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment