@arbiwallet/contracts 1.0.250 → 1.0.252
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/gen/exchange_core.ts +1 -169
- package/package.json +1 -1
- package/proto/exchange_core.proto +1 -137
package/gen/exchange_core.ts
CHANGED
|
@@ -229,81 +229,6 @@ export interface CancelExchangeDealResponse {
|
|
|
229
229
|
validationErrors?: { [key: string]: any } | undefined;
|
|
230
230
|
}
|
|
231
231
|
|
|
232
|
-
export interface GetTransactionsRequest {
|
|
233
|
-
authManagerContext: AuthManagerContext | undefined;
|
|
234
|
-
startDate?: string | undefined;
|
|
235
|
-
endDate?: string | undefined;
|
|
236
|
-
userId?: string | undefined;
|
|
237
|
-
currencyId?: string | undefined;
|
|
238
|
-
walletId?: string | undefined;
|
|
239
|
-
type?: number | undefined;
|
|
240
|
-
accountType?: number | undefined;
|
|
241
|
-
categoryId?: string | undefined;
|
|
242
|
-
businessUnitId?: string | undefined;
|
|
243
|
-
search?: string | undefined;
|
|
244
|
-
page?: number | undefined;
|
|
245
|
-
pageSize?: number | undefined;
|
|
246
|
-
}
|
|
247
|
-
|
|
248
|
-
export interface GetTransactionsItem {
|
|
249
|
-
id: string;
|
|
250
|
-
transactionDatetime: string;
|
|
251
|
-
createdAt: string;
|
|
252
|
-
amount: number;
|
|
253
|
-
currency?: string | undefined;
|
|
254
|
-
usdtAmount?: number | undefined;
|
|
255
|
-
status: boolean;
|
|
256
|
-
walletId?: string | undefined;
|
|
257
|
-
walletName?: string | undefined;
|
|
258
|
-
moveWalletId?: string | undefined;
|
|
259
|
-
moveWalletName?: string | undefined;
|
|
260
|
-
type: number;
|
|
261
|
-
typeName?: string | undefined;
|
|
262
|
-
categoryId?: string | undefined;
|
|
263
|
-
categoryName?: string | undefined;
|
|
264
|
-
businessUnitId?: string | undefined;
|
|
265
|
-
businessUnitName?: string | undefined;
|
|
266
|
-
name: string;
|
|
267
|
-
comment?: string | undefined;
|
|
268
|
-
exchangeId?: string | undefined;
|
|
269
|
-
exchangeUrl?: string | undefined;
|
|
270
|
-
managerId?: string | undefined;
|
|
271
|
-
managerName?: string | undefined;
|
|
272
|
-
accountType: number;
|
|
273
|
-
}
|
|
274
|
-
|
|
275
|
-
export interface GetTransactionsSummaryRequest {
|
|
276
|
-
authManagerContext: AuthManagerContext | undefined;
|
|
277
|
-
startDate?: string | undefined;
|
|
278
|
-
endDate?: string | undefined;
|
|
279
|
-
userId?: string | undefined;
|
|
280
|
-
currencyId?: string | undefined;
|
|
281
|
-
walletId?: string | undefined;
|
|
282
|
-
type?: number | undefined;
|
|
283
|
-
accountType?: number | undefined;
|
|
284
|
-
categoryId?: string | undefined;
|
|
285
|
-
businessUnitId?: string | undefined;
|
|
286
|
-
search?: string | undefined;
|
|
287
|
-
}
|
|
288
|
-
|
|
289
|
-
export interface GetTransactionsSummaryItem {
|
|
290
|
-
currency: string;
|
|
291
|
-
totalIncome: number;
|
|
292
|
-
totalExpense: number;
|
|
293
|
-
}
|
|
294
|
-
|
|
295
|
-
export interface GetTransactionsResponse {
|
|
296
|
-
count: number;
|
|
297
|
-
next?: string | undefined;
|
|
298
|
-
previous?: string | undefined;
|
|
299
|
-
results: GetTransactionsItem[];
|
|
300
|
-
summary: GetTransactionsSummaryItem[];
|
|
301
|
-
}
|
|
302
|
-
|
|
303
|
-
export interface GetTransactionsSummaryResponse {
|
|
304
|
-
summary: GetTransactionsSummaryItem[];
|
|
305
|
-
}
|
|
306
|
-
|
|
307
232
|
export interface ExchangeCalculationsFiltersRequest {
|
|
308
233
|
dateFrom?: string | undefined;
|
|
309
234
|
dateTo?: string | undefined;
|
|
@@ -500,7 +425,7 @@ export interface WalletMonikaCurrency {
|
|
|
500
425
|
}
|
|
501
426
|
|
|
502
427
|
export interface WalletMonikaItem {
|
|
503
|
-
id:
|
|
428
|
+
id: string;
|
|
504
429
|
name: string;
|
|
505
430
|
currencies: WalletMonikaCurrency[];
|
|
506
431
|
balance: number;
|
|
@@ -515,61 +440,6 @@ export interface GetWalletsMonikaResponse {
|
|
|
515
440
|
wallets: WalletMonikaItem[];
|
|
516
441
|
}
|
|
517
442
|
|
|
518
|
-
export interface CreateWalletRequest {
|
|
519
|
-
authManagerContext: AuthManagerContext | undefined;
|
|
520
|
-
name: string;
|
|
521
|
-
sort?: number | undefined;
|
|
522
|
-
isGeneral?: boolean | undefined;
|
|
523
|
-
showOnBalances?: boolean | undefined;
|
|
524
|
-
cryptoAddress?: string | undefined;
|
|
525
|
-
cryptoNetwork?: number | undefined;
|
|
526
|
-
isActive?: boolean | undefined;
|
|
527
|
-
status?: boolean | undefined;
|
|
528
|
-
currentManagerId?: string | undefined;
|
|
529
|
-
currencyIds: string[];
|
|
530
|
-
}
|
|
531
|
-
|
|
532
|
-
export interface CreateWalletResponse {
|
|
533
|
-
ok: boolean;
|
|
534
|
-
result?: WalletItem | undefined;
|
|
535
|
-
error?: string | undefined;
|
|
536
|
-
validationErrors?: { [key: string]: any } | undefined;
|
|
537
|
-
}
|
|
538
|
-
|
|
539
|
-
export interface UpdateWalletRequest {
|
|
540
|
-
authManagerContext: AuthManagerContext | undefined;
|
|
541
|
-
id: string;
|
|
542
|
-
name?: string | undefined;
|
|
543
|
-
sort?: number | undefined;
|
|
544
|
-
isGeneral?: boolean | undefined;
|
|
545
|
-
showOnBalances?: boolean | undefined;
|
|
546
|
-
cryptoAddress?: string | undefined;
|
|
547
|
-
cryptoNetwork?: number | undefined;
|
|
548
|
-
isActive?: boolean | undefined;
|
|
549
|
-
status?: boolean | undefined;
|
|
550
|
-
managerId?: string | undefined;
|
|
551
|
-
currencyIds: string[];
|
|
552
|
-
}
|
|
553
|
-
|
|
554
|
-
export interface UpdateWalletResponse {
|
|
555
|
-
ok: boolean;
|
|
556
|
-
result?: WalletItem | undefined;
|
|
557
|
-
error?: string | undefined;
|
|
558
|
-
validationErrors?: { [key: string]: any } | undefined;
|
|
559
|
-
}
|
|
560
|
-
|
|
561
|
-
export interface DeleteWalletRequest {
|
|
562
|
-
authManagerContext: AuthManagerContext | undefined;
|
|
563
|
-
id: string;
|
|
564
|
-
}
|
|
565
|
-
|
|
566
|
-
export interface DeleteWalletResponse {
|
|
567
|
-
success: boolean;
|
|
568
|
-
message?: string | undefined;
|
|
569
|
-
error?: string | undefined;
|
|
570
|
-
validationErrors?: { [key: string]: any } | undefined;
|
|
571
|
-
}
|
|
572
|
-
|
|
573
443
|
export const EXCHANGE_CORE_PACKAGE_NAME = "exchange_core";
|
|
574
444
|
|
|
575
445
|
wrappers[".google.protobuf.Struct"] = { fromObject: Struct.wrap, toObject: Struct.unwrap } as any;
|
|
@@ -587,10 +457,6 @@ export interface ExchangeCoreServiceClient {
|
|
|
587
457
|
|
|
588
458
|
cancelExchangeDeal(request: CancelExchangeDealRequest): Observable<CancelExchangeDealResponse>;
|
|
589
459
|
|
|
590
|
-
getTransactions(request: GetTransactionsRequest): Observable<GetTransactionsResponse>;
|
|
591
|
-
|
|
592
|
-
getTransactionsSummary(request: GetTransactionsSummaryRequest): Observable<GetTransactionsSummaryResponse>;
|
|
593
|
-
|
|
594
460
|
createExchangePayment(request: CreateExchangePaymentRequest): Observable<CreateExchangePaymentResponse>;
|
|
595
461
|
|
|
596
462
|
handlePaymentWebhook(request: HandlePaymentWebhookRequest): Observable<HandlePaymentWebhookResponse>;
|
|
@@ -608,12 +474,6 @@ export interface ExchangeCoreServiceClient {
|
|
|
608
474
|
getWallets(request: GetWalletsRequest): Observable<GetWalletsResponse>;
|
|
609
475
|
|
|
610
476
|
getWalletsMonika(request: GetWalletsMonikaRequest): Observable<GetWalletsMonikaResponse>;
|
|
611
|
-
|
|
612
|
-
createWallet(request: CreateWalletRequest): Observable<CreateWalletResponse>;
|
|
613
|
-
|
|
614
|
-
updateWallet(request: UpdateWalletRequest): Observable<UpdateWalletResponse>;
|
|
615
|
-
|
|
616
|
-
deleteWallet(request: DeleteWalletRequest): Observable<DeleteWalletResponse>;
|
|
617
477
|
}
|
|
618
478
|
|
|
619
479
|
export interface ExchangeCoreServiceController {
|
|
@@ -644,17 +504,6 @@ export interface ExchangeCoreServiceController {
|
|
|
644
504
|
request: CancelExchangeDealRequest,
|
|
645
505
|
): Promise<CancelExchangeDealResponse> | Observable<CancelExchangeDealResponse> | CancelExchangeDealResponse;
|
|
646
506
|
|
|
647
|
-
getTransactions(
|
|
648
|
-
request: GetTransactionsRequest,
|
|
649
|
-
): Promise<GetTransactionsResponse> | Observable<GetTransactionsResponse> | GetTransactionsResponse;
|
|
650
|
-
|
|
651
|
-
getTransactionsSummary(
|
|
652
|
-
request: GetTransactionsSummaryRequest,
|
|
653
|
-
):
|
|
654
|
-
| Promise<GetTransactionsSummaryResponse>
|
|
655
|
-
| Observable<GetTransactionsSummaryResponse>
|
|
656
|
-
| GetTransactionsSummaryResponse;
|
|
657
|
-
|
|
658
507
|
createExchangePayment(
|
|
659
508
|
request: CreateExchangePaymentRequest,
|
|
660
509
|
): Promise<CreateExchangePaymentResponse> | Observable<CreateExchangePaymentResponse> | CreateExchangePaymentResponse;
|
|
@@ -690,18 +539,6 @@ export interface ExchangeCoreServiceController {
|
|
|
690
539
|
getWalletsMonika(
|
|
691
540
|
request: GetWalletsMonikaRequest,
|
|
692
541
|
): Promise<GetWalletsMonikaResponse> | Observable<GetWalletsMonikaResponse> | GetWalletsMonikaResponse;
|
|
693
|
-
|
|
694
|
-
createWallet(
|
|
695
|
-
request: CreateWalletRequest,
|
|
696
|
-
): Promise<CreateWalletResponse> | Observable<CreateWalletResponse> | CreateWalletResponse;
|
|
697
|
-
|
|
698
|
-
updateWallet(
|
|
699
|
-
request: UpdateWalletRequest,
|
|
700
|
-
): Promise<UpdateWalletResponse> | Observable<UpdateWalletResponse> | UpdateWalletResponse;
|
|
701
|
-
|
|
702
|
-
deleteWallet(
|
|
703
|
-
request: DeleteWalletRequest,
|
|
704
|
-
): Promise<DeleteWalletResponse> | Observable<DeleteWalletResponse> | DeleteWalletResponse;
|
|
705
542
|
}
|
|
706
543
|
|
|
707
544
|
export function ExchangeCoreServiceControllerMethods() {
|
|
@@ -713,8 +550,6 @@ export function ExchangeCoreServiceControllerMethods() {
|
|
|
713
550
|
"updateExchangeDeal",
|
|
714
551
|
"completeExchangeDeal",
|
|
715
552
|
"cancelExchangeDeal",
|
|
716
|
-
"getTransactions",
|
|
717
|
-
"getTransactionsSummary",
|
|
718
553
|
"createExchangePayment",
|
|
719
554
|
"handlePaymentWebhook",
|
|
720
555
|
"getExchangePayments",
|
|
@@ -724,9 +559,6 @@ export function ExchangeCoreServiceControllerMethods() {
|
|
|
724
559
|
"getExchangeStatuses",
|
|
725
560
|
"getWallets",
|
|
726
561
|
"getWalletsMonika",
|
|
727
|
-
"createWallet",
|
|
728
|
-
"updateWallet",
|
|
729
|
-
"deleteWallet",
|
|
730
562
|
];
|
|
731
563
|
for (const method of grpcMethods) {
|
|
732
564
|
const descriptor: any = Reflect.getOwnPropertyDescriptor(constructor.prototype, method);
|
package/package.json
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@arbiwallet/contracts",
|
|
3
3
|
"descriptions": "Generate and manage smart contracts for ArbiWallet",
|
|
4
|
-
"version": "1.0.
|
|
4
|
+
"version": "1.0.252",
|
|
5
5
|
"scripts": {
|
|
6
6
|
"generate": "protoc -I ./proto ./proto/*.proto --ts_proto_out=./gen --ts_proto_opt=nestJs=true,package=omit"
|
|
7
7
|
},
|
|
@@ -16,9 +16,6 @@ service ExchangeCoreService {
|
|
|
16
16
|
rpc CompleteExchangeDeal(CompleteExchangeDealRequest) returns (CompleteExchangeDealResponse);
|
|
17
17
|
rpc CancelExchangeDeal(CancelExchangeDealRequest) returns (CancelExchangeDealResponse);
|
|
18
18
|
|
|
19
|
-
rpc GetTransactions(GetTransactionsRequest) returns (GetTransactionsResponse);
|
|
20
|
-
rpc GetTransactionsSummary(GetTransactionsSummaryRequest) returns (GetTransactionsSummaryResponse);
|
|
21
|
-
|
|
22
19
|
rpc CreateExchangePayment(CreateExchangePaymentRequest) returns (CreateExchangePaymentResponse);
|
|
23
20
|
rpc HandlePaymentWebhook(HandlePaymentWebhookRequest) returns (HandlePaymentWebhookResponse);
|
|
24
21
|
rpc GetExchangePayments(GetExchangePaymentsRequest) returns (GetExchangePaymentsResponse);
|
|
@@ -30,9 +27,6 @@ service ExchangeCoreService {
|
|
|
30
27
|
|
|
31
28
|
rpc GetWallets(GetWalletsRequest) returns (GetWalletsResponse);
|
|
32
29
|
rpc GetWalletsMonika(GetWalletsMonikaRequest) returns (GetWalletsMonikaResponse);
|
|
33
|
-
rpc CreateWallet(CreateWalletRequest) returns (CreateWalletResponse);
|
|
34
|
-
rpc UpdateWallet(UpdateWalletRequest) returns (UpdateWalletResponse);
|
|
35
|
-
rpc DeleteWallet(DeleteWalletRequest) returns (DeleteWalletResponse);
|
|
36
30
|
}
|
|
37
31
|
|
|
38
32
|
message AuthManagerContext {
|
|
@@ -273,81 +267,6 @@ message CancelExchangeDealResponse {
|
|
|
273
267
|
optional google.protobuf.Struct validationErrors = 4;
|
|
274
268
|
}
|
|
275
269
|
|
|
276
|
-
message GetTransactionsRequest {
|
|
277
|
-
AuthManagerContext auth_manager_context = 1;
|
|
278
|
-
optional string start_date = 2;
|
|
279
|
-
optional string end_date = 3;
|
|
280
|
-
optional string user_id = 4;
|
|
281
|
-
optional string currency_id = 5;
|
|
282
|
-
optional string wallet_id = 6;
|
|
283
|
-
optional int32 type = 7;
|
|
284
|
-
optional int32 account_type = 8;
|
|
285
|
-
optional string category_id = 9;
|
|
286
|
-
optional string business_unit_id = 10;
|
|
287
|
-
optional string search = 11;
|
|
288
|
-
optional int32 page = 12;
|
|
289
|
-
optional int32 page_size = 13;
|
|
290
|
-
}
|
|
291
|
-
|
|
292
|
-
message GetTransactionsItem {
|
|
293
|
-
string id = 1;
|
|
294
|
-
string transaction_datetime = 2;
|
|
295
|
-
string created_at = 3;
|
|
296
|
-
double amount = 4;
|
|
297
|
-
optional string currency = 5;
|
|
298
|
-
optional double usdt_amount = 6;
|
|
299
|
-
bool status = 7;
|
|
300
|
-
optional string wallet_id = 8;
|
|
301
|
-
optional string wallet_name = 9;
|
|
302
|
-
optional string move_wallet_id = 10;
|
|
303
|
-
optional string move_wallet_name = 11;
|
|
304
|
-
int32 type = 12;
|
|
305
|
-
optional string type_name = 13;
|
|
306
|
-
optional string category_id = 14;
|
|
307
|
-
optional string category_name = 15;
|
|
308
|
-
optional string business_unit_id = 16;
|
|
309
|
-
optional string business_unit_name = 17;
|
|
310
|
-
string name = 18;
|
|
311
|
-
optional string comment = 19;
|
|
312
|
-
optional string exchange_id = 20;
|
|
313
|
-
optional string exchange_url = 21;
|
|
314
|
-
optional string manager_id = 22;
|
|
315
|
-
optional string manager_name = 23;
|
|
316
|
-
int32 account_type = 24;
|
|
317
|
-
}
|
|
318
|
-
|
|
319
|
-
message GetTransactionsSummaryRequest {
|
|
320
|
-
AuthManagerContext auth_manager_context = 1;
|
|
321
|
-
optional string start_date = 2;
|
|
322
|
-
optional string end_date = 3;
|
|
323
|
-
optional string user_id = 4;
|
|
324
|
-
optional string currency_id = 5;
|
|
325
|
-
optional string wallet_id = 6;
|
|
326
|
-
optional int32 type = 7;
|
|
327
|
-
optional int32 account_type = 8;
|
|
328
|
-
optional string category_id = 9;
|
|
329
|
-
optional string business_unit_id = 10;
|
|
330
|
-
optional string search = 11;
|
|
331
|
-
}
|
|
332
|
-
|
|
333
|
-
message GetTransactionsSummaryItem {
|
|
334
|
-
string currency = 1;
|
|
335
|
-
double total_income = 2;
|
|
336
|
-
double total_expense = 3;
|
|
337
|
-
}
|
|
338
|
-
|
|
339
|
-
message GetTransactionsResponse {
|
|
340
|
-
int32 count = 1;
|
|
341
|
-
optional string next = 2;
|
|
342
|
-
optional string previous = 3;
|
|
343
|
-
repeated GetTransactionsItem results = 4;
|
|
344
|
-
repeated GetTransactionsSummaryItem summary = 5;
|
|
345
|
-
}
|
|
346
|
-
|
|
347
|
-
message GetTransactionsSummaryResponse {
|
|
348
|
-
repeated GetTransactionsSummaryItem summary = 1;
|
|
349
|
-
}
|
|
350
|
-
|
|
351
270
|
message ExchangeCalculationsFiltersRequest {
|
|
352
271
|
optional string date_from = 1;
|
|
353
272
|
optional string date_to = 2;
|
|
@@ -542,7 +461,7 @@ message WalletMonikaCurrency {
|
|
|
542
461
|
}
|
|
543
462
|
|
|
544
463
|
message WalletMonikaItem {
|
|
545
|
-
|
|
464
|
+
string id = 1;
|
|
546
465
|
string name = 2;
|
|
547
466
|
repeated WalletMonikaCurrency currencies = 3;
|
|
548
467
|
double balance = 4;
|
|
@@ -556,58 +475,3 @@ message WalletMonikaItem {
|
|
|
556
475
|
message GetWalletsMonikaResponse {
|
|
557
476
|
repeated WalletMonikaItem wallets = 2;
|
|
558
477
|
}
|
|
559
|
-
|
|
560
|
-
message CreateWalletRequest {
|
|
561
|
-
AuthManagerContext auth_manager_context = 1;
|
|
562
|
-
string name = 2;
|
|
563
|
-
optional int32 sort = 3;
|
|
564
|
-
optional bool is_general = 4;
|
|
565
|
-
optional bool show_on_balances = 5;
|
|
566
|
-
optional string crypto_address = 6;
|
|
567
|
-
optional int32 crypto_network = 7;
|
|
568
|
-
optional bool is_active = 8;
|
|
569
|
-
optional bool status = 9;
|
|
570
|
-
optional string current_manager_id = 10;
|
|
571
|
-
repeated string currency_ids = 11;
|
|
572
|
-
}
|
|
573
|
-
|
|
574
|
-
message CreateWalletResponse {
|
|
575
|
-
bool ok = 1;
|
|
576
|
-
optional WalletItem result = 2;
|
|
577
|
-
optional string error = 3;
|
|
578
|
-
optional google.protobuf.Struct validationErrors = 4;
|
|
579
|
-
}
|
|
580
|
-
|
|
581
|
-
message UpdateWalletRequest {
|
|
582
|
-
AuthManagerContext auth_manager_context = 1;
|
|
583
|
-
string id = 2;
|
|
584
|
-
optional string name = 3;
|
|
585
|
-
optional int32 sort = 4;
|
|
586
|
-
optional bool is_general = 5;
|
|
587
|
-
optional bool show_on_balances = 6;
|
|
588
|
-
optional string crypto_address = 7;
|
|
589
|
-
optional int32 crypto_network = 8;
|
|
590
|
-
optional bool is_active = 9;
|
|
591
|
-
optional bool status = 10;
|
|
592
|
-
optional string manager_id = 11;
|
|
593
|
-
repeated string currency_ids = 12;
|
|
594
|
-
}
|
|
595
|
-
|
|
596
|
-
message UpdateWalletResponse {
|
|
597
|
-
bool ok = 1;
|
|
598
|
-
optional WalletItem result = 2;
|
|
599
|
-
optional string error = 3;
|
|
600
|
-
optional google.protobuf.Struct validationErrors = 4;
|
|
601
|
-
}
|
|
602
|
-
|
|
603
|
-
message DeleteWalletRequest {
|
|
604
|
-
AuthManagerContext auth_manager_context = 1;
|
|
605
|
-
string id = 2;
|
|
606
|
-
}
|
|
607
|
-
|
|
608
|
-
message DeleteWalletResponse {
|
|
609
|
-
bool success = 1;
|
|
610
|
-
optional string message = 2;
|
|
611
|
-
optional string error = 3;
|
|
612
|
-
optional google.protobuf.Struct validationErrors = 4;
|
|
613
|
-
}
|