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

add getEscrow

parent 3670b734
No related branches found
No related tags found
1 merge request!17update readme
...@@ -1719,83 +1719,101 @@ hive.broadcast.changeRecoveryAccount(wif, accountToRecover, newRecoveryAccount, ...@@ -1719,83 +1719,101 @@ hive.broadcast.changeRecoveryAccount(wif, accountToRecover, newRecoveryAccount,
}); });
``` ```
### Comment ### Comment
``` ```js
hive.broadcast.comment(wif, parentAuthor, parentPermlink, author, permlink, title, body, jsonMetadata, function(err, result) { hive.broadcast.comment(wif, parentAuthor, parentPermlink, author, permlink, title, body, jsonMetadata, function(err, result) {
console.log(err, result); console.log(err, result);
}); });
``` ```
### Comment Options ### Comment Options
``` ```js
hive.broadcast.commentOptions(wif, author, permlink, maxAcceptedPayout, percentHiveDollars, allowVotes, allowCurationRewards, extensions, function(err, result) { hive.broadcast.commentOptions(wif, author, permlink, maxAcceptedPayout, percentHiveDollars, allowVotes, allowCurationRewards, extensions, function(err, result) {
console.log(err, result); console.log(err, result);
}); });
``` ```
### Comment Payout ### Comment Payout
``` ```js
hive.broadcast.commentPayout(wif, author, permlink, payout, function(err, result) { hive.broadcast.commentPayout(wif, author, permlink, payout, function(err, result) {
console.log(err, result); console.log(err, result);
}); });
``` ```
### Comment Reward ### Comment Reward
``` ```js
hive.broadcast.commentReward(wif, author, permlink, hbdPayout, vestingPayout, function(err, result) { hive.broadcast.commentReward(wif, author, permlink, hbdPayout, vestingPayout, function(err, result) {
console.log(err, result); console.log(err, result);
}); });
``` ```
### Convert ### Convert
``` ```js
hive.broadcast.convert(wif, owner, requestid, amount, function(err, result) { hive.broadcast.convert(wif, owner, requestid, amount, function(err, result) {
console.log(err, result); console.log(err, result);
}); });
``` ```
### Curate Reward ### Curate Reward
``` ```js
hive.broadcast.curateReward(wif, curator, reward, commentAuthor, commentPermlink, function(err, result) { hive.broadcast.curateReward(wif, curator, reward, commentAuthor, commentPermlink, function(err, result) {
console.log(err, result); console.log(err, result);
}); });
``` ```
### Custom ### Custom
``` ```js
hive.broadcast.custom(wif, requiredAuths, id, data, function(err, result) { hive.broadcast.custom(wif, requiredAuths, id, data, function(err, result) {
console.log(err, result); console.log(err, result);
}); });
``` ```
### Custom Binary ### Custom Binary
``` ```js
hive.broadcast.customBinary(wif, id, data, function(err, result) { hive.broadcast.customBinary(wif, id, data, function(err, result) {
console.log(err, result); console.log(err, result);
}); });
``` ```
### Custom Json ### Custom Json
``` ```js
hive.broadcast.customJson(wif, requiredAuths, requiredPostingAuths, id, json, function(err, result) { hive.broadcast.customJson(wif, requiredAuths, requiredPostingAuths, id, json, function(err, result) {
console.log(err, result); console.log(err, result);
}); });
``` ```
### Delete Comment ### Delete Comment
``` ```js
hive.broadcast.deleteComment(wif, author, permlink, function(err, result) { hive.broadcast.deleteComment(wif, author, permlink, function(err, result) {
console.log(err, result); console.log(err, result);
}); });
``` ```
### Escrow Dispute ### Escrow Dispute
``` ```js
hive.broadcast.escrowDispute(wif, from, to, agent, who, escrowId, function(err, result) { hive.broadcast.escrowDispute(wif, from, to, agent, who, escrowId, function(err, result) {
console.log(err, result); console.log(err, result);
}); });
``` ```
### Escrow Release ### Escrow Release
``` ```js
hive.broadcast.escrowRelease(wif, from, to, agent, who, receiver, escrowId, hbdAmount, hiveAmount, function(err, result) { hive.broadcast.escrowRelease(wif, from, to, agent, who, receiver, escrowId, hbdAmount, hiveAmount, function(err, result) {
console.log(err, result); console.log(err, result);
}); });
``` ```
### Escrow Transfer ### Escrow Transfer
``` ```js
hive.broadcast.escrowTransfer(wif, from, to, agent, escrowId, hbdAmount, hiveAmount, fee, ratificationDeadline, escrowExpiration, jsonMeta, function(err, result) { hive.broadcast.escrowTransfer(wif, from, to, agent, escrowId, hbdAmount, hiveAmount, fee, ratificationDeadline, escrowExpiration, jsonMeta, function(err, result) {
console.log(err, result); console.log(err, result);
}); });
``` ```
### Get Escrow
```js
hive.api.getEscrow(from, escrowId, callback);
```
|Parameter|Datatype|Description|
|---------|--------|-----------|
|from|string|a hive username|
|escrowId|number|id of the specific escrow transfer|
|callback|function|function(err, data) {/*code*/}|
Call Example:
```js
hive.api.getEscrow("username", 23456789, function(err, data) {
console.log(err, data);
});
```
### Feed Publish ### Feed Publish
``` ```
hive.broadcast.feedPublish(wif, publisher, exchangeRate, function(err, result) { hive.broadcast.feedPublish(wif, publisher, exchangeRate, function(err, result) {
......
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