@meshtrade/api-web 1.60.0 → 1.61.0
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/dist/meshtrade/iam/role/v1/role.js +2 -0
- package/dist/meshtrade/iam/role/v1/role_pb.d.ts +8 -0
- package/dist/meshtrade/iam/role/v1/role_pb.js +9 -1
- package/dist/meshtrade/wallet/transfer/v1/index.d.ts +3 -0
- package/dist/meshtrade/wallet/transfer/v1/index.js +44 -0
- package/dist/meshtrade/wallet/transfer/v1/service_pb.d.ts +232 -0
- package/dist/meshtrade/wallet/transfer/v1/service_pb.js +65 -0
- package/dist/meshtrade/wallet/transfer/v1/service_web_meshts.d.ts +124 -0
- package/dist/meshtrade/wallet/transfer/v1/service_web_meshts.js +228 -0
- package/dist/meshtrade/wallet/transfer/v1/transfer_pb.d.ts +187 -0
- package/dist/meshtrade/wallet/transfer/v1/transfer_pb.js +61 -0
- package/package.json +1 -1
|
@@ -17,6 +17,8 @@ const roleToStringMapping = {
|
|
|
17
17
|
[role_pb_1.Role.WALLET_VIEWER]: "Wallet Viewer",
|
|
18
18
|
[role_pb_1.Role.WALLET_ACCOUNT_ADMIN]: "Wallet Account Admin",
|
|
19
19
|
[role_pb_1.Role.WALLET_ACCOUNT_VIEWER]: "Wallet Account Viewer",
|
|
20
|
+
[role_pb_1.Role.WALLET_TRANSFER_ADMIN]: "Wallet Transfer Admin",
|
|
21
|
+
[role_pb_1.Role.WALLET_TRANSFER_VIEWER]: "Wallet Transfer Viewer",
|
|
20
22
|
[role_pb_1.Role.COMPLIANCE_ADMIN]: "Compliance Admin",
|
|
21
23
|
[role_pb_1.Role.COMPLIANCE_VIEWER]: "Compliance Viewer",
|
|
22
24
|
[role_pb_1.Role.COMPLIANCE_CLIENT_ADMIN]: "Compliance Client Admin",
|
|
@@ -37,6 +37,14 @@ export declare enum Role {
|
|
|
37
37
|
* @generated from enum value: ROLE_WALLET_ACCOUNT_VIEWER = 1000003;
|
|
38
38
|
*/
|
|
39
39
|
WALLET_ACCOUNT_VIEWER = 1000003,
|
|
40
|
+
/**
|
|
41
|
+
* @generated from enum value: ROLE_WALLET_TRANSFER_ADMIN = 1000004;
|
|
42
|
+
*/
|
|
43
|
+
WALLET_TRANSFER_ADMIN = 1000004,
|
|
44
|
+
/**
|
|
45
|
+
* @generated from enum value: ROLE_WALLET_TRANSFER_VIEWER = 1000005;
|
|
46
|
+
*/
|
|
47
|
+
WALLET_TRANSFER_VIEWER = 1000005,
|
|
40
48
|
/**
|
|
41
49
|
* @generated from enum value: ROLE_COMPLIANCE_ADMIN = 2000000;
|
|
42
50
|
*/
|
|
@@ -8,7 +8,7 @@ const codegenv2_1 = require("@bufbuild/protobuf/codegenv2");
|
|
|
8
8
|
/**
|
|
9
9
|
* Describes the file meshtrade/iam/role/v1/role.proto.
|
|
10
10
|
*/
|
|
11
|
-
exports.file_meshtrade_iam_role_v1_role = (0, codegenv2_1.fileDesc)("
|
|
11
|
+
exports.file_meshtrade_iam_role_v1_role = (0, codegenv2_1.fileDesc)("CiBtZXNodHJhZGUvaWFtL3JvbGUvdjEvcm9sZS5wcm90bxIVbWVzaHRyYWRlLmlhbS5yb2xlLnYxKq4KCgRSb2xlEhQKEFJPTEVfVU5TUEVDSUZJRUQQABIXChFST0xFX1dBTExFVF9BRE1JThDAhD0SGAoSUk9MRV9XQUxMRVRfVklFV0VSEMGEPRIfChlST0xFX1dBTExFVF9BQ0NPVU5UX0FETUlOEMKEPRIgChpST0xFX1dBTExFVF9BQ0NPVU5UX1ZJRVdFUhDDhD0SIAoaUk9MRV9XQUxMRVRfVFJBTlNGRVJfQURNSU4QxIQ9EiEKG1JPTEVfV0FMTEVUX1RSQU5TRkVSX1ZJRVdFUhDFhD0SGwoVUk9MRV9DT01QTElBTkNFX0FETUlOEICJehIcChZST0xFX0NPTVBMSUFOQ0VfVklFV0VSEIGJehIiChxST0xFX0NPTVBMSUFOQ0VfQ0xJRU5UX0FETUlOEIKJehIjCh1ST0xFX0NPTVBMSUFOQ0VfQ0xJRU5UX1ZJRVdFUhCDiXoSFQoOUk9MRV9JQU1fQURNSU4QwI23ARIWCg9ST0xFX0lBTV9WSUVXRVIQwY23ARIeChdST0xFX0lBTV9BUElfVVNFUl9BRE1JThDCjbcBEh8KGFJPTEVfSUFNX0FQSV9VU0VSX1ZJRVdFUhDDjbcBEhsKFFJPTEVfSUFNX0dST1VQX0FETUlOEMSNtwESHAoVUk9MRV9JQU1fR1JPVVBfVklFV0VSEMWNtwESGgoTUk9MRV9JQU1fVVNFUl9BRE1JThDGjbcBEhsKFFJPTEVfSUFNX1VTRVJfVklFV0VSEMeNtwESIgobUk9MRV9JQU1fVVNFUl9QUk9GSUxFX0FETUlOEMiNtwESIwocUk9MRV9JQU1fVVNFUl9QUk9GSUxFX1ZJRVdFUhDJjbcBEhgKEVJPTEVfU1RVRElPX0FETUlOEICS9AESGQoSUk9MRV9TVFVESU9fVklFV0VSEIGS9AESIwocUk9MRV9TVFVESU9fSU5TVFJVTUVOVF9BRE1JThCCkvQBEiQKHVJPTEVfU1RVRElPX0lOU1RSVU1FTlRfVklFV0VSEIOS9AESGQoSUk9MRV9UUkFESU5HX0FETUlOEMCWsQISGgoTUk9MRV9UUkFESU5HX1ZJRVdFUhDBlrECEiUKHlJPTEVfVFJBRElOR19MSU1JVF9PUkRFUl9BRE1JThDClrECEiYKH1JPTEVfVFJBRElOR19MSU1JVF9PUkRFUl9WSUVXRVIQw5axAhIbChRST0xFX1JFUE9SVElOR19BRE1JThCAm+4CEhwKFVJPTEVfUkVQT1JUSU5HX1ZJRVdFUhCBm+4CEhgKEVJPTEVfTEVER0VSX0FETUlOEMCfqwMSGQoSUk9MRV9MRURHRVJfVklFV0VSEMGfqwMSJAodUk9MRV9MRURHRVJfVFJBTlNBQ1RJT05fQURNSU4Qwp+rAxIlCh5ST0xFX0xFREdFUl9UUkFOU0FDVElPTl9WSUVXRVIQw5+rAxIdChZST0xFX01BUktFVF9EQVRBX0FETUlOEICk6AMSHgoXUk9MRV9NQVJLRVRfREFUQV9WSUVXRVIQgaToAxIjChxST0xFX01BUktFVF9EQVRBX1BSSUNFX0FETUlOEIKk6AMSJAodUk9MRV9NQVJLRVRfREFUQV9QUklDRV9WSUVXRVIQg6ToAxIqCiNST0xFX1RFU1RJTkdfTEVER0VSX1RPS0VOX1RBUF9BRE1JThDAqKUEEisKJFJPTEVfVEVTVElOR19MRURHRVJfVE9LRU5fVEFQX1ZJRVdFUhDBqKUEQk8KHGNvLm1lc2h0cmFkZS5hcGkuaWFtLnJvbGUudjFaL2dpdGh1Yi5jb20vbWVzaHRyYWRlL2FwaS9nby9pYW0vcm9sZS92MTtyb2xlX3YxYgZwcm90bzM");
|
|
12
12
|
/**
|
|
13
13
|
*
|
|
14
14
|
* Role defines a named collection of permissions.
|
|
@@ -44,6 +44,14 @@ var Role;
|
|
|
44
44
|
* @generated from enum value: ROLE_WALLET_ACCOUNT_VIEWER = 1000003;
|
|
45
45
|
*/
|
|
46
46
|
Role[Role["WALLET_ACCOUNT_VIEWER"] = 1000003] = "WALLET_ACCOUNT_VIEWER";
|
|
47
|
+
/**
|
|
48
|
+
* @generated from enum value: ROLE_WALLET_TRANSFER_ADMIN = 1000004;
|
|
49
|
+
*/
|
|
50
|
+
Role[Role["WALLET_TRANSFER_ADMIN"] = 1000004] = "WALLET_TRANSFER_ADMIN";
|
|
51
|
+
/**
|
|
52
|
+
* @generated from enum value: ROLE_WALLET_TRANSFER_VIEWER = 1000005;
|
|
53
|
+
*/
|
|
54
|
+
Role[Role["WALLET_TRANSFER_VIEWER"] = 1000005] = "WALLET_TRANSFER_VIEWER";
|
|
47
55
|
/**
|
|
48
56
|
* @generated from enum value: ROLE_COMPLIANCE_ADMIN = 2000000;
|
|
49
57
|
*/
|
|
@@ -0,0 +1,44 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
// ===================================================================
|
|
3
|
+
// AUTO-GENERATED SECTION - ONLY EDIT BELOW THE CLOSING COMMENT BLOCK
|
|
4
|
+
// ===================================================================
|
|
5
|
+
// This section is automatically managed by protoc-gen-meshts.
|
|
6
|
+
//
|
|
7
|
+
// DO NOT EDIT ANYTHING IN THIS SECTION MANUALLY!
|
|
8
|
+
// Your changes will be overwritten during code generation.
|
|
9
|
+
//
|
|
10
|
+
// To add custom exports, scroll down to the
|
|
11
|
+
// "MANUAL EXPORTS" section indicated below.
|
|
12
|
+
// ===================================================================
|
|
13
|
+
var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
|
|
14
|
+
if (k2 === undefined) k2 = k;
|
|
15
|
+
var desc = Object.getOwnPropertyDescriptor(m, k);
|
|
16
|
+
if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
|
|
17
|
+
desc = { enumerable: true, get: function() { return m[k]; } };
|
|
18
|
+
}
|
|
19
|
+
Object.defineProperty(o, k2, desc);
|
|
20
|
+
}) : (function(o, m, k, k2) {
|
|
21
|
+
if (k2 === undefined) k2 = k;
|
|
22
|
+
o[k2] = m[k];
|
|
23
|
+
}));
|
|
24
|
+
var __exportStar = (this && this.__exportStar) || function(m, exports) {
|
|
25
|
+
for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p);
|
|
26
|
+
};
|
|
27
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
28
|
+
// Generated exports
|
|
29
|
+
__exportStar(require("./service_pb"), exports);
|
|
30
|
+
__exportStar(require("./service_web_meshts"), exports);
|
|
31
|
+
__exportStar(require("./transfer_pb"), exports);
|
|
32
|
+
// ===================================================================
|
|
33
|
+
// END OF AUTO-GENERATED SECTION
|
|
34
|
+
// ===================================================================
|
|
35
|
+
//
|
|
36
|
+
// MANUAL EXPORTS - ADD YOUR CUSTOM EXPORTS BELOW
|
|
37
|
+
//
|
|
38
|
+
// You can safely add your own export statements in this section.
|
|
39
|
+
// They will be preserved across code generation.
|
|
40
|
+
//
|
|
41
|
+
// Example:
|
|
42
|
+
// export * from "./my_custom_module";
|
|
43
|
+
// export { MyCustomClass } from "./another_module";
|
|
44
|
+
// ===================================================================
|
|
@@ -0,0 +1,232 @@
|
|
|
1
|
+
import type { GenFile, GenMessage, GenService } from "@bufbuild/protobuf/codegenv2";
|
|
2
|
+
import type { SortingOrder } from "../../../type/v1/sorting_pb";
|
|
3
|
+
import type { Transfer, TransferSchema } from "./transfer_pb";
|
|
4
|
+
import type { Message } from "@bufbuild/protobuf";
|
|
5
|
+
/**
|
|
6
|
+
* Describes the file meshtrade/wallet/transfer/v1/service.proto.
|
|
7
|
+
*/
|
|
8
|
+
export declare const file_meshtrade_wallet_transfer_v1_service: GenFile;
|
|
9
|
+
/**
|
|
10
|
+
*
|
|
11
|
+
* Request to create a transfer.
|
|
12
|
+
*
|
|
13
|
+
* @generated from message meshtrade.wallet.transfer.v1.CreateTransferRequest
|
|
14
|
+
*/
|
|
15
|
+
export type CreateTransferRequest = Message<"meshtrade.wallet.transfer.v1.CreateTransferRequest"> & {
|
|
16
|
+
/**
|
|
17
|
+
*
|
|
18
|
+
* The transfer configuration for creation.
|
|
19
|
+
* The name, number, ledger_id, and owners fields will be ignored and assigned by the system.
|
|
20
|
+
*
|
|
21
|
+
* @generated from field: meshtrade.wallet.transfer.v1.Transfer transfer = 1;
|
|
22
|
+
*/
|
|
23
|
+
transfer?: Transfer;
|
|
24
|
+
};
|
|
25
|
+
/**
|
|
26
|
+
* Describes the message meshtrade.wallet.transfer.v1.CreateTransferRequest.
|
|
27
|
+
* Use `create(CreateTransferRequestSchema)` to create a new message.
|
|
28
|
+
*/
|
|
29
|
+
export declare const CreateTransferRequestSchema: GenMessage<CreateTransferRequest>;
|
|
30
|
+
/**
|
|
31
|
+
* @generated from message meshtrade.wallet.transfer.v1.GetTransferRequest
|
|
32
|
+
*/
|
|
33
|
+
export type GetTransferRequest = Message<"meshtrade.wallet.transfer.v1.GetTransferRequest"> & {
|
|
34
|
+
/**
|
|
35
|
+
*
|
|
36
|
+
* The resource name of the transfer to retrieve.
|
|
37
|
+
* Format: wallet/transfers/{ULIDv2}.
|
|
38
|
+
*
|
|
39
|
+
* @generated from field: string name = 1;
|
|
40
|
+
*/
|
|
41
|
+
name: string;
|
|
42
|
+
};
|
|
43
|
+
/**
|
|
44
|
+
* Describes the message meshtrade.wallet.transfer.v1.GetTransferRequest.
|
|
45
|
+
* Use `create(GetTransferRequestSchema)` to create a new message.
|
|
46
|
+
*/
|
|
47
|
+
export declare const GetTransferRequestSchema: GenMessage<GetTransferRequest>;
|
|
48
|
+
/**
|
|
49
|
+
* @generated from message meshtrade.wallet.transfer.v1.SearchTransfersByAddressRequest
|
|
50
|
+
*/
|
|
51
|
+
export type SearchTransfersByAddressRequest = Message<"meshtrade.wallet.transfer.v1.SearchTransfersByAddressRequest"> & {
|
|
52
|
+
/**
|
|
53
|
+
*
|
|
54
|
+
* The ledger address of the account
|
|
55
|
+
*
|
|
56
|
+
* @generated from field: string address = 1;
|
|
57
|
+
*/
|
|
58
|
+
address: string;
|
|
59
|
+
};
|
|
60
|
+
/**
|
|
61
|
+
* Describes the message meshtrade.wallet.transfer.v1.SearchTransfersByAddressRequest.
|
|
62
|
+
* Use `create(SearchTransfersByAddressRequestSchema)` to create a new message.
|
|
63
|
+
*/
|
|
64
|
+
export declare const SearchTransfersByAddressRequestSchema: GenMessage<SearchTransfersByAddressRequest>;
|
|
65
|
+
/**
|
|
66
|
+
* @generated from message meshtrade.wallet.transfer.v1.SearchTransfersByAddressResponse
|
|
67
|
+
*/
|
|
68
|
+
export type SearchTransfersByAddressResponse = Message<"meshtrade.wallet.transfer.v1.SearchTransfersByAddressResponse"> & {
|
|
69
|
+
/**
|
|
70
|
+
* @generated from field: repeated meshtrade.wallet.transfer.v1.Transfer transfers = 1;
|
|
71
|
+
*/
|
|
72
|
+
transfers: Transfer[];
|
|
73
|
+
};
|
|
74
|
+
/**
|
|
75
|
+
* Describes the message meshtrade.wallet.transfer.v1.SearchTransfersByAddressResponse.
|
|
76
|
+
* Use `create(SearchTransfersByAddressResponseSchema)` to create a new message.
|
|
77
|
+
*/
|
|
78
|
+
export declare const SearchTransfersByAddressResponseSchema: GenMessage<SearchTransfersByAddressResponse>;
|
|
79
|
+
/**
|
|
80
|
+
* @generated from message meshtrade.wallet.transfer.v1.ListTransfersRequest
|
|
81
|
+
*/
|
|
82
|
+
export type ListTransfersRequest = Message<"meshtrade.wallet.transfer.v1.ListTransfersRequest"> & {
|
|
83
|
+
/**
|
|
84
|
+
*
|
|
85
|
+
* Optional sorting configuration.
|
|
86
|
+
*
|
|
87
|
+
* @generated from field: meshtrade.wallet.transfer.v1.ListTransfersRequest.Sorting sorting = 1;
|
|
88
|
+
*/
|
|
89
|
+
sorting?: ListTransfersRequest_Sorting;
|
|
90
|
+
};
|
|
91
|
+
/**
|
|
92
|
+
* Describes the message meshtrade.wallet.transfer.v1.ListTransfersRequest.
|
|
93
|
+
* Use `create(ListTransfersRequestSchema)` to create a new message.
|
|
94
|
+
*/
|
|
95
|
+
export declare const ListTransfersRequestSchema: GenMessage<ListTransfersRequest>;
|
|
96
|
+
/**
|
|
97
|
+
*
|
|
98
|
+
* Sorting configuration for organizing results.
|
|
99
|
+
*
|
|
100
|
+
* @generated from message meshtrade.wallet.transfer.v1.ListTransfersRequest.Sorting
|
|
101
|
+
*/
|
|
102
|
+
export type ListTransfersRequest_Sorting = Message<"meshtrade.wallet.transfer.v1.ListTransfersRequest.Sorting"> & {
|
|
103
|
+
/**
|
|
104
|
+
*
|
|
105
|
+
* Field to sort by.
|
|
106
|
+
* Supported values: "number" or empty string for default ordering.
|
|
107
|
+
*
|
|
108
|
+
* @generated from field: string field = 1;
|
|
109
|
+
*/
|
|
110
|
+
field: string;
|
|
111
|
+
/**
|
|
112
|
+
*
|
|
113
|
+
* Sort order for results.
|
|
114
|
+
*
|
|
115
|
+
* @generated from field: meshtrade.type.v1.SortingOrder order = 2;
|
|
116
|
+
*/
|
|
117
|
+
order: SortingOrder;
|
|
118
|
+
};
|
|
119
|
+
/**
|
|
120
|
+
* Describes the message meshtrade.wallet.transfer.v1.ListTransfersRequest.Sorting.
|
|
121
|
+
* Use `create(ListTransfersRequest_SortingSchema)` to create a new message.
|
|
122
|
+
*/
|
|
123
|
+
export declare const ListTransfersRequest_SortingSchema: GenMessage<ListTransfersRequest_Sorting>;
|
|
124
|
+
/**
|
|
125
|
+
* @generated from message meshtrade.wallet.transfer.v1.ListTransfersResponse
|
|
126
|
+
*/
|
|
127
|
+
export type ListTransfersResponse = Message<"meshtrade.wallet.transfer.v1.ListTransfersResponse"> & {
|
|
128
|
+
/**
|
|
129
|
+
* @generated from field: repeated meshtrade.wallet.transfer.v1.Transfer transfers = 1;
|
|
130
|
+
*/
|
|
131
|
+
transfers: Transfer[];
|
|
132
|
+
};
|
|
133
|
+
/**
|
|
134
|
+
* Describes the message meshtrade.wallet.transfer.v1.ListTransfersResponse.
|
|
135
|
+
* Use `create(ListTransfersResponseSchema)` to create a new message.
|
|
136
|
+
*/
|
|
137
|
+
export declare const ListTransfersResponseSchema: GenMessage<ListTransfersResponse>;
|
|
138
|
+
/**
|
|
139
|
+
*
|
|
140
|
+
* Request to monitor a transfer.
|
|
141
|
+
*
|
|
142
|
+
* @generated from message meshtrade.wallet.transfer.v1.MonitorTransferRequest
|
|
143
|
+
*/
|
|
144
|
+
export type MonitorTransferRequest = Message<"meshtrade.wallet.transfer.v1.MonitorTransferRequest"> & {
|
|
145
|
+
/**
|
|
146
|
+
*
|
|
147
|
+
* The resource name of the transfer to monitor.
|
|
148
|
+
* Format: wallet/transfers/{ULIDv2}.
|
|
149
|
+
*
|
|
150
|
+
* @generated from field: string name = 1;
|
|
151
|
+
*/
|
|
152
|
+
name: string;
|
|
153
|
+
};
|
|
154
|
+
/**
|
|
155
|
+
* Describes the message meshtrade.wallet.transfer.v1.MonitorTransferRequest.
|
|
156
|
+
* Use `create(MonitorTransferRequestSchema)` to create a new message.
|
|
157
|
+
*/
|
|
158
|
+
export declare const MonitorTransferRequestSchema: GenMessage<MonitorTransferRequest>;
|
|
159
|
+
/**
|
|
160
|
+
*
|
|
161
|
+
* TransferService manages asset transfers.
|
|
162
|
+
*
|
|
163
|
+
* Service allows for the creation and retrieval of transfers. It can also be used
|
|
164
|
+
* to monitor transfers to react to state changes.
|
|
165
|
+
*
|
|
166
|
+
* @generated from service meshtrade.wallet.transfer.v1.TransferService
|
|
167
|
+
*/
|
|
168
|
+
export declare const TransferService: GenService<{
|
|
169
|
+
/**
|
|
170
|
+
*
|
|
171
|
+
* Transfer creates a transfer entity and executes a transfer on chain
|
|
172
|
+
*
|
|
173
|
+
* @generated from rpc meshtrade.wallet.transfer.v1.TransferService.CreateTransfer
|
|
174
|
+
*/
|
|
175
|
+
createTransfer: {
|
|
176
|
+
methodKind: "unary";
|
|
177
|
+
input: typeof CreateTransferRequestSchema;
|
|
178
|
+
output: typeof TransferSchema;
|
|
179
|
+
};
|
|
180
|
+
/**
|
|
181
|
+
*
|
|
182
|
+
* Retrieves a specific transfer by its resource identifier.
|
|
183
|
+
*
|
|
184
|
+
* @generated from rpc meshtrade.wallet.transfer.v1.TransferService.GetTransfer
|
|
185
|
+
*/
|
|
186
|
+
getTransfer: {
|
|
187
|
+
methodKind: "unary";
|
|
188
|
+
input: typeof GetTransferRequestSchema;
|
|
189
|
+
output: typeof TransferSchema;
|
|
190
|
+
};
|
|
191
|
+
/**
|
|
192
|
+
*
|
|
193
|
+
* Retrieves all transfers associated with a ledger account address.
|
|
194
|
+
*
|
|
195
|
+
* Finds all transfers where the given ledger account address was either in the to or from field.
|
|
196
|
+
*
|
|
197
|
+
* @generated from rpc meshtrade.wallet.transfer.v1.TransferService.SearchTransfersByAddress
|
|
198
|
+
*/
|
|
199
|
+
searchTransfersByAddress: {
|
|
200
|
+
methodKind: "unary";
|
|
201
|
+
input: typeof SearchTransfersByAddressRequestSchema;
|
|
202
|
+
output: typeof SearchTransfersByAddressResponseSchema;
|
|
203
|
+
};
|
|
204
|
+
/**
|
|
205
|
+
*
|
|
206
|
+
* Lists all transfers within the authenticated group's hierarchical scope.
|
|
207
|
+
*
|
|
208
|
+
* Returns the complete set of transfers accessible to the executing context,
|
|
209
|
+
* including transfers owned by the group and all descendant groups.
|
|
210
|
+
*
|
|
211
|
+
* @generated from rpc meshtrade.wallet.transfer.v1.TransferService.ListTransfers
|
|
212
|
+
*/
|
|
213
|
+
listTransfers: {
|
|
214
|
+
methodKind: "unary";
|
|
215
|
+
input: typeof ListTransfersRequestSchema;
|
|
216
|
+
output: typeof ListTransfersResponseSchema;
|
|
217
|
+
};
|
|
218
|
+
/**
|
|
219
|
+
*
|
|
220
|
+
* Monitors a transfer for real-time updates.
|
|
221
|
+
*
|
|
222
|
+
* Supports lookup by either resource name.
|
|
223
|
+
* Returns a stream of transfer states as they change.
|
|
224
|
+
*
|
|
225
|
+
* @generated from rpc meshtrade.wallet.transfer.v1.TransferService.MonitorTransfer
|
|
226
|
+
*/
|
|
227
|
+
monitorTransfer: {
|
|
228
|
+
methodKind: "server_streaming";
|
|
229
|
+
input: typeof MonitorTransferRequestSchema;
|
|
230
|
+
output: typeof TransferSchema;
|
|
231
|
+
};
|
|
232
|
+
}>;
|
|
@@ -0,0 +1,65 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
// @generated by protoc-gen-es v2.10.1 with parameter "target=ts"
|
|
3
|
+
// @generated from file meshtrade/wallet/transfer/v1/service.proto (package meshtrade.wallet.transfer.v1, syntax proto3)
|
|
4
|
+
/* eslint-disable */
|
|
5
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
6
|
+
exports.TransferService = exports.MonitorTransferRequestSchema = exports.ListTransfersResponseSchema = exports.ListTransfersRequest_SortingSchema = exports.ListTransfersRequestSchema = exports.SearchTransfersByAddressResponseSchema = exports.SearchTransfersByAddressRequestSchema = exports.GetTransferRequestSchema = exports.CreateTransferRequestSchema = exports.file_meshtrade_wallet_transfer_v1_service = void 0;
|
|
7
|
+
const codegenv2_1 = require("@bufbuild/protobuf/codegenv2");
|
|
8
|
+
const validate_pb_1 = require("../../../../buf/validate/validate_pb");
|
|
9
|
+
const method_options_pb_1 = require("../../../option/method_options/v1/method_options_pb");
|
|
10
|
+
const sorting_pb_1 = require("../../../type/v1/sorting_pb");
|
|
11
|
+
const transfer_pb_1 = require("./transfer_pb");
|
|
12
|
+
/**
|
|
13
|
+
* Describes the file meshtrade/wallet/transfer/v1/service.proto.
|
|
14
|
+
*/
|
|
15
|
+
exports.file_meshtrade_wallet_transfer_v1_service = (0, codegenv2_1.fileDesc)("CiptZXNodHJhZGUvd2FsbGV0L3RyYW5zZmVyL3YxL3NlcnZpY2UucHJvdG8SHG1lc2h0cmFkZS53YWxsZXQudHJhbnNmZXIudjEiWQoVQ3JlYXRlVHJhbnNmZXJSZXF1ZXN0EkAKCHRyYW5zZmVyGAEgASgLMiYubWVzaHRyYWRlLndhbGxldC50cmFuc2Zlci52MS5UcmFuc2ZlckIGukgDyAEBImcKEkdldFRyYW5zZmVyUmVxdWVzdBJRCgRuYW1lGAEgASgJQkO6SEByPjI5XndhbGxldC90cmFuc2ZlcnMvWzAxMjM0NTY3ODlBQkNERUZHSEpLTU5QUVJTVFZXWFlaXXsyNn0kmAEjIj8KH1NlYXJjaFRyYW5zZmVyc0J5QWRkcmVzc1JlcXVlc3QSHAoHYWRkcmVzcxgBIAEoCUILukgIyAEBcgMY/wEiXQogU2VhcmNoVHJhbnNmZXJzQnlBZGRyZXNzUmVzcG9uc2USOQoJdHJhbnNmZXJzGAEgAygLMiYubWVzaHRyYWRlLndhbGxldC50cmFuc2Zlci52MS5UcmFuc2ZlciKPAgoUTGlzdFRyYW5zZmVyc1JlcXVlc3QSSwoHc29ydGluZxgBIAEoCzI6Lm1lc2h0cmFkZS53YWxsZXQudHJhbnNmZXIudjEuTGlzdFRyYW5zZmVyc1JlcXVlc3QuU29ydGluZxqpAQoHU29ydGluZxJuCgVmaWVsZBgBIAEoCUJfukhcugFNCgtmaWVsZC52YWxpZBImZmllbGQgbXVzdCBiZSBvbmUgb2Y6IG51bWJlciwgb3IgZW1wdHkaFnRoaXMgaW4gWycnLCAnbnVtYmVyJ11yClIAUgZudW1iZXISLgoFb3JkZXIYAiABKA4yHy5tZXNodHJhZGUudHlwZS52MS5Tb3J0aW5nT3JkZXIiUgoVTGlzdFRyYW5zZmVyc1Jlc3BvbnNlEjkKCXRyYW5zZmVycxgBIAMoCzImLm1lc2h0cmFkZS53YWxsZXQudHJhbnNmZXIudjEuVHJhbnNmZXIiawoWTW9uaXRvclRyYW5zZmVyUmVxdWVzdBJRCgRuYW1lGAEgASgJQkO6SEByPjI5XndhbGxldC90cmFuc2ZlcnMvWzAxMjM0NTY3ODlBQkNERUZHSEpLTU5QUVJTVFZXWFlaXXsyNn0kmAEnMvIFCg9UcmFuc2ZlclNlcnZpY2USgQEKDkNyZWF0ZVRyYW5zZmVyEjMubWVzaHRyYWRlLndhbGxldC50cmFuc2Zlci52MS5DcmVhdGVUcmFuc2ZlclJlcXVlc3QaJi5tZXNodHJhZGUud2FsbGV0LnRyYW5zZmVyLnYxLlRyYW5zZmVyIhKytRgOCAIQAhoGwIQ9xIQ9IAESgQEKC0dldFRyYW5zZmVyEjAubWVzaHRyYWRlLndhbGxldC50cmFuc2Zlci52MS5HZXRUcmFuc2ZlclJlcXVlc3QaJi5tZXNodHJhZGUud2FsbGV0LnRyYW5zZmVyLnYxLlRyYW5zZmVyIhiytRgUCAEQAhoMwIQ9wYQ9xIQ9xYQ9IAESswEKGFNlYXJjaFRyYW5zZmVyc0J5QWRkcmVzcxI9Lm1lc2h0cmFkZS53YWxsZXQudHJhbnNmZXIudjEuU2VhcmNoVHJhbnNmZXJzQnlBZGRyZXNzUmVxdWVzdBo+Lm1lc2h0cmFkZS53YWxsZXQudHJhbnNmZXIudjEuU2VhcmNoVHJhbnNmZXJzQnlBZGRyZXNzUmVzcG9uc2UiGLK1GBQIARACGgzAhD3BhD3EhD3FhD0gARKSAQoNTGlzdFRyYW5zZmVycxIyLm1lc2h0cmFkZS53YWxsZXQudHJhbnNmZXIudjEuTGlzdFRyYW5zZmVyc1JlcXVlc3QaMy5tZXNodHJhZGUud2FsbGV0LnRyYW5zZmVyLnYxLkxpc3RUcmFuc2ZlcnNSZXNwb25zZSIYsrUYFAgBEAIaDMCEPcGEPcSEPcWEPSABEosBCg9Nb25pdG9yVHJhbnNmZXISNC5tZXNodHJhZGUud2FsbGV0LnRyYW5zZmVyLnYxLk1vbml0b3JUcmFuc2ZlclJlcXVlc3QaJi5tZXNodHJhZGUud2FsbGV0LnRyYW5zZmVyLnYxLlRyYW5zZmVyIhiytRgUCAEQAhoMwIQ9wYQ9xIQ9xYQ9IAEwAUJhCiNjby5tZXNodHJhZGUuYXBpLndhbGxldC50cmFuc2Zlci52MVo6Z2l0aHViLmNvbS9tZXNodHJhZGUvYXBpL2dvL3dhbGxldC90cmFuc2Zlci92MTt0cmFuc2Zlcl92MWIGcHJvdG8z", [validate_pb_1.file_buf_validate_validate, method_options_pb_1.file_meshtrade_option_method_options_v1_method_options, sorting_pb_1.file_meshtrade_type_v1_sorting, transfer_pb_1.file_meshtrade_wallet_transfer_v1_transfer]);
|
|
16
|
+
/**
|
|
17
|
+
* Describes the message meshtrade.wallet.transfer.v1.CreateTransferRequest.
|
|
18
|
+
* Use `create(CreateTransferRequestSchema)` to create a new message.
|
|
19
|
+
*/
|
|
20
|
+
exports.CreateTransferRequestSchema = (0, codegenv2_1.messageDesc)(exports.file_meshtrade_wallet_transfer_v1_service, 0);
|
|
21
|
+
/**
|
|
22
|
+
* Describes the message meshtrade.wallet.transfer.v1.GetTransferRequest.
|
|
23
|
+
* Use `create(GetTransferRequestSchema)` to create a new message.
|
|
24
|
+
*/
|
|
25
|
+
exports.GetTransferRequestSchema = (0, codegenv2_1.messageDesc)(exports.file_meshtrade_wallet_transfer_v1_service, 1);
|
|
26
|
+
/**
|
|
27
|
+
* Describes the message meshtrade.wallet.transfer.v1.SearchTransfersByAddressRequest.
|
|
28
|
+
* Use `create(SearchTransfersByAddressRequestSchema)` to create a new message.
|
|
29
|
+
*/
|
|
30
|
+
exports.SearchTransfersByAddressRequestSchema = (0, codegenv2_1.messageDesc)(exports.file_meshtrade_wallet_transfer_v1_service, 2);
|
|
31
|
+
/**
|
|
32
|
+
* Describes the message meshtrade.wallet.transfer.v1.SearchTransfersByAddressResponse.
|
|
33
|
+
* Use `create(SearchTransfersByAddressResponseSchema)` to create a new message.
|
|
34
|
+
*/
|
|
35
|
+
exports.SearchTransfersByAddressResponseSchema = (0, codegenv2_1.messageDesc)(exports.file_meshtrade_wallet_transfer_v1_service, 3);
|
|
36
|
+
/**
|
|
37
|
+
* Describes the message meshtrade.wallet.transfer.v1.ListTransfersRequest.
|
|
38
|
+
* Use `create(ListTransfersRequestSchema)` to create a new message.
|
|
39
|
+
*/
|
|
40
|
+
exports.ListTransfersRequestSchema = (0, codegenv2_1.messageDesc)(exports.file_meshtrade_wallet_transfer_v1_service, 4);
|
|
41
|
+
/**
|
|
42
|
+
* Describes the message meshtrade.wallet.transfer.v1.ListTransfersRequest.Sorting.
|
|
43
|
+
* Use `create(ListTransfersRequest_SortingSchema)` to create a new message.
|
|
44
|
+
*/
|
|
45
|
+
exports.ListTransfersRequest_SortingSchema = (0, codegenv2_1.messageDesc)(exports.file_meshtrade_wallet_transfer_v1_service, 4, 0);
|
|
46
|
+
/**
|
|
47
|
+
* Describes the message meshtrade.wallet.transfer.v1.ListTransfersResponse.
|
|
48
|
+
* Use `create(ListTransfersResponseSchema)` to create a new message.
|
|
49
|
+
*/
|
|
50
|
+
exports.ListTransfersResponseSchema = (0, codegenv2_1.messageDesc)(exports.file_meshtrade_wallet_transfer_v1_service, 5);
|
|
51
|
+
/**
|
|
52
|
+
* Describes the message meshtrade.wallet.transfer.v1.MonitorTransferRequest.
|
|
53
|
+
* Use `create(MonitorTransferRequestSchema)` to create a new message.
|
|
54
|
+
*/
|
|
55
|
+
exports.MonitorTransferRequestSchema = (0, codegenv2_1.messageDesc)(exports.file_meshtrade_wallet_transfer_v1_service, 6);
|
|
56
|
+
/**
|
|
57
|
+
*
|
|
58
|
+
* TransferService manages asset transfers.
|
|
59
|
+
*
|
|
60
|
+
* Service allows for the creation and retrieval of transfers. It can also be used
|
|
61
|
+
* to monitor transfers to react to state changes.
|
|
62
|
+
*
|
|
63
|
+
* @generated from service meshtrade.wallet.transfer.v1.TransferService
|
|
64
|
+
*/
|
|
65
|
+
exports.TransferService = (0, codegenv2_1.serviceDesc)(exports.file_meshtrade_wallet_transfer_v1_service, 0);
|
|
@@ -0,0 +1,124 @@
|
|
|
1
|
+
import { CreateTransferRequest, GetTransferRequest, ListTransfersRequest, ListTransfersResponse, MonitorTransferRequest, SearchTransfersByAddressRequest, SearchTransfersByAddressResponse } from "./service_pb";
|
|
2
|
+
import { Transfer } from "./transfer_pb";
|
|
3
|
+
import { ClientOption } from "../../../config";
|
|
4
|
+
/**
|
|
5
|
+
* Web client for interacting with the meshtrade.wallet.transfer.v1 transfer v1 API resource service.
|
|
6
|
+
* Uses Connect-ES with gRPC-Web transport for browser-based communication.
|
|
7
|
+
*
|
|
8
|
+
* Supports flexible authentication modes using functional options pattern:
|
|
9
|
+
*
|
|
10
|
+
* 1. **No Authentication** (public APIs):
|
|
11
|
+
* ```typescript
|
|
12
|
+
* const client = new TransferServiceWeb(
|
|
13
|
+
* WithServerUrl("http://localhost:10000")
|
|
14
|
+
* );
|
|
15
|
+
* ```
|
|
16
|
+
*
|
|
17
|
+
* 2. **API Key Authentication** (backend services):
|
|
18
|
+
* ```typescript
|
|
19
|
+
* const client = new TransferServiceWeb(
|
|
20
|
+
* WithAPIKey("your-api-key"),
|
|
21
|
+
* WithGroup("groups/01ARZ3NDEKTSV4YWVF8F5BH32"),
|
|
22
|
+
* WithServerUrl("https://api.example.com")
|
|
23
|
+
* );
|
|
24
|
+
* ```
|
|
25
|
+
*
|
|
26
|
+
* 3. **JWT Token Authentication** (Next.js frontend with user session):
|
|
27
|
+
* ```typescript
|
|
28
|
+
* const client = new TransferServiceWeb(
|
|
29
|
+
* WithJWTAccessToken("eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9..."),
|
|
30
|
+
* WithServerUrl("https://api.example.com")
|
|
31
|
+
* );
|
|
32
|
+
* ```
|
|
33
|
+
*
|
|
34
|
+
* 4. **JWT with Group Context** (user session with specific group):
|
|
35
|
+
* ```typescript
|
|
36
|
+
* const client = new TransferServiceWeb(
|
|
37
|
+
* WithJWTAccessToken("eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9..."),
|
|
38
|
+
* WithGroup("groups/01ARZ3NDEKTSV4YWVF8F5BH32"),
|
|
39
|
+
* WithServerUrl("https://api.example.com")
|
|
40
|
+
* );
|
|
41
|
+
* ```
|
|
42
|
+
*
|
|
43
|
+
* Available options:
|
|
44
|
+
* - `WithAPIKey(key)` - API key authentication (mutually exclusive with JWT)
|
|
45
|
+
* - `WithJWTAccessToken(token)` - JWT authentication (mutually exclusive with API key)
|
|
46
|
+
* - `WithGroup(group)` - Group context (optional, works with both auth modes)
|
|
47
|
+
* - `WithServerUrl(url)` - Custom server URL (optional, defaults to production)
|
|
48
|
+
*/
|
|
49
|
+
export declare class TransferServiceWeb {
|
|
50
|
+
private _client;
|
|
51
|
+
private readonly _config;
|
|
52
|
+
private readonly _interceptors;
|
|
53
|
+
private readonly _validator;
|
|
54
|
+
/**
|
|
55
|
+
* Constructs an instance of TransferServiceWeb.
|
|
56
|
+
*
|
|
57
|
+
* Uses functional options pattern for flexible configuration:
|
|
58
|
+
* - `WithAPIKey(key)` - API key authentication
|
|
59
|
+
* - `WithJWTAccessToken(token)` - JWT authentication
|
|
60
|
+
* - `WithGroup(group)` - Group context (optional)
|
|
61
|
+
* - `WithServerUrl(url)` - Custom server URL (optional)
|
|
62
|
+
*
|
|
63
|
+
* @param {...ClientOption} opts - Variable number of configuration options
|
|
64
|
+
*/
|
|
65
|
+
constructor(...opts: ClientOption[]);
|
|
66
|
+
/**
|
|
67
|
+
* Returns a new client instance configured to send the specified group
|
|
68
|
+
* resource name in the request headers for subsequent API calls.
|
|
69
|
+
*
|
|
70
|
+
* This method creates a new client with the same authentication configuration
|
|
71
|
+
* but with the group context updated to the specified value.
|
|
72
|
+
*
|
|
73
|
+
* **Compatibility**: Works with all authentication modes:
|
|
74
|
+
* - **API key auth**: Creates new client with API key + new group
|
|
75
|
+
* - **JWT auth**: Creates new client with JWT + new group
|
|
76
|
+
* - **No auth**: Creates new client with standalone group interceptor
|
|
77
|
+
*
|
|
78
|
+
* @param {string} group - The operating group context to inject into the request
|
|
79
|
+
* in the format `groups/{ulid}` where {ulid} is a 26-character ULID.
|
|
80
|
+
* Example: 'groups/01ARZ3NDEKTSV4YWVF8F5BH32'
|
|
81
|
+
* @returns {TransferServiceWeb} A new, configured instance of the client.
|
|
82
|
+
* @throws {Error} If the group format is invalid
|
|
83
|
+
*/
|
|
84
|
+
withGroup(group: string): TransferServiceWeb;
|
|
85
|
+
/**
|
|
86
|
+
* Creates a new transfer.
|
|
87
|
+
* @param {CreateTransferRequest} request - The request object for createtransfer.
|
|
88
|
+
* @returns {Promise<Transfer>} A promise that resolves with the transfer.
|
|
89
|
+
*/
|
|
90
|
+
createTransfer(request: CreateTransferRequest): Promise<Transfer>;
|
|
91
|
+
/**
|
|
92
|
+
* Retrieves a transfer.
|
|
93
|
+
* @param {GetTransferRequest} request - The request object for gettransfer.
|
|
94
|
+
* @returns {Promise<Transfer>} A promise that resolves with the transfer.
|
|
95
|
+
*/
|
|
96
|
+
getTransfer(request: GetTransferRequest): Promise<Transfer>;
|
|
97
|
+
/**
|
|
98
|
+
* Searches for transfers.
|
|
99
|
+
* @param {SearchTransfersByAddressRequest} request - The request object for searchtransfersbyaddress.
|
|
100
|
+
* @returns {Promise<SearchTransfersByAddressResponse>} A promise that resolves with the search results.
|
|
101
|
+
*/
|
|
102
|
+
searchTransfersByAddress(request: SearchTransfersByAddressRequest): Promise<SearchTransfersByAddressResponse>;
|
|
103
|
+
/**
|
|
104
|
+
* Retrieves a list of transfers.
|
|
105
|
+
* @param {ListTransfersRequest} request - The request object for listtransfers.
|
|
106
|
+
* @returns {Promise<ListTransfersResponse>} A promise that resolves with the list of transfers.
|
|
107
|
+
*/
|
|
108
|
+
listTransfers(request: ListTransfersRequest): Promise<ListTransfersResponse>;
|
|
109
|
+
/**
|
|
110
|
+
* Performs monitortransfer operation on transfer.
|
|
111
|
+
* Server-side streaming method with client-side validation and authentication.
|
|
112
|
+
* @param {MonitorTransferRequest} request - The request object for monitortransfer.
|
|
113
|
+
* @returns {AsyncIterable<Transfer>} An async iterable of Transfer messages.
|
|
114
|
+
* @throws {Error} If request validation fails.
|
|
115
|
+
*
|
|
116
|
+
* @example
|
|
117
|
+
* const stream = client.monitorTransfer(request);
|
|
118
|
+
* for await (const response of stream) {
|
|
119
|
+
* // Process each response
|
|
120
|
+
* console.log(response);
|
|
121
|
+
* }
|
|
122
|
+
*/
|
|
123
|
+
monitorTransfer(request: MonitorTransferRequest): AsyncIterable<Transfer>;
|
|
124
|
+
}
|
|
@@ -0,0 +1,228 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
// Code generated by protoc-gen-meshts. DO NOT EDIT.
|
|
3
|
+
// @generated by protoc-gen-meshts v1
|
|
4
|
+
// @generated from file meshtrade/wallet/transfer/v1/service.proto (package meshtrade.wallet.transfer.v1, syntax proto3)
|
|
5
|
+
/* eslint-disable */
|
|
6
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
7
|
+
exports.TransferServiceWeb = void 0;
|
|
8
|
+
const connect_1 = require("@connectrpc/connect");
|
|
9
|
+
const connect_web_1 = require("@connectrpc/connect-web");
|
|
10
|
+
const service_pb_1 = require("./service_pb");
|
|
11
|
+
const service_pb_2 = require("./service_pb");
|
|
12
|
+
const config_1 = require("../../../config");
|
|
13
|
+
const protovalidate_1 = require("@bufbuild/protovalidate");
|
|
14
|
+
const interceptors_1 = require("../../../interceptors");
|
|
15
|
+
/**
|
|
16
|
+
* Web client for interacting with the meshtrade.wallet.transfer.v1 transfer v1 API resource service.
|
|
17
|
+
* Uses Connect-ES with gRPC-Web transport for browser-based communication.
|
|
18
|
+
*
|
|
19
|
+
* Supports flexible authentication modes using functional options pattern:
|
|
20
|
+
*
|
|
21
|
+
* 1. **No Authentication** (public APIs):
|
|
22
|
+
* ```typescript
|
|
23
|
+
* const client = new TransferServiceWeb(
|
|
24
|
+
* WithServerUrl("http://localhost:10000")
|
|
25
|
+
* );
|
|
26
|
+
* ```
|
|
27
|
+
*
|
|
28
|
+
* 2. **API Key Authentication** (backend services):
|
|
29
|
+
* ```typescript
|
|
30
|
+
* const client = new TransferServiceWeb(
|
|
31
|
+
* WithAPIKey("your-api-key"),
|
|
32
|
+
* WithGroup("groups/01ARZ3NDEKTSV4YWVF8F5BH32"),
|
|
33
|
+
* WithServerUrl("https://api.example.com")
|
|
34
|
+
* );
|
|
35
|
+
* ```
|
|
36
|
+
*
|
|
37
|
+
* 3. **JWT Token Authentication** (Next.js frontend with user session):
|
|
38
|
+
* ```typescript
|
|
39
|
+
* const client = new TransferServiceWeb(
|
|
40
|
+
* WithJWTAccessToken("eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9..."),
|
|
41
|
+
* WithServerUrl("https://api.example.com")
|
|
42
|
+
* );
|
|
43
|
+
* ```
|
|
44
|
+
*
|
|
45
|
+
* 4. **JWT with Group Context** (user session with specific group):
|
|
46
|
+
* ```typescript
|
|
47
|
+
* const client = new TransferServiceWeb(
|
|
48
|
+
* WithJWTAccessToken("eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9..."),
|
|
49
|
+
* WithGroup("groups/01ARZ3NDEKTSV4YWVF8F5BH32"),
|
|
50
|
+
* WithServerUrl("https://api.example.com")
|
|
51
|
+
* );
|
|
52
|
+
* ```
|
|
53
|
+
*
|
|
54
|
+
* Available options:
|
|
55
|
+
* - `WithAPIKey(key)` - API key authentication (mutually exclusive with JWT)
|
|
56
|
+
* - `WithJWTAccessToken(token)` - JWT authentication (mutually exclusive with API key)
|
|
57
|
+
* - `WithGroup(group)` - Group context (optional, works with both auth modes)
|
|
58
|
+
* - `WithServerUrl(url)` - Custom server URL (optional, defaults to production)
|
|
59
|
+
*/
|
|
60
|
+
class TransferServiceWeb {
|
|
61
|
+
/**
|
|
62
|
+
* Constructs an instance of TransferServiceWeb.
|
|
63
|
+
*
|
|
64
|
+
* Uses functional options pattern for flexible configuration:
|
|
65
|
+
* - `WithAPIKey(key)` - API key authentication
|
|
66
|
+
* - `WithJWTAccessToken(token)` - JWT authentication
|
|
67
|
+
* - `WithGroup(group)` - Group context (optional)
|
|
68
|
+
* - `WithServerUrl(url)` - Custom server URL (optional)
|
|
69
|
+
*
|
|
70
|
+
* @param {...ClientOption} opts - Variable number of configuration options
|
|
71
|
+
*/
|
|
72
|
+
constructor(...opts) {
|
|
73
|
+
// Build configuration from options
|
|
74
|
+
this._config = (0, config_1.buildConfigFromOptions)(...opts);
|
|
75
|
+
// Initialize validator for request validation
|
|
76
|
+
this._validator = (0, protovalidate_1.createValidator)();
|
|
77
|
+
this._interceptors = [];
|
|
78
|
+
this._interceptors.push((0, interceptors_1.createLoggingInterceptor)());
|
|
79
|
+
if (this._config.apiKey) {
|
|
80
|
+
this._interceptors.push((0, interceptors_1.createApiKeyInterceptor)(this._config.apiKey));
|
|
81
|
+
}
|
|
82
|
+
if (this._config.jwtToken) {
|
|
83
|
+
this._interceptors.push((0, interceptors_1.createJwtInterceptor)(this._config.jwtToken));
|
|
84
|
+
}
|
|
85
|
+
if (this._config.group) {
|
|
86
|
+
this._interceptors.push((0, interceptors_1.createGroupInterceptor)(this._config.group));
|
|
87
|
+
}
|
|
88
|
+
// Create the gRPC-Web transport for browser with interceptors
|
|
89
|
+
// Custom fetch wrapper to include credentials for cookie-based authentication
|
|
90
|
+
const transport = (0, connect_web_1.createGrpcWebTransport)({
|
|
91
|
+
baseUrl: this._config.apiServerURL,
|
|
92
|
+
interceptors: this._interceptors,
|
|
93
|
+
fetch: (input, init) => fetch(input, { ...init, credentials: "include" }),
|
|
94
|
+
});
|
|
95
|
+
// Construct the Connect-ES client
|
|
96
|
+
this._client = (0, connect_1.createClient)(service_pb_1.TransferService, transport);
|
|
97
|
+
}
|
|
98
|
+
/**
|
|
99
|
+
* Returns a new client instance configured to send the specified group
|
|
100
|
+
* resource name in the request headers for subsequent API calls.
|
|
101
|
+
*
|
|
102
|
+
* This method creates a new client with the same authentication configuration
|
|
103
|
+
* but with the group context updated to the specified value.
|
|
104
|
+
*
|
|
105
|
+
* **Compatibility**: Works with all authentication modes:
|
|
106
|
+
* - **API key auth**: Creates new client with API key + new group
|
|
107
|
+
* - **JWT auth**: Creates new client with JWT + new group
|
|
108
|
+
* - **No auth**: Creates new client with standalone group interceptor
|
|
109
|
+
*
|
|
110
|
+
* @param {string} group - The operating group context to inject into the request
|
|
111
|
+
* in the format `groups/{ulid}` where {ulid} is a 26-character ULID.
|
|
112
|
+
* Example: 'groups/01ARZ3NDEKTSV4YWVF8F5BH32'
|
|
113
|
+
* @returns {TransferServiceWeb} A new, configured instance of the client.
|
|
114
|
+
* @throws {Error} If the group format is invalid
|
|
115
|
+
*/
|
|
116
|
+
withGroup(group) {
|
|
117
|
+
// Build new options array with existing auth and updated group
|
|
118
|
+
const newOpts = [];
|
|
119
|
+
// Add server URL
|
|
120
|
+
newOpts.push((0, config_1.WithServerUrl)(this._config.apiServerURL));
|
|
121
|
+
// Add authentication (preserve existing mode)
|
|
122
|
+
if (this._config.apiKey) {
|
|
123
|
+
newOpts.push((0, config_1.WithAPIKey)(this._config.apiKey));
|
|
124
|
+
}
|
|
125
|
+
else if (this._config.jwtToken) {
|
|
126
|
+
newOpts.push((0, config_1.WithJWTAccessToken)(this._config.jwtToken));
|
|
127
|
+
}
|
|
128
|
+
// Add the new group
|
|
129
|
+
newOpts.push((0, config_1.WithGroup)(group));
|
|
130
|
+
// Return a new client instance with updated configuration
|
|
131
|
+
return new TransferServiceWeb(...newOpts);
|
|
132
|
+
}
|
|
133
|
+
/**
|
|
134
|
+
* Creates a new transfer.
|
|
135
|
+
* @param {CreateTransferRequest} request - The request object for createtransfer.
|
|
136
|
+
* @returns {Promise<Transfer>} A promise that resolves with the transfer.
|
|
137
|
+
*/
|
|
138
|
+
createTransfer(request) {
|
|
139
|
+
// Validate request
|
|
140
|
+
const result = this._validator.validate(service_pb_2.CreateTransferRequestSchema, request);
|
|
141
|
+
if (result.kind === "invalid") {
|
|
142
|
+
const violations = result.violations.map(v => `${v.field.toString()}: ${v.message}`).join("; ");
|
|
143
|
+
throw new Error(`Validation failed: ${violations}`);
|
|
144
|
+
}
|
|
145
|
+
else if (result.kind === "error") {
|
|
146
|
+
throw result.error;
|
|
147
|
+
}
|
|
148
|
+
return this._client.createTransfer(request);
|
|
149
|
+
}
|
|
150
|
+
/**
|
|
151
|
+
* Retrieves a transfer.
|
|
152
|
+
* @param {GetTransferRequest} request - The request object for gettransfer.
|
|
153
|
+
* @returns {Promise<Transfer>} A promise that resolves with the transfer.
|
|
154
|
+
*/
|
|
155
|
+
getTransfer(request) {
|
|
156
|
+
// Validate request
|
|
157
|
+
const result = this._validator.validate(service_pb_2.GetTransferRequestSchema, request);
|
|
158
|
+
if (result.kind === "invalid") {
|
|
159
|
+
const violations = result.violations.map(v => `${v.field.toString()}: ${v.message}`).join("; ");
|
|
160
|
+
throw new Error(`Validation failed: ${violations}`);
|
|
161
|
+
}
|
|
162
|
+
else if (result.kind === "error") {
|
|
163
|
+
throw result.error;
|
|
164
|
+
}
|
|
165
|
+
return this._client.getTransfer(request);
|
|
166
|
+
}
|
|
167
|
+
/**
|
|
168
|
+
* Searches for transfers.
|
|
169
|
+
* @param {SearchTransfersByAddressRequest} request - The request object for searchtransfersbyaddress.
|
|
170
|
+
* @returns {Promise<SearchTransfersByAddressResponse>} A promise that resolves with the search results.
|
|
171
|
+
*/
|
|
172
|
+
searchTransfersByAddress(request) {
|
|
173
|
+
// Validate request
|
|
174
|
+
const result = this._validator.validate(service_pb_2.SearchTransfersByAddressRequestSchema, request);
|
|
175
|
+
if (result.kind === "invalid") {
|
|
176
|
+
const violations = result.violations.map(v => `${v.field.toString()}: ${v.message}`).join("; ");
|
|
177
|
+
throw new Error(`Validation failed: ${violations}`);
|
|
178
|
+
}
|
|
179
|
+
else if (result.kind === "error") {
|
|
180
|
+
throw result.error;
|
|
181
|
+
}
|
|
182
|
+
return this._client.searchTransfersByAddress(request);
|
|
183
|
+
}
|
|
184
|
+
/**
|
|
185
|
+
* Retrieves a list of transfers.
|
|
186
|
+
* @param {ListTransfersRequest} request - The request object for listtransfers.
|
|
187
|
+
* @returns {Promise<ListTransfersResponse>} A promise that resolves with the list of transfers.
|
|
188
|
+
*/
|
|
189
|
+
listTransfers(request) {
|
|
190
|
+
// Validate request
|
|
191
|
+
const result = this._validator.validate(service_pb_2.ListTransfersRequestSchema, request);
|
|
192
|
+
if (result.kind === "invalid") {
|
|
193
|
+
const violations = result.violations.map(v => `${v.field.toString()}: ${v.message}`).join("; ");
|
|
194
|
+
throw new Error(`Validation failed: ${violations}`);
|
|
195
|
+
}
|
|
196
|
+
else if (result.kind === "error") {
|
|
197
|
+
throw result.error;
|
|
198
|
+
}
|
|
199
|
+
return this._client.listTransfers(request);
|
|
200
|
+
}
|
|
201
|
+
/**
|
|
202
|
+
* Performs monitortransfer operation on transfer.
|
|
203
|
+
* Server-side streaming method with client-side validation and authentication.
|
|
204
|
+
* @param {MonitorTransferRequest} request - The request object for monitortransfer.
|
|
205
|
+
* @returns {AsyncIterable<Transfer>} An async iterable of Transfer messages.
|
|
206
|
+
* @throws {Error} If request validation fails.
|
|
207
|
+
*
|
|
208
|
+
* @example
|
|
209
|
+
* const stream = client.monitorTransfer(request);
|
|
210
|
+
* for await (const response of stream) {
|
|
211
|
+
* // Process each response
|
|
212
|
+
* console.log(response);
|
|
213
|
+
* }
|
|
214
|
+
*/
|
|
215
|
+
monitorTransfer(request) {
|
|
216
|
+
// Validate request before initiating stream
|
|
217
|
+
const result = this._validator.validate(service_pb_2.MonitorTransferRequestSchema, request);
|
|
218
|
+
if (result.kind === "invalid") {
|
|
219
|
+
const violations = result.violations.map(v => `${v.field.toString()}: ${v.message}`).join("; ");
|
|
220
|
+
throw new Error(`Validation failed: ${violations}`);
|
|
221
|
+
}
|
|
222
|
+
else if (result.kind === "error") {
|
|
223
|
+
throw result.error;
|
|
224
|
+
}
|
|
225
|
+
return this._client.monitorTransfer(request);
|
|
226
|
+
}
|
|
227
|
+
}
|
|
228
|
+
exports.TransferServiceWeb = TransferServiceWeb;
|
|
@@ -0,0 +1,187 @@
|
|
|
1
|
+
import type { GenEnum, GenFile, GenMessage } from "@bufbuild/protobuf/codegenv2";
|
|
2
|
+
import type { Amount } from "../../../type/v1/amount_pb";
|
|
3
|
+
import type { Decimal } from "../../../type/v1/decimal_pb";
|
|
4
|
+
import type { Message } from "@bufbuild/protobuf";
|
|
5
|
+
/**
|
|
6
|
+
* Describes the file meshtrade/wallet/transfer/v1/transfer.proto.
|
|
7
|
+
*/
|
|
8
|
+
export declare const file_meshtrade_wallet_transfer_v1_transfer: GenFile;
|
|
9
|
+
/**
|
|
10
|
+
*
|
|
11
|
+
* Transfer resource for transferring assets between accounts.
|
|
12
|
+
*
|
|
13
|
+
* Transfers can be used to move assets between accounts, a transfer can currently only be done between two accounts on the SAME ledger.
|
|
14
|
+
*
|
|
15
|
+
* @generated from message meshtrade.wallet.transfer.v1.Transfer
|
|
16
|
+
*/
|
|
17
|
+
export type Transfer = Message<"meshtrade.wallet.transfer.v1.Transfer"> & {
|
|
18
|
+
/**
|
|
19
|
+
*
|
|
20
|
+
* The unique resource name for the transfer.
|
|
21
|
+
* Format: wallet/transfers/{ULIDv2}.
|
|
22
|
+
* This field is system-generated and immutable upon creation.
|
|
23
|
+
* Any value provided on creation is ignored.
|
|
24
|
+
*
|
|
25
|
+
* @generated from field: string name = 1;
|
|
26
|
+
*/
|
|
27
|
+
name: string;
|
|
28
|
+
/**
|
|
29
|
+
*
|
|
30
|
+
* The resource name of the parent group that owns this transfer.
|
|
31
|
+
* This field is required on creation and establishes the direct ownership link.
|
|
32
|
+
* Format: groups/{ULIDv2}.
|
|
33
|
+
*
|
|
34
|
+
* @generated from field: string owner = 2;
|
|
35
|
+
*/
|
|
36
|
+
owner: string;
|
|
37
|
+
/**
|
|
38
|
+
*
|
|
39
|
+
* Ownership hiearchy of groups that have access to this resource in the format groups/{group_id}.
|
|
40
|
+
* System set on creation.
|
|
41
|
+
*
|
|
42
|
+
* @generated from field: repeated string owners = 3;
|
|
43
|
+
*/
|
|
44
|
+
owners: string[];
|
|
45
|
+
/**
|
|
46
|
+
*
|
|
47
|
+
* Number is a monotonically increasing number for the transfer and serves as a human readable identifier for the entity
|
|
48
|
+
* This is system generated and immutable.
|
|
49
|
+
*
|
|
50
|
+
* @generated from field: string number = 4;
|
|
51
|
+
*/
|
|
52
|
+
number: string;
|
|
53
|
+
/**
|
|
54
|
+
*
|
|
55
|
+
* The account's ledger address on the relevant ledger.
|
|
56
|
+
* Format varies by ledger e.g. Ed25519 public key for Stellar/Solana,
|
|
57
|
+
* secp256k1 address for Bitcoin/Ethereum.
|
|
58
|
+
* The format is used to determine which ledger the transfer will be performed on.
|
|
59
|
+
* Needs to have same format as the to adress field.
|
|
60
|
+
*
|
|
61
|
+
* @generated from field: string from = 5;
|
|
62
|
+
*/
|
|
63
|
+
from: string;
|
|
64
|
+
/**
|
|
65
|
+
*
|
|
66
|
+
* The account's ledger address on the relevant ledger.
|
|
67
|
+
* Format varies by ledger e.g. Ed25519 public key for Stellar/Solana,
|
|
68
|
+
* secp256k1 address for Bitcoin/Ethereum.
|
|
69
|
+
* The format is used to determine which ledger the transfer will be performed on.
|
|
70
|
+
* Needs to have same format as the to adress field.
|
|
71
|
+
*
|
|
72
|
+
* @generated from field: string to = 6;
|
|
73
|
+
*/
|
|
74
|
+
to: string;
|
|
75
|
+
/**
|
|
76
|
+
*
|
|
77
|
+
* Amount of asset being transferred
|
|
78
|
+
*
|
|
79
|
+
* @generated from field: meshtrade.type.v1.Amount amount = 7;
|
|
80
|
+
*/
|
|
81
|
+
amount?: Amount;
|
|
82
|
+
/**
|
|
83
|
+
*
|
|
84
|
+
* Corresponding ledger transaction resource name for the transaction that performed the transfer.
|
|
85
|
+
* Can be used to determine the state of the transfer.
|
|
86
|
+
*
|
|
87
|
+
* @generated from field: string transaction = 8;
|
|
88
|
+
*/
|
|
89
|
+
transaction: string;
|
|
90
|
+
/**
|
|
91
|
+
*
|
|
92
|
+
* Calculated fee that was charged for the transfer.
|
|
93
|
+
* This is set by the system when the transfer is created.
|
|
94
|
+
*
|
|
95
|
+
* @generated from field: meshtrade.wallet.transfer.v1.TransferFee fee = 9;
|
|
96
|
+
*/
|
|
97
|
+
fee?: TransferFee;
|
|
98
|
+
/**
|
|
99
|
+
*
|
|
100
|
+
* State of the transfer
|
|
101
|
+
*
|
|
102
|
+
* @generated from field: meshtrade.wallet.transfer.v1.TransferState state = 10;
|
|
103
|
+
*/
|
|
104
|
+
state: TransferState;
|
|
105
|
+
/**
|
|
106
|
+
*
|
|
107
|
+
* Optional description to describe the reason of the transfer
|
|
108
|
+
*
|
|
109
|
+
* @generated from field: string description = 11;
|
|
110
|
+
*/
|
|
111
|
+
description: string;
|
|
112
|
+
/**
|
|
113
|
+
*
|
|
114
|
+
* Flag to indicate if description should be included in ledger and thus publically visible
|
|
115
|
+
*
|
|
116
|
+
* @generated from field: bool include_in_ledger = 12;
|
|
117
|
+
*/
|
|
118
|
+
includeInLedger: boolean;
|
|
119
|
+
};
|
|
120
|
+
/**
|
|
121
|
+
* Describes the message meshtrade.wallet.transfer.v1.Transfer.
|
|
122
|
+
* Use `create(TransferSchema)` to create a new message.
|
|
123
|
+
*/
|
|
124
|
+
export declare const TransferSchema: GenMessage<Transfer>;
|
|
125
|
+
/**
|
|
126
|
+
*
|
|
127
|
+
* TransferFee describes the calculated fee for the asset transfer
|
|
128
|
+
*
|
|
129
|
+
* @generated from message meshtrade.wallet.transfer.v1.TransferFee
|
|
130
|
+
*/
|
|
131
|
+
export type TransferFee = Message<"meshtrade.wallet.transfer.v1.TransferFee"> & {
|
|
132
|
+
/**
|
|
133
|
+
*
|
|
134
|
+
* Calculated fee on the transfer
|
|
135
|
+
*
|
|
136
|
+
* @generated from field: meshtrade.type.v1.Amount amount = 1;
|
|
137
|
+
*/
|
|
138
|
+
amount?: Amount;
|
|
139
|
+
/**
|
|
140
|
+
*
|
|
141
|
+
* VAT rate used for fee calculation
|
|
142
|
+
*
|
|
143
|
+
* @generated from field: meshtrade.type.v1.Decimal vat_rate = 2;
|
|
144
|
+
*/
|
|
145
|
+
vatRate?: Decimal;
|
|
146
|
+
};
|
|
147
|
+
/**
|
|
148
|
+
* Describes the message meshtrade.wallet.transfer.v1.TransferFee.
|
|
149
|
+
* Use `create(TransferFeeSchema)` to create a new message.
|
|
150
|
+
*/
|
|
151
|
+
export declare const TransferFeeSchema: GenMessage<TransferFee>;
|
|
152
|
+
/**
|
|
153
|
+
*
|
|
154
|
+
* TransferState describes the state of the transfer
|
|
155
|
+
*
|
|
156
|
+
* @generated from enum meshtrade.wallet.transfer.v1.TransferState
|
|
157
|
+
*/
|
|
158
|
+
export declare enum TransferState {
|
|
159
|
+
/**
|
|
160
|
+
* Unspecified state
|
|
161
|
+
*
|
|
162
|
+
* @generated from enum value: TRANSFER_STATE_UNSPECIFIED = 0;
|
|
163
|
+
*/
|
|
164
|
+
UNSPECIFIED = 0,
|
|
165
|
+
/**
|
|
166
|
+
* Transfer in progress
|
|
167
|
+
*
|
|
168
|
+
* @generated from enum value: TRANSFER_STATE_IN_PROGRESS = 1;
|
|
169
|
+
*/
|
|
170
|
+
IN_PROGRESS = 1,
|
|
171
|
+
/**
|
|
172
|
+
* Transfer failed
|
|
173
|
+
*
|
|
174
|
+
* @generated from enum value: TRANSFER_STATE_FAILED = 2;
|
|
175
|
+
*/
|
|
176
|
+
FAILED = 2,
|
|
177
|
+
/**
|
|
178
|
+
* Transfer successful
|
|
179
|
+
*
|
|
180
|
+
* @generated from enum value: TRANSFER_STATE_SUCCESSFUL = 3;
|
|
181
|
+
*/
|
|
182
|
+
SUCCESSFUL = 3
|
|
183
|
+
}
|
|
184
|
+
/**
|
|
185
|
+
* Describes the enum meshtrade.wallet.transfer.v1.TransferState.
|
|
186
|
+
*/
|
|
187
|
+
export declare const TransferStateSchema: GenEnum<TransferState>;
|
|
@@ -0,0 +1,61 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
// @generated by protoc-gen-es v2.10.1 with parameter "target=ts"
|
|
3
|
+
// @generated from file meshtrade/wallet/transfer/v1/transfer.proto (package meshtrade.wallet.transfer.v1, syntax proto3)
|
|
4
|
+
/* eslint-disable */
|
|
5
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
6
|
+
exports.TransferStateSchema = exports.TransferState = exports.TransferFeeSchema = exports.TransferSchema = exports.file_meshtrade_wallet_transfer_v1_transfer = void 0;
|
|
7
|
+
const codegenv2_1 = require("@bufbuild/protobuf/codegenv2");
|
|
8
|
+
const validate_pb_1 = require("../../../../buf/validate/validate_pb");
|
|
9
|
+
const amount_pb_1 = require("../../../type/v1/amount_pb");
|
|
10
|
+
const decimal_pb_1 = require("../../../type/v1/decimal_pb");
|
|
11
|
+
/**
|
|
12
|
+
* Describes the file meshtrade/wallet/transfer/v1/transfer.proto.
|
|
13
|
+
*/
|
|
14
|
+
exports.file_meshtrade_wallet_transfer_v1_transfer = (0, codegenv2_1.fileDesc)("CittZXNodHJhZGUvd2FsbGV0L3RyYW5zZmVyL3YxL3RyYW5zZmVyLnByb3RvEhxtZXNodHJhZGUud2FsbGV0LnRyYW5zZmVyLnYxIsYFCghUcmFuc2ZlchLKAQoEbmFtZRgBIAEoCUK7AbpItwG6AbMBChRuYW1lLmZvcm1hdC5vcHRpb25hbBI9bmFtZSBtdXN0IGJlIGVtcHR5IG9yIGluIHRoZSBmb3JtYXQgd2FsbGV0L3RyYW5zZmVycy97VUxJRHYyfRpcc2l6ZSh0aGlzKSA9PSAwIHx8IHRoaXMubWF0Y2hlcygnXndhbGxldC90cmFuc2ZlcnMvWzAxMjM0NTY3ODlBQkNERUZHSEpLTU5QUVJTVFZXWFlaXXsyNn0kJykSSwoFb3duZXIYAiABKAlCPLpIOcgBAXI0Mi9eZ3JvdXBzL1swMTIzNDU2Nzg5QUJDREVGR0hKS01OUFFSU1RWV1hZWl17MjZ9JJgBIRJOCgZvd25lcnMYAyADKAlCPrpIO5IBOCI2cjQyL15ncm91cHMvWzAxMjM0NTY3ODlBQkNERUZHSEpLTU5QUVJTVFZXWFlaXXsyNn0kmAEhEg4KBm51bWJlchgEIAEoCRIZCgRmcm9tGAUgASgJQgu6SAjIAQFyAxj/ARIXCgJ0bxgGIAEoCUILukgIyAEBcgMY/wESMQoGYW1vdW50GAcgASgLMhkubWVzaHRyYWRlLnR5cGUudjEuQW1vdW50Qga6SAPIAQESGwoLdHJhbnNhY3Rpb24YCCABKAlCBrpIA8gBARI+CgNmZWUYCSABKAsyKS5tZXNodHJhZGUud2FsbGV0LnRyYW5zZmVyLnYxLlRyYW5zZmVyRmVlQga6SAPIAQESQgoFc3RhdGUYCiABKA4yKy5tZXNodHJhZGUud2FsbGV0LnRyYW5zZmVyLnYxLlRyYW5zZmVyU3RhdGVCBrpIA8gBARIdCgtkZXNjcmlwdGlvbhgLIAEoCUIIukgFcgMY/wESGQoRaW5jbHVkZV9pbl9sZWRnZXIYDCABKAgidgoLVHJhbnNmZXJGZWUSMQoGYW1vdW50GAEgASgLMhkubWVzaHRyYWRlLnR5cGUudjEuQW1vdW50Qga6SAPIAQESNAoIdmF0X3JhdGUYAiABKAsyGi5tZXNodHJhZGUudHlwZS52MS5EZWNpbWFsQga6SAPIAQEqiQEKDVRyYW5zZmVyU3RhdGUSHgoaVFJBTlNGRVJfU1RBVEVfVU5TUEVDSUZJRUQQABIeChpUUkFOU0ZFUl9TVEFURV9JTl9QUk9HUkVTUxABEhkKFVRSQU5TRkVSX1NUQVRFX0ZBSUxFRBACEh0KGVRSQU5TRkVSX1NUQVRFX1NVQ0NFU1NGVUwQA0JhCiNjby5tZXNodHJhZGUuYXBpLndhbGxldC50cmFuc2Zlci52MVo6Z2l0aHViLmNvbS9tZXNodHJhZGUvYXBpL2dvL3dhbGxldC90cmFuc2Zlci92MTt0cmFuc2Zlcl92MWIGcHJvdG8z", [validate_pb_1.file_buf_validate_validate, amount_pb_1.file_meshtrade_type_v1_amount, decimal_pb_1.file_meshtrade_type_v1_decimal]);
|
|
15
|
+
/**
|
|
16
|
+
* Describes the message meshtrade.wallet.transfer.v1.Transfer.
|
|
17
|
+
* Use `create(TransferSchema)` to create a new message.
|
|
18
|
+
*/
|
|
19
|
+
exports.TransferSchema = (0, codegenv2_1.messageDesc)(exports.file_meshtrade_wallet_transfer_v1_transfer, 0);
|
|
20
|
+
/**
|
|
21
|
+
* Describes the message meshtrade.wallet.transfer.v1.TransferFee.
|
|
22
|
+
* Use `create(TransferFeeSchema)` to create a new message.
|
|
23
|
+
*/
|
|
24
|
+
exports.TransferFeeSchema = (0, codegenv2_1.messageDesc)(exports.file_meshtrade_wallet_transfer_v1_transfer, 1);
|
|
25
|
+
/**
|
|
26
|
+
*
|
|
27
|
+
* TransferState describes the state of the transfer
|
|
28
|
+
*
|
|
29
|
+
* @generated from enum meshtrade.wallet.transfer.v1.TransferState
|
|
30
|
+
*/
|
|
31
|
+
var TransferState;
|
|
32
|
+
(function (TransferState) {
|
|
33
|
+
/**
|
|
34
|
+
* Unspecified state
|
|
35
|
+
*
|
|
36
|
+
* @generated from enum value: TRANSFER_STATE_UNSPECIFIED = 0;
|
|
37
|
+
*/
|
|
38
|
+
TransferState[TransferState["UNSPECIFIED"] = 0] = "UNSPECIFIED";
|
|
39
|
+
/**
|
|
40
|
+
* Transfer in progress
|
|
41
|
+
*
|
|
42
|
+
* @generated from enum value: TRANSFER_STATE_IN_PROGRESS = 1;
|
|
43
|
+
*/
|
|
44
|
+
TransferState[TransferState["IN_PROGRESS"] = 1] = "IN_PROGRESS";
|
|
45
|
+
/**
|
|
46
|
+
* Transfer failed
|
|
47
|
+
*
|
|
48
|
+
* @generated from enum value: TRANSFER_STATE_FAILED = 2;
|
|
49
|
+
*/
|
|
50
|
+
TransferState[TransferState["FAILED"] = 2] = "FAILED";
|
|
51
|
+
/**
|
|
52
|
+
* Transfer successful
|
|
53
|
+
*
|
|
54
|
+
* @generated from enum value: TRANSFER_STATE_SUCCESSFUL = 3;
|
|
55
|
+
*/
|
|
56
|
+
TransferState[TransferState["SUCCESSFUL"] = 3] = "SUCCESSFUL";
|
|
57
|
+
})(TransferState || (exports.TransferState = TransferState = {}));
|
|
58
|
+
/**
|
|
59
|
+
* Describes the enum meshtrade.wallet.transfer.v1.TransferState.
|
|
60
|
+
*/
|
|
61
|
+
exports.TransferStateSchema = (0, codegenv2_1.enumDesc)(exports.file_meshtrade_wallet_transfer_v1_transfer, 0);
|