@mysten/kiosk 1.0.1 → 1.1.1

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 (101) hide show
  1. package/CHANGELOG.md +16 -0
  2. package/dist/client/kiosk-client.d.mts +4 -4
  3. package/dist/client/kiosk-client.d.mts.map +1 -1
  4. package/dist/client/kiosk-client.mjs.map +1 -1
  5. package/dist/contracts/0x2/bag.mjs.map +1 -1
  6. package/dist/contracts/0x2/balance.mjs +1 -5
  7. package/dist/contracts/0x2/balance.mjs.map +1 -1
  8. package/dist/contracts/0x2/kiosk.mjs +5 -5
  9. package/dist/contracts/0x2/kiosk.mjs.map +1 -1
  10. package/dist/contracts/0x2/kiosk_extension.mjs +1 -1
  11. package/dist/contracts/0x2/kiosk_extension.mjs.map +1 -1
  12. package/dist/contracts/0x2/transfer_policy.mjs +6 -6
  13. package/dist/contracts/0x2/transfer_policy.mjs.map +1 -1
  14. package/dist/contracts/0x2/vec_set.mjs.map +1 -1
  15. package/dist/index.d.mts +4 -4
  16. package/dist/index.mjs +2 -2
  17. package/dist/query/client-utils.mjs +186 -1
  18. package/dist/query/client-utils.mjs.map +1 -1
  19. package/dist/query/kiosk.mjs +2 -1
  20. package/dist/query/kiosk.mjs.map +1 -1
  21. package/dist/query/transfer-policy.mjs +1 -1
  22. package/dist/query/transfer-policy.mjs.map +1 -1
  23. package/dist/types/index.d.mts +7 -4
  24. package/dist/types/index.d.mts.map +1 -1
  25. package/dist/types/kiosk.d.mts +13 -3
  26. package/dist/types/kiosk.d.mts.map +1 -1
  27. package/dist/types/kiosk.mjs.map +1 -1
  28. package/dist/utils.d.mts +3 -9
  29. package/dist/utils.d.mts.map +1 -1
  30. package/dist/utils.mjs +5 -24
  31. package/dist/utils.mjs.map +1 -1
  32. package/package.json +8 -7
  33. package/src/client/kiosk-client.ts +4 -3
  34. package/src/contracts/0x2/bag.ts +2 -181
  35. package/src/contracts/0x2/balance.ts +3 -260
  36. package/src/contracts/0x2/kiosk.ts +4 -4
  37. package/src/contracts/0x2/kiosk_extension.ts +1 -1
  38. package/src/contracts/0x2/transfer_policy.ts +6 -6
  39. package/src/contracts/0x2/vec_set.ts +1 -198
  40. package/src/contracts/kiosk/witness_rule.ts +1 -1
  41. package/src/query/client-utils.ts +253 -2
  42. package/src/query/kiosk.ts +3 -2
  43. package/src/query/transfer-policy.ts +4 -5
  44. package/src/types/index.ts +6 -2
  45. package/src/types/kiosk.ts +15 -3
  46. package/src/utils.ts +8 -38
  47. package/src/contracts/0x2/accumulator.ts +0 -24
  48. package/src/contracts/0x2/accumulator_metadata.ts +0 -38
  49. package/src/contracts/0x2/accumulator_settlement.ts +0 -14
  50. package/src/contracts/0x2/address.ts +0 -145
  51. package/src/contracts/0x2/address_alias.ts +0 -92
  52. package/src/contracts/0x2/authenticator_state.ts +0 -44
  53. package/src/contracts/0x2/bcs.ts +0 -495
  54. package/src/contracts/0x2/bls12381.ts +0 -717
  55. package/src/contracts/0x2/borrow.ts +0 -99
  56. package/src/contracts/0x2/clock.ts +0 -30
  57. package/src/contracts/0x2/coin.ts +0 -977
  58. package/src/contracts/0x2/coin_registry.ts +0 -874
  59. package/src/contracts/0x2/config.ts +0 -30
  60. package/src/contracts/0x2/deny_list.ts +0 -55
  61. package/src/contracts/0x2/derived_object.ts +0 -95
  62. package/src/contracts/0x2/display.ts +0 -258
  63. package/src/contracts/0x2/dynamic_field.ts +0 -171
  64. package/src/contracts/0x2/dynamic_object_field.ts +0 -167
  65. package/src/contracts/0x2/ecdsa_k1.ts +0 -65
  66. package/src/contracts/0x2/ecdsa_r1.ts +0 -49
  67. package/src/contracts/0x2/ecvrf.ts +0 -29
  68. package/src/contracts/0x2/ed25519.ts +0 -25
  69. package/src/contracts/0x2/event.ts +0 -42
  70. package/src/contracts/0x2/funds_accumulator.ts +0 -86
  71. package/src/contracts/0x2/groth16.ts +0 -171
  72. package/src/contracts/0x2/group_ops.ts +0 -49
  73. package/src/contracts/0x2/hash.ts +0 -37
  74. package/src/contracts/0x2/hex.ts +0 -37
  75. package/src/contracts/0x2/hmac.ts +0 -21
  76. package/src/contracts/0x2/linked_table.ts +0 -354
  77. package/src/contracts/0x2/math.ts +0 -117
  78. package/src/contracts/0x2/nitro_attestation.ts +0 -186
  79. package/src/contracts/0x2/object.ts +0 -249
  80. package/src/contracts/0x2/object_bag.ts +0 -210
  81. package/src/contracts/0x2/object_table.ts +0 -200
  82. package/src/contracts/0x2/package.ts +0 -414
  83. package/src/contracts/0x2/party.ts +0 -37
  84. package/src/contracts/0x2/pay.ts +0 -153
  85. package/src/contracts/0x2/poseidon.ts +0 -21
  86. package/src/contracts/0x2/priority_queue.ts +0 -139
  87. package/src/contracts/0x2/random.ts +0 -294
  88. package/src/contracts/0x2/sui.ts +0 -29
  89. package/src/contracts/0x2/table.ts +0 -200
  90. package/src/contracts/0x2/table_vec.ts +0 -232
  91. package/src/contracts/0x2/token.ts +0 -873
  92. package/src/contracts/0x2/transfer.ts +0 -216
  93. package/src/contracts/0x2/tx_context.ts +0 -129
  94. package/src/contracts/0x2/types.ts +0 -24
  95. package/src/contracts/0x2/url.ts +0 -77
  96. package/src/contracts/0x2/vdf.ts +0 -45
  97. package/src/contracts/0x2/vec_map.ts +0 -401
  98. package/src/contracts/0x2/versioned.ts +0 -153
  99. package/src/contracts/0x2/zklogin_verified_id.ts +0 -172
  100. package/src/contracts/0x2/zklogin_verified_issuer.ts +0 -99
  101. package/src/contracts/kiosk/deps/sui/object.ts +0 -15
