@mysten/sui 2.16.3 → 2.18.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.
Files changed (138) hide show
  1. package/CHANGELOG.md +36 -0
  2. package/dist/bcs/bcs.d.mts +6 -6
  3. package/dist/bcs/index.d.mts +20 -20
  4. package/dist/graphql/generated/queries.d.mts.map +1 -1
  5. package/dist/graphql/generated/queries.mjs.map +1 -1
  6. package/dist/graphql/generated/tada-env.d.mts +82 -1
  7. package/dist/grpc/client.d.mts +2 -0
  8. package/dist/grpc/client.d.mts.map +1 -1
  9. package/dist/grpc/client.mjs +2 -0
  10. package/dist/grpc/client.mjs.map +1 -1
  11. package/dist/grpc/proto/google/protobuf/struct.mjs +1 -1
  12. package/dist/grpc/proto/google/protobuf/struct.mjs.map +1 -1
  13. package/dist/grpc/proto/google/rpc/status.mjs +1 -1
  14. package/dist/grpc/proto/google/rpc/status.mjs.map +1 -1
  15. package/dist/grpc/proto/sui/forking/v1alpha/forking_service.client.d.mts +66 -0
  16. package/dist/grpc/proto/sui/forking/v1alpha/forking_service.client.d.mts.map +1 -0
  17. package/dist/grpc/proto/sui/forking/v1alpha/forking_service.client.mjs +48 -0
  18. package/dist/grpc/proto/sui/forking/v1alpha/forking_service.client.mjs.map +1 -0
  19. package/dist/grpc/proto/sui/forking/v1alpha/forking_service.d.mts +135 -0
  20. package/dist/grpc/proto/sui/forking/v1alpha/forking_service.d.mts.map +1 -0
  21. package/dist/grpc/proto/sui/forking/v1alpha/forking_service.mjs +144 -0
  22. package/dist/grpc/proto/sui/forking/v1alpha/forking_service.mjs.map +1 -0
  23. package/dist/grpc/proto/sui/rpc/v2/checkpoint.mjs +1 -1
  24. package/dist/grpc/proto/sui/rpc/v2/checkpoint.mjs.map +1 -1
  25. package/dist/grpc/proto/sui/rpc/v2/checkpoint_contents.mjs +3 -3
  26. package/dist/grpc/proto/sui/rpc/v2/checkpoint_contents.mjs.map +1 -1
  27. package/dist/grpc/proto/sui/rpc/v2/checkpoint_summary.mjs +3 -3
  28. package/dist/grpc/proto/sui/rpc/v2/checkpoint_summary.mjs.map +1 -1
  29. package/dist/grpc/proto/sui/rpc/v2/effects.d.mts +71 -3
  30. package/dist/grpc/proto/sui/rpc/v2/effects.d.mts.map +1 -1
  31. package/dist/grpc/proto/sui/rpc/v2/effects.mjs +71 -5
  32. package/dist/grpc/proto/sui/rpc/v2/effects.mjs.map +1 -1
  33. package/dist/grpc/proto/sui/rpc/v2/event.mjs +1 -1
  34. package/dist/grpc/proto/sui/rpc/v2/event.mjs.map +1 -1
  35. package/dist/grpc/proto/sui/rpc/v2/executed_transaction.mjs +2 -2
  36. package/dist/grpc/proto/sui/rpc/v2/executed_transaction.mjs.map +1 -1
  37. package/dist/grpc/proto/sui/rpc/v2/ledger_service.client.d.mts +4 -4
  38. package/dist/grpc/proto/sui/rpc/v2/ledger_service.mjs +3 -3
  39. package/dist/grpc/proto/sui/rpc/v2/ledger_service.mjs.map +1 -1
  40. package/dist/grpc/proto/sui/rpc/v2/move_package.d.mts.map +1 -1
  41. package/dist/grpc/proto/sui/rpc/v2/move_package.mjs +13 -13
  42. package/dist/grpc/proto/sui/rpc/v2/move_package.mjs.map +1 -1
  43. package/dist/grpc/proto/sui/rpc/v2/move_package_service.client.d.mts +4 -4
  44. package/dist/grpc/proto/sui/rpc/v2/move_package_service.mjs +1 -1
  45. package/dist/grpc/proto/sui/rpc/v2/move_package_service.mjs.map +1 -1
  46. package/dist/grpc/proto/sui/rpc/v2/name_service.client.d.mts +4 -4
  47. package/dist/grpc/proto/sui/rpc/v2/object.d.mts.map +1 -1
  48. package/dist/grpc/proto/sui/rpc/v2/object.mjs +1 -1
  49. package/dist/grpc/proto/sui/rpc/v2/object.mjs.map +1 -1
  50. package/dist/grpc/proto/sui/rpc/v2/signature.mjs +3 -3
  51. package/dist/grpc/proto/sui/rpc/v2/signature.mjs.map +1 -1
  52. package/dist/grpc/proto/sui/rpc/v2/signature_verification_service.client.d.mts +4 -4
  53. package/dist/grpc/proto/sui/rpc/v2/signature_verification_service.d.mts.map +1 -1
  54. package/dist/grpc/proto/sui/rpc/v2/signature_verification_service.mjs +1 -1
  55. package/dist/grpc/proto/sui/rpc/v2/signature_verification_service.mjs.map +1 -1
  56. package/dist/grpc/proto/sui/rpc/v2/state_service.client.d.mts +4 -4
  57. package/dist/grpc/proto/sui/rpc/v2/state_service.d.mts.map +1 -1
  58. package/dist/grpc/proto/sui/rpc/v2/state_service.mjs +3 -3
  59. package/dist/grpc/proto/sui/rpc/v2/state_service.mjs.map +1 -1
  60. package/dist/grpc/proto/sui/rpc/v2/subscription_service.client.d.mts +4 -4
  61. package/dist/grpc/proto/sui/rpc/v2/system_state.mjs +2 -2
  62. package/dist/grpc/proto/sui/rpc/v2/system_state.mjs.map +1 -1
  63. package/dist/grpc/proto/sui/rpc/v2/transaction.d.mts.map +1 -1
  64. package/dist/grpc/proto/sui/rpc/v2/transaction.mjs +16 -16
  65. package/dist/grpc/proto/sui/rpc/v2/transaction.mjs.map +1 -1
  66. package/dist/grpc/proto/sui/rpc/v2/transaction_execution_service.mjs +4 -4
  67. package/dist/grpc/proto/sui/rpc/v2/transaction_execution_service.mjs.map +1 -1
  68. package/dist/grpc/proto/types.d.mts +3 -2
  69. package/dist/grpc/proto/types.mjs +11 -1
  70. package/dist/grpc/proto/types.mjs.map +1 -1
  71. package/dist/jsonRpc/types/params.d.mts +5 -5
  72. package/dist/transactions/Transaction.d.mts +25 -11
  73. package/dist/transactions/Transaction.d.mts.map +1 -1
  74. package/dist/transactions/Transaction.mjs +8 -3
  75. package/dist/transactions/Transaction.mjs.map +1 -1
  76. package/dist/transactions/index.d.mts +2 -2
  77. package/dist/version.mjs +1 -1
  78. package/dist/version.mjs.map +1 -1
  79. package/dist/zklogin/jwt-utils.d.mts.map +1 -1
  80. package/dist/zklogin/jwt-utils.mjs.map +1 -1
  81. package/dist/zklogin/utils.d.mts.map +1 -1
  82. package/dist/zklogin/utils.mjs +9 -0
  83. package/dist/zklogin/utils.mjs.map +1 -1
  84. package/docs/bcs.md +11 -6
  85. package/docs/clients/core.md +10 -9
  86. package/docs/clients/grpc.md +1 -1
  87. package/docs/index.md +176 -22
  88. package/docs/llms-index.md +6 -9
  89. package/docs/migrations/0.38.md +2 -2
  90. package/docs/migrations/sui-1.0.md +2 -2
  91. package/docs/migrations/sui-2.0/json-rpc-migration.md +76 -33
  92. package/docs/plugins.md +29 -5
  93. package/docs/transactions/basics.md +279 -0
  94. package/docs/transactions/coins-and-balances.md +293 -0
  95. package/docs/transactions/offline.md +192 -0
  96. package/docs/transactions/reference.md +380 -0
  97. package/docs/transactions/signing-and-execution.md +401 -0
  98. package/package.json +27 -27
  99. package/src/graphql/generated/queries.ts +46 -1
  100. package/src/graphql/generated/schema.graphql +49 -3
  101. package/src/graphql/generated/tada-env.ts +97 -1
  102. package/src/grpc/client.ts +3 -0
  103. package/src/grpc/proto/google/protobuf/struct.ts +1 -1
  104. package/src/grpc/proto/google/rpc/error_details.ts +4 -4
  105. package/src/grpc/proto/google/rpc/status.ts +1 -1
  106. package/src/grpc/proto/sui/forking/v1alpha/forking_service.client.ts +125 -0
  107. package/src/grpc/proto/sui/forking/v1alpha/forking_service.ts +230 -0
  108. package/src/grpc/proto/sui/rpc/v2/checkpoint.ts +1 -1
  109. package/src/grpc/proto/sui/rpc/v2/checkpoint_contents.ts +3 -3
  110. package/src/grpc/proto/sui/rpc/v2/checkpoint_summary.ts +3 -3
  111. package/src/grpc/proto/sui/rpc/v2/effects.ts +112 -6
  112. package/src/grpc/proto/sui/rpc/v2/event.ts +1 -1
  113. package/src/grpc/proto/sui/rpc/v2/executed_transaction.ts +2 -2
  114. package/src/grpc/proto/sui/rpc/v2/ledger_service.ts +3 -3
  115. package/src/grpc/proto/sui/rpc/v2/move_package.ts +19 -13
  116. package/src/grpc/proto/sui/rpc/v2/move_package_service.ts +1 -1
  117. package/src/grpc/proto/sui/rpc/v2/object.ts +7 -1
  118. package/src/grpc/proto/sui/rpc/v2/signature.ts +3 -3
  119. package/src/grpc/proto/sui/rpc/v2/signature_verification_service.ts +7 -1
  120. package/src/grpc/proto/sui/rpc/v2/state_service.ts +9 -3
  121. package/src/grpc/proto/sui/rpc/v2/system_state.ts +2 -2
  122. package/src/grpc/proto/sui/rpc/v2/transaction.ts +22 -16
  123. package/src/grpc/proto/sui/rpc/v2/transaction_execution_service.ts +4 -4
  124. package/src/grpc/proto/types.ts +1 -0
  125. package/src/jsonRpc/types/params.ts +5 -5
  126. package/src/transactions/Transaction.ts +36 -5
  127. package/src/transactions/index.ts +1 -0
  128. package/src/version.ts +1 -1
  129. package/src/zklogin/jwt-utils.ts +3 -0
  130. package/src/zklogin/utils.ts +17 -0
  131. package/docs/faucet.md +0 -26
  132. package/docs/hello-sui.md +0 -115
  133. package/docs/install.md +0 -61
  134. package/docs/transaction-building/basics.md +0 -299
  135. package/docs/transaction-building/gas.md +0 -61
  136. package/docs/transaction-building/intents.md +0 -62
  137. package/docs/transaction-building/offline.md +0 -73
  138. package/docs/transaction-building/sponsored-transactions.md +0 -22
