-
Notifications
You must be signed in to change notification settings - Fork 1
Expand file tree
/
Copy pathconfig.js.dist
More file actions
98 lines (95 loc) · 2.61 KB
/
config.js.dist
File metadata and controls
98 lines (95 loc) · 2.61 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
module.exports = {
server: {
host: '0.0.0.0',
port: 8080,
path: '/',
},
basicAuth: {
enabled: false,
users: {
'techworker': 'test'
}
},
ssl: {
enabled: false,
key: 'key.pem',
cert: 'cert.pem'
},
nodes: ['http://127.0.0.1:4003'],
methods: {
addnode: true,
getaccount: true,
getwalletaccounts: true,
getwalletaccountscount: true,
getwalletpubkeys: true,
getwalletpubkey: true,
getwalletcoins: true,
getblock: true,
getblocks: true,
getblockcount: true,
getblockoperation: true,
getblockoperations: true,
getaccountoperations: true,
getpendings: true,
getpendingscount: true,
findoperation: true,
findaccounts: true,
sendto: true,
changekey: true,
changekeys: true,
listaccountforsale: true,
delistaccountforsale: true,
buyaccount: true,
changeaccountinfo: true,
signsendto: true,
signchangekey: true,
signlistaccountforsale: true,
signdelistaccountforsale: true,
signbuyaccount: true,
signchangeaccountinfo: true,
operationsinfo: true,
executeoperations: true,
nodestatus: true,
encodepubkey: true,
decodepubkey: true,
payloadencrypt: true,
payloaddecrypt: true,
getconnections: true,
addnewkey: true,
lock: true,
unlock: true,
setwalletpassword: true,
stopnode: true,
startnode: true,
signmessage: true,
verifysign: true,
multioperationaddoperation: true,
multioperationsignoffline: true,
multioperationsignonline: true,
operationsdelete: true,
},
hooks: {
before: {
// will be called for every request, BEFORE the hook of the method itself
'*': function(method, params) {
return params;
},
findaccounts: function(params) {
if(params.max !== undefined && params.max > 100) {
throw new Error("Invalid MAX value, allowed 100");
}
return params;
}
},
after: {
// will be called for every request, BEFORE the hook of the method itself
'*': function(method, data) {
return data;
},
nodestatus: function(data) {
delete data.result.nodeservers;
return data;
}
}
}
};