@ocap/proto 1.29.13 → 1.29.15
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/lib/gen/enum_pb.js +1 -0
- package/lib/gen/spec.json +25 -0
- package/lib/gen/state_pb.js +88 -1
- package/lib/gen/trace-type_pb.js +32 -1
- package/lib/gen/tx_pb.js +81 -1
- package/lib/gen/type_pb.js +1 -0
- package/lib/gen/vendor_pb.js +1 -0
- package/lib/index.d.ts +426 -422
- package/package.json +1 -1
package/lib/gen/enum_pb.js
CHANGED
package/lib/gen/spec.json
CHANGED
|
@@ -1,4 +1,7 @@
|
|
|
1
1
|
{
|
|
2
|
+
"options": {
|
|
3
|
+
"syntax": "proto3"
|
|
4
|
+
},
|
|
2
5
|
"nested": {
|
|
3
6
|
"ocap": {
|
|
4
7
|
"nested": {
|
|
@@ -3068,6 +3071,15 @@
|
|
|
3068
3071
|
"type": "string",
|
|
3069
3072
|
"id": 4
|
|
3070
3073
|
},
|
|
3074
|
+
"deny": {
|
|
3075
|
+
"rule": "repeated",
|
|
3076
|
+
"type": "string",
|
|
3077
|
+
"id": 5
|
|
3078
|
+
},
|
|
3079
|
+
"validUntil": {
|
|
3080
|
+
"type": "uint64",
|
|
3081
|
+
"id": 6
|
|
3082
|
+
},
|
|
3071
3083
|
"context": {
|
|
3072
3084
|
"type": "StateContext",
|
|
3073
3085
|
"id": 14
|
|
@@ -3698,6 +3710,15 @@
|
|
|
3698
3710
|
"type": "DelegateOp",
|
|
3699
3711
|
"id": 3
|
|
3700
3712
|
},
|
|
3713
|
+
"deny": {
|
|
3714
|
+
"rule": "repeated",
|
|
3715
|
+
"type": "string",
|
|
3716
|
+
"id": 4
|
|
3717
|
+
},
|
|
3718
|
+
"validUntil": {
|
|
3719
|
+
"type": "uint64",
|
|
3720
|
+
"id": 5
|
|
3721
|
+
},
|
|
3701
3722
|
"data": {
|
|
3702
3723
|
"type": "google.protobuf.Any",
|
|
3703
3724
|
"id": 15
|
|
@@ -6139,6 +6160,10 @@
|
|
|
6139
6160
|
"id": {
|
|
6140
6161
|
"type": "string",
|
|
6141
6162
|
"id": 2
|
|
6163
|
+
},
|
|
6164
|
+
"title": {
|
|
6165
|
+
"type": "string",
|
|
6166
|
+
"id": 3
|
|
6142
6167
|
}
|
|
6143
6168
|
}
|
|
6144
6169
|
},
|
package/lib/gen/state_pb.js
CHANGED
|
@@ -8,6 +8,7 @@
|
|
|
8
8
|
* @public
|
|
9
9
|
*/
|
|
10
10
|
// GENERATED CODE -- DO NOT EDIT!
|
|
11
|
+
/* eslint-disable */
|
|
11
12
|
// @ts-nocheck
|
|
12
13
|
|
|
13
14
|
var jspb = require('google-protobuf');
|
|
@@ -158,7 +159,7 @@ if (goog.DEBUG && !COMPILED) {
|
|
|
158
159
|
* @constructor
|
|
159
160
|
*/
|
|
160
161
|
proto.ocap.DelegateState = function(opt_data) {
|
|
161
|
-
jspb.Message.initialize(this, opt_data, 0, -1,
|
|
162
|
+
jspb.Message.initialize(this, opt_data, 0, -1, proto.ocap.DelegateState.repeatedFields_, null);
|
|
162
163
|
};
|
|
163
164
|
goog.inherits(proto.ocap.DelegateState, jspb.Message);
|
|
164
165
|
if (goog.DEBUG && !COMPILED) {
|
|
@@ -3119,6 +3120,13 @@ proto.ocap.DelegateOpState.prototype.hasLimit = function() {
|
|
|
3119
3120
|
|
|
3120
3121
|
|
|
3121
3122
|
|
|
3123
|
+
/**
|
|
3124
|
+
* List of repeated fields within this message type.
|
|
3125
|
+
* @private {!Array<number>}
|
|
3126
|
+
* @const
|
|
3127
|
+
*/
|
|
3128
|
+
proto.ocap.DelegateState.repeatedFields_ = [5];
|
|
3129
|
+
|
|
3122
3130
|
|
|
3123
3131
|
|
|
3124
3132
|
if (jspb.Message.GENERATE_TO_OBJECT) {
|
|
@@ -3154,6 +3162,8 @@ proto.ocap.DelegateState.toObject = function(includeInstance, msg) {
|
|
|
3154
3162
|
opsMap: (f = msg.getOpsMap()) ? f.toObject(includeInstance, proto.ocap.DelegateOpState.toObject) : [],
|
|
3155
3163
|
from: jspb.Message.getFieldWithDefault(msg, 3, ""),
|
|
3156
3164
|
to: jspb.Message.getFieldWithDefault(msg, 4, ""),
|
|
3165
|
+
denyList: (f = jspb.Message.getRepeatedField(msg, 5)) == null ? undefined : f,
|
|
3166
|
+
validUntil: jspb.Message.getFieldWithDefault(msg, 6, 0),
|
|
3157
3167
|
context: (f = msg.getContext()) && type_pb.StateContext.toObject(includeInstance, f),
|
|
3158
3168
|
data: (f = msg.getData()) && google_protobuf_any_pb.Any.toObject(includeInstance, f)
|
|
3159
3169
|
};
|
|
@@ -3210,6 +3220,14 @@ proto.ocap.DelegateState.deserializeBinaryFromReader = function(msg, reader) {
|
|
|
3210
3220
|
var value = /** @type {string} */ (reader.readString());
|
|
3211
3221
|
msg.setTo(value);
|
|
3212
3222
|
break;
|
|
3223
|
+
case 5:
|
|
3224
|
+
var value = /** @type {string} */ (reader.readString());
|
|
3225
|
+
msg.addDeny(value);
|
|
3226
|
+
break;
|
|
3227
|
+
case 6:
|
|
3228
|
+
var value = /** @type {number} */ (reader.readUint64());
|
|
3229
|
+
msg.setValidUntil(value);
|
|
3230
|
+
break;
|
|
3213
3231
|
case 14:
|
|
3214
3232
|
var value = new type_pb.StateContext;
|
|
3215
3233
|
reader.readMessage(value,type_pb.StateContext.deserializeBinaryFromReader);
|
|
@@ -3274,6 +3292,20 @@ proto.ocap.DelegateState.serializeBinaryToWriter = function(message, writer) {
|
|
|
3274
3292
|
f
|
|
3275
3293
|
);
|
|
3276
3294
|
}
|
|
3295
|
+
f = message.getDenyList();
|
|
3296
|
+
if (f.length > 0) {
|
|
3297
|
+
writer.writeRepeatedString(
|
|
3298
|
+
5,
|
|
3299
|
+
f
|
|
3300
|
+
);
|
|
3301
|
+
}
|
|
3302
|
+
f = message.getValidUntil();
|
|
3303
|
+
if (f !== 0) {
|
|
3304
|
+
writer.writeUint64(
|
|
3305
|
+
6,
|
|
3306
|
+
f
|
|
3307
|
+
);
|
|
3308
|
+
}
|
|
3277
3309
|
f = message.getContext();
|
|
3278
3310
|
if (f != null) {
|
|
3279
3311
|
writer.writeMessage(
|
|
@@ -3369,6 +3401,61 @@ proto.ocap.DelegateState.prototype.setTo = function(value) {
|
|
|
3369
3401
|
};
|
|
3370
3402
|
|
|
3371
3403
|
|
|
3404
|
+
/**
|
|
3405
|
+
* repeated string deny = 5;
|
|
3406
|
+
* @return {!Array<string>}
|
|
3407
|
+
*/
|
|
3408
|
+
proto.ocap.DelegateState.prototype.getDenyList = function() {
|
|
3409
|
+
return /** @type {!Array<string>} */ (jspb.Message.getRepeatedField(this, 5));
|
|
3410
|
+
};
|
|
3411
|
+
|
|
3412
|
+
|
|
3413
|
+
/**
|
|
3414
|
+
* @param {!Array<string>} value
|
|
3415
|
+
* @return {!proto.ocap.DelegateState} returns this
|
|
3416
|
+
*/
|
|
3417
|
+
proto.ocap.DelegateState.prototype.setDenyList = function(value) {
|
|
3418
|
+
return jspb.Message.setField(this, 5, value || []);
|
|
3419
|
+
};
|
|
3420
|
+
|
|
3421
|
+
|
|
3422
|
+
/**
|
|
3423
|
+
* @param {string} value
|
|
3424
|
+
* @param {number=} opt_index
|
|
3425
|
+
* @return {!proto.ocap.DelegateState} returns this
|
|
3426
|
+
*/
|
|
3427
|
+
proto.ocap.DelegateState.prototype.addDeny = function(value, opt_index) {
|
|
3428
|
+
return jspb.Message.addToRepeatedField(this, 5, value, opt_index);
|
|
3429
|
+
};
|
|
3430
|
+
|
|
3431
|
+
|
|
3432
|
+
/**
|
|
3433
|
+
* Clears the list making it empty but non-null.
|
|
3434
|
+
* @return {!proto.ocap.DelegateState} returns this
|
|
3435
|
+
*/
|
|
3436
|
+
proto.ocap.DelegateState.prototype.clearDenyList = function() {
|
|
3437
|
+
return this.setDenyList([]);
|
|
3438
|
+
};
|
|
3439
|
+
|
|
3440
|
+
|
|
3441
|
+
/**
|
|
3442
|
+
* optional uint64 valid_until = 6;
|
|
3443
|
+
* @return {number}
|
|
3444
|
+
*/
|
|
3445
|
+
proto.ocap.DelegateState.prototype.getValidUntil = function() {
|
|
3446
|
+
return /** @type {number} */ (jspb.Message.getFieldWithDefault(this, 6, 0));
|
|
3447
|
+
};
|
|
3448
|
+
|
|
3449
|
+
|
|
3450
|
+
/**
|
|
3451
|
+
* @param {number} value
|
|
3452
|
+
* @return {!proto.ocap.DelegateState} returns this
|
|
3453
|
+
*/
|
|
3454
|
+
proto.ocap.DelegateState.prototype.setValidUntil = function(value) {
|
|
3455
|
+
return jspb.Message.setProto3IntField(this, 6, value);
|
|
3456
|
+
};
|
|
3457
|
+
|
|
3458
|
+
|
|
3372
3459
|
/**
|
|
3373
3460
|
* optional StateContext context = 14;
|
|
3374
3461
|
* @return {?proto.ocap.StateContext}
|
package/lib/gen/trace-type_pb.js
CHANGED
|
@@ -8,6 +8,7 @@
|
|
|
8
8
|
* @public
|
|
9
9
|
*/
|
|
10
10
|
// GENERATED CODE -- DO NOT EDIT!
|
|
11
|
+
/* eslint-disable */
|
|
11
12
|
// @ts-nocheck
|
|
12
13
|
|
|
13
14
|
var jspb = require('google-protobuf');
|
|
@@ -11850,7 +11851,8 @@ proto.ocap.SearchResult.prototype.toObject = function(opt_includeInstance) {
|
|
|
11850
11851
|
proto.ocap.SearchResult.toObject = function(includeInstance, msg) {
|
|
11851
11852
|
var f, obj = {
|
|
11852
11853
|
type: jspb.Message.getFieldWithDefault(msg, 1, ""),
|
|
11853
|
-
id: jspb.Message.getFieldWithDefault(msg, 2, "")
|
|
11854
|
+
id: jspb.Message.getFieldWithDefault(msg, 2, ""),
|
|
11855
|
+
title: jspb.Message.getFieldWithDefault(msg, 3, "")
|
|
11854
11856
|
};
|
|
11855
11857
|
|
|
11856
11858
|
if (includeInstance) {
|
|
@@ -11895,6 +11897,10 @@ proto.ocap.SearchResult.deserializeBinaryFromReader = function(msg, reader) {
|
|
|
11895
11897
|
var value = /** @type {string} */ (reader.readString());
|
|
11896
11898
|
msg.setId(value);
|
|
11897
11899
|
break;
|
|
11900
|
+
case 3:
|
|
11901
|
+
var value = /** @type {string} */ (reader.readString());
|
|
11902
|
+
msg.setTitle(value);
|
|
11903
|
+
break;
|
|
11898
11904
|
default:
|
|
11899
11905
|
reader.skipField();
|
|
11900
11906
|
break;
|
|
@@ -11938,6 +11944,13 @@ proto.ocap.SearchResult.serializeBinaryToWriter = function(message, writer) {
|
|
|
11938
11944
|
f
|
|
11939
11945
|
);
|
|
11940
11946
|
}
|
|
11947
|
+
f = message.getTitle();
|
|
11948
|
+
if (f.length > 0) {
|
|
11949
|
+
writer.writeString(
|
|
11950
|
+
3,
|
|
11951
|
+
f
|
|
11952
|
+
);
|
|
11953
|
+
}
|
|
11941
11954
|
};
|
|
11942
11955
|
|
|
11943
11956
|
|
|
@@ -11977,6 +11990,24 @@ proto.ocap.SearchResult.prototype.setId = function(value) {
|
|
|
11977
11990
|
};
|
|
11978
11991
|
|
|
11979
11992
|
|
|
11993
|
+
/**
|
|
11994
|
+
* optional string title = 3;
|
|
11995
|
+
* @return {string}
|
|
11996
|
+
*/
|
|
11997
|
+
proto.ocap.SearchResult.prototype.getTitle = function() {
|
|
11998
|
+
return /** @type {string} */ (jspb.Message.getFieldWithDefault(this, 3, ""));
|
|
11999
|
+
};
|
|
12000
|
+
|
|
12001
|
+
|
|
12002
|
+
/**
|
|
12003
|
+
* @param {string} value
|
|
12004
|
+
* @return {!proto.ocap.SearchResult} returns this
|
|
12005
|
+
*/
|
|
12006
|
+
proto.ocap.SearchResult.prototype.setTitle = function(value) {
|
|
12007
|
+
return jspb.Message.setProto3StringField(this, 3, value);
|
|
12008
|
+
};
|
|
12009
|
+
|
|
12010
|
+
|
|
11980
12011
|
|
|
11981
12012
|
|
|
11982
12013
|
|
package/lib/gen/tx_pb.js
CHANGED
|
@@ -8,6 +8,7 @@
|
|
|
8
8
|
* @public
|
|
9
9
|
*/
|
|
10
10
|
// GENERATED CODE -- DO NOT EDIT!
|
|
11
|
+
/* eslint-disable */
|
|
11
12
|
// @ts-nocheck
|
|
12
13
|
|
|
13
14
|
var jspb = require('google-protobuf');
|
|
@@ -1735,7 +1736,7 @@ proto.ocap.DelegateOp.prototype.hasLimit = function() {
|
|
|
1735
1736
|
* @private {!Array<number>}
|
|
1736
1737
|
* @const
|
|
1737
1738
|
*/
|
|
1738
|
-
proto.ocap.DelegateTx.repeatedFields_ = [3];
|
|
1739
|
+
proto.ocap.DelegateTx.repeatedFields_ = [3,4];
|
|
1739
1740
|
|
|
1740
1741
|
|
|
1741
1742
|
|
|
@@ -1772,6 +1773,8 @@ proto.ocap.DelegateTx.toObject = function(includeInstance, msg) {
|
|
|
1772
1773
|
to: jspb.Message.getFieldWithDefault(msg, 2, ""),
|
|
1773
1774
|
opsList: jspb.Message.toObjectList(msg.getOpsList(),
|
|
1774
1775
|
proto.ocap.DelegateOp.toObject, includeInstance),
|
|
1776
|
+
denyList: (f = jspb.Message.getRepeatedField(msg, 4)) == null ? undefined : f,
|
|
1777
|
+
validUntil: jspb.Message.getFieldWithDefault(msg, 5, 0),
|
|
1775
1778
|
data: (f = msg.getData()) && google_protobuf_any_pb.Any.toObject(includeInstance, f)
|
|
1776
1779
|
};
|
|
1777
1780
|
|
|
@@ -1822,6 +1825,14 @@ proto.ocap.DelegateTx.deserializeBinaryFromReader = function(msg, reader) {
|
|
|
1822
1825
|
reader.readMessage(value,proto.ocap.DelegateOp.deserializeBinaryFromReader);
|
|
1823
1826
|
msg.addOps(value);
|
|
1824
1827
|
break;
|
|
1828
|
+
case 4:
|
|
1829
|
+
var value = /** @type {string} */ (reader.readString());
|
|
1830
|
+
msg.addDeny(value);
|
|
1831
|
+
break;
|
|
1832
|
+
case 5:
|
|
1833
|
+
var value = /** @type {number} */ (reader.readUint64());
|
|
1834
|
+
msg.setValidUntil(value);
|
|
1835
|
+
break;
|
|
1825
1836
|
case 15:
|
|
1826
1837
|
var value = new google_protobuf_any_pb.Any;
|
|
1827
1838
|
reader.readMessage(value,google_protobuf_any_pb.Any.deserializeBinaryFromReader);
|
|
@@ -1878,6 +1889,20 @@ proto.ocap.DelegateTx.serializeBinaryToWriter = function(message, writer) {
|
|
|
1878
1889
|
proto.ocap.DelegateOp.serializeBinaryToWriter
|
|
1879
1890
|
);
|
|
1880
1891
|
}
|
|
1892
|
+
f = message.getDenyList();
|
|
1893
|
+
if (f.length > 0) {
|
|
1894
|
+
writer.writeRepeatedString(
|
|
1895
|
+
4,
|
|
1896
|
+
f
|
|
1897
|
+
);
|
|
1898
|
+
}
|
|
1899
|
+
f = message.getValidUntil();
|
|
1900
|
+
if (f !== 0) {
|
|
1901
|
+
writer.writeUint64(
|
|
1902
|
+
5,
|
|
1903
|
+
f
|
|
1904
|
+
);
|
|
1905
|
+
}
|
|
1881
1906
|
f = message.getData();
|
|
1882
1907
|
if (f != null) {
|
|
1883
1908
|
writer.writeMessage(
|
|
@@ -1963,6 +1988,61 @@ proto.ocap.DelegateTx.prototype.clearOpsList = function() {
|
|
|
1963
1988
|
};
|
|
1964
1989
|
|
|
1965
1990
|
|
|
1991
|
+
/**
|
|
1992
|
+
* repeated string deny = 4;
|
|
1993
|
+
* @return {!Array<string>}
|
|
1994
|
+
*/
|
|
1995
|
+
proto.ocap.DelegateTx.prototype.getDenyList = function() {
|
|
1996
|
+
return /** @type {!Array<string>} */ (jspb.Message.getRepeatedField(this, 4));
|
|
1997
|
+
};
|
|
1998
|
+
|
|
1999
|
+
|
|
2000
|
+
/**
|
|
2001
|
+
* @param {!Array<string>} value
|
|
2002
|
+
* @return {!proto.ocap.DelegateTx} returns this
|
|
2003
|
+
*/
|
|
2004
|
+
proto.ocap.DelegateTx.prototype.setDenyList = function(value) {
|
|
2005
|
+
return jspb.Message.setField(this, 4, value || []);
|
|
2006
|
+
};
|
|
2007
|
+
|
|
2008
|
+
|
|
2009
|
+
/**
|
|
2010
|
+
* @param {string} value
|
|
2011
|
+
* @param {number=} opt_index
|
|
2012
|
+
* @return {!proto.ocap.DelegateTx} returns this
|
|
2013
|
+
*/
|
|
2014
|
+
proto.ocap.DelegateTx.prototype.addDeny = function(value, opt_index) {
|
|
2015
|
+
return jspb.Message.addToRepeatedField(this, 4, value, opt_index);
|
|
2016
|
+
};
|
|
2017
|
+
|
|
2018
|
+
|
|
2019
|
+
/**
|
|
2020
|
+
* Clears the list making it empty but non-null.
|
|
2021
|
+
* @return {!proto.ocap.DelegateTx} returns this
|
|
2022
|
+
*/
|
|
2023
|
+
proto.ocap.DelegateTx.prototype.clearDenyList = function() {
|
|
2024
|
+
return this.setDenyList([]);
|
|
2025
|
+
};
|
|
2026
|
+
|
|
2027
|
+
|
|
2028
|
+
/**
|
|
2029
|
+
* optional uint64 valid_until = 5;
|
|
2030
|
+
* @return {number}
|
|
2031
|
+
*/
|
|
2032
|
+
proto.ocap.DelegateTx.prototype.getValidUntil = function() {
|
|
2033
|
+
return /** @type {number} */ (jspb.Message.getFieldWithDefault(this, 5, 0));
|
|
2034
|
+
};
|
|
2035
|
+
|
|
2036
|
+
|
|
2037
|
+
/**
|
|
2038
|
+
* @param {number} value
|
|
2039
|
+
* @return {!proto.ocap.DelegateTx} returns this
|
|
2040
|
+
*/
|
|
2041
|
+
proto.ocap.DelegateTx.prototype.setValidUntil = function(value) {
|
|
2042
|
+
return jspb.Message.setProto3IntField(this, 5, value);
|
|
2043
|
+
};
|
|
2044
|
+
|
|
2045
|
+
|
|
1966
2046
|
/**
|
|
1967
2047
|
* optional google.protobuf.Any data = 15;
|
|
1968
2048
|
* @return {?proto.google.protobuf.Any}
|
package/lib/gen/type_pb.js
CHANGED
package/lib/gen/vendor_pb.js
CHANGED
package/lib/index.d.ts
CHANGED
|
@@ -4,474 +4,478 @@ declare const _Lib: object;
|
|
|
4
4
|
export = _Lib;
|
|
5
5
|
|
|
6
6
|
declare namespace Enums {
|
|
7
|
-
|
|
7
|
+
|
|
8
|
+
export enum StatusCode {
|
|
8
9
|
OK = 0,
|
|
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
|
-
|
|
10
|
+
INVALID_NONCE = 1,
|
|
11
|
+
INVALID_SIGNATURE = 2,
|
|
12
|
+
INVALID_SENDER_STATE = 3,
|
|
13
|
+
INVALID_RECEIVER_STATE = 4,
|
|
14
|
+
INSUFFICIENT_DATA = 5,
|
|
15
|
+
INSUFFICIENT_FUND = 6,
|
|
16
|
+
INVALID_OWNER = 7,
|
|
17
|
+
INVALID_TX = 8,
|
|
18
|
+
UNSUPPORTED_TX = 9,
|
|
19
|
+
EXPIRED_TX = 10,
|
|
20
|
+
TOO_MANY_TXS = 11,
|
|
21
|
+
INVALID_LOCK_STATUS = 12,
|
|
22
|
+
INVALID_REQUEST = 13,
|
|
23
|
+
INVALID_MONIKER = 16,
|
|
24
|
+
INVALID_PASSPHRASE = 17,
|
|
25
|
+
INVALID_MULTISIG = 20,
|
|
26
|
+
INVALID_WALLET = 21,
|
|
27
|
+
INVALID_CHAIN_ID = 22,
|
|
28
|
+
CONSENSUS_RPC_ERROR = 24,
|
|
29
|
+
STORAGE_RPC_ERROR = 25,
|
|
30
|
+
NOENT = 26,
|
|
31
|
+
ACCOUNT_MIGRATED = 27,
|
|
32
|
+
RPC_CONNECTION_ERROR = 28,
|
|
33
|
+
UNSUPPORTED_STAKE = 30,
|
|
34
|
+
INSUFFICIENT_STAKE = 31,
|
|
35
|
+
INVALID_STAKE_STATE = 32,
|
|
36
|
+
EXPIRED_WALLET_TOKEN = 33,
|
|
37
|
+
BANNED_UNSTAKE = 34,
|
|
38
|
+
INVALID_ASSET = 35,
|
|
39
|
+
INVALID_TX_SIZE = 36,
|
|
40
|
+
INVALID_SIGNER_STATE = 37,
|
|
41
|
+
INVALID_FORGE_STATE = 38,
|
|
42
|
+
EXPIRED_ASSET = 39,
|
|
43
|
+
UNTRANSFERRABLE_ASSET = 40,
|
|
44
|
+
READONLY_ASSET = 41,
|
|
45
|
+
CONSUMED_ASSET = 42,
|
|
46
|
+
INVALID_DEPOSIT_VALUE = 43,
|
|
47
|
+
EXCEED_DEPOSIT_CAP = 44,
|
|
48
|
+
INVALID_DEPOSIT_TARGET = 45,
|
|
49
|
+
INVALID_DEPOSITOR = 46,
|
|
50
|
+
INVALID_WITHDRAWER = 47,
|
|
51
|
+
INVALID_EXPIRY_DATE = 49,
|
|
52
|
+
INVALID_CUSTODIAN = 51,
|
|
53
|
+
INSUFFICIENT_GAS = 52,
|
|
54
|
+
INVALID_SWAP = 53,
|
|
55
|
+
INVALID_HASHKEY = 54,
|
|
56
|
+
INVALID_DELEGATION = 55,
|
|
57
|
+
INSUFFICIENT_DELEGATION = 56,
|
|
58
|
+
INVALID_DELEGATION_RULE = 57,
|
|
59
|
+
INVALID_DELEGATION_TYPE_URL = 58,
|
|
60
|
+
SENDER_NOT_AUTHORIZED = 59,
|
|
61
|
+
PROTOCOL_NOT_RUNNING = 60,
|
|
62
|
+
PROTOCOL_NOT_PAUSED = 61,
|
|
63
|
+
PROTOCOL_NOT_ACTIVATED = 62,
|
|
64
|
+
INVALID_DEACTIVATION = 63,
|
|
65
|
+
SENDER_WITHDRAW_ITEMS_FULL = 64,
|
|
66
|
+
WITHDRAW_ITEM_MISSING = 65,
|
|
67
|
+
INVALID_WITHDRAW_TX = 66,
|
|
68
|
+
INVALID_CHAIN_TYPE = 67,
|
|
69
|
+
INVALID_TIME = 68,
|
|
70
|
+
INVALID_SUBSCRIBE = 69,
|
|
71
|
+
INVALID_DID_TYPE = 70,
|
|
72
|
+
INVALID_CANDIDATE_STATE = 71,
|
|
73
|
+
VALIDATOR_NOT_FOUND = 72,
|
|
74
|
+
VALIDATOR_NOT_CHANGED = 73,
|
|
75
|
+
INVALID_FACTORY_STATE = 74,
|
|
76
|
+
INVALID_FACTORY_PROPS = 75,
|
|
77
|
+
INVALID_FACTORY_INPUT = 76,
|
|
78
|
+
INVALID_TOKEN = 77,
|
|
79
|
+
INVALID_ROLLUP = 78,
|
|
80
|
+
INVALID_BLOCK = 79,
|
|
81
|
+
FORBIDDEN = 403,
|
|
82
|
+
INTERNAL = 500,
|
|
83
|
+
TIMEOUT = 504,
|
|
84
|
+
}
|
|
85
|
+
|
|
86
|
+
export enum KeyType {
|
|
86
87
|
ED25519 = 0,
|
|
87
|
-
|
|
88
|
-
|
|
89
|
-
|
|
88
|
+
SECP256K1 = 1,
|
|
89
|
+
ETHEREUM = 2,
|
|
90
|
+
}
|
|
90
91
|
|
|
91
|
-
|
|
92
|
+
export enum HashType {
|
|
92
93
|
KECCAK = 0,
|
|
93
|
-
|
|
94
|
-
|
|
95
|
-
|
|
96
|
-
|
|
97
|
-
|
|
98
|
-
|
|
99
|
-
|
|
100
|
-
|
|
101
|
-
|
|
94
|
+
SHA3 = 1,
|
|
95
|
+
SHA2 = 2,
|
|
96
|
+
KECCAK_384 = 6,
|
|
97
|
+
SHA3_384 = 7,
|
|
98
|
+
KECCAK_512 = 13,
|
|
99
|
+
SHA3_512 = 14,
|
|
100
|
+
}
|
|
101
|
+
|
|
102
|
+
export enum EncodingType {
|
|
102
103
|
BASE16 = 0,
|
|
103
|
-
|
|
104
|
-
|
|
104
|
+
BASE58 = 1,
|
|
105
|
+
}
|
|
105
106
|
|
|
106
|
-
|
|
107
|
+
export enum RoleType {
|
|
107
108
|
ROLE_ACCOUNT = 0,
|
|
108
|
-
|
|
109
|
-
|
|
110
|
-
|
|
111
|
-
|
|
112
|
-
|
|
113
|
-
|
|
114
|
-
|
|
115
|
-
|
|
116
|
-
|
|
117
|
-
|
|
118
|
-
|
|
119
|
-
|
|
120
|
-
|
|
121
|
-
|
|
122
|
-
|
|
123
|
-
|
|
124
|
-
|
|
125
|
-
|
|
126
|
-
|
|
127
|
-
|
|
128
|
-
|
|
129
|
-
|
|
130
|
-
|
|
131
|
-
|
|
109
|
+
ROLE_NODE = 1,
|
|
110
|
+
ROLE_DEVICE = 2,
|
|
111
|
+
ROLE_APPLICATION = 3,
|
|
112
|
+
ROLE_SMART_CONTRACT = 4,
|
|
113
|
+
ROLE_BOT = 5,
|
|
114
|
+
ROLE_ASSET = 6,
|
|
115
|
+
ROLE_STAKE = 7,
|
|
116
|
+
ROLE_VALIDATOR = 8,
|
|
117
|
+
ROLE_GROUP = 9,
|
|
118
|
+
ROLE_TX = 10,
|
|
119
|
+
ROLE_TETHER = 11,
|
|
120
|
+
ROLE_SWAP = 12,
|
|
121
|
+
ROLE_DELEGATION = 13,
|
|
122
|
+
ROLE_VC = 14,
|
|
123
|
+
ROLE_BLOCKLET = 15,
|
|
124
|
+
ROLE_STORE = 16,
|
|
125
|
+
ROLE_TOKEN = 17,
|
|
126
|
+
ROLE_FACTORY = 18,
|
|
127
|
+
ROLE_ROLLUP = 19,
|
|
128
|
+
ROLE_STORAGE = 20,
|
|
129
|
+
ROLE_ANY = 63,
|
|
130
|
+
}
|
|
131
|
+
|
|
132
|
+
export enum UpgradeType {
|
|
132
133
|
CONFIG_APP = 0,
|
|
133
|
-
|
|
134
|
-
|
|
135
|
-
|
|
136
|
-
|
|
137
|
-
|
|
138
|
-
|
|
139
|
-
|
|
140
|
-
|
|
141
|
-
|
|
142
|
-
|
|
143
|
-
|
|
144
|
-
|
|
134
|
+
CONFIG_FORGE = 1,
|
|
135
|
+
CONFIG_DFS = 2,
|
|
136
|
+
CONFIG_CONSENSUS = 3,
|
|
137
|
+
CONFIG_P2P = 4,
|
|
138
|
+
EXE_APP = 10,
|
|
139
|
+
EXE_FORGE = 11,
|
|
140
|
+
EXE_DFS = 12,
|
|
141
|
+
EXE_CONSENSUS = 13,
|
|
142
|
+
EXE_P2P = 14,
|
|
143
|
+
}
|
|
144
|
+
|
|
145
|
+
export enum UpgradeAction {
|
|
145
146
|
VERIFY = 0,
|
|
146
|
-
|
|
147
|
-
|
|
148
|
-
|
|
149
|
-
|
|
150
|
-
|
|
151
|
-
|
|
152
|
-
|
|
153
|
-
|
|
154
|
-
|
|
155
|
-
|
|
156
|
-
|
|
157
|
-
|
|
158
|
-
|
|
159
|
-
|
|
147
|
+
BACKUP = 1,
|
|
148
|
+
REPLACE = 2,
|
|
149
|
+
RESTART_APP = 10,
|
|
150
|
+
RESTART_DFS = 11,
|
|
151
|
+
RESTART_CONSENSUS = 12,
|
|
152
|
+
RESTART_P2P = 13,
|
|
153
|
+
RESTART_FORGE = 14,
|
|
154
|
+
ROLLBACK_IF_FAIL = 30,
|
|
155
|
+
RESTART_ALL_IF_FAIL = 31,
|
|
156
|
+
CRASH_IF_FAIL = 33,
|
|
157
|
+
DROP_ADDRESS_BOOK = 50,
|
|
158
|
+
}
|
|
159
|
+
|
|
160
|
+
export enum StateType {
|
|
160
161
|
STATE_ACCOUNT = 0,
|
|
161
|
-
|
|
162
|
-
|
|
163
|
-
|
|
164
|
-
|
|
165
|
-
|
|
162
|
+
STATE_ASSET = 1,
|
|
163
|
+
STATE_CHANNEL = 2,
|
|
164
|
+
STATE_FORGE = 3,
|
|
165
|
+
STATE_STAKE = 4,
|
|
166
|
+
}
|
|
166
167
|
|
|
167
|
-
|
|
168
|
+
export enum StakeType {
|
|
168
169
|
STAKE_NODE = 0,
|
|
169
|
-
|
|
170
|
-
|
|
171
|
-
|
|
172
|
-
|
|
170
|
+
STAKE_USER = 1,
|
|
171
|
+
STAKE_ASSET = 2,
|
|
172
|
+
STAKE_CHAIN = 3,
|
|
173
|
+
}
|
|
173
174
|
|
|
174
|
-
|
|
175
|
+
export enum ProtocolStatus {
|
|
175
176
|
RUNNING = 0,
|
|
176
|
-
|
|
177
|
-
|
|
178
|
-
|
|
177
|
+
PAUSED = 1,
|
|
178
|
+
TERMINATED = 2,
|
|
179
|
+
}
|
|
179
180
|
|
|
180
|
-
|
|
181
|
+
export enum TokenFactoryStatus {
|
|
181
182
|
TOKEN_FACTORY_ACTIVE = 0,
|
|
182
|
-
|
|
183
|
-
|
|
183
|
+
TOKEN_FACTORY_PAUSED = 1,
|
|
184
|
+
}
|
|
184
185
|
|
|
185
|
-
|
|
186
|
+
export enum Direction {
|
|
186
187
|
MUTUAL = 0,
|
|
187
|
-
|
|
188
|
-
|
|
189
|
-
|
|
188
|
+
ONE_WAY = 1,
|
|
189
|
+
UNION = 2,
|
|
190
|
+
}
|
|
190
191
|
|
|
191
|
-
|
|
192
|
+
export enum Validity {
|
|
192
193
|
BOTH = 0,
|
|
193
|
-
|
|
194
|
-
|
|
195
|
-
|
|
194
|
+
VALID = 1,
|
|
195
|
+
INVALID = 2,
|
|
196
|
+
}
|
|
196
197
|
|
|
197
|
-
|
|
198
|
+
export enum TokenFlowDirection {
|
|
198
199
|
IN = 0,
|
|
199
|
-
|
|
200
|
-
|
|
200
|
+
OUT = 1,
|
|
201
|
+
}
|
|
201
202
|
|
|
202
|
-
|
|
203
|
+
export enum SupportedTxs {
|
|
203
204
|
0 = AccountMigrateTx,
|
|
204
|
-
|
|
205
|
-
|
|
206
|
-
|
|
207
|
-
|
|
208
|
-
|
|
209
|
-
|
|
210
|
-
|
|
211
|
-
|
|
212
|
-
|
|
213
|
-
|
|
214
|
-
|
|
215
|
-
|
|
216
|
-
|
|
217
|
-
|
|
218
|
-
|
|
219
|
-
|
|
220
|
-
|
|
221
|
-
|
|
222
|
-
|
|
223
|
-
|
|
224
|
-
|
|
225
|
-
|
|
226
|
-
|
|
227
|
-
|
|
228
|
-
|
|
229
|
-
|
|
230
|
-
|
|
231
|
-
|
|
232
|
-
|
|
233
|
-
|
|
234
|
-
|
|
235
|
-
|
|
236
|
-
|
|
237
|
-
|
|
238
|
-
|
|
239
|
-
|
|
240
|
-
|
|
241
|
-
|
|
242
|
-
|
|
243
|
-
|
|
244
|
-
|
|
245
|
-
|
|
246
|
-
|
|
247
|
-
|
|
248
|
-
|
|
249
|
-
|
|
250
|
-
|
|
251
|
-
|
|
252
|
-
|
|
253
|
-
|
|
254
|
-
|
|
255
|
-
|
|
256
|
-
|
|
257
|
-
|
|
258
|
-
|
|
259
|
-
|
|
260
|
-
|
|
261
|
-
|
|
262
|
-
|
|
263
|
-
|
|
205
|
+
1 = AcquireAssetV2Tx,
|
|
206
|
+
2 = AcquireAssetV3Tx,
|
|
207
|
+
3 = BurnTokenTx,
|
|
208
|
+
4 = ClaimBlockRewardTx,
|
|
209
|
+
5 = ClaimStakeTx,
|
|
210
|
+
6 = CloseRollupTx,
|
|
211
|
+
7 = ConsumeAssetTx,
|
|
212
|
+
8 = CreateAssetTx,
|
|
213
|
+
9 = CreateFactoryTx,
|
|
214
|
+
10 = CreateRollupBlockTx,
|
|
215
|
+
11 = CreateRollupTx,
|
|
216
|
+
12 = CreateTokenFactoryTx,
|
|
217
|
+
13 = CreateTokenTx,
|
|
218
|
+
14 = DeclareTx,
|
|
219
|
+
15 = DelegateTx,
|
|
220
|
+
16 = DepositTokenV2Tx,
|
|
221
|
+
17 = ExchangeTx,
|
|
222
|
+
18 = ExchangeV2Tx,
|
|
223
|
+
19 = JoinRollupTx,
|
|
224
|
+
20 = LeaveRollupTx,
|
|
225
|
+
21 = MigrateRollupTx,
|
|
226
|
+
22 = MintAssetTx,
|
|
227
|
+
23 = MintTokenTx,
|
|
228
|
+
24 = PauseRollupTx,
|
|
229
|
+
25 = ResumeRollupTx,
|
|
230
|
+
26 = ReturnStakeTx,
|
|
231
|
+
27 = RevokeDelegateTx,
|
|
232
|
+
28 = RevokeStakeTx,
|
|
233
|
+
29 = SlashStakeTx,
|
|
234
|
+
30 = StakeTx,
|
|
235
|
+
31 = TransferTx,
|
|
236
|
+
32 = TransferV2Tx,
|
|
237
|
+
33 = TransferV3Tx,
|
|
238
|
+
34 = UpdateAssetTx,
|
|
239
|
+
35 = UpdateRollupTx,
|
|
240
|
+
36 = UpdateTokenFactoryTx,
|
|
241
|
+
37 = UpgradeNodeTx,
|
|
242
|
+
38 = WithdrawTokenV2Tx,
|
|
243
|
+
}
|
|
244
|
+
|
|
245
|
+
export enum SupportedStakes {
|
|
246
|
+
|
|
247
|
+
}
|
|
248
|
+
|
|
249
|
+
export interface main {
|
|
250
|
+
StatusCode: typeof Enums.StatusCode;
|
|
251
|
+
KeyType: typeof Enums.KeyType;
|
|
252
|
+
HashType: typeof Enums.HashType;
|
|
253
|
+
EncodingType: typeof Enums.EncodingType;
|
|
254
|
+
RoleType: typeof Enums.RoleType;
|
|
255
|
+
UpgradeType: typeof Enums.UpgradeType;
|
|
256
|
+
UpgradeAction: typeof Enums.UpgradeAction;
|
|
257
|
+
StateType: typeof Enums.StateType;
|
|
258
|
+
StakeType: typeof Enums.StakeType;
|
|
259
|
+
ProtocolStatus: typeof Enums.ProtocolStatus;
|
|
260
|
+
TokenFactoryStatus: typeof Enums.TokenFactoryStatus;
|
|
261
|
+
Direction: typeof Enums.Direction;
|
|
262
|
+
Validity: typeof Enums.Validity;
|
|
263
|
+
TokenFlowDirection: typeof Enums.TokenFlowDirection;
|
|
264
|
+
SupportedTxs: typeof Enums.SupportedTxs;
|
|
265
|
+
SupportedStakes: typeof Enums.SupportedStakes;
|
|
266
|
+
}
|
|
264
267
|
}
|
|
265
268
|
declare namespace Messages {
|
|
266
|
-
|
|
269
|
+
|
|
270
|
+
export enum StatusCode {
|
|
267
271
|
0 = OK,
|
|
268
|
-
|
|
269
|
-
|
|
270
|
-
|
|
271
|
-
|
|
272
|
-
|
|
273
|
-
|
|
274
|
-
|
|
275
|
-
|
|
276
|
-
|
|
277
|
-
|
|
278
|
-
|
|
279
|
-
|
|
280
|
-
|
|
281
|
-
|
|
282
|
-
|
|
283
|
-
|
|
284
|
-
|
|
285
|
-
|
|
286
|
-
|
|
287
|
-
|
|
288
|
-
|
|
289
|
-
|
|
290
|
-
|
|
291
|
-
|
|
292
|
-
|
|
293
|
-
|
|
294
|
-
|
|
295
|
-
|
|
296
|
-
|
|
297
|
-
|
|
298
|
-
|
|
299
|
-
|
|
300
|
-
|
|
301
|
-
|
|
302
|
-
|
|
303
|
-
|
|
304
|
-
|
|
305
|
-
|
|
306
|
-
|
|
307
|
-
|
|
308
|
-
|
|
309
|
-
|
|
310
|
-
|
|
311
|
-
|
|
312
|
-
|
|
313
|
-
|
|
314
|
-
|
|
315
|
-
|
|
316
|
-
|
|
317
|
-
|
|
318
|
-
|
|
319
|
-
|
|
320
|
-
|
|
321
|
-
|
|
322
|
-
|
|
323
|
-
|
|
324
|
-
|
|
325
|
-
|
|
326
|
-
|
|
327
|
-
|
|
328
|
-
|
|
329
|
-
|
|
330
|
-
|
|
331
|
-
|
|
332
|
-
|
|
333
|
-
|
|
334
|
-
|
|
335
|
-
|
|
336
|
-
|
|
337
|
-
|
|
338
|
-
|
|
339
|
-
|
|
340
|
-
|
|
341
|
-
|
|
342
|
-
|
|
343
|
-
|
|
344
|
-
|
|
272
|
+
1 = INVALID_NONCE,
|
|
273
|
+
2 = INVALID_SIGNATURE,
|
|
274
|
+
3 = INVALID_SENDER_STATE,
|
|
275
|
+
4 = INVALID_RECEIVER_STATE,
|
|
276
|
+
5 = INSUFFICIENT_DATA,
|
|
277
|
+
6 = INSUFFICIENT_FUND,
|
|
278
|
+
7 = INVALID_OWNER,
|
|
279
|
+
8 = INVALID_TX,
|
|
280
|
+
9 = UNSUPPORTED_TX,
|
|
281
|
+
10 = EXPIRED_TX,
|
|
282
|
+
11 = TOO_MANY_TXS,
|
|
283
|
+
12 = INVALID_LOCK_STATUS,
|
|
284
|
+
13 = INVALID_REQUEST,
|
|
285
|
+
16 = INVALID_MONIKER,
|
|
286
|
+
17 = INVALID_PASSPHRASE,
|
|
287
|
+
20 = INVALID_MULTISIG,
|
|
288
|
+
21 = INVALID_WALLET,
|
|
289
|
+
22 = INVALID_CHAIN_ID,
|
|
290
|
+
24 = CONSENSUS_RPC_ERROR,
|
|
291
|
+
25 = STORAGE_RPC_ERROR,
|
|
292
|
+
26 = NOENT,
|
|
293
|
+
27 = ACCOUNT_MIGRATED,
|
|
294
|
+
28 = RPC_CONNECTION_ERROR,
|
|
295
|
+
30 = UNSUPPORTED_STAKE,
|
|
296
|
+
31 = INSUFFICIENT_STAKE,
|
|
297
|
+
32 = INVALID_STAKE_STATE,
|
|
298
|
+
33 = EXPIRED_WALLET_TOKEN,
|
|
299
|
+
34 = BANNED_UNSTAKE,
|
|
300
|
+
35 = INVALID_ASSET,
|
|
301
|
+
36 = INVALID_TX_SIZE,
|
|
302
|
+
37 = INVALID_SIGNER_STATE,
|
|
303
|
+
38 = INVALID_FORGE_STATE,
|
|
304
|
+
39 = EXPIRED_ASSET,
|
|
305
|
+
40 = UNTRANSFERRABLE_ASSET,
|
|
306
|
+
41 = READONLY_ASSET,
|
|
307
|
+
42 = CONSUMED_ASSET,
|
|
308
|
+
43 = INVALID_DEPOSIT_VALUE,
|
|
309
|
+
44 = EXCEED_DEPOSIT_CAP,
|
|
310
|
+
45 = INVALID_DEPOSIT_TARGET,
|
|
311
|
+
46 = INVALID_DEPOSITOR,
|
|
312
|
+
47 = INVALID_WITHDRAWER,
|
|
313
|
+
49 = INVALID_EXPIRY_DATE,
|
|
314
|
+
51 = INVALID_CUSTODIAN,
|
|
315
|
+
52 = INSUFFICIENT_GAS,
|
|
316
|
+
53 = INVALID_SWAP,
|
|
317
|
+
54 = INVALID_HASHKEY,
|
|
318
|
+
55 = INVALID_DELEGATION,
|
|
319
|
+
56 = INSUFFICIENT_DELEGATION,
|
|
320
|
+
57 = INVALID_DELEGATION_RULE,
|
|
321
|
+
58 = INVALID_DELEGATION_TYPE_URL,
|
|
322
|
+
59 = SENDER_NOT_AUTHORIZED,
|
|
323
|
+
60 = PROTOCOL_NOT_RUNNING,
|
|
324
|
+
61 = PROTOCOL_NOT_PAUSED,
|
|
325
|
+
62 = PROTOCOL_NOT_ACTIVATED,
|
|
326
|
+
63 = INVALID_DEACTIVATION,
|
|
327
|
+
64 = SENDER_WITHDRAW_ITEMS_FULL,
|
|
328
|
+
65 = WITHDRAW_ITEM_MISSING,
|
|
329
|
+
66 = INVALID_WITHDRAW_TX,
|
|
330
|
+
67 = INVALID_CHAIN_TYPE,
|
|
331
|
+
68 = INVALID_TIME,
|
|
332
|
+
69 = INVALID_SUBSCRIBE,
|
|
333
|
+
70 = INVALID_DID_TYPE,
|
|
334
|
+
71 = INVALID_CANDIDATE_STATE,
|
|
335
|
+
72 = VALIDATOR_NOT_FOUND,
|
|
336
|
+
73 = VALIDATOR_NOT_CHANGED,
|
|
337
|
+
74 = INVALID_FACTORY_STATE,
|
|
338
|
+
75 = INVALID_FACTORY_PROPS,
|
|
339
|
+
76 = INVALID_FACTORY_INPUT,
|
|
340
|
+
77 = INVALID_TOKEN,
|
|
341
|
+
78 = INVALID_ROLLUP,
|
|
342
|
+
79 = INVALID_BLOCK,
|
|
343
|
+
403 = FORBIDDEN,
|
|
344
|
+
500 = INTERNAL,
|
|
345
|
+
504 = TIMEOUT,
|
|
346
|
+
}
|
|
347
|
+
|
|
348
|
+
export enum KeyType {
|
|
345
349
|
0 = ED25519,
|
|
346
|
-
|
|
347
|
-
|
|
348
|
-
|
|
350
|
+
1 = SECP256K1,
|
|
351
|
+
2 = ETHEREUM,
|
|
352
|
+
}
|
|
349
353
|
|
|
350
|
-
|
|
354
|
+
export enum HashType {
|
|
351
355
|
0 = KECCAK,
|
|
352
|
-
|
|
353
|
-
|
|
354
|
-
|
|
355
|
-
|
|
356
|
-
|
|
357
|
-
|
|
358
|
-
|
|
359
|
-
|
|
360
|
-
|
|
356
|
+
1 = SHA3,
|
|
357
|
+
2 = SHA2,
|
|
358
|
+
6 = KECCAK_384,
|
|
359
|
+
7 = SHA3_384,
|
|
360
|
+
13 = KECCAK_512,
|
|
361
|
+
14 = SHA3_512,
|
|
362
|
+
}
|
|
363
|
+
|
|
364
|
+
export enum EncodingType {
|
|
361
365
|
0 = BASE16,
|
|
362
|
-
|
|
363
|
-
|
|
366
|
+
1 = BASE58,
|
|
367
|
+
}
|
|
364
368
|
|
|
365
|
-
|
|
369
|
+
export enum RoleType {
|
|
366
370
|
0 = ROLE_ACCOUNT,
|
|
367
|
-
|
|
368
|
-
|
|
369
|
-
|
|
370
|
-
|
|
371
|
-
|
|
372
|
-
|
|
373
|
-
|
|
374
|
-
|
|
375
|
-
|
|
376
|
-
|
|
377
|
-
|
|
378
|
-
|
|
379
|
-
|
|
380
|
-
|
|
381
|
-
|
|
382
|
-
|
|
383
|
-
|
|
384
|
-
|
|
385
|
-
|
|
386
|
-
|
|
387
|
-
|
|
388
|
-
|
|
389
|
-
|
|
390
|
-
|
|
371
|
+
1 = ROLE_NODE,
|
|
372
|
+
2 = ROLE_DEVICE,
|
|
373
|
+
3 = ROLE_APPLICATION,
|
|
374
|
+
4 = ROLE_SMART_CONTRACT,
|
|
375
|
+
5 = ROLE_BOT,
|
|
376
|
+
6 = ROLE_ASSET,
|
|
377
|
+
7 = ROLE_STAKE,
|
|
378
|
+
8 = ROLE_VALIDATOR,
|
|
379
|
+
9 = ROLE_GROUP,
|
|
380
|
+
10 = ROLE_TX,
|
|
381
|
+
11 = ROLE_TETHER,
|
|
382
|
+
12 = ROLE_SWAP,
|
|
383
|
+
13 = ROLE_DELEGATION,
|
|
384
|
+
14 = ROLE_VC,
|
|
385
|
+
15 = ROLE_BLOCKLET,
|
|
386
|
+
16 = ROLE_STORE,
|
|
387
|
+
17 = ROLE_TOKEN,
|
|
388
|
+
18 = ROLE_FACTORY,
|
|
389
|
+
19 = ROLE_ROLLUP,
|
|
390
|
+
20 = ROLE_STORAGE,
|
|
391
|
+
63 = ROLE_ANY,
|
|
392
|
+
}
|
|
393
|
+
|
|
394
|
+
export enum UpgradeType {
|
|
391
395
|
0 = CONFIG_APP,
|
|
392
|
-
|
|
393
|
-
|
|
394
|
-
|
|
395
|
-
|
|
396
|
-
|
|
397
|
-
|
|
398
|
-
|
|
399
|
-
|
|
400
|
-
|
|
401
|
-
|
|
402
|
-
|
|
403
|
-
|
|
396
|
+
1 = CONFIG_FORGE,
|
|
397
|
+
2 = CONFIG_DFS,
|
|
398
|
+
3 = CONFIG_CONSENSUS,
|
|
399
|
+
4 = CONFIG_P2P,
|
|
400
|
+
10 = EXE_APP,
|
|
401
|
+
11 = EXE_FORGE,
|
|
402
|
+
12 = EXE_DFS,
|
|
403
|
+
13 = EXE_CONSENSUS,
|
|
404
|
+
14 = EXE_P2P,
|
|
405
|
+
}
|
|
406
|
+
|
|
407
|
+
export enum UpgradeAction {
|
|
404
408
|
0 = VERIFY,
|
|
405
|
-
|
|
406
|
-
|
|
407
|
-
|
|
408
|
-
|
|
409
|
-
|
|
410
|
-
|
|
411
|
-
|
|
412
|
-
|
|
413
|
-
|
|
414
|
-
|
|
415
|
-
|
|
416
|
-
|
|
417
|
-
|
|
418
|
-
|
|
409
|
+
1 = BACKUP,
|
|
410
|
+
2 = REPLACE,
|
|
411
|
+
10 = RESTART_APP,
|
|
412
|
+
11 = RESTART_DFS,
|
|
413
|
+
12 = RESTART_CONSENSUS,
|
|
414
|
+
13 = RESTART_P2P,
|
|
415
|
+
14 = RESTART_FORGE,
|
|
416
|
+
30 = ROLLBACK_IF_FAIL,
|
|
417
|
+
31 = RESTART_ALL_IF_FAIL,
|
|
418
|
+
33 = CRASH_IF_FAIL,
|
|
419
|
+
50 = DROP_ADDRESS_BOOK,
|
|
420
|
+
}
|
|
421
|
+
|
|
422
|
+
export enum StateType {
|
|
419
423
|
0 = STATE_ACCOUNT,
|
|
420
|
-
|
|
421
|
-
|
|
422
|
-
|
|
423
|
-
|
|
424
|
-
|
|
424
|
+
1 = STATE_ASSET,
|
|
425
|
+
2 = STATE_CHANNEL,
|
|
426
|
+
3 = STATE_FORGE,
|
|
427
|
+
4 = STATE_STAKE,
|
|
428
|
+
}
|
|
425
429
|
|
|
426
|
-
|
|
430
|
+
export enum StakeType {
|
|
427
431
|
0 = STAKE_NODE,
|
|
428
|
-
|
|
429
|
-
|
|
430
|
-
|
|
431
|
-
|
|
432
|
+
1 = STAKE_USER,
|
|
433
|
+
2 = STAKE_ASSET,
|
|
434
|
+
3 = STAKE_CHAIN,
|
|
435
|
+
}
|
|
432
436
|
|
|
433
|
-
|
|
437
|
+
export enum ProtocolStatus {
|
|
434
438
|
0 = RUNNING,
|
|
435
|
-
|
|
436
|
-
|
|
437
|
-
|
|
439
|
+
1 = PAUSED,
|
|
440
|
+
2 = TERMINATED,
|
|
441
|
+
}
|
|
438
442
|
|
|
439
|
-
|
|
443
|
+
export enum TokenFactoryStatus {
|
|
440
444
|
0 = TOKEN_FACTORY_ACTIVE,
|
|
441
|
-
|
|
442
|
-
|
|
445
|
+
1 = TOKEN_FACTORY_PAUSED,
|
|
446
|
+
}
|
|
443
447
|
|
|
444
|
-
|
|
448
|
+
export enum Direction {
|
|
445
449
|
0 = MUTUAL,
|
|
446
|
-
|
|
447
|
-
|
|
448
|
-
|
|
450
|
+
1 = ONE_WAY,
|
|
451
|
+
2 = UNION,
|
|
452
|
+
}
|
|
449
453
|
|
|
450
|
-
|
|
454
|
+
export enum Validity {
|
|
451
455
|
0 = BOTH,
|
|
452
|
-
|
|
453
|
-
|
|
454
|
-
|
|
456
|
+
1 = VALID,
|
|
457
|
+
2 = INVALID,
|
|
458
|
+
}
|
|
455
459
|
|
|
456
|
-
|
|
460
|
+
export enum TokenFlowDirection {
|
|
457
461
|
0 = IN,
|
|
458
|
-
|
|
459
|
-
|
|
460
|
-
|
|
461
|
-
|
|
462
|
-
|
|
463
|
-
|
|
464
|
-
|
|
465
|
-
|
|
466
|
-
|
|
467
|
-
|
|
468
|
-
|
|
469
|
-
|
|
470
|
-
|
|
471
|
-
|
|
472
|
-
|
|
473
|
-
|
|
474
|
-
|
|
475
|
-
|
|
476
|
-
}
|
|
462
|
+
1 = OUT,
|
|
463
|
+
}
|
|
464
|
+
|
|
465
|
+
export interface main {
|
|
466
|
+
StatusCode: typeof Messages.StatusCode;
|
|
467
|
+
KeyType: typeof Messages.KeyType;
|
|
468
|
+
HashType: typeof Messages.HashType;
|
|
469
|
+
EncodingType: typeof Messages.EncodingType;
|
|
470
|
+
RoleType: typeof Messages.RoleType;
|
|
471
|
+
UpgradeType: typeof Messages.UpgradeType;
|
|
472
|
+
UpgradeAction: typeof Messages.UpgradeAction;
|
|
473
|
+
StateType: typeof Messages.StateType;
|
|
474
|
+
StakeType: typeof Messages.StakeType;
|
|
475
|
+
ProtocolStatus: typeof Messages.ProtocolStatus;
|
|
476
|
+
TokenFactoryStatus: typeof Messages.TokenFactoryStatus;
|
|
477
|
+
Direction: typeof Messages.Direction;
|
|
478
|
+
Validity: typeof Messages.Validity;
|
|
479
|
+
TokenFlowDirection: typeof Messages.TokenFlowDirection;
|
|
477
480
|
}
|
|
481
|
+
}
|