@@ -5480,6 +5480,20 @@ const introspection = {
5480
5480
  "kind": "SCALAR",
5481
5481
  "name": "Int"
5482
5482
  },
5483
+ {
5484
+ "kind": "ENUM",
5485
+ "name": "IntentScope",
5486
+ "enumValues": [
5487
+ {
5488
+ "name": "TRANSACTION_DATA",
5489
+ "isDeprecated": false
5490
+ },
5491
+ {
5492
+ "name": "PERSONAL_MESSAGE",
5493
+ "isDeprecated": false
5494
+ }
5495
+ ]
5496
+ },
5483
5497
  {
5484
5498
  "kind": "SCALAR",
5485
5499
  "name": "JSON"
@@ -10555,6 +10569,13 @@ const introspection = {
10555
10569
  "name": "Checkpoint"
10556
10570
  },
10557
10571
  "args": [
10572
+ {
10573
+ "name": "digest",
10574
+ "type": {
10575
+ "kind": "SCALAR",
10576
+ "name": "String"
10577
+ }
10578
+ },
10558
10579
  {
10559
10580
  "name": "sequenceNumber",
10560
10581
  "type": {
@@ -11475,6 +11496,56 @@ const introspection = {
11475
11496
  ],
11476
11497
  "isDeprecated": false
11477
11498
  },
11499
+ {
11500
+ "name": "verifySignature",
11501
+ "type": {
11502
+ "kind": "OBJECT",
11503
+ "name": "SignatureVerifyResult"
11504
+ },
11505
+ "args": [
11506
+ {
11507
+ "name": "author",
11508
+ "type": {
11509
+ "kind": "NON_NULL",
11510
+ "ofType": {
11511
+ "kind": "SCALAR",
11512
+ "name": "SuiAddress"
11513
+ }
11514
+ }
11515
+ },
11516
+ {
11517
+ "name": "intentScope",
11518
+ "type": {
11519
+ "kind": "NON_NULL",
11520
+ "ofType": {
11521
+ "kind": "ENUM",
11522
+ "name": "IntentScope"
11523
+ }
11524
+ }
11525
+ },
11526
+ {
11527
+ "name": "message",
11528
+ "type": {
11529
+ "kind": "NON_NULL",
11530
+ "ofType": {
11531
+ "kind": "SCALAR",
11532
+ "name": "Base64"
11533
+ }
11534
+ }
11535
+ },
11536
+ {
11537
+ "name": "signature",
11538
+ "type": {
11539
+ "kind": "NON_NULL",
11540
+ "ofType": {
11541
+ "kind": "SCALAR",
11542
+ "name": "Base64"
11543
+ }
11544
+ }
11545
+ }
11546
+ ],
11547
+ "isDeprecated": false
11548
+ },
11478
11549
  {
11479
11550
  "name": "verifyZkLoginSignature",
11480
11551
  "type": {
@@ -11523,7 +11594,7 @@ const introspection = {
11523
11594
  }
11524
11595
  }
11525
11596
  ],
11526
- "isDeprecated": false
11597
+ "isDeprecated": true
11527
11598
  }
11528
11599
  ],
11529
11600
  "interfaces": []
@@ -12085,6 +12156,22 @@ const introspection = {
12085
12156
  }
12086
12157
  ]
