@arbiwallet/contracts 1.0.225 → 1.0.226

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.
@@ -12,22 +12,6 @@ import { Struct } from "./google/protobuf/struct";
12
12
 
13
13
  export const protobufPackage = "exchange_core";
14
14
 
15
- export enum ExchangeDealStatus {
16
- EXCHANGE_DEAL_STATUS_UNSPECIFIED = 0,
17
- EXCHANGE_DEAL_STATUS_NO_DEAL = 1,
18
- EXCHANGE_DEAL_STATUS_IN_PROGRESS = 2,
19
- EXCHANGE_DEAL_STATUS_COMPLETED = 3,
20
- EXCHANGE_DEAL_STATUS_CANCELLED = 4,
21
- UNRECOGNIZED = -1,
22
- }
23
-
24
- export enum ExchangeDealAction {
25
- EXCHANGE_DEAL_ACTION_UNSPECIFIED = 0,
26
- EXCHANGE_DEAL_ACTION_CREATE_DEAL = 1,
27
- EXCHANGE_DEAL_ACTION_OPEN_DEAL = 2,
28
- UNRECOGNIZED = -1,
29
- }
30
-
31
15
  export interface AuthManagerContext {
32
16
  managerId: string;
33
17
  officeIds: string[];
@@ -48,7 +32,7 @@ export interface CreateExchangeDealRequest {
48
32
  factOutputAmount?: number | undefined;
49
33
  inputCurrencyId?: string | undefined;
50
34
  outputCurrencyId?: string | undefined;
51
- customerId?: string | undefined;
35
+ userId?: string | undefined;
52
36
  managerPersonId?: string | undefined;
53
37
  expensesForCourier?: number | undefined;
54
38
  includeInTotalCalculation?: boolean | undefined;
@@ -65,7 +49,7 @@ export interface CreateExchangeDealRequest {
65
49
 
66
50
  export interface CreateExchangeDealResult {
67
51
  exchangeId: string;
68
- customerId: string;
52
+ userId: string;
69
53
  inputAmount: number;
70
54
  inputCurrencyId: string;
71
55
  outputAmount: number;
@@ -85,7 +69,7 @@ export interface GetExchangeDealsRequest {
85
69
  fromDate?: string | undefined;
86
70
  toDate?: string | undefined;
87
71
  managerId?: string | undefined;
88
- customerId?: string | undefined;
72
+ userId?: string | undefined;
89
73
  page?: number | undefined;
90
74
  pageSize?: number | undefined;
91
75
  ordering?: string | undefined;
@@ -98,7 +82,7 @@ export interface GetExchangeDealsManager {
98
82
 
99
83
  export interface GetExchangeDealsItem {
100
84
  id: string;
101
- customerId: string;
85
+ userId: string;
102
86
  paymentId?: string | undefined;
103
87
  inputAmount: number;
104
88
  inputCurrencyId: string;
@@ -122,7 +106,7 @@ export interface GetExchangeDealsResponse {
122
106
  export interface UpdateExchangeDealRequest {
123
107
  authManagerContext: AuthManagerContext | undefined;
124
108
  id: string;
125
- customerId?: string | undefined;
109
+ userId?: string | undefined;
126
110
  inputAmount?: number | undefined;
127
111
  inputCurrencyId?: string | undefined;
128
112
  inputWalletId?: string | undefined;
@@ -148,7 +132,7 @@ export interface UpdateExchangeDealRequest {
148
132
 
149
133
  export interface UpdateExchangeDealResult {
150
134
  id: string;
151
- customerId: string;
135
+ userId: string;
152
136
  inputAmount: number;
153
137
  inputCurrencyId: string;
154
138
  outputAmount: number;
@@ -234,8 +218,8 @@ export interface GetTransactionsItem {
234
218
  comment?: string | undefined;
235
219
  exchangeId?: string | undefined;
236
220
  exchangeUrl?: string | undefined;
237
- userId?: string | undefined;
238
- username?: string | undefined;
221
+ managerId?: string | undefined;
222
+ managerName?: string | undefined;
239
223
  accountType: number;
240
224
  }
241
225
 
@@ -247,71 +231,6 @@ export interface GetTransactionsResponse {
247
231
  summary: GetTransactionsSummaryItem[];
248
232
  }
249
233
 
250
- export interface GetExchangeDealHistoryStatisticsRequest {
251
- dateFrom?: string | undefined;
252
- dateTo?: string | undefined;
253
- amountFrom?: number | undefined;
254
- amountTo?: number | undefined;
255
- inputCurrency?: string | undefined;
256
- outputCurrency?:
257
- | string
258
- | undefined;
259
- /** no_payment | with_payment | with_exchange | completed */
260
- status?: string | undefined;
261
- search?: string | undefined;
262
- page?: number | undefined;
263
- pageSize?: number | undefined;
264
- }
265
-
266
- export interface GetExchangeDealHistoryStatisticsResponse {
267
- items: ExchangeDealStateByCalculation[];
268
- }
269
-
270
- export interface GetExchangePaymentRefsByCalculationIdsRequest {
271
- calculationIds: string[];
272
- }
273
-
274
- export interface ExchangePaymentRefByCalculation {
275
- calculationId: string;
276
- paymentUuid: string;
277
- }
278
-
279
- export interface GetExchangePaymentRefsByCalculationIdsResponse {
280
- items: ExchangePaymentRefByCalculation[];
281
- notFoundCalculationIds: string[];
282
- }
283
-
284
- export interface GetExchangeDealRefsByCalculationIdsRequest {
285
- calculationIds: string[];
286
- }
287
-
288
- export interface ExchangeDealRefByCalculation {
289
- calculationId: string;
290
- exchangeId: string;
291
- status: boolean;
292
- }
293
-
294
- export interface GetExchangeDealRefsByCalculationIdsResponse {
295
- items: ExchangeDealRefByCalculation[];
296
- notFoundCalculationIds: string[];
297
- }
298
-
299
- export interface GetExchangeDealStatesByCalculationIdsRequest {
300
- calculationIds: string[];
301
- }
302
-
303
- export interface ExchangeDealStateByCalculation {
304
- calculationId: string;
305
- dealId?: string | undefined;
306
- status: ExchangeDealStatus;
307
- allowedActions: ExchangeDealAction[];
308
- }
309
-
310
- export interface GetExchangeDealStatesByCalculationIdsResponse {
311
- items: ExchangeDealStateByCalculation[];
312
- notFoundCalculationIds: string[];
313
- }
314
-
315
234
  export const EXCHANGE_CORE_PACKAGE_NAME = "exchange_core";
316
235
 
317
236
  wrappers[".google.protobuf.Struct"] = { fromObject: Struct.wrap, toObject: Struct.unwrap } as any;
@@ -334,22 +253,6 @@ export interface ExchangeCoreServiceClient {
334
253
  cancelExchangeDeal(request: CancelExchangeDealRequest): Observable<CancelExchangeDealResponse>;
335
254
 
336
255
  getTransactions(request: GetTransactionsRequest): Observable<GetTransactionsResponse>;
337
-
338
- getExchangeDealHistoryStatistics(
339
- request: GetExchangeDealHistoryStatisticsRequest,
340
- ): Observable<GetExchangeDealHistoryStatisticsResponse>;
341
-
342
- getExchangePaymentRefsByCalculationIds(
343
- request: GetExchangePaymentRefsByCalculationIdsRequest,
344
- ): Observable<GetExchangePaymentRefsByCalculationIdsResponse>;
345
-
346
- getExchangeDealRefsByCalculationIds(
347
- request: GetExchangeDealRefsByCalculationIdsRequest,
348
- ): Observable<GetExchangeDealRefsByCalculationIdsResponse>;
349
-
350
- getExchangeDealStatesByCalculationIds(
351
- request: GetExchangeDealStatesByCalculationIdsRequest,
352
- ): Observable<GetExchangeDealStatesByCalculationIdsResponse>;
353
256
  }
354
257
 
355
258
  /**
@@ -382,34 +285,6 @@ export interface ExchangeCoreServiceController {
382
285
  getTransactions(
383
286
  request: GetTransactionsRequest,
384
287
  ): Promise<GetTransactionsResponse> | Observable<GetTransactionsResponse> | GetTransactionsResponse;
385
-
386
- getExchangeDealHistoryStatistics(
387
- request: GetExchangeDealHistoryStatisticsRequest,
388
- ):
389
- | Promise<GetExchangeDealHistoryStatisticsResponse>
390
- | Observable<GetExchangeDealHistoryStatisticsResponse>
391
- | GetExchangeDealHistoryStatisticsResponse;
392
-
393
- getExchangePaymentRefsByCalculationIds(
394
- request: GetExchangePaymentRefsByCalculationIdsRequest,
395
- ):
396
- | Promise<GetExchangePaymentRefsByCalculationIdsResponse>
397
- | Observable<GetExchangePaymentRefsByCalculationIdsResponse>
398
- | GetExchangePaymentRefsByCalculationIdsResponse;
399
-
400
- getExchangeDealRefsByCalculationIds(
401
- request: GetExchangeDealRefsByCalculationIdsRequest,
402
- ):
403
- | Promise<GetExchangeDealRefsByCalculationIdsResponse>
404
- | Observable<GetExchangeDealRefsByCalculationIdsResponse>
405
- | GetExchangeDealRefsByCalculationIdsResponse;
406
-
407
- getExchangeDealStatesByCalculationIds(
408
- request: GetExchangeDealStatesByCalculationIdsRequest,
409
- ):
410
- | Promise<GetExchangeDealStatesByCalculationIdsResponse>
411
- | Observable<GetExchangeDealStatesByCalculationIdsResponse>
412
- | GetExchangeDealStatesByCalculationIdsResponse;
413
288
  }
414
289
 
415
290
  export function ExchangeCoreServiceControllerMethods() {
@@ -421,10 +296,6 @@ export function ExchangeCoreServiceControllerMethods() {
421
296
  "completeExchangeDeal",
422
297
  "cancelExchangeDeal",
423
298
  "getTransactions",
424
- "getExchangeDealHistoryStatistics",
425
- "getExchangePaymentRefsByCalculationIds",
426
- "getExchangeDealRefsByCalculationIds",
427
- "getExchangeDealStatesByCalculationIds",
428
299
  ];
429
300
  for (const method of grpcMethods) {
430
301
  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.225",
4
+ "version": "1.0.226",
5
5
  "scripts": {
6
6
  "generate": "protoc -I ./proto ./proto/*.proto --ts_proto_out=./gen --ts_proto_opt=nestJs=true,package=omit"
7
7
  },
@@ -20,13 +20,6 @@ service ExchangeCoreService {
20
20
  rpc CancelExchangeDeal(CancelExchangeDealRequest) returns (CancelExchangeDealResponse);
21
21
 
22
22
  rpc GetTransactions(GetTransactionsRequest) returns (GetTransactionsResponse);
23
-
24
- rpc GetExchangeDealHistoryStatistics(GetExchangeDealHistoryStatisticsRequest) returns (GetExchangeDealHistoryStatisticsResponse);
25
-
26
-
27
- rpc GetExchangePaymentRefsByCalculationIds(GetExchangePaymentRefsByCalculationIdsRequest) returns (GetExchangePaymentRefsByCalculationIdsResponse);
28
- rpc GetExchangeDealRefsByCalculationIds(GetExchangeDealRefsByCalculationIdsRequest) returns (GetExchangeDealRefsByCalculationIdsResponse);
29
- rpc GetExchangeDealStatesByCalculationIds(GetExchangeDealStatesByCalculationIdsRequest) returns (GetExchangeDealStatesByCalculationIdsResponse);
30
23
  }
31
24
 
32
25
  // message CreateExchangePaymentRequest {
@@ -36,7 +29,7 @@ service ExchangeCoreService {
36
29
  // optional string calculation_id = 3;
37
30
  // int32 agent_id = 4;
38
31
  // optional double amount = 5;
39
- // optional string customer_id = 6;
32
+ // optional string user_id = 6;
40
33
  // optional string crypto_network = 7;
41
34
  // optional string customer_source = 8;
42
35
  // optional string customer_referrer = 9;
@@ -120,7 +113,7 @@ message CreateExchangeDealRequest {
120
113
  optional string input_currency_id = 11;
121
114
  optional string output_currency_id = 12;
122
115
 
123
- optional string customer_id = 13;
116
+ optional string user_id = 13;
124
117
  optional string manager_person_id = 14;
125
118
 
126
119
  optional double expenses_for_courier = 15;
@@ -141,7 +134,7 @@ message CreateExchangeDealRequest {
141
134
 
142
135
  message CreateExchangeDealResult {
143
136
  string exchange_id = 1;
144
- string customer_id = 2;
137
+ string user_id = 2;
145
138
  double input_amount = 3;
146
139
  string input_currency_id = 4;
147
140
  double output_amount = 5;
@@ -161,7 +154,7 @@ message GetExchangeDealsRequest {
161
154
  optional string from_date = 2;
162
155
  optional string to_date = 3;
163
156
  optional string manager_id = 4;
164
- optional string customer_id = 5;
157
+ optional string user_id = 5;
165
158
  optional int32 page = 6;
166
159
  optional int32 page_size = 7;
167
160
  optional string ordering = 8;
@@ -174,7 +167,7 @@ message GetExchangeDealsManager {
174
167
 
175
168
  message GetExchangeDealsItem {
176
169
  string id = 1;
177
- string customer_id = 2;
170
+ string user_id = 2;
178
171
  optional string payment_id = 3;
179
172
  double input_amount = 4;
180
173
  string input_currency_id = 5;
@@ -199,7 +192,7 @@ message UpdateExchangeDealRequest {
199
192
  AuthManagerContext auth_manager_context = 1;
200
193
  string id = 2;
201
194
 
202
- optional string customer_id = 3;
195
+ optional string user_id = 3;
203
196
  optional double input_amount = 4;
204
197
  optional string input_currency_id = 5;
205
198
  optional string input_wallet_id = 6;
@@ -226,7 +219,7 @@ message UpdateExchangeDealRequest {
226
219
 
227
220
  message UpdateExchangeDealResult {
228
221
  string id = 1;
229
- string customer_id = 2;
222
+ string user_id = 2;
230
223
  double input_amount = 3;
231
224
  string input_currency_id = 4;
232
225
  double output_amount = 5;
@@ -312,8 +305,8 @@ message GetTransactionsItem {
312
305
  optional string comment = 19;
313
306
  optional string exchange_id = 20;
314
307
  optional string exchange_url = 21;
315
- optional string user_id = 22;
316
- optional string username = 23;
308
+ optional string manager_id = 22;
309
+ optional string manager_name = 23;
317
310
  int32 account_type = 24;
318
311
  }
319
312
 
@@ -324,80 +317,3 @@ message GetTransactionsResponse {
324
317
  repeated GetTransactionsItem results = 4;
325
318
  repeated GetTransactionsSummaryItem summary = 5;
326
319
  }
327
-
328
- message GetExchangeDealHistoryStatisticsRequest {
329
- optional string date_from = 1;
330
- optional string date_to = 2;
331
- optional double amount_from = 3;
332
- optional double amount_to = 4;
333
- optional string input_currency = 5;
334
- optional string output_currency = 6;
335
- optional string status = 7; // no_payment | with_payment | with_exchange | completed
336
- optional string search = 8;
337
- optional int32 page = 9;
338
- optional int32 page_size = 10;
339
- }
340
-
341
- message GetExchangeDealHistoryStatisticsResponse {
342
- repeated ExchangeDealStateByCalculation items = 1;
343
- }
344
-
345
- message GetExchangePaymentRefsByCalculationIdsRequest {
346
- repeated string calculation_ids = 1;
347
- }
348
-
349
- message ExchangePaymentRefByCalculation {
350
- string calculation_id = 1;
351
- string payment_uuid = 2;
352
- }
353
-
354
- message GetExchangePaymentRefsByCalculationIdsResponse {
355
- repeated ExchangePaymentRefByCalculation items = 1;
356
- repeated string not_found_calculation_ids = 2;
357
- }
358
-
359
- message GetExchangeDealRefsByCalculationIdsRequest {
360
- repeated string calculation_ids = 1;
361
- }
362
-
363
- message ExchangeDealRefByCalculation {
364
- string calculation_id = 1;
365
- string exchange_id = 2;
366
- bool status = 3;
367
- }
368
-
369
- message GetExchangeDealRefsByCalculationIdsResponse {
370
- repeated ExchangeDealRefByCalculation items = 1;
371
- repeated string not_found_calculation_ids = 2;
372
- }
373
-
374
-
375
- message GetExchangeDealStatesByCalculationIdsRequest {
376
- repeated string calculation_ids = 1;
377
- }
378
-
379
- enum ExchangeDealStatus {
380
- EXCHANGE_DEAL_STATUS_UNSPECIFIED = 0;
381
- EXCHANGE_DEAL_STATUS_NO_DEAL = 1;
382
- EXCHANGE_DEAL_STATUS_IN_PROGRESS = 2;
383
- EXCHANGE_DEAL_STATUS_COMPLETED = 3;
384
- EXCHANGE_DEAL_STATUS_CANCELLED = 4;
385
- }
386
-
387
- enum ExchangeDealAction {
388
- EXCHANGE_DEAL_ACTION_UNSPECIFIED = 0;
389
- EXCHANGE_DEAL_ACTION_CREATE_DEAL = 1;
390
- EXCHANGE_DEAL_ACTION_OPEN_DEAL = 2;
391
- }
392
-
393
- message ExchangeDealStateByCalculation {
394
- string calculation_id = 1;
395
- optional string deal_id = 2;
396
- ExchangeDealStatus status = 3;
397
- repeated ExchangeDealAction allowed_actions = 4;
398
- }
399
-
400
- message GetExchangeDealStatesByCalculationIdsResponse {
401
- repeated ExchangeDealStateByCalculation items = 1;
402
- repeated string not_found_calculation_ids = 2;
403
- }