protobuf-platform 1.2.301 → 1.2.304
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/package.json +1 -1
- package/payment/payment.proto +96 -0
- package/payment/payment_grpc_pb.js +144 -0
- package/payment/payment_pb.js +5056 -897
package/package.json
CHANGED
package/payment/payment.proto
CHANGED
|
@@ -33,11 +33,18 @@ service Payment {
|
|
|
33
33
|
rpc readListDeposits(PaginationRequest) returns (DepositItemsResponse);
|
|
34
34
|
rpc processingDepositWebHook(DepositWebHookRequest) returns (ProcessedDepositResponse);
|
|
35
35
|
rpc getRedirectPaymentForm(DepositRedirectFormRequest) returns (DepositRedirectFormResponse);
|
|
36
|
+
//Withdrawal
|
|
37
|
+
rpc attemptWithdrawal(AttemptWithdrawalRequest) returns (WithdrawalResponse);
|
|
38
|
+
rpc changeWithdrawalStatus(GetWithdrawalRequest) returns (WithdrawalResponse);
|
|
39
|
+
rpc readListWithdrawals(PaginationRequest) returns (WithdrawalItemsResponse);
|
|
40
|
+
rpc readSingleWithdrawal(GetWithdrawalRequest) returns (WithdrawalResponse);
|
|
41
|
+
rpc processingWithdrawalWebHook(WithdrawalWebHookRequest) returns (ProcessedWithdrawalResponse);
|
|
36
42
|
//Deposit Statuses
|
|
37
43
|
rpc readListDepositStatuses(PaginationRequest) returns (DepositStatusItemsResponse);
|
|
38
44
|
//User
|
|
39
45
|
rpc userPaymentsInfo(GetUserPaymentsInfoRequest) returns (UserPaymentsInfoResponse);
|
|
40
46
|
rpc userDepositHistory(GetUserPaymentsInfoRequest) returns (UserDepositItemsResponse);
|
|
47
|
+
rpc userWithdrawalHistory(GetUserPaymentsInfoRequest) returns (UserWithdrawalItemsResponse);
|
|
41
48
|
rpc getPaymentMethodsForUser(GetUserPaymentsInfoRequest) returns (UserPaymentMethodsResponse);
|
|
42
49
|
//Segmentation
|
|
43
50
|
rpc getSegmentedUsers(SegmentedUserRequest) returns (SegmentedUserResponse);
|
|
@@ -79,6 +86,7 @@ message PaymentSearchRequest {
|
|
|
79
86
|
repeated string operation_type = 15;
|
|
80
87
|
repeated string operation_reason_code = 16;
|
|
81
88
|
repeated string operation_status_code = 17;
|
|
89
|
+
repeated string withdrawal_status_code = 18;
|
|
82
90
|
}
|
|
83
91
|
message ItemsBunchRequest {
|
|
84
92
|
repeated int32 ids = 1;
|
|
@@ -343,6 +351,74 @@ message DepositRedirectFormRequest {
|
|
|
343
351
|
message DepositRedirectFormResponse {
|
|
344
352
|
string content = 1;
|
|
345
353
|
}
|
|
354
|
+
//Withdrawal
|
|
355
|
+
message AttemptWithdrawalRequest {
|
|
356
|
+
int32 payment_method_id = 1;
|
|
357
|
+
int32 user_id = 2;
|
|
358
|
+
float amount = 3;
|
|
359
|
+
optional string user_currency = 4;
|
|
360
|
+
optional string user_country = 5;
|
|
361
|
+
optional string origin_country = 6;
|
|
362
|
+
optional string user_ip = 7;
|
|
363
|
+
optional string user_locale = 8;
|
|
364
|
+
optional string user_first_name = 9;
|
|
365
|
+
optional string user_last_name = 10;
|
|
366
|
+
optional string user_email = 11;
|
|
367
|
+
optional string user_public_id = 12;
|
|
368
|
+
optional string destination = 13;
|
|
369
|
+
optional string destination_type = 14;
|
|
370
|
+
optional string destination_details = 15;
|
|
371
|
+
optional string token_id = 16;
|
|
372
|
+
}
|
|
373
|
+
message GetWithdrawalRequest {
|
|
374
|
+
int32 id = 1;
|
|
375
|
+
optional string status_code = 2;
|
|
376
|
+
optional int32 maker_id = 3;
|
|
377
|
+
optional string reason = 4;
|
|
378
|
+
}
|
|
379
|
+
message WithdrawalResponse {
|
|
380
|
+
int32 id = 1;
|
|
381
|
+
optional int32 user_id = 2;
|
|
382
|
+
optional string status = 3;
|
|
383
|
+
optional float amount = 4;
|
|
384
|
+
optional float fee = 5;
|
|
385
|
+
optional string currency = 6;
|
|
386
|
+
optional string payment_method_title = 7;
|
|
387
|
+
optional string payment_provider_image = 8;
|
|
388
|
+
optional string created = 9;
|
|
389
|
+
optional string destination = 10;
|
|
390
|
+
optional string destination_type = 11;
|
|
391
|
+
optional string external_ref = 12;
|
|
392
|
+
optional string country = 13;
|
|
393
|
+
}
|
|
394
|
+
message WithdrawalItem {
|
|
395
|
+
int32 id = 1;
|
|
396
|
+
int32 user_id = 2;
|
|
397
|
+
string status = 3;
|
|
398
|
+
float amount = 4;
|
|
399
|
+
float fee = 5;
|
|
400
|
+
string currency = 6;
|
|
401
|
+
optional string payment_method_title = 7;
|
|
402
|
+
optional string payment_provider_image = 8;
|
|
403
|
+
optional string created = 9;
|
|
404
|
+
optional string destination = 10;
|
|
405
|
+
optional string destination_type = 11;
|
|
406
|
+
optional string external_ref = 12;
|
|
407
|
+
optional string country = 13;
|
|
408
|
+
}
|
|
409
|
+
message WithdrawalItemsResponse {
|
|
410
|
+
repeated WithdrawalItem items = 1;
|
|
411
|
+
optional int32 total_pages = 2;
|
|
412
|
+
optional int32 total_items = 3;
|
|
413
|
+
}
|
|
414
|
+
message WithdrawalWebHookRequest {
|
|
415
|
+
string method = 1;
|
|
416
|
+
string data = 2;
|
|
417
|
+
optional string headers = 3;
|
|
418
|
+
}
|
|
419
|
+
message ProcessedWithdrawalResponse {
|
|
420
|
+
string status = 1;
|
|
421
|
+
}
|
|
346
422
|
//Deposit Status
|
|
347
423
|
message DepositStatus {
|
|
348
424
|
int32 id = 1;
|
|
@@ -400,6 +476,26 @@ message UserDepositItemsResponse {
|
|
|
400
476
|
optional int32 total_pages = 2;
|
|
401
477
|
optional int32 total_items = 3;
|
|
402
478
|
}
|
|
479
|
+
message UserWithdrawalItem {
|
|
480
|
+
int32 withdrawal_id = 1;
|
|
481
|
+
float amount = 2;
|
|
482
|
+
float fee = 3;
|
|
483
|
+
string currency = 4;
|
|
484
|
+
optional string payment_method_title = 5;
|
|
485
|
+
optional string payment_provider_image = 6;
|
|
486
|
+
optional string payment_provider_image_cdn = 7;
|
|
487
|
+
optional string payment_provider_title = 8;
|
|
488
|
+
optional string created = 9;
|
|
489
|
+
optional string status = 10;
|
|
490
|
+
optional string destination = 11;
|
|
491
|
+
optional string destination_type = 12;
|
|
492
|
+
optional string external_ref = 13;
|
|
493
|
+
}
|
|
494
|
+
message UserWithdrawalItemsResponse {
|
|
495
|
+
repeated UserWithdrawalItem items = 1;
|
|
496
|
+
optional int32 total_pages = 2;
|
|
497
|
+
optional int32 total_items = 3;
|
|
498
|
+
}
|
|
403
499
|
//Users
|
|
404
500
|
message UserPaymentMethodItem {
|
|
405
501
|
int32 method_id = 1;
|
|
@@ -15,6 +15,17 @@ function deserialize_payment_AttemptDepositRequest(buffer_arg) {
|
|
|
15
15
|
return payment_pb.AttemptDepositRequest.deserializeBinary(new Uint8Array(buffer_arg));
|
|
16
16
|
}
|
|
17
17
|
|
|
18
|
+
function serialize_payment_AttemptWithdrawalRequest(arg) {
|
|
19
|
+
if (!(arg instanceof payment_pb.AttemptWithdrawalRequest)) {
|
|
20
|
+
throw new Error('Expected argument of type payment.AttemptWithdrawalRequest');
|
|
21
|
+
}
|
|
22
|
+
return Buffer.from(arg.serializeBinary());
|
|
23
|
+
}
|
|
24
|
+
|
|
25
|
+
function deserialize_payment_AttemptWithdrawalRequest(buffer_arg) {
|
|
26
|
+
return payment_pb.AttemptWithdrawalRequest.deserializeBinary(new Uint8Array(buffer_arg));
|
|
27
|
+
}
|
|
28
|
+
|
|
18
29
|
function serialize_payment_CurrencyItemsResponse(arg) {
|
|
19
30
|
if (!(arg instanceof payment_pb.CurrencyItemsResponse)) {
|
|
20
31
|
throw new Error('Expected argument of type payment.CurrencyItemsResponse');
|
|
@@ -224,6 +235,17 @@ function deserialize_payment_GetUserPaymentsInfoRequest(buffer_arg) {
|
|
|
224
235
|
return payment_pb.GetUserPaymentsInfoRequest.deserializeBinary(new Uint8Array(buffer_arg));
|
|
225
236
|
}
|
|
226
237
|
|
|
238
|
+
function serialize_payment_GetWithdrawalRequest(arg) {
|
|
239
|
+
if (!(arg instanceof payment_pb.GetWithdrawalRequest)) {
|
|
240
|
+
throw new Error('Expected argument of type payment.GetWithdrawalRequest');
|
|
241
|
+
}
|
|
242
|
+
return Buffer.from(arg.serializeBinary());
|
|
243
|
+
}
|
|
244
|
+
|
|
245
|
+
function deserialize_payment_GetWithdrawalRequest(buffer_arg) {
|
|
246
|
+
return payment_pb.GetWithdrawalRequest.deserializeBinary(new Uint8Array(buffer_arg));
|
|
247
|
+
}
|
|
248
|
+
|
|
227
249
|
function serialize_payment_ItemsBunchRequest(arg) {
|
|
228
250
|
if (!(arg instanceof payment_pb.ItemsBunchRequest)) {
|
|
229
251
|
throw new Error('Expected argument of type payment.ItemsBunchRequest');
|
|
@@ -378,6 +400,17 @@ function deserialize_payment_ProcessedDepositResponse(buffer_arg) {
|
|
|
378
400
|
return payment_pb.ProcessedDepositResponse.deserializeBinary(new Uint8Array(buffer_arg));
|
|
379
401
|
}
|
|
380
402
|
|
|
403
|
+
function serialize_payment_ProcessedWithdrawalResponse(arg) {
|
|
404
|
+
if (!(arg instanceof payment_pb.ProcessedWithdrawalResponse)) {
|
|
405
|
+
throw new Error('Expected argument of type payment.ProcessedWithdrawalResponse');
|
|
406
|
+
}
|
|
407
|
+
return Buffer.from(arg.serializeBinary());
|
|
408
|
+
}
|
|
409
|
+
|
|
410
|
+
function deserialize_payment_ProcessedWithdrawalResponse(buffer_arg) {
|
|
411
|
+
return payment_pb.ProcessedWithdrawalResponse.deserializeBinary(new Uint8Array(buffer_arg));
|
|
412
|
+
}
|
|
413
|
+
|
|
381
414
|
function serialize_payment_ProviderItemsResponse(arg) {
|
|
382
415
|
if (!(arg instanceof payment_pb.ProviderItemsResponse)) {
|
|
383
416
|
throw new Error('Expected argument of type payment.ProviderItemsResponse');
|
|
@@ -499,6 +532,50 @@ function deserialize_payment_UserPaymentsInfoResponse(buffer_arg) {
|
|
|
499
532
|
return payment_pb.UserPaymentsInfoResponse.deserializeBinary(new Uint8Array(buffer_arg));
|
|
500
533
|
}
|
|
501
534
|
|
|
535
|
+
function serialize_payment_UserWithdrawalItemsResponse(arg) {
|
|
536
|
+
if (!(arg instanceof payment_pb.UserWithdrawalItemsResponse)) {
|
|
537
|
+
throw new Error('Expected argument of type payment.UserWithdrawalItemsResponse');
|
|
538
|
+
}
|
|
539
|
+
return Buffer.from(arg.serializeBinary());
|
|
540
|
+
}
|
|
541
|
+
|
|
542
|
+
function deserialize_payment_UserWithdrawalItemsResponse(buffer_arg) {
|
|
543
|
+
return payment_pb.UserWithdrawalItemsResponse.deserializeBinary(new Uint8Array(buffer_arg));
|
|
544
|
+
}
|
|
545
|
+
|
|
546
|
+
function serialize_payment_WithdrawalItemsResponse(arg) {
|
|
547
|
+
if (!(arg instanceof payment_pb.WithdrawalItemsResponse)) {
|
|
548
|
+
throw new Error('Expected argument of type payment.WithdrawalItemsResponse');
|
|
549
|
+
}
|
|
550
|
+
return Buffer.from(arg.serializeBinary());
|
|
551
|
+
}
|
|
552
|
+
|
|
553
|
+
function deserialize_payment_WithdrawalItemsResponse(buffer_arg) {
|
|
554
|
+
return payment_pb.WithdrawalItemsResponse.deserializeBinary(new Uint8Array(buffer_arg));
|
|
555
|
+
}
|
|
556
|
+
|
|
557
|
+
function serialize_payment_WithdrawalResponse(arg) {
|
|
558
|
+
if (!(arg instanceof payment_pb.WithdrawalResponse)) {
|
|
559
|
+
throw new Error('Expected argument of type payment.WithdrawalResponse');
|
|
560
|
+
}
|
|
561
|
+
return Buffer.from(arg.serializeBinary());
|
|
562
|
+
}
|
|
563
|
+
|
|
564
|
+
function deserialize_payment_WithdrawalResponse(buffer_arg) {
|
|
565
|
+
return payment_pb.WithdrawalResponse.deserializeBinary(new Uint8Array(buffer_arg));
|
|
566
|
+
}
|
|
567
|
+
|
|
568
|
+
function serialize_payment_WithdrawalWebHookRequest(arg) {
|
|
569
|
+
if (!(arg instanceof payment_pb.WithdrawalWebHookRequest)) {
|
|
570
|
+
throw new Error('Expected argument of type payment.WithdrawalWebHookRequest');
|
|
571
|
+
}
|
|
572
|
+
return Buffer.from(arg.serializeBinary());
|
|
573
|
+
}
|
|
574
|
+
|
|
575
|
+
function deserialize_payment_WithdrawalWebHookRequest(buffer_arg) {
|
|
576
|
+
return payment_pb.WithdrawalWebHookRequest.deserializeBinary(new Uint8Array(buffer_arg));
|
|
577
|
+
}
|
|
578
|
+
|
|
502
579
|
|
|
503
580
|
var PaymentService = exports.PaymentService = {
|
|
504
581
|
checkConnection: {
|
|
@@ -791,6 +868,62 @@ attemptDeposit: {
|
|
|
791
868
|
responseSerialize: serialize_payment_DepositRedirectFormResponse,
|
|
792
869
|
responseDeserialize: deserialize_payment_DepositRedirectFormResponse,
|
|
793
870
|
},
|
|
871
|
+
// Withdrawal
|
|
872
|
+
attemptWithdrawal: {
|
|
873
|
+
path: '/payment.Payment/attemptWithdrawal',
|
|
874
|
+
requestStream: false,
|
|
875
|
+
responseStream: false,
|
|
876
|
+
requestType: payment_pb.AttemptWithdrawalRequest,
|
|
877
|
+
responseType: payment_pb.WithdrawalResponse,
|
|
878
|
+
requestSerialize: serialize_payment_AttemptWithdrawalRequest,
|
|
879
|
+
requestDeserialize: deserialize_payment_AttemptWithdrawalRequest,
|
|
880
|
+
responseSerialize: serialize_payment_WithdrawalResponse,
|
|
881
|
+
responseDeserialize: deserialize_payment_WithdrawalResponse,
|
|
882
|
+
},
|
|
883
|
+
changeWithdrawalStatus: {
|
|
884
|
+
path: '/payment.Payment/changeWithdrawalStatus',
|
|
885
|
+
requestStream: false,
|
|
886
|
+
responseStream: false,
|
|
887
|
+
requestType: payment_pb.GetWithdrawalRequest,
|
|
888
|
+
responseType: payment_pb.WithdrawalResponse,
|
|
889
|
+
requestSerialize: serialize_payment_GetWithdrawalRequest,
|
|
890
|
+
requestDeserialize: deserialize_payment_GetWithdrawalRequest,
|
|
891
|
+
responseSerialize: serialize_payment_WithdrawalResponse,
|
|
892
|
+
responseDeserialize: deserialize_payment_WithdrawalResponse,
|
|
893
|
+
},
|
|
894
|
+
readListWithdrawals: {
|
|
895
|
+
path: '/payment.Payment/readListWithdrawals',
|
|
896
|
+
requestStream: false,
|
|
897
|
+
responseStream: false,
|
|
898
|
+
requestType: payment_pb.PaginationRequest,
|
|
899
|
+
responseType: payment_pb.WithdrawalItemsResponse,
|
|
900
|
+
requestSerialize: serialize_payment_PaginationRequest,
|
|
901
|
+
requestDeserialize: deserialize_payment_PaginationRequest,
|
|
902
|
+
responseSerialize: serialize_payment_WithdrawalItemsResponse,
|
|
903
|
+
responseDeserialize: deserialize_payment_WithdrawalItemsResponse,
|
|
904
|
+
},
|
|
905
|
+
readSingleWithdrawal: {
|
|
906
|
+
path: '/payment.Payment/readSingleWithdrawal',
|
|
907
|
+
requestStream: false,
|
|
908
|
+
responseStream: false,
|
|
909
|
+
requestType: payment_pb.GetWithdrawalRequest,
|
|
910
|
+
responseType: payment_pb.WithdrawalResponse,
|
|
911
|
+
requestSerialize: serialize_payment_GetWithdrawalRequest,
|
|
912
|
+
requestDeserialize: deserialize_payment_GetWithdrawalRequest,
|
|
913
|
+
responseSerialize: serialize_payment_WithdrawalResponse,
|
|
914
|
+
responseDeserialize: deserialize_payment_WithdrawalResponse,
|
|
915
|
+
},
|
|
916
|
+
processingWithdrawalWebHook: {
|
|
917
|
+
path: '/payment.Payment/processingWithdrawalWebHook',
|
|
918
|
+
requestStream: false,
|
|
919
|
+
responseStream: false,
|
|
920
|
+
requestType: payment_pb.WithdrawalWebHookRequest,
|
|
921
|
+
responseType: payment_pb.ProcessedWithdrawalResponse,
|
|
922
|
+
requestSerialize: serialize_payment_WithdrawalWebHookRequest,
|
|
923
|
+
requestDeserialize: deserialize_payment_WithdrawalWebHookRequest,
|
|
924
|
+
responseSerialize: serialize_payment_ProcessedWithdrawalResponse,
|
|
925
|
+
responseDeserialize: deserialize_payment_ProcessedWithdrawalResponse,
|
|
926
|
+
},
|
|
794
927
|
// Deposit Statuses
|
|
795
928
|
readListDepositStatuses: {
|
|
796
929
|
path: '/payment.Payment/readListDepositStatuses',
|
|
@@ -826,6 +959,17 @@ userPaymentsInfo: {
|
|
|
826
959
|
responseSerialize: serialize_payment_UserDepositItemsResponse,
|
|
827
960
|
responseDeserialize: deserialize_payment_UserDepositItemsResponse,
|
|
828
961
|
},
|
|
962
|
+
userWithdrawalHistory: {
|
|
963
|
+
path: '/payment.Payment/userWithdrawalHistory',
|
|
964
|
+
requestStream: false,
|
|
965
|
+
responseStream: false,
|
|
966
|
+
requestType: payment_pb.GetUserPaymentsInfoRequest,
|
|
967
|
+
responseType: payment_pb.UserWithdrawalItemsResponse,
|
|
968
|
+
requestSerialize: serialize_payment_GetUserPaymentsInfoRequest,
|
|
969
|
+
requestDeserialize: deserialize_payment_GetUserPaymentsInfoRequest,
|
|
970
|
+
responseSerialize: serialize_payment_UserWithdrawalItemsResponse,
|
|
971
|
+
responseDeserialize: deserialize_payment_UserWithdrawalItemsResponse,
|
|
972
|
+
},
|
|
829
973
|
getPaymentMethodsForUser: {
|
|
830
974
|
path: '/payment.Payment/getPaymentMethodsForUser',
|
|
831
975
|
requestStream: false,
|