12087
12158
  },
12159
+ {
12160
+ "kind": "OBJECT",
12161
+ "name": "SignatureVerifyResult",
12162
+ "fields": [
12163
+ {
12164
+ "name": "success",
12165
+ "type": {
12166
+ "kind": "SCALAR",
12167
+ "name": "Boolean"
12168
+ },
12169
+ "args": [],
12170
+ "isDeprecated": false
12171
+ }
12172
+ ],
12173
+ "interfaces": []
12174
+ },
12088
12175
  {
12089
12176
  "kind": "OBJECT",
12090
12177
  "name": "SimulationResult",
@@ -12722,6 +12809,15 @@ const introspection = {
12722
12809
  }
12723
12810
  ],
12724
12811
  "isDeprecated": false
12812
+ },
12813
+ {
12814
+ "name": "version",
12815
+ "type": {
12816
+ "kind": "SCALAR",
12817
+ "name": "Int"
12818
+ },
12819
+ "args": [],
12820
+ "isDeprecated": false
12725
12821
  }
12726
12822
  ],
12727
12823
  "interfaces": []
@@ -17,6 +17,7 @@ import { DynamicField_DynamicFieldKind } from './proto/sui/rpc/v2/state_service.
17
17
  import { normalizeStructTag } from '../utils/sui-types.js';
