@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,172 +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 } from '@mysten/sui/bcs';
6
- import { type Transaction } from '@mysten/sui/transactions';
7
- const $moduleName = '0x2::zklogin_verified_id';
8
- export const VerifiedID = new MoveStruct({
9
- name: `${$moduleName}::VerifiedID`,
10
- fields: {
11
- id: bcs.Address,
12
- owner: bcs.Address,
13
- key_claim_name: bcs.string(),
14
- key_claim_value: bcs.string(),
15
- issuer: bcs.string(),
16
- audience: bcs.string(),
17
- },
18
- });
19
- export interface OwnerOptions {
20
- package?: string;
21
- arguments: [RawTransactionArgument<string>];
22
- }
23
- export function owner(options: OwnerOptions) {
24
- const packageAddress =
25
- options.package ?? '0x0000000000000000000000000000000000000000000000000000000000000002';
26
- const argumentsTypes = [null] satisfies (string | null)[];
27
- return (tx: Transaction) =>
28
- tx.moveCall({
29
- package: packageAddress,
30
- module: 'zklogin_verified_id',
31
- function: 'owner',
32
- arguments: normalizeMoveArguments(options.arguments, argumentsTypes),
33
- });
34
- }
35
- export interface KeyClaimNameOptions {
36
- package?: string;
37
- arguments: [RawTransactionArgument<string>];
38
- }
39
- export function keyClaimName(options: KeyClaimNameOptions) {
40
- const packageAddress =
41
- options.package ?? '0x0000000000000000000000000000000000000000000000000000000000000002';
42
- const argumentsTypes = [null] satisfies (string | null)[];
43
- return (tx: Transaction) =>
44
- tx.moveCall({
45
- package: packageAddress,
46
- module: 'zklogin_verified_id',
47
- function: 'key_claim_name',
48
- arguments: normalizeMoveArguments(options.arguments, argumentsTypes),
49
- });
50
- }
51
- export interface KeyClaimValueOptions {
52
- package?: string;
53
- arguments: [RawTransactionArgument<string>];
54
- }
55
- export function keyClaimValue(options: KeyClaimValueOptions) {
56
- const packageAddress =
57
- options.package ?? '0x0000000000000000000000000000000000000000000000000000000000000002';
58
- const argumentsTypes = [null] satisfies (string | null)[];
59
- return (tx: Transaction) =>
60
- tx.moveCall({
61
- package: packageAddress,
62
- module: 'zklogin_verified_id',
63
- function: 'key_claim_value',
64
- arguments: normalizeMoveArguments(options.arguments, argumentsTypes),
65
- });
66
- }
67
- export interface IssuerOptions {
68
- package?: string;
69
- arguments: [RawTransactionArgument<string>];
70
- }
71
- export function issuer(options: IssuerOptions) {
72
- const packageAddress =
73
- options.package ?? '0x0000000000000000000000000000000000000000000000000000000000000002';
74
- const argumentsTypes = [null] satisfies (string | null)[];
75
- return (tx: Transaction) =>
76
- tx.moveCall({
77
- package: packageAddress,
78
- module: 'zklogin_verified_id',
79
- function: 'issuer',
80
- arguments: normalizeMoveArguments(options.arguments, argumentsTypes),
81
- });
82
- }
83
- export interface AudienceOptions {
84
- package?: string;
85
- arguments: [RawTransactionArgument<string>];
86
- }
87
- export function audience(options: AudienceOptions) {
88
- const packageAddress =
89
- options.package ?? '0x0000000000000000000000000000000000000000000000000000000000000002';
90
- const argumentsTypes = [null] satisfies (string | null)[];
91
- return (tx: Transaction) =>
92
- tx.moveCall({
93
- package: packageAddress,
94
- module: 'zklogin_verified_id',
95
- function: 'audience',
96
- arguments: normalizeMoveArguments(options.arguments, argumentsTypes),
97
- });
98
- }
99
- export interface DeleteOptions {
100
- package?: string;
101
- arguments: [RawTransactionArgument<string>];
102
- }
103
- export function _delete(options: DeleteOptions) {
104
- const packageAddress =
105
- options.package ?? '0x0000000000000000000000000000000000000000000000000000000000000002';
106
- const argumentsTypes = [null] satisfies (string | null)[];
107
- return (tx: Transaction) =>
108
- tx.moveCall({
109
- package: packageAddress,
110
- module: 'zklogin_verified_id',
111
- function: 'delete',
112
- arguments: normalizeMoveArguments(options.arguments, argumentsTypes),
113
- });
114
- }
115
- export interface VerifyZkloginIdOptions {
116
- package?: string;
117
- arguments: [
118
- RawTransactionArgument<string>,
119
- RawTransactionArgument<string>,
120
- RawTransactionArgument<string>,
121
- RawTransactionArgument<string>,
122
- RawTransactionArgument<number | bigint>,
123
- ];
124
- }
125
- export function verifyZkloginId(options: VerifyZkloginIdOptions) {
126
- const packageAddress =
127
- options.package ?? '0x0000000000000000000000000000000000000000000000000000000000000002';
128
- const argumentsTypes = [
129
- '0x1::string::String',
130
- '0x1::string::String',
131
- '0x1::string::String',
132
- '0x1::string::String',
133
- 'u256',
134
- ] satisfies (string | null)[];
135
- return (tx: Transaction) =>
136
- tx.moveCall({
137
- package: packageAddress,
138
- module: 'zklogin_verified_id',
139
- function: 'verify_zklogin_id',
140
- arguments: normalizeMoveArguments(options.arguments, argumentsTypes),
141
- });
142
- }
143
- export interface CheckZkloginIdOptions {
144
- package?: string;
145
- arguments: [
146
- RawTransactionArgument<string>,
147
- RawTransactionArgument<string>,
148
- RawTransactionArgument<string>,
149
- RawTransactionArgument<string>,
150
- RawTransactionArgument<string>,
151
- RawTransactionArgument<number | bigint>,
152
- ];
153
- }
154
- export function checkZkloginId(options: CheckZkloginIdOptions) {
155
- const packageAddress =
156
- options.package ?? '0x0000000000000000000000000000000000000000000000000000000000000002';
157
- const argumentsTypes = [
158
- 'address',
159
- '0x1::string::String',
160
- '0x1::string::String',
161
- '0x1::string::String',
162
- '0x1::string::String',
163
- 'u256',
164
- ] satisfies (string | null)[];
165
- return (tx: Transaction) =>
166
- tx.moveCall({
167
- package: packageAddress,
168
- module: 'zklogin_verified_id',
169
- function: 'check_zklogin_id',
170
- arguments: normalizeMoveArguments(options.arguments, argumentsTypes),
171
- });
172
- }
@@ -1,99 +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 } from '@mysten/sui/bcs';
6
- import { type Transaction } from '@mysten/sui/transactions';
7
- const $moduleName = '0x2::zklogin_verified_issuer';
8
- export const VerifiedIssuer = new MoveStruct({
9
- name: `${$moduleName}::VerifiedIssuer`,
10
- fields: {
11
- id: bcs.Address,
12
- owner: bcs.Address,
13
- issuer: bcs.string(),
14
- },
15
- });
16
- export interface OwnerOptions {
17
- package?: string;
18
- arguments: [RawTransactionArgument<string>];
19
- }
20
- export function owner(options: OwnerOptions) {
21
- const packageAddress =
22
- options.package ?? '0x0000000000000000000000000000000000000000000000000000000000000002';
23
- const argumentsTypes = [null] satisfies (string | null)[];
24
- return (tx: Transaction) =>
25
- tx.moveCall({
26
- package: packageAddress,
27
- module: 'zklogin_verified_issuer',
28
- function: 'owner',
29
- arguments: normalizeMoveArguments(options.arguments, argumentsTypes),
30
- });
31
- }
32
- export interface IssuerOptions {
33
- package?: string;
34
- arguments: [RawTransactionArgument<string>];
35
- }
36
- export function issuer(options: IssuerOptions) {
37
- const packageAddress =
38
- options.package ?? '0x0000000000000000000000000000000000000000000000000000000000000002';
39
- const argumentsTypes = [null] satisfies (string | null)[];
40
- return (tx: Transaction) =>
41
- tx.moveCall({
42
- package: packageAddress,
43
- module: 'zklogin_verified_issuer',
44
- function: 'issuer',
45
- arguments: normalizeMoveArguments(options.arguments, argumentsTypes),
46
- });
47
- }
48
- export interface DeleteOptions {
49
- package?: string;
50
- arguments: [RawTransactionArgument<string>];
51
- }
52
- export function _delete(options: DeleteOptions) {
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: 'zklogin_verified_issuer',
60
- function: 'delete',
61
- arguments: normalizeMoveArguments(options.arguments, argumentsTypes),
62
- });
63
- }
64
- export interface VerifyZkloginIssuerOptions {
65
- package?: string;
66
- arguments: [RawTransactionArgument<number | bigint>, RawTransactionArgument<string>];
67
- }
68
- export function verifyZkloginIssuer(options: VerifyZkloginIssuerOptions) {
69
- const packageAddress =
70
- options.package ?? '0x0000000000000000000000000000000000000000000000000000000000000002';
71
- const argumentsTypes = ['u256', '0x1::string::String'] satisfies (string | null)[];
72
- return (tx: Transaction) =>
73
- tx.moveCall({
74
- package: packageAddress,
75
- module: 'zklogin_verified_issuer',
76
- function: 'verify_zklogin_issuer',
77
- arguments: normalizeMoveArguments(options.arguments, argumentsTypes),
78
- });
79
- }
80
- export interface CheckZkloginIssuerOptions {
81
- package?: string;
82
- arguments: [
83
- RawTransactionArgument<string>,
84
- RawTransactionArgument<number | bigint>,
85
- RawTransactionArgument<string>,
86
- ];
87
- }
88
- export function checkZkloginIssuer(options: CheckZkloginIssuerOptions) {
89
- const packageAddress =
90
- options.package ?? '0x0000000000000000000000000000000000000000000000000000000000000002';
91
- const argumentsTypes = ['address', 'u256', '0x1::string::String'] satisfies (string | null)[];
92
- return (tx: Transaction) =>
93
- tx.moveCall({
94
- package: packageAddress,
95
- module: 'zklogin_verified_issuer',
96
- function: 'check_zklogin_issuer',
97
- arguments: normalizeMoveArguments(options.arguments, argumentsTypes),
98
- });
99
- }
@@ -1,15 +0,0 @@
1
- /**************************************************************
2
- * THIS FILE IS GENERATED AND SHOULD NOT BE MANUALLY MODIFIED *
3
- **************************************************************/
4
-
5
- /** Sui object identifiers */
6
-
7
- import { MoveStruct } from '../../../utils/index.js';
8
- import { bcs } from '@mysten/sui/bcs';
9
- const $moduleName = '0x2::object';
10
- export const UID = new MoveStruct({
11
- name: `${$moduleName}::UID`,
12
- fields: {
13
- id: bcs.Address,
14
- },
15
- });