@@ -1,495 +0,0 @@
1
- /**************************************************************
2
- * THIS FILE IS GENERATED AND SHOULD NOT BE MANUALLY MODIFIED *
3
- **************************************************************/
4
- import { MoveStruct, normalizeMoveArguments, type RawTransactionArgument } from '../utils/index.js';
5
- import { bcs, type BcsType } from '@mysten/sui/bcs';
6
- import { type Transaction } from '@mysten/sui/transactions';
7
- const $moduleName = '0x2::bcs';
8
- export const BCS = new MoveStruct({
9
- name: `${$moduleName}::BCS`,
10
- fields: {
11
- bytes: bcs.vector(bcs.u8()),
12
- },
13
- });
14
- export interface ToBytesOptions<T0 extends BcsType<any>> {
15
- package?: string;
16
- arguments: [RawTransactionArgument<T0>];
17
- typeArguments: [string];
18
- }
19
- export function toBytes<T0 extends BcsType<any>>(options: ToBytesOptions<T0>) {
20
- const packageAddress =
21
- options.package ?? '0x0000000000000000000000000000000000000000000000000000000000000002';
22
- const argumentsTypes = [`${options.typeArguments[0]}`] satisfies (string | null)[];
23
- return (tx: Transaction) =>
24
- tx.moveCall({
25
- package: packageAddress,
26
- module: 'bcs',
27
- function: 'to_bytes',
28
- arguments: normalizeMoveArguments(options.arguments, argumentsTypes),
29
- typeArguments: options.typeArguments,
30
- });
31
- }
32
- export interface NewOptions {
33
- package?: string;
34
- arguments: [RawTransactionArgument<number[]>];
35
- }
36
- export function _new(options: NewOptions) {
37
- const packageAddress =
38
- options.package ?? '0x0000000000000000000000000000000000000000000000000000000000000002';
39
- const argumentsTypes = ['vector<u8>'] satisfies (string | null)[];
40
- return (tx: Transaction) =>
41
- tx.moveCall({
42
- package: packageAddress,
43
- module: 'bcs',
44
- function: 'new',
45
- arguments: normalizeMoveArguments(options.arguments, argumentsTypes),
46
- });
47
- }
48
- export interface IntoRemainderBytesOptions {
49
- package?: string;
50
- arguments: [RawTransactionArgument<string>];
51
- }
52
- export function intoRemainderBytes(options: IntoRemainderBytesOptions) {
53
- const packageAddress =
54
- options.package ?? '0x0000000000000000000000000000000000000000000000000000000000000002';
55
- const argumentsTypes = [null] satisfies (string | null)[];
56
- return (tx: Transaction) =>
57
- tx.moveCall({
58
- package: packageAddress,
59
- module: 'bcs',
60
- function: 'into_remainder_bytes',
61
- arguments: normalizeMoveArguments(options.arguments, argumentsTypes),
62
- });
63
- }
64
- export interface PeelAddressOptions {
65
- package?: string;
66
- arguments: [RawTransactionArgument<string>];
67
- }
68
- export function peelAddress(options: PeelAddressOptions) {
69
- const packageAddress =
70
- options.package ?? '0x0000000000000000000000000000000000000000000000000000000000000002';
71
- const argumentsTypes = [null] satisfies (string | null)[];
72
- return (tx: Transaction) =>
73
- tx.moveCall({
74
- package: packageAddress,
75
- module: 'bcs',
76
- function: 'peel_address',
77
- arguments: normalizeMoveArguments(options.arguments, argumentsTypes),
78
- });
79
- }
80
- export interface PeelBoolOptions {
81
- package?: string;
82
- arguments: [RawTransactionArgument<string>];
83
- }
84
- export function peelBool(options: PeelBoolOptions) {
85
- const packageAddress =
86
- options.package ?? '0x0000000000000000000000000000000000000000000000000000000000000002';
87
- const argumentsTypes = [null] satisfies (string | null)[];
88
- return (tx: Transaction) =>
89
- tx.moveCall({
90
- package: packageAddress,
91
- module: 'bcs',
92
- function: 'peel_bool',
93
- arguments: normalizeMoveArguments(options.arguments, argumentsTypes),
94
- });
95
- }
96
- export interface PeelU8Options {
97
- package?: string;
98
- arguments: [RawTransactionArgument<string>];
99
- }
100
- export function peelU8(options: PeelU8Options) {
101
- const packageAddress =
102
- options.package ?? '0x0000000000000000000000000000000000000000000000000000000000000002';
103
- const argumentsTypes = [null] satisfies (string | null)[];
104
- return (tx: Transaction) =>
105
- tx.moveCall({
106
- package: packageAddress,
107
- module: 'bcs',
108
- function: 'peel_u8',
109
- arguments: normalizeMoveArguments(options.arguments, argumentsTypes),
110
- });
111
- }
112
- export interface PeelU16Options {
113
- package?: string;
114
- arguments: [RawTransactionArgument<string>];
115
- }
116
- export function peelU16(options: PeelU16Options) {
117
- const packageAddress =
118
- options.package ?? '0x0000000000000000000000000000000000000000000000000000000000000002';
119
- const argumentsTypes = [null] satisfies (string | null)[];
120
- return (tx: Transaction) =>
121
- tx.moveCall({
122
- package: packageAddress,
123
- module: 'bcs',
124
- function: 'peel_u16',
125
- arguments: normalizeMoveArguments(options.arguments, argumentsTypes),
126
- });
127
- }
128
- export interface PeelU32Options {
129
- package?: string;
130
- arguments: [RawTransactionArgument<string>];
131
- }
132
- export function peelU32(options: PeelU32Options) {
133
- const packageAddress =
134
- options.package ?? '0x0000000000000000000000000000000000000000000000000000000000000002';
135
- const argumentsTypes = [null] satisfies (string | null)[];
136
- return (tx: Transaction) =>
137
- tx.moveCall({
138
- package: packageAddress,
139
- module: 'bcs',
140
- function: 'peel_u32',
141
- arguments: normalizeMoveArguments(options.arguments, argumentsTypes),
142
- });
143
- }
144
- export interface PeelU64Options {
145
- package?: string;
146
- arguments: [RawTransactionArgument<string>];
147
- }
148
- export function peelU64(options: PeelU64Options) {
149
- const packageAddress =
150
- options.package ?? '0x0000000000000000000000000000000000000000000000000000000000000002';
151
- const argumentsTypes = [null] satisfies (string | null)[];
152
- return (tx: Transaction) =>
153
- tx.moveCall({
154
- package: packageAddress,
155
- module: 'bcs',
156
- function: 'peel_u64',
157
- arguments: normalizeMoveArguments(options.arguments, argumentsTypes),
158
- });
159
- }
160
- export interface PeelU128Options {
161
- package?: string;
162
- arguments: [RawTransactionArgument<string>];
163
- }
164
- export function peelU128(options: PeelU128Options) {
165
- const packageAddress =
166
- options.package ?? '0x0000000000000000000000000000000000000000000000000000000000000002';
167
- const argumentsTypes = [null] satisfies (string | null)[];
168
- return (tx: Transaction) =>
169
- tx.moveCall({
170
- package: packageAddress,
171
- module: 'bcs',
172
- function: 'peel_u128',
173
- arguments: normalizeMoveArguments(options.arguments, argumentsTypes),
174
- });
175
- }
176
- export interface PeelU256Options {
177
- package?: string;
178
- arguments: [RawTransactionArgument<string>];
179
- }
180
- export function peelU256(options: PeelU256Options) {
181
- const packageAddress =
182
- options.package ?? '0x0000000000000000000000000000000000000000000000000000000000000002';
183
- const argumentsTypes = [null] satisfies (string | null)[];
184
- return (tx: Transaction) =>
185
- tx.moveCall({
186
- package: packageAddress,
187
- module: 'bcs',
188
- function: 'peel_u256',
189
- arguments: normalizeMoveArguments(options.arguments, argumentsTypes),
190
- });
191
- }
192
- export interface PeelVecLengthOptions {
193
- package?: string;
194
- arguments: [RawTransactionArgument<string>];
195
- }
196
- export function peelVecLength(options: PeelVecLengthOptions) {
197
- const packageAddress =
198
- options.package ?? '0x0000000000000000000000000000000000000000000000000000000000000002';
199
- const argumentsTypes = [null] satisfies (string | null)[];
200
- return (tx: Transaction) =>
201
- tx.moveCall({
202
- package: packageAddress,
203
- module: 'bcs',
204
- function: 'peel_vec_length',
205
- arguments: normalizeMoveArguments(options.arguments, argumentsTypes),
206
- });
207
- }
208
- export interface PeelVecAddressOptions {
209
- package?: string;
210
- arguments: [RawTransactionArgument<string>];
211
- }
212
- export function peelVecAddress(options: PeelVecAddressOptions) {
213
- const packageAddress =
214
- options.package ?? '0x0000000000000000000000000000000000000000000000000000000000000002';
215
- const argumentsTypes = [null] satisfies (string | null)[];
216
- return (tx: Transaction) =>
217
- tx.moveCall({
218
- package: packageAddress,
219
- module: 'bcs',
220
- function: 'peel_vec_address',
221
- arguments: normalizeMoveArguments(options.arguments, argumentsTypes),
222
- });
223
- }
224
- export interface PeelVecBoolOptions {
225
- package?: string;
226
- arguments: [RawTransactionArgument<string>];
227
- }
228
- export function peelVecBool(options: PeelVecBoolOptions) {
229
- const packageAddress =
230
- options.package ?? '0x0000000000000000000000000000000000000000000000000000000000000002';
231
- const argumentsTypes = [null] satisfies (string | null)[];
232
- return (tx: Transaction) =>
233
- tx.moveCall({
234
- package: packageAddress,
235
- module: 'bcs',
236
- function: 'peel_vec_bool',
237
- arguments: normalizeMoveArguments(options.arguments, argumentsTypes),
238
- });
239
- }
240
- export interface PeelVecU8Options {
241
- package?: string;
242
- arguments: [RawTransactionArgument<string>];
243
- }
244
- export function peelVecU8(options: PeelVecU8Options) {
245
- const packageAddress =
246
- options.package ?? '0x0000000000000000000000000000000000000000000000000000000000000002';
247
- const argumentsTypes = [null] satisfies (string | null)[];
248
- return (tx: Transaction) =>
249
- tx.moveCall({
250
- package: packageAddress,
251
- module: 'bcs',
252
- function: 'peel_vec_u8',
253
- arguments: normalizeMoveArguments(options.arguments, argumentsTypes),
254
- });
255
- }
256
- export interface PeelVecVecU8Options {
257
- package?: string;
258
- arguments: [RawTransactionArgument<string>];
259
- }
260
- export function peelVecVecU8(options: PeelVecVecU8Options) {
261
- const packageAddress =
262
- options.package ?? '0x0000000000000000000000000000000000000000000000000000000000000002';
263
- const argumentsTypes = [null] satisfies (string | null)[];
264
- return (tx: Transaction) =>
265
- tx.moveCall({
266
- package: packageAddress,
267
- module: 'bcs',
268
- function: 'peel_vec_vec_u8',
269
- arguments: normalizeMoveArguments(options.arguments, argumentsTypes),
270
- });
271
- }
272
- export interface PeelVecU16Options {
273
- package?: string;
274
- arguments: [RawTransactionArgument<string>];
275
- }
276
- export function peelVecU16(options: PeelVecU16Options) {
277
- const packageAddress =
278
- options.package ?? '0x0000000000000000000000000000000000000000000000000000000000000002';
279
- const argumentsTypes = [null] satisfies (string | null)[];
280
- return (tx: Transaction) =>
281
- tx.moveCall({
282
- package: packageAddress,
283
- module: 'bcs',
284
- function: 'peel_vec_u16',
285
- arguments: normalizeMoveArguments(options.arguments, argumentsTypes),
286
- });
287
- }
288
- export interface PeelVecU32Options {
289
- package?: string;
290
- arguments: [RawTransactionArgument<string>];
291
- }
292
- export function peelVecU32(options: PeelVecU32Options) {
293
- const packageAddress =
294
- options.package ?? '0x0000000000000000000000000000000000000000000000000000000000000002';
295
- const argumentsTypes = [null] satisfies (string | null)[];
296
- return (tx: Transaction) =>
297
- tx.moveCall({
298
- package: packageAddress,
299
- module: 'bcs',
300
- function: 'peel_vec_u32',
301
- arguments: normalizeMoveArguments(options.arguments, argumentsTypes),
302
- });
303
- }
304
- export interface PeelVecU64Options {
305
- package?: string;
306
- arguments: [RawTransactionArgument<string>];
307
- }
308
- export function peelVecU64(options: PeelVecU64Options) {
309
- const packageAddress =
310
- options.package ?? '0x0000000000000000000000000000000000000000000000000000000000000002';
311
- const argumentsTypes = [null] satisfies (string | null)[];
312
- return (tx: Transaction) =>
313
- tx.moveCall({
314
- package: packageAddress,
315
- module: 'bcs',
316
- function: 'peel_vec_u64',
317
- arguments: normalizeMoveArguments(options.arguments, argumentsTypes),
318
- });
319
- }
320
- export interface PeelVecU128Options {
321
- package?: string;
322
- arguments: [RawTransactionArgument<string>];
323
- }
324
- export function peelVecU128(options: PeelVecU128Options) {
325
- const packageAddress =
326
- options.package ?? '0x0000000000000000000000000000000000000000000000000000000000000002';
327
- const argumentsTypes = [null] satisfies (string | null)[];
328
- return (tx: Transaction) =>
329
- tx.moveCall({
330
- package: packageAddress,
331
- module: 'bcs',
332
- function: 'peel_vec_u128',
333
- arguments: normalizeMoveArguments(options.arguments, argumentsTypes),
334
- });
335
- }
336
- export interface PeelVecU256Options {
337
- package?: string;
338
- arguments: [RawTransactionArgument<string>];
339
- }
340
- export function peelVecU256(options: PeelVecU256Options) {
341
- const packageAddress =
342
- options.package ?? '0x0000000000000000000000000000000000000000000000000000000000000002';
343
- const argumentsTypes = [null] satisfies (string | null)[];
344
- return (tx: Transaction) =>
345
- tx.moveCall({
346
- package: packageAddress,
347
- module: 'bcs',
348
- function: 'peel_vec_u256',
349
- arguments: normalizeMoveArguments(options.arguments, argumentsTypes),
350
- });
351
- }
352
- export interface PeelEnumTagOptions {
353
- package?: string;
354
- arguments: [RawTransactionArgument<string>];
355
- }
356
- export function peelEnumTag(options: PeelEnumTagOptions) {
357
- const packageAddress =
358
- options.package ?? '0x0000000000000000000000000000000000000000000000000000000000000002';
359
- const argumentsTypes = [null] satisfies (string | null)[];
360
- return (tx: Transaction) =>
361
- tx.moveCall({
362
- package: packageAddress,
363
- module: 'bcs',
364
- function: 'peel_enum_tag',
365
- arguments: normalizeMoveArguments(options.arguments, argumentsTypes),
366
- });
367
- }
368
- export interface PeelOptionAddressOptions {
369
- package?: string;
370
- arguments: [RawTransactionArgument<string>];
371
- }
372
- export function peelOptionAddress(options: PeelOptionAddressOptions) {
373
- const packageAddress =
374
- options.package ?? '0x0000000000000000000000000000000000000000000000000000000000000002';
375
- const argumentsTypes = [null] satisfies (string | null)[];
376
- return (tx: Transaction) =>
377
- tx.moveCall({
378
- package: packageAddress,
379
- module: 'bcs',
380
- function: 'peel_option_address',
381
- arguments: normalizeMoveArguments(options.arguments, argumentsTypes),
382
- });
383
- }
384
- export interface PeelOptionBoolOptions {
385
- package?: string;
386
- arguments: [RawTransactionArgument<string>];
387
- }
388
- export function peelOptionBool(options: PeelOptionBoolOptions) {
389
- const packageAddress =
390
- options.package ?? '0x0000000000000000000000000000000000000000000000000000000000000002';
391
- const argumentsTypes = [null] satisfies (string | null)[];
392
- return (tx: Transaction) =>
393
- tx.moveCall({
394
- package: packageAddress,
395
- module: 'bcs',
396
- function: 'peel_option_bool',
397
- arguments: normalizeMoveArguments(options.arguments, argumentsTypes),
398
- });
399
- }
400
- export interface PeelOptionU8Options {
401
- package?: string;
402
- arguments: [RawTransactionArgument<string>];
403
- }
404
- export function peelOptionU8(options: PeelOptionU8Options) {
405
- const packageAddress =
406
- options.package ?? '0x0000000000000000000000000000000000000000000000000000000000000002';
407
- const argumentsTypes = [null] satisfies (string | null)[];
408
- return (tx: Transaction) =>
409
- tx.moveCall({
410
- package: packageAddress,
411
- module: 'bcs',
412
- function: 'peel_option_u8',
413
- arguments: normalizeMoveArguments(options.arguments, argumentsTypes),
414
- });
415
- }
416
- export interface PeelOptionU16Options {
417
- package?: string;
418
- arguments: [RawTransactionArgument<string>];
419
- }
420
- export function peelOptionU16(options: PeelOptionU16Options) {
421
- const packageAddress =
422
- options.package ?? '0x0000000000000000000000000000000000000000000000000000000000000002';
423
- const argumentsTypes = [null] satisfies (string | null)[];
424
- return (tx: Transaction) =>
425
- tx.moveCall({
426
- package: packageAddress,
427
- module: 'bcs',
428
- function: 'peel_option_u16',
429
- arguments: normalizeMoveArguments(options.arguments, argumentsTypes),
430
- });
431
- }
432
- export interface PeelOptionU32Options {
433
- package?: string;
434
- arguments: [RawTransactionArgument<string>];
435
- }
436
- export function peelOptionU32(options: PeelOptionU32Options) {
437
- const packageAddress =
438
- options.package ?? '0x0000000000000000000000000000000000000000000000000000000000000002';
439
- const argumentsTypes = [null] satisfies (string | null)[];
440
- return (tx: Transaction) =>
441
- tx.moveCall({
442
- package: packageAddress,
443
- module: 'bcs',
444
- function: 'peel_option_u32',
445
- arguments: normalizeMoveArguments(options.arguments, argumentsTypes),
446
- });
447
- }
448
- export interface PeelOptionU64Options {
449
- package?: string;
450
- arguments: [RawTransactionArgument<string>];
451
- }
452
- export function peelOptionU64(options: PeelOptionU64Options) {
453
- const packageAddress =
454
- options.package ?? '0x0000000000000000000000000000000000000000000000000000000000000002';
455
- const argumentsTypes = [null] satisfies (string | null)[];
456
- return (tx: Transaction) =>
457
- tx.moveCall({
458
- package: packageAddress,
459
- module: 'bcs',
460
- function: 'peel_option_u64',
461
- arguments: normalizeMoveArguments(options.arguments, argumentsTypes),
462
- });
463
- }
464
- export interface PeelOptionU128Options {
465
- package?: string;
466
- arguments: [RawTransactionArgument<string>];
467
- }
468
- export function peelOptionU128(options: PeelOptionU128Options) {
469
- const packageAddress =
470
- options.package ?? '0x0000000000000000000000000000000000000000000000000000000000000002';
471
- const argumentsTypes = [null] satisfies (string | null)[];
472
- return (tx: Transaction) =>
473
- tx.moveCall({
474
- package: packageAddress,
475
- module: 'bcs',
476
- function: 'peel_option_u128',
477
- arguments: normalizeMoveArguments(options.arguments, argumentsTypes),
478
- });
479
- }
480
- export interface PeelOptionU256Options {
481
- package?: string;
482
- arguments: [RawTransactionArgument<string>];
483
- }
484
- export function peelOptionU256(options: PeelOptionU256Options) {
485
- const packageAddress =
486
- options.package ?? '0x0000000000000000000000000000000000000000000000000000000000000002';
487
- const argumentsTypes = [null] satisfies (string | null)[];
488
- return (tx: Transaction) =>
489
- tx.moveCall({
490
- package: packageAddress,
491
- module: 'bcs',
492
- function: 'peel_option_u256',
493
- arguments: normalizeMoveArguments(options.arguments, argumentsTypes),
494
- });
495
- }