18
18
  import { fromBase64, toBase64 } from '@mysten/utils';
19
19
  import { NameServiceClient } from './proto/sui/rpc/v2/name_service.client.js';
20
+ import { ForkingServiceClient } from './proto/sui/forking/v1alpha/forking_service.client.js';
20
21
  import type { TransactionPlugin } from '../transactions/index.js';
21
22
 
22
23
  interface SuiGrpcTransportOptions extends GrpcWebOptions {
@@ -68,6 +69,7 @@ export class SuiGrpcClient extends BaseClient implements SuiClientTypes.Transpor
68
69
  movePackageService: MovePackageServiceClient;
69
70
  signatureVerificationService: SignatureVerificationServiceClient;
70
71
  nameService: NameServiceClient;
72
+ forkingService: ForkingServiceClient;
71
73
 
72
74
  get [SUI_CLIENT_BRAND]() {
73
75
  return true;
@@ -85,6 +87,7 @@ export class SuiGrpcClient extends BaseClient implements SuiClientTypes.Transpor
85
87
  this.movePackageService = new MovePackageServiceClient(transport);
86
88
  this.signatureVerificationService = new SignatureVerificationServiceClient(transport);
87
89
  this.nameService = new NameServiceClient(transport);
90
+ this.forkingService = new ForkingServiceClient(transport);
88
91
 
89
92
  this.core = new GrpcCoreClient({
90
93
  client: this,
@@ -298,7 +298,7 @@ export const Value = new Value$Type();
298
298
  class ListValue$Type extends MessageType<ListValue> {
299
299
  constructor() {
300
300
  super('google.protobuf.ListValue', [
301
- { no: 1, name: 'values', kind: 'message', repeat: 1 /*RepeatType.PACKED*/, T: () => Value },
301
+ { no: 1, name: 'values', kind: 'message', repeat: 2 /*RepeatType.UNPACKED*/, T: () => Value },
302
302
  ]);
303
303
  }
304
304
  /**
@@ -505,7 +505,7 @@ class QuotaFailure$Type extends MessageType<QuotaFailure> {
505
505
  no: 1,
506
506
  name: 'violations',
507
507
  kind: 'message',
508
- repeat: 1 /*RepeatType.PACKED*/,
508
+ repeat: 2 /*RepeatType.UNPACKED*/,
509
509
  T: () => QuotaFailure_Violation,
510
510
  },
511
511
  ]);
@@ -536,7 +536,7 @@ class PreconditionFailure$Type extends MessageType<PreconditionFailure> {
536
536
  no: 1,
537
537
  name: 'violations',
538
538
  kind: 'message',
539
- repeat: 1 /*RepeatType.PACKED*/,
539
+ repeat: 2 /*RepeatType.UNPACKED*/,
540
540
  T: () => PreconditionFailure_Violation,
541
541
  },
542
542
  ]);
@@ -568,7 +568,7 @@ class BadRequest$Type extends MessageType<BadRequest> {
568
568
  no: 1,
569
569
  name: 'field_violations',
570
570
  kind: 'message',
571
- repeat: 1 /*RepeatType.PACKED*/,
571
+ repeat: 2 /*RepeatType.UNPACKED*/,
572
572
  T: () => BadRequest_FieldViolation,
573
573
  },
574
574
  ]);
@@ -629,7 +629,7 @@ class Help$Type extends MessageType<Help> {
629
629
  no: 1,
630
630
  name: 'links',
631
631
  kind: 'message',
632
- repeat: 1 /*RepeatType.PACKED*/,
632
+ repeat: 2 /*RepeatType.UNPACKED*/,
633
633
  T: () => Help_Link,
634
634
  },
635
635
  ]);
