protobuf-platform 1.2.658 → 1.2.659
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 +68 -1
- package/payment/payment_grpc_pb.js +33 -0
- package/payment/payment_pb.js +2221 -3
- package/scripts/verify-precision-rg-contract.js +180 -0
- package/user/user.proto +57 -1
- package/user/user_grpc_pb.js +33 -0
- package/user/user_pb.js +1188 -0
package/package.json
CHANGED
package/payment/payment.proto
CHANGED
|
@@ -83,6 +83,8 @@ service Payment {
|
|
|
83
83
|
rpc readListConfiscations(PaginationRequest) returns (ConfiscationItemsResponse);
|
|
84
84
|
rpc createAdjustment(AdjustmentRequest) returns (FinancialOperationResponse);
|
|
85
85
|
rpc readListAdjustments(PaginationRequest) returns (AdjustmentItemsResponse);
|
|
86
|
+
rpc prepareGameplayPrecisionCommand(PrepareGameplayPrecisionCommandRequest)
|
|
87
|
+
returns (PrepareGameplayPrecisionCommandResponse);
|
|
86
88
|
}
|
|
87
89
|
//Technical
|
|
88
90
|
message PingRequest { string ping = 1; }
|
|
@@ -1275,9 +1277,12 @@ message ExecuteGameplayPrecisionCommandRequest {
|
|
|
1275
1277
|
string command_id = 2;
|
|
1276
1278
|
string callback_action = 3;
|
|
1277
1279
|
repeated GameplayPrecisionLeg legs = 4;
|
|
1280
|
+
string preparation_generation = 5;
|
|
1281
|
+
string preparation_fingerprint = 6;
|
|
1282
|
+
GameplayPrecisionRgEvidence rg_admission = 7;
|
|
1278
1283
|
}
|
|
1279
1284
|
message GameplayPrecisionResult {
|
|
1280
|
-
string status = 1; // ok | ineligible | insufficient_funds | conflict | closed
|
|
1285
|
+
string status = 1; // ok | ineligible | insufficient_funds | conflict | closed | STALE_PREPARATION
|
|
1281
1286
|
string precision_session_id = 2;
|
|
1282
1287
|
string context_fingerprint = 3;
|
|
1283
1288
|
uint32 precision_model_version = 4;
|
|
@@ -1293,4 +1298,66 @@ message GameplayPrecisionResult {
|
|
|
1293
1298
|
string provider_balance_denominator = 14;
|
|
1294
1299
|
string provider_balance_decimal = 15; // Populated only under the bound response policy.
|
|
1295
1300
|
string response_policy_version = 16;
|
|
1301
|
+
repeated GameplayPrecisionAccountingLeg accounting_legs = 17;
|
|
1302
|
+
string preparation_generation = 18;
|
|
1303
|
+
string preparation_fingerprint = 19;
|
|
1304
|
+
string command_key = 20;
|
|
1305
|
+
string request_fingerprint = 21;
|
|
1306
|
+
}
|
|
1307
|
+
|
|
1308
|
+
enum GameplayPrecisionPrepareMode {
|
|
1309
|
+
GAMEPLAY_PRECISION_PREPARE_UNSPECIFIED = 0;
|
|
1310
|
+
GAMEPLAY_PRECISION_PREPARE_INITIAL = 1;
|
|
1311
|
+
GAMEPLAY_PRECISION_REPREPARE = 2;
|
|
1312
|
+
}
|
|
1313
|
+
message GameplayPrecisionRgEvidence {
|
|
1314
|
+
string command_key = 1;
|
|
1315
|
+
string request_fingerprint = 2;
|
|
1316
|
+
string preparation_generation = 3;
|
|
1317
|
+
string preparation_fingerprint = 4;
|
|
1318
|
+
string accounting_currency = 5;
|
|
1319
|
+
uint32 accounting_scale = 6;
|
|
1320
|
+
string requested_debit_minor = 7;
|
|
1321
|
+
string state = 8; // RESERVED or RELEASED, strictly validated.
|
|
1322
|
+
string receipt_id = 9; // Admission receipt or release receipt, per state.
|
|
1323
|
+
}
|
|
1324
|
+
message GameplayPrecisionAccountingLeg {
|
|
1325
|
+
string action = 1;
|
|
1326
|
+
string provider_transaction_id = 2;
|
|
1327
|
+
string integer_delta_minor = 3;
|
|
1328
|
+
string fractional_delta_numerator = 4;
|
|
1329
|
+
string fractional_delta_denominator = 5;
|
|
1330
|
+
string accounting_currency = 6;
|
|
1331
|
+
uint32 accounting_scale = 7;
|
|
1332
|
+
string payment_operation_id = 8; // Empty before commit.
|
|
1333
|
+
string original_transaction_id = 9;
|
|
1334
|
+
string original_action = 10;
|
|
1335
|
+
}
|
|
1336
|
+
message GameplayPrecisionPreparation {
|
|
1337
|
+
string command_key = 1;
|
|
1338
|
+
string request_fingerprint = 2;
|
|
1339
|
+
string generation = 3;
|
|
1340
|
+
string fingerprint = 4;
|
|
1341
|
+
string cash_ledger_entry_id = 5; // Empty means no cash entry, not invented zero.
|
|
1342
|
+
string precision_version = 6;
|
|
1343
|
+
string accounting_currency = 7;
|
|
1344
|
+
uint32 accounting_scale = 8;
|
|
1345
|
+
string requested_debit_minor = 9;
|
|
1346
|
+
repeated GameplayPrecisionAccountingLeg accounting_legs = 10;
|
|
1347
|
+
bool requires_rg_admission = 11;
|
|
1348
|
+
}
|
|
1349
|
+
message PrepareGameplayPrecisionCommandRequest {
|
|
1350
|
+
ExecuteGameplayPrecisionCommandRequest command = 1;
|
|
1351
|
+
GameplayPrecisionPrepareMode mode = 2;
|
|
1352
|
+
string reprepare_request_id = 3;
|
|
1353
|
+
string expected_generation = 4;
|
|
1354
|
+
string expected_preparation_fingerprint = 5;
|
|
1355
|
+
GameplayPrecisionRgEvidence previous_release = 6;
|
|
1356
|
+
}
|
|
1357
|
+
message PrepareGameplayPrecisionCommandResponse {
|
|
1358
|
+
string status = 1; // PREPARED | STALE_PREPARATION | RELEASE_REQUIRED |
|
|
1359
|
+
// COMMITTED | REJECTED | CONFLICT
|
|
1360
|
+
GameplayPrecisionPreparation preparation = 2;
|
|
1361
|
+
GameplayPrecisionResult committed_result = 3;
|
|
1362
|
+
string reason_key = 4;
|
|
1296
1363
|
}
|
|
@@ -752,6 +752,28 @@ function deserialize_payment_PoorMethodsRequest(buffer_arg) {
|
|
|
752
752
|
return payment_pb.PoorMethodsRequest.deserializeBinary(new Uint8Array(buffer_arg));
|
|
753
753
|
}
|
|
754
754
|
|
|
755
|
+
function serialize_payment_PrepareGameplayPrecisionCommandRequest(arg) {
|
|
756
|
+
if (!(arg instanceof payment_pb.PrepareGameplayPrecisionCommandRequest)) {
|
|
757
|
+
throw new Error('Expected argument of type payment.PrepareGameplayPrecisionCommandRequest');
|
|
758
|
+
}
|
|
759
|
+
return Buffer.from(arg.serializeBinary());
|
|
760
|
+
}
|
|
761
|
+
|
|
762
|
+
function deserialize_payment_PrepareGameplayPrecisionCommandRequest(buffer_arg) {
|
|
763
|
+
return payment_pb.PrepareGameplayPrecisionCommandRequest.deserializeBinary(new Uint8Array(buffer_arg));
|
|
764
|
+
}
|
|
765
|
+
|
|
766
|
+
function serialize_payment_PrepareGameplayPrecisionCommandResponse(arg) {
|
|
767
|
+
if (!(arg instanceof payment_pb.PrepareGameplayPrecisionCommandResponse)) {
|
|
768
|
+
throw new Error('Expected argument of type payment.PrepareGameplayPrecisionCommandResponse');
|
|
769
|
+
}
|
|
770
|
+
return Buffer.from(arg.serializeBinary());
|
|
771
|
+
}
|
|
772
|
+
|
|
773
|
+
function deserialize_payment_PrepareGameplayPrecisionCommandResponse(buffer_arg) {
|
|
774
|
+
return payment_pb.PrepareGameplayPrecisionCommandResponse.deserializeBinary(new Uint8Array(buffer_arg));
|
|
775
|
+
}
|
|
776
|
+
|
|
755
777
|
function serialize_payment_ProcessedDepositResponse(arg) {
|
|
756
778
|
if (!(arg instanceof payment_pb.ProcessedDepositResponse)) {
|
|
757
779
|
throw new Error('Expected argument of type payment.ProcessedDepositResponse');
|
|
@@ -1757,6 +1779,17 @@ createManualDeposit: {
|
|
|
1757
1779
|
responseSerialize: serialize_payment_AdjustmentItemsResponse,
|
|
1758
1780
|
responseDeserialize: deserialize_payment_AdjustmentItemsResponse,
|
|
1759
1781
|
},
|
|
1782
|
+
prepareGameplayPrecisionCommand: {
|
|
1783
|
+
path: '/payment.Payment/prepareGameplayPrecisionCommand',
|
|
1784
|
+
requestStream: false,
|
|
1785
|
+
responseStream: false,
|
|
1786
|
+
requestType: payment_pb.PrepareGameplayPrecisionCommandRequest,
|
|
1787
|
+
responseType: payment_pb.PrepareGameplayPrecisionCommandResponse,
|
|
1788
|
+
requestSerialize: serialize_payment_PrepareGameplayPrecisionCommandRequest,
|
|
1789
|
+
requestDeserialize: deserialize_payment_PrepareGameplayPrecisionCommandRequest,
|
|
1790
|
+
responseSerialize: serialize_payment_PrepareGameplayPrecisionCommandResponse,
|
|
1791
|
+
responseDeserialize: deserialize_payment_PrepareGameplayPrecisionCommandResponse,
|
|
1792
|
+
},
|
|
1760
1793
|
};
|
|
1761
1794
|
|
|
1762
1795
|
exports.PaymentClient = grpc.makeGenericClientConstructor(PaymentService, 'Payment');
|