@kimafinance/kima-transaction-api 1.4.1 → 1.4.2
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/build/index.d.ts +50 -3
- package/build/index.js +121 -17
- package/build/kima/common.d.ts +1 -4
- package/build/kima/common.js +9 -12
- package/build/kima/tx.d.ts +674 -0
- package/build/kima/tx.js +2170 -0
- package/package.json +10 -10
- package/src/index.ts +206 -3
- package/src/kima/common.ts +12 -5
- package/src/kima/tx.ts +2945 -0
- package/build/api/htlc-lock.d.ts +0 -23
- package/build/api/htlc-lock.js +0 -37
- package/build/api/htlc-reclaim.d.ts +0 -14
- package/build/api/htlc-reclaim.js +0 -28
- package/build/api/submit.d.ts +0 -54
- package/build/api/submit.js +0 -94
- package/build/config/global-this.config.d.ts +0 -2
- package/build/config/global-this.config.js +0 -18
- package/build/config/probuff.config.d.ts +0 -2
- package/build/config/probuff.config.js +0 -12
- package/build/kima/tx/cancel.d.ts +0 -35
- package/build/kima/tx/cancel.js +0 -115
- package/build/kima/tx/drain-finalize.d.ts +0 -47
- package/build/kima/tx/drain-finalize.js +0 -155
- package/build/kima/tx/drain.d.ts +0 -50
- package/build/kima/tx/drain.js +0 -164
- package/build/kima/tx/finalize.d.ts +0 -47
- package/build/kima/tx/finalize.js +0 -155
- package/build/kima/tx/htlc-lock.d.ts +0 -42
- package/build/kima/tx/htlc-lock.js +0 -152
- package/build/kima/tx/htlc-reclaim.d.ts +0 -30
- package/build/kima/tx/htlc-reclaim.js +0 -105
- package/build/kima/tx/index.d.ts +0 -1
- package/build/kima/tx/index.js +0 -4
- package/build/kima/tx/liquidity-provision.d.ts +0 -30
- package/build/kima/tx/liquidity-provision.js +0 -102
- package/build/kima/tx/message-service.d.ts +0 -54
- package/build/kima/tx/message-service.js +0 -117
- package/build/kima/tx/provision-finalize.d.ts +0 -47
- package/build/kima/tx/provision-finalize.js +0 -155
- package/build/kima/tx/provision.d.ts +0 -70
- package/build/kima/tx/provision.js +0 -230
- package/build/kima/tx/request.d.ts +0 -63
- package/build/kima/tx/request.js +0 -222
- package/build/kima/tx/response.d.ts +0 -21
- package/build/kima/tx/response.js +0 -69
- package/build/kima/tx/rpc.d.ts +0 -0
- package/build/kima/tx/rpc.js +0 -1
- package/build/kima/tx/set-hash.d.ts +0 -42
- package/build/kima/tx/set-hash.js +0 -130
- package/build/kima/tx/set-process.d.ts +0 -37
- package/build/kima/tx/set-process.js +0 -121
- package/build/kima/tx/transfer-limit.d.ts +0 -30
- package/build/kima/tx/transfer-limit.js +0 -102
- package/build/kima/tx/withdraw.d.ts +0 -47
- package/build/kima/tx/withdraw.js +0 -155
- package/build/utils.d.ts +0 -17
- package/build/utils.js +0 -49
- package/src/api/htlc-lock.ts +0 -57
- package/src/api/htlc-reclaim.ts +0 -39
- package/src/api/submit.ts +0 -132
- package/src/config/global-this.config.ts +0 -20
- package/src/config/probuff.config.ts +0 -9
- package/src/kima/tx/cancel.ts +0 -147
- package/src/kima/tx/drain-finalize.ts +0 -191
- package/src/kima/tx/drain.ts +0 -201
- package/src/kima/tx/finalize.ts +0 -191
- package/src/kima/tx/htlc-lock.ts +0 -183
- package/src/kima/tx/htlc-reclaim.ts +0 -132
- package/src/kima/tx/index.ts +0 -1
- package/src/kima/tx/liquidity-provision.ts +0 -132
- package/src/kima/tx/message-service.ts +0 -278
- package/src/kima/tx/provision-finalize.ts +0 -191
- package/src/kima/tx/provision.ts +0 -279
- package/src/kima/tx/request.ts +0 -256
- package/src/kima/tx/response.ts +0 -83
- package/src/kima/tx/rpc.ts +0 -0
- package/src/kima/tx/set-hash.ts +0 -162
- package/src/kima/tx/set-process.ts +0 -151
- package/src/kima/tx/transfer-limit.ts +0 -132
- package/src/kima/tx/withdraw.ts +0 -191
- package/src/utils.ts +0 -67
package/build/kima/tx/drain.d.ts
DELETED
|
@@ -1,50 +0,0 @@
|
|
|
1
|
-
import _m0 from "../../config/probuff.config";
|
|
2
|
-
export interface MsgRequestDrainTransaction {
|
|
3
|
-
creator: string;
|
|
4
|
-
toChain: string;
|
|
5
|
-
toAddress: string;
|
|
6
|
-
symbol: string;
|
|
7
|
-
amount: string;
|
|
8
|
-
options: string;
|
|
9
|
-
}
|
|
10
|
-
export interface MsgRequestDrainTransactionResponse {
|
|
11
|
-
code: string;
|
|
12
|
-
msg: string;
|
|
13
|
-
txId: number;
|
|
14
|
-
}
|
|
15
|
-
export declare const MsgRequestDrainTransaction: {
|
|
16
|
-
encode(message: MsgRequestDrainTransaction, writer?: _m0.Writer): _m0.Writer;
|
|
17
|
-
decode(input: _m0.Reader | Uint8Array, length?: number): MsgRequestDrainTransaction;
|
|
18
|
-
fromJSON(object: any): MsgRequestDrainTransaction;
|
|
19
|
-
toJSON(message: MsgRequestDrainTransaction): unknown;
|
|
20
|
-
fromPartial<I extends {
|
|
21
|
-
creator?: string | undefined;
|
|
22
|
-
toChain?: string | undefined;
|
|
23
|
-
toAddress?: string | undefined;
|
|
24
|
-
symbol?: string | undefined;
|
|
25
|
-
amount?: string | undefined;
|
|
26
|
-
options?: string | undefined;
|
|
27
|
-
} & {
|
|
28
|
-
creator?: string | undefined;
|
|
29
|
-
toChain?: string | undefined;
|
|
30
|
-
toAddress?: string | undefined;
|
|
31
|
-
symbol?: string | undefined;
|
|
32
|
-
amount?: string | undefined;
|
|
33
|
-
options?: string | undefined;
|
|
34
|
-
} & { [K in Exclude<keyof I, keyof MsgRequestDrainTransaction>]: never; }>(object: I): MsgRequestDrainTransaction;
|
|
35
|
-
};
|
|
36
|
-
export declare const MsgRequestDrainTransactionResponse: {
|
|
37
|
-
encode(message: MsgRequestDrainTransactionResponse, writer?: _m0.Writer): _m0.Writer;
|
|
38
|
-
decode(input: _m0.Reader | Uint8Array, length?: number): MsgRequestDrainTransactionResponse;
|
|
39
|
-
fromJSON(object: any): MsgRequestDrainTransactionResponse;
|
|
40
|
-
toJSON(message: MsgRequestDrainTransactionResponse): unknown;
|
|
41
|
-
fromPartial<I extends {
|
|
42
|
-
code?: string | undefined;
|
|
43
|
-
msg?: string | undefined;
|
|
44
|
-
txId?: number | undefined;
|
|
45
|
-
} & {
|
|
46
|
-
code?: string | undefined;
|
|
47
|
-
msg?: string | undefined;
|
|
48
|
-
txId?: number | undefined;
|
|
49
|
-
} & { [K in Exclude<keyof I, keyof MsgRequestDrainTransactionResponse>]: never; }>(object: I): MsgRequestDrainTransactionResponse;
|
|
50
|
-
};
|
package/build/kima/tx/drain.js
DELETED
|
@@ -1,164 +0,0 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
var __importDefault = (this && this.__importDefault) || function (mod) {
|
|
3
|
-
return (mod && mod.__esModule) ? mod : { "default": mod };
|
|
4
|
-
};
|
|
5
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
6
|
-
exports.MsgRequestDrainTransactionResponse = exports.MsgRequestDrainTransaction = void 0;
|
|
7
|
-
const probuff_config_1 = __importDefault(require("../../config/probuff.config"));
|
|
8
|
-
const utils_1 = require("../../utils");
|
|
9
|
-
function createBaseMsgRequestDrainTransaction() {
|
|
10
|
-
return {
|
|
11
|
-
creator: "",
|
|
12
|
-
toChain: "",
|
|
13
|
-
toAddress: "",
|
|
14
|
-
symbol: "",
|
|
15
|
-
amount: "",
|
|
16
|
-
options: "",
|
|
17
|
-
};
|
|
18
|
-
}
|
|
19
|
-
exports.MsgRequestDrainTransaction = {
|
|
20
|
-
encode(message, writer = probuff_config_1.default.Writer.create()) {
|
|
21
|
-
if (message.creator !== "") {
|
|
22
|
-
writer.uint32(10).string(message.creator);
|
|
23
|
-
}
|
|
24
|
-
if (message.toChain !== "") {
|
|
25
|
-
writer.uint32(18).string(message.toChain);
|
|
26
|
-
}
|
|
27
|
-
if (message.toAddress !== "") {
|
|
28
|
-
writer.uint32(26).string(message.toAddress);
|
|
29
|
-
}
|
|
30
|
-
if (message.symbol !== "") {
|
|
31
|
-
writer.uint32(34).string(message.symbol);
|
|
32
|
-
}
|
|
33
|
-
if (message.amount !== "") {
|
|
34
|
-
writer.uint32(42).string(message.amount);
|
|
35
|
-
}
|
|
36
|
-
if (message.options !== "") {
|
|
37
|
-
writer.uint32(50).string(message.options);
|
|
38
|
-
}
|
|
39
|
-
return writer;
|
|
40
|
-
},
|
|
41
|
-
decode(input, length) {
|
|
42
|
-
const reader = input instanceof probuff_config_1.default.Reader ? input : new probuff_config_1.default.Reader(input);
|
|
43
|
-
let end = length === undefined ? reader.len : reader.pos + length;
|
|
44
|
-
const message = createBaseMsgRequestDrainTransaction();
|
|
45
|
-
while (reader.pos < end) {
|
|
46
|
-
const tag = reader.uint32();
|
|
47
|
-
switch (tag >>> 3) {
|
|
48
|
-
case 1:
|
|
49
|
-
message.creator = reader.string();
|
|
50
|
-
break;
|
|
51
|
-
case 2:
|
|
52
|
-
message.toChain = reader.string();
|
|
53
|
-
break;
|
|
54
|
-
case 3:
|
|
55
|
-
message.toAddress = reader.string();
|
|
56
|
-
break;
|
|
57
|
-
case 4:
|
|
58
|
-
message.symbol = reader.string();
|
|
59
|
-
break;
|
|
60
|
-
case 5:
|
|
61
|
-
message.amount = reader.string();
|
|
62
|
-
break;
|
|
63
|
-
case 6:
|
|
64
|
-
message.options = reader.string();
|
|
65
|
-
break;
|
|
66
|
-
default:
|
|
67
|
-
reader.skipType(tag & 7);
|
|
68
|
-
break;
|
|
69
|
-
}
|
|
70
|
-
}
|
|
71
|
-
return message;
|
|
72
|
-
},
|
|
73
|
-
fromJSON(object) {
|
|
74
|
-
return {
|
|
75
|
-
creator: (0, utils_1.isSet)(object.creator) ? String(object.creator) : "",
|
|
76
|
-
toChain: (0, utils_1.isSet)(object.toChain) ? String(object.toChain) : "",
|
|
77
|
-
toAddress: (0, utils_1.isSet)(object.toAddress) ? String(object.toAddress) : "",
|
|
78
|
-
symbol: (0, utils_1.isSet)(object.symbol) ? String(object.symbol) : "",
|
|
79
|
-
amount: (0, utils_1.isSet)(object.amount) ? String(object.amount) : "",
|
|
80
|
-
options: (0, utils_1.isSet)(object.options) ? String(object.options) : "",
|
|
81
|
-
};
|
|
82
|
-
},
|
|
83
|
-
toJSON(message) {
|
|
84
|
-
const obj = {};
|
|
85
|
-
message.creator !== undefined && (obj.creator = message.creator);
|
|
86
|
-
message.toChain !== undefined && (obj.toChain = message.toChain);
|
|
87
|
-
message.toAddress !== undefined && (obj.toAddress = message.toAddress);
|
|
88
|
-
message.symbol !== undefined && (obj.symbol = message.symbol);
|
|
89
|
-
message.amount !== undefined && (obj.amount = message.amount);
|
|
90
|
-
message.options !== undefined && (obj.options = message.options);
|
|
91
|
-
return obj;
|
|
92
|
-
},
|
|
93
|
-
fromPartial(object) {
|
|
94
|
-
const message = createBaseMsgRequestDrainTransaction();
|
|
95
|
-
message.creator = object.creator ?? "";
|
|
96
|
-
message.toChain = object.toChain ?? "";
|
|
97
|
-
message.toAddress = object.toAddress ?? "";
|
|
98
|
-
message.symbol = object.symbol ?? "";
|
|
99
|
-
message.amount = object.amount ?? "";
|
|
100
|
-
message.options = object.options ?? "";
|
|
101
|
-
return message;
|
|
102
|
-
},
|
|
103
|
-
};
|
|
104
|
-
function createBaseMsgRequestDrainTransactionResponse() {
|
|
105
|
-
return { code: "", msg: "", txId: 0 };
|
|
106
|
-
}
|
|
107
|
-
exports.MsgRequestDrainTransactionResponse = {
|
|
108
|
-
encode(message, writer = probuff_config_1.default.Writer.create()) {
|
|
109
|
-
if (message.code !== "") {
|
|
110
|
-
writer.uint32(10).string(message.code);
|
|
111
|
-
}
|
|
112
|
-
if (message.msg !== "") {
|
|
113
|
-
writer.uint32(18).string(message.msg);
|
|
114
|
-
}
|
|
115
|
-
if (message.txId !== 0) {
|
|
116
|
-
writer.uint32(24).uint64(message.txId);
|
|
117
|
-
}
|
|
118
|
-
return writer;
|
|
119
|
-
},
|
|
120
|
-
decode(input, length) {
|
|
121
|
-
const reader = input instanceof probuff_config_1.default.Reader ? input : new probuff_config_1.default.Reader(input);
|
|
122
|
-
let end = length === undefined ? reader.len : reader.pos + length;
|
|
123
|
-
const message = createBaseMsgRequestDrainTransactionResponse();
|
|
124
|
-
while (reader.pos < end) {
|
|
125
|
-
const tag = reader.uint32();
|
|
126
|
-
switch (tag >>> 3) {
|
|
127
|
-
case 1:
|
|
128
|
-
message.code = reader.string();
|
|
129
|
-
break;
|
|
130
|
-
case 2:
|
|
131
|
-
message.msg = reader.string();
|
|
132
|
-
break;
|
|
133
|
-
case 3:
|
|
134
|
-
message.txId = (0, utils_1.longToNumber)(reader.uint64());
|
|
135
|
-
break;
|
|
136
|
-
default:
|
|
137
|
-
reader.skipType(tag & 7);
|
|
138
|
-
break;
|
|
139
|
-
}
|
|
140
|
-
}
|
|
141
|
-
return message;
|
|
142
|
-
},
|
|
143
|
-
fromJSON(object) {
|
|
144
|
-
return {
|
|
145
|
-
code: (0, utils_1.isSet)(object.code) ? String(object.code) : "",
|
|
146
|
-
msg: (0, utils_1.isSet)(object.msg) ? String(object.msg) : "",
|
|
147
|
-
txId: (0, utils_1.isSet)(object.txId) ? Number(object.txId) : 0,
|
|
148
|
-
};
|
|
149
|
-
},
|
|
150
|
-
toJSON(message) {
|
|
151
|
-
const obj = {};
|
|
152
|
-
message.code !== undefined && (obj.code = message.code);
|
|
153
|
-
message.msg !== undefined && (obj.msg = message.msg);
|
|
154
|
-
message.txId !== undefined && (obj.txId = Math.round(message.txId));
|
|
155
|
-
return obj;
|
|
156
|
-
},
|
|
157
|
-
fromPartial(object) {
|
|
158
|
-
const message = createBaseMsgRequestDrainTransactionResponse();
|
|
159
|
-
message.code = object.code ?? "";
|
|
160
|
-
message.msg = object.msg ?? "";
|
|
161
|
-
message.txId = object.txId ?? 0;
|
|
162
|
-
return message;
|
|
163
|
-
},
|
|
164
|
-
};
|
|
@@ -1,47 +0,0 @@
|
|
|
1
|
-
import _m0 from "../../config/probuff.config";
|
|
2
|
-
export interface MsgFinalizeTransaction {
|
|
3
|
-
creator: string;
|
|
4
|
-
txId: number;
|
|
5
|
-
txHash: string;
|
|
6
|
-
success: boolean;
|
|
7
|
-
signedKey: string;
|
|
8
|
-
errReason: string;
|
|
9
|
-
}
|
|
10
|
-
export interface MsgFinalizeTransactionResponse {
|
|
11
|
-
code: string;
|
|
12
|
-
msg: string;
|
|
13
|
-
}
|
|
14
|
-
export declare const MsgFinalizeTransaction: {
|
|
15
|
-
encode(message: MsgFinalizeTransaction, writer?: _m0.Writer): _m0.Writer;
|
|
16
|
-
decode(input: _m0.Reader | Uint8Array, length?: number): MsgFinalizeTransaction;
|
|
17
|
-
fromJSON(object: any): MsgFinalizeTransaction;
|
|
18
|
-
toJSON(message: MsgFinalizeTransaction): unknown;
|
|
19
|
-
fromPartial<I extends {
|
|
20
|
-
creator?: string | undefined;
|
|
21
|
-
txId?: number | undefined;
|
|
22
|
-
txHash?: string | undefined;
|
|
23
|
-
success?: boolean | undefined;
|
|
24
|
-
signedKey?: string | undefined;
|
|
25
|
-
errReason?: string | undefined;
|
|
26
|
-
} & {
|
|
27
|
-
creator?: string | undefined;
|
|
28
|
-
txId?: number | undefined;
|
|
29
|
-
txHash?: string | undefined;
|
|
30
|
-
success?: boolean | undefined;
|
|
31
|
-
signedKey?: string | undefined;
|
|
32
|
-
errReason?: string | undefined;
|
|
33
|
-
} & { [K in Exclude<keyof I, keyof MsgFinalizeTransaction>]: never; }>(object: I): MsgFinalizeTransaction;
|
|
34
|
-
};
|
|
35
|
-
export declare const MsgFinalizeTransactionResponse: {
|
|
36
|
-
encode(message: MsgFinalizeTransactionResponse, writer?: _m0.Writer): _m0.Writer;
|
|
37
|
-
decode(input: _m0.Reader | Uint8Array, length?: number): MsgFinalizeTransactionResponse;
|
|
38
|
-
fromJSON(object: any): MsgFinalizeTransactionResponse;
|
|
39
|
-
toJSON(message: MsgFinalizeTransactionResponse): unknown;
|
|
40
|
-
fromPartial<I extends {
|
|
41
|
-
code?: string | undefined;
|
|
42
|
-
msg?: string | undefined;
|
|
43
|
-
} & {
|
|
44
|
-
code?: string | undefined;
|
|
45
|
-
msg?: string | undefined;
|
|
46
|
-
} & { [K in Exclude<keyof I, keyof MsgFinalizeTransactionResponse>]: never; }>(object: I): MsgFinalizeTransactionResponse;
|
|
47
|
-
};
|
|
@@ -1,155 +0,0 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
var __importDefault = (this && this.__importDefault) || function (mod) {
|
|
3
|
-
return (mod && mod.__esModule) ? mod : { "default": mod };
|
|
4
|
-
};
|
|
5
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
6
|
-
exports.MsgFinalizeTransactionResponse = exports.MsgFinalizeTransaction = void 0;
|
|
7
|
-
const probuff_config_1 = __importDefault(require("../../config/probuff.config"));
|
|
8
|
-
const utils_1 = require("../../utils");
|
|
9
|
-
function createBaseMsgFinalizeTransaction() {
|
|
10
|
-
return {
|
|
11
|
-
creator: "",
|
|
12
|
-
txId: 0,
|
|
13
|
-
txHash: "",
|
|
14
|
-
success: false,
|
|
15
|
-
signedKey: "",
|
|
16
|
-
errReason: "",
|
|
17
|
-
};
|
|
18
|
-
}
|
|
19
|
-
exports.MsgFinalizeTransaction = {
|
|
20
|
-
encode(message, writer = probuff_config_1.default.Writer.create()) {
|
|
21
|
-
if (message.creator !== "") {
|
|
22
|
-
writer.uint32(10).string(message.creator);
|
|
23
|
-
}
|
|
24
|
-
if (message.txId !== 0) {
|
|
25
|
-
writer.uint32(16).uint64(message.txId);
|
|
26
|
-
}
|
|
27
|
-
if (message.txHash !== "") {
|
|
28
|
-
writer.uint32(26).string(message.txHash);
|
|
29
|
-
}
|
|
30
|
-
if (message.success === true) {
|
|
31
|
-
writer.uint32(32).bool(message.success);
|
|
32
|
-
}
|
|
33
|
-
if (message.signedKey !== "") {
|
|
34
|
-
writer.uint32(42).string(message.signedKey);
|
|
35
|
-
}
|
|
36
|
-
if (message.errReason !== "") {
|
|
37
|
-
writer.uint32(50).string(message.errReason);
|
|
38
|
-
}
|
|
39
|
-
return writer;
|
|
40
|
-
},
|
|
41
|
-
decode(input, length) {
|
|
42
|
-
const reader = input instanceof probuff_config_1.default.Reader ? input : new probuff_config_1.default.Reader(input);
|
|
43
|
-
let end = length === undefined ? reader.len : reader.pos + length;
|
|
44
|
-
const message = createBaseMsgFinalizeTransaction();
|
|
45
|
-
while (reader.pos < end) {
|
|
46
|
-
const tag = reader.uint32();
|
|
47
|
-
switch (tag >>> 3) {
|
|
48
|
-
case 1:
|
|
49
|
-
message.creator = reader.string();
|
|
50
|
-
break;
|
|
51
|
-
case 2:
|
|
52
|
-
message.txId = (0, utils_1.longToNumber)(reader.uint64());
|
|
53
|
-
break;
|
|
54
|
-
case 3:
|
|
55
|
-
message.txHash = reader.string();
|
|
56
|
-
break;
|
|
57
|
-
case 4:
|
|
58
|
-
message.success = reader.bool();
|
|
59
|
-
break;
|
|
60
|
-
case 5:
|
|
61
|
-
message.signedKey = reader.string();
|
|
62
|
-
break;
|
|
63
|
-
case 6:
|
|
64
|
-
message.errReason = reader.string();
|
|
65
|
-
break;
|
|
66
|
-
default:
|
|
67
|
-
reader.skipType(tag & 7);
|
|
68
|
-
break;
|
|
69
|
-
}
|
|
70
|
-
}
|
|
71
|
-
return message;
|
|
72
|
-
},
|
|
73
|
-
fromJSON(object) {
|
|
74
|
-
return {
|
|
75
|
-
creator: (0, utils_1.isSet)(object.creator) ? String(object.creator) : "",
|
|
76
|
-
txId: (0, utils_1.isSet)(object.txId) ? Number(object.txId) : 0,
|
|
77
|
-
txHash: (0, utils_1.isSet)(object.txHash) ? String(object.txHash) : "",
|
|
78
|
-
success: (0, utils_1.isSet)(object.success) ? Boolean(object.success) : false,
|
|
79
|
-
signedKey: (0, utils_1.isSet)(object.signedKey) ? String(object.signedKey) : "",
|
|
80
|
-
errReason: (0, utils_1.isSet)(object.errReason) ? String(object.errReason) : "",
|
|
81
|
-
};
|
|
82
|
-
},
|
|
83
|
-
toJSON(message) {
|
|
84
|
-
const obj = {};
|
|
85
|
-
message.creator !== undefined && (obj.creator = message.creator);
|
|
86
|
-
message.txId !== undefined && (obj.txId = Math.round(message.txId));
|
|
87
|
-
message.txHash !== undefined && (obj.txHash = message.txHash);
|
|
88
|
-
message.success !== undefined && (obj.success = message.success);
|
|
89
|
-
message.signedKey !== undefined && (obj.signedKey = message.signedKey);
|
|
90
|
-
message.errReason !== undefined && (obj.errReason = message.errReason);
|
|
91
|
-
return obj;
|
|
92
|
-
},
|
|
93
|
-
fromPartial(object) {
|
|
94
|
-
const message = createBaseMsgFinalizeTransaction();
|
|
95
|
-
message.creator = object.creator ?? "";
|
|
96
|
-
message.txId = object.txId ?? 0;
|
|
97
|
-
message.txHash = object.txHash ?? "";
|
|
98
|
-
message.success = object.success ?? false;
|
|
99
|
-
message.signedKey = object.signedKey ?? "";
|
|
100
|
-
message.errReason = object.errReason ?? "";
|
|
101
|
-
return message;
|
|
102
|
-
},
|
|
103
|
-
};
|
|
104
|
-
function createBaseMsgFinalizeTransactionResponse() {
|
|
105
|
-
return { code: "", msg: "" };
|
|
106
|
-
}
|
|
107
|
-
exports.MsgFinalizeTransactionResponse = {
|
|
108
|
-
encode(message, writer = probuff_config_1.default.Writer.create()) {
|
|
109
|
-
if (message.code !== "") {
|
|
110
|
-
writer.uint32(10).string(message.code);
|
|
111
|
-
}
|
|
112
|
-
if (message.msg !== "") {
|
|
113
|
-
writer.uint32(18).string(message.msg);
|
|
114
|
-
}
|
|
115
|
-
return writer;
|
|
116
|
-
},
|
|
117
|
-
decode(input, length) {
|
|
118
|
-
const reader = input instanceof probuff_config_1.default.Reader ? input : new probuff_config_1.default.Reader(input);
|
|
119
|
-
let end = length === undefined ? reader.len : reader.pos + length;
|
|
120
|
-
const message = createBaseMsgFinalizeTransactionResponse();
|
|
121
|
-
while (reader.pos < end) {
|
|
122
|
-
const tag = reader.uint32();
|
|
123
|
-
switch (tag >>> 3) {
|
|
124
|
-
case 1:
|
|
125
|
-
message.code = reader.string();
|
|
126
|
-
break;
|
|
127
|
-
case 2:
|
|
128
|
-
message.msg = reader.string();
|
|
129
|
-
break;
|
|
130
|
-
default:
|
|
131
|
-
reader.skipType(tag & 7);
|
|
132
|
-
break;
|
|
133
|
-
}
|
|
134
|
-
}
|
|
135
|
-
return message;
|
|
136
|
-
},
|
|
137
|
-
fromJSON(object) {
|
|
138
|
-
return {
|
|
139
|
-
code: (0, utils_1.isSet)(object.code) ? String(object.code) : "",
|
|
140
|
-
msg: (0, utils_1.isSet)(object.msg) ? String(object.msg) : "",
|
|
141
|
-
};
|
|
142
|
-
},
|
|
143
|
-
toJSON(message) {
|
|
144
|
-
const obj = {};
|
|
145
|
-
message.code !== undefined && (obj.code = message.code);
|
|
146
|
-
message.msg !== undefined && (obj.msg = message.msg);
|
|
147
|
-
return obj;
|
|
148
|
-
},
|
|
149
|
-
fromPartial(object) {
|
|
150
|
-
const message = createBaseMsgFinalizeTransactionResponse();
|
|
151
|
-
message.code = object.code ?? "";
|
|
152
|
-
message.msg = object.msg ?? "";
|
|
153
|
-
return message;
|
|
154
|
-
},
|
|
155
|
-
};
|
|
@@ -1,42 +0,0 @@
|
|
|
1
|
-
import _m0 from "../../config/probuff.config";
|
|
2
|
-
export interface MsgRequestHtlcLock {
|
|
3
|
-
creator: string;
|
|
4
|
-
fromAddress: string;
|
|
5
|
-
senderPubkey: string;
|
|
6
|
-
amount: string;
|
|
7
|
-
htlcTimeout: string;
|
|
8
|
-
txHash: string;
|
|
9
|
-
htlcAddress: string;
|
|
10
|
-
}
|
|
11
|
-
export interface MsgRequestHtlcLockResponse {
|
|
12
|
-
}
|
|
13
|
-
export declare const MsgRequestHtlcLock: {
|
|
14
|
-
encode(message: MsgRequestHtlcLock, writer?: _m0.Writer): _m0.Writer;
|
|
15
|
-
decode(input: _m0.Reader | Uint8Array, length?: number): MsgRequestHtlcLock;
|
|
16
|
-
fromJSON(object: any): MsgRequestHtlcLock;
|
|
17
|
-
toJSON(message: MsgRequestHtlcLock): unknown;
|
|
18
|
-
fromPartial<I extends {
|
|
19
|
-
creator?: string | undefined;
|
|
20
|
-
fromAddress?: string | undefined;
|
|
21
|
-
senderPubkey?: string | undefined;
|
|
22
|
-
amount?: string | undefined;
|
|
23
|
-
htlcTimeout?: string | undefined;
|
|
24
|
-
txHash?: string | undefined;
|
|
25
|
-
htlcAddress?: string | undefined;
|
|
26
|
-
} & {
|
|
27
|
-
creator?: string | undefined;
|
|
28
|
-
fromAddress?: string | undefined;
|
|
29
|
-
senderPubkey?: string | undefined;
|
|
30
|
-
amount?: string | undefined;
|
|
31
|
-
htlcTimeout?: string | undefined;
|
|
32
|
-
txHash?: string | undefined;
|
|
33
|
-
htlcAddress?: string | undefined;
|
|
34
|
-
} & { [K in Exclude<keyof I, keyof MsgRequestHtlcLock>]: never; }>(object: I): MsgRequestHtlcLock;
|
|
35
|
-
};
|
|
36
|
-
export declare const MsgRequestHtlcLockResponse: {
|
|
37
|
-
encode(_: MsgRequestHtlcLockResponse, writer?: _m0.Writer): _m0.Writer;
|
|
38
|
-
decode(input: _m0.Reader | Uint8Array, length?: number): MsgRequestHtlcLockResponse;
|
|
39
|
-
fromJSON(_: any): MsgRequestHtlcLockResponse;
|
|
40
|
-
toJSON(_: MsgRequestHtlcLockResponse): unknown;
|
|
41
|
-
fromPartial<I extends {} & {} & { [K in Exclude<keyof I, never>]: never; }>(_: I): MsgRequestHtlcLockResponse;
|
|
42
|
-
};
|
|
@@ -1,152 +0,0 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
var __importDefault = (this && this.__importDefault) || function (mod) {
|
|
3
|
-
return (mod && mod.__esModule) ? mod : { "default": mod };
|
|
4
|
-
};
|
|
5
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
6
|
-
exports.MsgRequestHtlcLockResponse = exports.MsgRequestHtlcLock = void 0;
|
|
7
|
-
const probuff_config_1 = __importDefault(require("../../config/probuff.config"));
|
|
8
|
-
const utils_1 = require("../../utils");
|
|
9
|
-
function createBaseMsgRequestHtlcLock() {
|
|
10
|
-
return {
|
|
11
|
-
creator: "",
|
|
12
|
-
fromAddress: "",
|
|
13
|
-
senderPubkey: "",
|
|
14
|
-
amount: "",
|
|
15
|
-
htlcTimeout: "",
|
|
16
|
-
txHash: "",
|
|
17
|
-
htlcAddress: "",
|
|
18
|
-
};
|
|
19
|
-
}
|
|
20
|
-
exports.MsgRequestHtlcLock = {
|
|
21
|
-
encode(message, writer = probuff_config_1.default.Writer.create()) {
|
|
22
|
-
if (message.creator !== "") {
|
|
23
|
-
writer.uint32(10).string(message.creator);
|
|
24
|
-
}
|
|
25
|
-
if (message.fromAddress !== "") {
|
|
26
|
-
writer.uint32(18).string(message.fromAddress);
|
|
27
|
-
}
|
|
28
|
-
if (message.senderPubkey !== "") {
|
|
29
|
-
writer.uint32(26).string(message.senderPubkey);
|
|
30
|
-
}
|
|
31
|
-
if (message.amount !== "") {
|
|
32
|
-
writer.uint32(34).string(message.amount);
|
|
33
|
-
}
|
|
34
|
-
if (message.htlcTimeout !== "") {
|
|
35
|
-
writer.uint32(42).string(message.htlcTimeout);
|
|
36
|
-
}
|
|
37
|
-
if (message.txHash !== "") {
|
|
38
|
-
writer.uint32(50).string(message.txHash);
|
|
39
|
-
}
|
|
40
|
-
if (message.htlcAddress !== "") {
|
|
41
|
-
writer.uint32(58).string(message.htlcAddress);
|
|
42
|
-
}
|
|
43
|
-
return writer;
|
|
44
|
-
},
|
|
45
|
-
decode(input, length) {
|
|
46
|
-
const reader = input instanceof probuff_config_1.default.Reader ? input : new probuff_config_1.default.Reader(input);
|
|
47
|
-
let end = length === undefined ? reader.len : reader.pos + length;
|
|
48
|
-
const message = createBaseMsgRequestHtlcLock();
|
|
49
|
-
while (reader.pos < end) {
|
|
50
|
-
const tag = reader.uint32();
|
|
51
|
-
switch (tag >>> 3) {
|
|
52
|
-
case 1:
|
|
53
|
-
message.creator = reader.string();
|
|
54
|
-
break;
|
|
55
|
-
case 2:
|
|
56
|
-
message.fromAddress = reader.string();
|
|
57
|
-
break;
|
|
58
|
-
case 3:
|
|
59
|
-
message.senderPubkey = reader.string();
|
|
60
|
-
break;
|
|
61
|
-
case 4:
|
|
62
|
-
message.amount = reader.string();
|
|
63
|
-
break;
|
|
64
|
-
case 5:
|
|
65
|
-
message.htlcTimeout = reader.string();
|
|
66
|
-
break;
|
|
67
|
-
case 6:
|
|
68
|
-
message.txHash = reader.string();
|
|
69
|
-
break;
|
|
70
|
-
case 7:
|
|
71
|
-
message.htlcAddress = reader.string();
|
|
72
|
-
break;
|
|
73
|
-
default:
|
|
74
|
-
reader.skipType(tag & 7);
|
|
75
|
-
break;
|
|
76
|
-
}
|
|
77
|
-
}
|
|
78
|
-
return message;
|
|
79
|
-
},
|
|
80
|
-
fromJSON(object) {
|
|
81
|
-
return {
|
|
82
|
-
creator: (0, utils_1.isSet)(object.creator) ? String(object.creator) : "",
|
|
83
|
-
fromAddress: (0, utils_1.isSet)(object.fromAddress) ? String(object.fromAddress) : "",
|
|
84
|
-
senderPubkey: (0, utils_1.isSet)(object.senderPubkey)
|
|
85
|
-
? String(object.senderPubkey)
|
|
86
|
-
: "",
|
|
87
|
-
amount: (0, utils_1.isSet)(object.amount) ? String(object.amount) : "",
|
|
88
|
-
htlcTimeout: (0, utils_1.isSet)(object.htlcTimeout) ? String(object.htlcTimeout) : "",
|
|
89
|
-
txHash: (0, utils_1.isSet)(object.txHash) ? String(object.txHash) : "",
|
|
90
|
-
htlcAddress: (0, utils_1.isSet)(object.htlcAddress) ? String(object.htlcAddress) : "",
|
|
91
|
-
};
|
|
92
|
-
},
|
|
93
|
-
toJSON(message) {
|
|
94
|
-
const obj = {};
|
|
95
|
-
message.creator !== undefined && (obj.creator = message.creator);
|
|
96
|
-
message.fromAddress !== undefined &&
|
|
97
|
-
(obj.fromAddress = message.fromAddress);
|
|
98
|
-
message.senderPubkey !== undefined &&
|
|
99
|
-
(obj.senderPubkey = message.senderPubkey);
|
|
100
|
-
message.amount !== undefined && (obj.amount = message.amount);
|
|
101
|
-
message.htlcTimeout !== undefined &&
|
|
102
|
-
(obj.htlcTimeout = message.htlcTimeout);
|
|
103
|
-
message.txHash !== undefined && (obj.txHash = message.txHash);
|
|
104
|
-
message.htlcAddress !== undefined &&
|
|
105
|
-
(obj.htlcAddress = message.htlcAddress);
|
|
106
|
-
return obj;
|
|
107
|
-
},
|
|
108
|
-
fromPartial(object) {
|
|
109
|
-
const message = createBaseMsgRequestHtlcLock();
|
|
110
|
-
message.creator = object.creator ?? "";
|
|
111
|
-
message.fromAddress = object.fromAddress ?? "";
|
|
112
|
-
message.senderPubkey = object.senderPubkey ?? "";
|
|
113
|
-
message.amount = object.amount ?? "";
|
|
114
|
-
message.htlcTimeout = object.htlcTimeout ?? "";
|
|
115
|
-
message.txHash = object.txHash ?? "";
|
|
116
|
-
message.htlcAddress = object.htlcAddress ?? "";
|
|
117
|
-
return message;
|
|
118
|
-
},
|
|
119
|
-
};
|
|
120
|
-
function createBaseMsgRequestHtlcLockResponse() {
|
|
121
|
-
return {};
|
|
122
|
-
}
|
|
123
|
-
exports.MsgRequestHtlcLockResponse = {
|
|
124
|
-
encode(_, writer = probuff_config_1.default.Writer.create()) {
|
|
125
|
-
return writer;
|
|
126
|
-
},
|
|
127
|
-
decode(input, length) {
|
|
128
|
-
const reader = input instanceof probuff_config_1.default.Reader ? input : new probuff_config_1.default.Reader(input);
|
|
129
|
-
let end = length === undefined ? reader.len : reader.pos + length;
|
|
130
|
-
const message = createBaseMsgRequestHtlcLockResponse();
|
|
131
|
-
while (reader.pos < end) {
|
|
132
|
-
const tag = reader.uint32();
|
|
133
|
-
switch (tag >>> 3) {
|
|
134
|
-
default:
|
|
135
|
-
reader.skipType(tag & 7);
|
|
136
|
-
break;
|
|
137
|
-
}
|
|
138
|
-
}
|
|
139
|
-
return message;
|
|
140
|
-
},
|
|
141
|
-
fromJSON(_) {
|
|
142
|
-
return {};
|
|
143
|
-
},
|
|
144
|
-
toJSON(_) {
|
|
145
|
-
const obj = {};
|
|
146
|
-
return obj;
|
|
147
|
-
},
|
|
148
|
-
fromPartial(_) {
|
|
149
|
-
const message = createBaseMsgRequestHtlcLockResponse();
|
|
150
|
-
return message;
|
|
151
|
-
},
|
|
152
|
-
};
|
|
@@ -1,30 +0,0 @@
|
|
|
1
|
-
import _m0 from "../../config/probuff.config";
|
|
2
|
-
export interface MsgHtlcReclaim {
|
|
3
|
-
creator: string;
|
|
4
|
-
txHash: string;
|
|
5
|
-
senderAddress: string;
|
|
6
|
-
}
|
|
7
|
-
export interface MsgHtlcReclaimResponse {
|
|
8
|
-
}
|
|
9
|
-
export declare const MsgHtlcReclaim: {
|
|
10
|
-
encode(message: MsgHtlcReclaim, writer?: _m0.Writer): _m0.Writer;
|
|
11
|
-
decode(input: _m0.Reader | Uint8Array, length?: number): MsgHtlcReclaim;
|
|
12
|
-
fromJSON(object: any): MsgHtlcReclaim;
|
|
13
|
-
toJSON(message: MsgHtlcReclaim): unknown;
|
|
14
|
-
fromPartial<I extends {
|
|
15
|
-
creator?: string | undefined;
|
|
16
|
-
txHash?: string | undefined;
|
|
17
|
-
senderAddress?: string | undefined;
|
|
18
|
-
} & {
|
|
19
|
-
creator?: string | undefined;
|
|
20
|
-
txHash?: string | undefined;
|
|
21
|
-
senderAddress?: string | undefined;
|
|
22
|
-
} & { [K in Exclude<keyof I, keyof MsgHtlcReclaim>]: never; }>(object: I): MsgHtlcReclaim;
|
|
23
|
-
};
|
|
24
|
-
export declare const MsgHtlcReclaimResponse: {
|
|
25
|
-
encode(_: MsgHtlcReclaimResponse, writer?: _m0.Writer): _m0.Writer;
|
|
26
|
-
decode(input: _m0.Reader | Uint8Array, length?: number): MsgHtlcReclaimResponse;
|
|
27
|
-
fromJSON(_: any): MsgHtlcReclaimResponse;
|
|
28
|
-
toJSON(_: MsgHtlcReclaimResponse): unknown;
|
|
29
|
-
fromPartial<I extends {} & {} & { [K in Exclude<keyof I, never>]: never; }>(_: I): MsgHtlcReclaimResponse;
|
|
30
|
-
};
|