@@ -64,7 +64,7 @@ class Status$Type extends MessageType<Status> {
64
64
  super('google.rpc.Status', [
65
65
  { no: 1, name: 'code', kind: 'scalar', T: 5 /*ScalarType.INT32*/ },
66
66
  { no: 2, name: 'message', kind: 'scalar', T: 9 /*ScalarType.STRING*/ },
67
- { no: 3, name: 'details', kind: 'message', repeat: 1 /*RepeatType.PACKED*/, T: () => Any },
67
+ { no: 3, name: 'details', kind: 'message', repeat: 2 /*RepeatType.UNPACKED*/, T: () => Any },
68
68
  ]);
69
69
  }
70
70
  }
@@ -0,0 +1,125 @@
1
+ // Copyright (c) Mysten Labs, Inc.
2
+ // SPDX-License-Identifier: Apache-2.0
3
+
4
+ // @generated by protobuf-ts 2.9.6 with parameter force_server_none,optimize_code_size,ts_nocheck
5
+ // @generated from protobuf file "sui/forking/v1alpha/forking_service.proto" (package "sui.forking.v1alpha", syntax proto3)
6
+ // tslint:disable
7
+ // @ts-nocheck
8
+ //
9
+ // Copyright (c) Mysten Labs, Inc.
10
+ // SPDX-License-Identifier: Apache-2.0
11
+ //
12
+ import type { RpcTransport } from '@protobuf-ts/runtime-rpc';
13
+ import type { ServiceInfo } from '@protobuf-ts/runtime-rpc';
14
+ import { ForkingService } from './forking_service.js';
15
+ import type { GetStatusResponse } from './forking_service.js';
16
+ import type { GetStatusRequest } from './forking_service.js';
17
+ import type { AdvanceCheckpointResponse } from './forking_service.js';
18
+ import type { AdvanceCheckpointRequest } from './forking_service.js';
19
+ import { stackIntercept } from '@protobuf-ts/runtime-rpc';
20
+ import type { AdvanceClockResponse } from './forking_service.js';
21
+ import type { AdvanceClockRequest } from './forking_service.js';
22
+ import type { UnaryCall } from '@protobuf-ts/runtime-rpc';
23
+ import type { RpcOptions } from '@protobuf-ts/runtime-rpc';
24
+ /**
25
+ * Administrative service for controlling a forked Sui network.
26
+ *
27
+ * @generated from protobuf service sui.forking.v1alpha.ForkingService
28
+ */
29
+ export interface IForkingServiceClient {
30
+ /**
31
+ * Advance the forked network's clock by a given duration.
32
+ *
33
+ * @generated from protobuf rpc: AdvanceClock(sui.forking.v1alpha.AdvanceClockRequest) returns (sui.forking.v1alpha.AdvanceClockResponse);
34
+ */
35
+ advanceClock(
36
+ input: AdvanceClockRequest,
37
+ options?: RpcOptions,
38
+ ): UnaryCall<AdvanceClockRequest, AdvanceClockResponse>;
39
+ /**
40
+ * Seal pending transactions into a new checkpoint.
41
+ *
42
+ * @generated from protobuf rpc: AdvanceCheckpoint(sui.forking.v1alpha.AdvanceCheckpointRequest) returns (sui.forking.v1alpha.AdvanceCheckpointResponse);
43
+ */
44
+ advanceCheckpoint(
45
+ input: AdvanceCheckpointRequest,
46
+ options?: RpcOptions,
47
+ ): UnaryCall<AdvanceCheckpointRequest, AdvanceCheckpointResponse>;
48
+ /**
49
+ * Return the current state of the forked network.
50
+ *
51
+ * @generated from protobuf rpc: GetStatus(sui.forking.v1alpha.GetStatusRequest) returns (sui.forking.v1alpha.GetStatusResponse);
52
+ */
53
+ getStatus(
54
+ input: GetStatusRequest,
55
+ options?: RpcOptions,
56
+ ): UnaryCall<GetStatusRequest, GetStatusResponse>;
57
+ }
58
+ /**
59
+ * Administrative service for controlling a forked Sui network.
60
+ *
61
+ * @generated from protobuf service sui.forking.v1alpha.ForkingService
62
+ */
63
+ export class ForkingServiceClient implements IForkingServiceClient, ServiceInfo {
64
+ typeName = ForkingService.typeName;
65
+ methods = ForkingService.methods;
66
+ options = ForkingService.options;
67
+ constructor(private readonly _transport: RpcTransport) {}
68
+ /**
69
+ * Advance the forked network's clock by a given duration.
70
+ *
71
+ * @generated from protobuf rpc: AdvanceClock(sui.forking.v1alpha.AdvanceClockRequest) returns (sui.forking.v1alpha.AdvanceClockResponse);
72
+ */
73
+ advanceClock(
74
+ input: AdvanceClockRequest,
75
+ options?: RpcOptions,
76
+ ): UnaryCall<AdvanceClockRequest, AdvanceClockResponse> {
77
+ const method = this.methods[0],
78
+ opt = this._transport.mergeOptions(options);
79
+ return stackIntercept<AdvanceClockRequest, AdvanceClockResponse>(
80
+ 'unary',
81
+ this._transport,
82
+ method,
83
+ opt,
84
+ input,
85
+ );
86
+ }
87
+ /**
88
+ * Seal pending transactions into a new checkpoint.
89
+ *
90
+ * @generated from protobuf rpc: AdvanceCheckpoint(sui.forking.v1alpha.AdvanceCheckpointRequest) returns (sui.forking.v1alpha.AdvanceCheckpointResponse);
91
+ */
92
+ advanceCheckpoint(
93
+ input: AdvanceCheckpointRequest,
94
+ options?: RpcOptions,
95
+ ): UnaryCall<AdvanceCheckpointRequest, AdvanceCheckpointResponse> {
96
+ const method = this.methods[1],
97
+ opt = this._transport.mergeOptions(options);
98
+ return stackIntercept<AdvanceCheckpointRequest, AdvanceCheckpointResponse>(
99
+ 'unary',
100
+ this._transport,
101
+ method,
102
+ opt,
103
+ input,
104
+ );
105
+ }
106
+ /**
107
+ * Return the current state of the forked network.
108
+ *
109
+ * @generated from protobuf rpc: GetStatus(sui.forking.v1alpha.GetStatusRequest) returns (sui.forking.v1alpha.GetStatusResponse);
110
+ */
111
+ getStatus(
112
+ input: GetStatusRequest,
113
+ options?: RpcOptions,
114
+ ): UnaryCall<GetStatusRequest, GetStatusResponse> {
115
+ const method = this.methods[2],
116
+ opt = this._transport.mergeOptions(options);
117
+ return stackIntercept<GetStatusRequest, GetStatusResponse>(
118
+ 'unary',
119
+ this._transport,
120
+ method,
121
+ opt,
122
+ input,
123
+ );
124
+ }
125
+ }
@@ -0,0 +1,230 @@
1
+ // Copyright (c) Mysten Labs, Inc.
2
+ // SPDX-License-Identifier: Apache-2.0
3
+
4
+ // @generated by protobuf-ts 2.9.6 with parameter force_server_none,optimize_code_size,ts_nocheck
5
+ // @generated from protobuf file "sui/forking/v1alpha/forking_service.proto" (package "sui.forking.v1alpha", syntax proto3)
6
+ // tslint:disable
7
+ // @ts-nocheck
8
+ //
9
+ // Copyright (c) Mysten Labs, Inc.
10
+ // SPDX-License-Identifier: Apache-2.0
11
+ //
12
+ import { ServiceType } from '@protobuf-ts/runtime-rpc';
13
+ import { MessageType } from '@protobuf-ts/runtime';
14
+ /**
15
+ * @generated from protobuf message sui.forking.v1alpha.AdvanceClockRequest
16
+ */
17
+ export interface AdvanceClockRequest {
18
+ /**
19
+ * Duration in milliseconds to advance the clock. Defaults to 1 if unset.
20
+ *
21
+ * @generated from protobuf field: optional uint64 duration_ms = 1;
22
+ */
23
+ durationMs?: bigint;
24
+ }
25
+ /**
26
+ * @generated from protobuf message sui.forking.v1alpha.AdvanceClockResponse
27
+ */
28
+ export interface AdvanceClockResponse {
29
+ /**
30
+ * Clock timestamp after advancing (milliseconds since Unix epoch).
31
+ *
32
+ * @generated from protobuf field: uint64 timestamp_ms = 1;
33
+ */
34
+ timestampMs: bigint;
35
+ /**
36
+ * Digest of the ConsensusCommitPrologue transaction that advanced the clock.
37
+ *
38
+ * @generated from protobuf field: string tx_digest = 2;
39
+ */
40
+ txDigest: string;
41
+ }
42
+ /**
43
+ * @generated from protobuf message sui.forking.v1alpha.AdvanceCheckpointRequest
44
+ */
45
+ export interface AdvanceCheckpointRequest {}
46
+ /**
47
+ * @generated from protobuf message sui.forking.v1alpha.AdvanceCheckpointResponse
48
+ */
49
+ export interface AdvanceCheckpointResponse {
50
+ /**
51
+ * Sequence number of the newly created checkpoint.
52
+ *
53
+ * @generated from protobuf field: uint64 checkpoint_sequence_number = 1;
54
+ */
55
+ checkpointSequenceNumber: bigint;
56
+ /**
57
+ * Timestamp embedded in the checkpoint (milliseconds since Unix epoch).
58
+ *
59
+ * @generated from protobuf field: uint64 timestamp_ms = 2;
60
+ */
61
+ timestampMs: bigint;
62
+ }
63
+ /**
64
+ * @generated from protobuf message sui.forking.v1alpha.GetStatusRequest
65
+ */
66
+ export interface GetStatusRequest {}
67
+ /**
68
+ * @generated from protobuf message sui.forking.v1alpha.GetStatusResponse
69
+ */
70
+ export interface GetStatusResponse {
71
+ /**
72
+ * Current epoch of the forked network.
73
+ *
74
+ * @generated from protobuf field: uint64 epoch = 1;
75
+ */
76
+ epoch: bigint;
77
+ /**
78
+ * Latest checkpoint sequence number.
79
+ *
80
+ * @generated from protobuf field: uint64 checkpoint_sequence_number = 2;
81
+ */
82
+ checkpointSequenceNumber: bigint;
83
+ /**
84
+ * Current clock timestamp (milliseconds since Unix epoch).
85
+ *
86
+ * @generated from protobuf field: uint64 timestamp_ms = 3;
87
+ */
88
+ timestampMs: bigint;
89
+ /**
90
+ * The upstream checkpoint at which the fork was created.
91
+ *
92
+ * @generated from protobuf field: uint64 forked_at_checkpoint = 4;
93
+ */
94
+ forkedAtCheckpoint: bigint;
95
+ }
96
+ // @generated message type with reflection information, may provide speed optimized methods
97
+ class AdvanceClockRequest$Type extends MessageType<AdvanceClockRequest> {
98
+ constructor() {
99
+ super('sui.forking.v1alpha.AdvanceClockRequest', [
100
+ {
101
+ no: 1,
102
+ name: 'duration_ms',
103
+ kind: 'scalar',
104
+ opt: true,
105
+ T: 4 /*ScalarType.UINT64*/,
106
+ L: 0 /*LongType.BIGINT*/,
107
+ },
108
+ ]);
109
+ }
110
+ }
111
+ /**
112
+ * @generated MessageType for protobuf message sui.forking.v1alpha.AdvanceClockRequest
113
+ */
114
+ export const AdvanceClockRequest = new AdvanceClockRequest$Type();
115
+ // @generated message type with reflection information, may provide speed optimized methods
116
+ class AdvanceClockResponse$Type extends MessageType<AdvanceClockResponse> {
117
+ constructor() {
118
+ super('sui.forking.v1alpha.AdvanceClockResponse', [
119
+ {
120
+ no: 1,
121
+ name: 'timestamp_ms',
122
+ kind: 'scalar',
123
+ T: 4 /*ScalarType.UINT64*/,
124
+ L: 0 /*LongType.BIGINT*/,
125
+ },
126
+ { no: 2, name: 'tx_digest', kind: 'scalar', T: 9 /*ScalarType.STRING*/ },
127
+ ]);
128
+ }
129
+ }
130
+ /**
131
+ * @generated MessageType for protobuf message sui.forking.v1alpha.AdvanceClockResponse
132
+ */
133
+ export const AdvanceClockResponse = new AdvanceClockResponse$Type();
134
+ // @generated message type with reflection information, may provide speed optimized methods
135
+ class AdvanceCheckpointRequest$Type extends MessageType<AdvanceCheckpointRequest> {
136
+ constructor() {
137
+ super('sui.forking.v1alpha.AdvanceCheckpointRequest', []);
138
+ }
139
+ }
140
+ /**
141
+ * @generated MessageType for protobuf message sui.forking.v1alpha.AdvanceCheckpointRequest
142
+ */
143
+ export const AdvanceCheckpointRequest = new AdvanceCheckpointRequest$Type();
144
+ // @generated message type with reflection information, may provide speed optimized methods
145
+ class AdvanceCheckpointResponse$Type extends MessageType<AdvanceCheckpointResponse> {
146
+ constructor() {
147
+ super('sui.forking.v1alpha.AdvanceCheckpointResponse', [
148
+ {
149
+ no: 1,
150
+ name: 'checkpoint_sequence_number',
151
+ kind: 'scalar',
152
+ T: 4 /*ScalarType.UINT64*/,
153
+ L: 0 /*LongType.BIGINT*/,
154
+ },
155
+ {
156
+ no: 2,
157
+ name: 'timestamp_ms',
158
+ kind: 'scalar',
159
+ T: 4 /*ScalarType.UINT64*/,
160
+ L: 0 /*LongType.BIGINT*/,
161
+ },
162
+ ]);
163
+ }
164
+ }
165
+ /**
166
+ * @generated MessageType for protobuf message sui.forking.v1alpha.AdvanceCheckpointResponse
167
+ */
168
+ export const AdvanceCheckpointResponse = new AdvanceCheckpointResponse$Type();
169
+ // @generated message type with reflection information, may provide speed optimized methods
170
+ class GetStatusRequest$Type extends MessageType<GetStatusRequest> {
171
+ constructor() {
172
+ super('sui.forking.v1alpha.GetStatusRequest', []);
173
+ }
174
+ }
175
+ /**
176
+ * @generated MessageType for protobuf message sui.forking.v1alpha.GetStatusRequest
177
+ */
178
+ export const GetStatusRequest = new GetStatusRequest$Type();
179
+ // @generated message type with reflection information, may provide speed optimized methods
180
+ class GetStatusResponse$Type extends MessageType<GetStatusResponse> {
181
+ constructor() {
182
+ super('sui.forking.v1alpha.GetStatusResponse', [
183
+ {
184
+ no: 1,
185
+ name: 'epoch',
186
+ kind: 'scalar',
187
+ T: 4 /*ScalarType.UINT64*/,
188
+ L: 0 /*LongType.BIGINT*/,
189
+ },
190
+ {
191
+ no: 2,
192
+ name: 'checkpoint_sequence_number',
193
+ kind: 'scalar',
194
+ T: 4 /*ScalarType.UINT64*/,
195
+ L: 0 /*LongType.BIGINT*/,
196
+ },
197
+ {
198
+ no: 3,
199
+ name: 'timestamp_ms',
200
+ kind: 'scalar',
201
+ T: 4 /*ScalarType.UINT64*/,
202
+ L: 0 /*LongType.BIGINT*/,
203
+ },
204
+ {
205
+ no: 4,
206
+ name: 'forked_at_checkpoint',
207
+ kind: 'scalar',
208
+ T: 4 /*ScalarType.UINT64*/,
209
+ L: 0 /*LongType.BIGINT*/,
210
+ },
211
+ ]);
212
+ }
213
+ }
214
+ /**
215
+ * @generated MessageType for protobuf message sui.forking.v1alpha.GetStatusResponse
216
+ */
217
+ export const GetStatusResponse = new GetStatusResponse$Type();
218
+ /**
219
+ * @generated ServiceType for protobuf service sui.forking.v1alpha.ForkingService
220
+ */
221
+ export const ForkingService = new ServiceType('sui.forking.v1alpha.ForkingService', [
222
+ { name: 'AdvanceClock', options: {}, I: AdvanceClockRequest, O: AdvanceClockResponse },
223
+ {
224
+ name: 'AdvanceCheckpoint',
225
+ options: {},
226
+ I: AdvanceCheckpointRequest,
227
+ O: AdvanceCheckpointResponse,
228
+ },
229
+ { name: 'GetStatus', options: {}, I: GetStatusRequest, O: GetStatusResponse },
230
+ ]);
@@ -89,7 +89,7 @@ class Checkpoint$Type extends MessageType<Checkpoint> {
89
89
  no: 6,
90
90
  name: 'transactions',
91
91
  kind: 'message',
92
- repeat: 1 /*RepeatType.PACKED*/,
92
+ repeat: 2 /*RepeatType.UNPACKED*/,
93
93
  T: () => ExecutedTransaction,
94
94
  },
95
95
  { no: 7, name: 'objects', kind: 'message', T: () => ObjectSet },
@@ -97,7 +97,7 @@ class CheckpointContents$Type extends MessageType<CheckpointContents> {
97
97
  no: 4,
98
98
  name: 'transactions',
99
99
  kind: 'message',
100
- repeat: 1 /*RepeatType.PACKED*/,
100
+ repeat: 2 /*RepeatType.UNPACKED*/,
101
101
  T: () => CheckpointedTransactionInfo,
102
102
  },
103
103
  ]);
@@ -117,14 +117,14 @@ class CheckpointedTransactionInfo$Type extends MessageType<CheckpointedTransacti
117
117
  no: 3,
118
118
  name: 'signatures',
119
119
  kind: 'message',
120
- repeat: 1 /*RepeatType.PACKED*/,
120
+ repeat: 2 /*RepeatType.UNPACKED*/,
121
121
  T: () => UserSignature,
122
122
  },
123
123
  {
124
124
  no: 4,
125
125
  name: 'address_aliases_versions',
126
126
  kind: 'message',
127
- repeat: 1 /*RepeatType.PACKED*/,
127
+ repeat: 2 /*RepeatType.UNPACKED*/,
128
128
  T: () => AddressAliasesVersion,
129
129
  },
130
130
  ]);
@@ -220,7 +220,7 @@ class CheckpointSummary$Type extends MessageType<CheckpointSummary> {
220
220
  no: 10,
221
221
  name: 'commitments',
222
222
  kind: 'message',
223
- repeat: 1 /*RepeatType.PACKED*/,
223
+ repeat: 2 /*RepeatType.UNPACKED*/,
224
224
  T: () => CheckpointCommitment,
225
225
  },
226
226
  { no: 11, name: 'end_of_epoch_data', kind: 'message', T: () => EndOfEpochData },
@@ -246,7 +246,7 @@ class EndOfEpochData$Type extends MessageType<EndOfEpochData> {
246
246
  no: 1,
247
247
  name: 'next_epoch_committee',
248
248
  kind: 'message',
249
- repeat: 1 /*RepeatType.PACKED*/,
249
+ repeat: 2 /*RepeatType.UNPACKED*/,
250
250
  T: () => ValidatorCommitteeMember,
251
251
  },
252
252
  {
@@ -261,7 +261,7 @@ class EndOfEpochData$Type extends MessageType<EndOfEpochData> {
261
261
  no: 3,
262
262
  name: 'epoch_commitments',
263
263
  kind: 'message',
264
- repeat: 1 /*RepeatType.PACKED*/,
264
+ repeat: 2 /*RepeatType.UNPACKED*/,
265
265
  T: () => CheckpointCommitment,
266
266
  },
267
267
  ]);