@zing-protocol/zing-sdk 0.0.17 → 0.1.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.
- package/dist/_generated/index.d.ts +0 -2
- package/dist/_generated/index.js +0 -2
- package/dist/_generated/utils/index.d.ts +21 -2
- package/dist/_generated/utils/index.js +35 -11
- package/dist/_generated/zing_framework/coin_utils.js +1 -4
- package/dist/_generated/zing_framework/derived_object_bag.d.ts +4 -3
- package/dist/_generated/zing_framework/derived_object_bag.js +12 -37
- package/dist/_generated/zing_framework/derived_table.d.ts +5 -4
- package/dist/_generated/zing_framework/derived_table.js +12 -33
- package/dist/_generated/zing_governance/admin.d.ts +4 -17
- package/dist/_generated/zing_governance/admin.js +3 -17
- package/dist/_generated/zing_governance/treasury.d.ts +5 -4
- package/dist/_generated/zing_governance/treasury.js +5 -15
- package/dist/_generated/zing_studio/app.d.ts +70 -2
- package/dist/_generated/zing_studio/app.js +154 -100
- package/dist/_generated/zing_studio/article.d.ts +6 -52
- package/dist/_generated/zing_studio/article.js +23 -74
- package/dist/_generated/zing_studio/config.d.ts +34 -3
- package/dist/_generated/zing_studio/config.js +47 -50
- package/dist/_generated/zing_studio/deps/sui/bag.d.ts +25 -3
- package/dist/_generated/zing_studio/deps/sui/bag.js +1 -2
- package/dist/_generated/zing_studio/deps/sui/balance.d.ts +1 -1
- package/dist/_generated/zing_studio/deps/sui/balance.js +1 -1
- package/dist/_generated/zing_studio/deps/sui/coin.d.ts +3 -5
- package/dist/_generated/zing_studio/deps/sui/coin.js +3 -3
- package/dist/_generated/zing_studio/deps/sui/table.d.ts +21 -4
- package/dist/_generated/zing_studio/deps/sui/table.js +2 -3
- package/dist/_generated/zing_studio/deps/walrus/blob.d.ts +2 -6
- package/dist/_generated/zing_studio/deps/walrus/blob.js +1 -2
- package/dist/_generated/zing_studio/deps/walrus/storage_resource.d.ts +1 -3
- package/dist/_generated/zing_studio/deps/walrus/storage_resource.js +1 -2
- package/dist/_generated/zing_studio/deps/zing_framework/derived_object_bag.d.ts +1 -3
- package/dist/_generated/zing_studio/deps/zing_framework/derived_object_bag.js +1 -2
- package/dist/_generated/zing_studio/deps/zing_framework/derived_table.d.ts +2 -4
- package/dist/_generated/zing_studio/deps/zing_framework/derived_table.js +2 -3
- package/dist/_generated/zing_studio/donation.d.ts +6 -14
- package/dist/_generated/zing_studio/donation.js +2 -2
- package/dist/_generated/zing_studio/enclave.d.ts +17 -10
- package/dist/_generated/zing_studio/enclave.js +16 -41
- package/dist/_generated/zing_studio/referral.js +15 -46
- package/dist/_generated/zing_studio/storage.d.ts +13 -17
- package/dist/_generated/zing_studio/storage.js +46 -100
- package/dist/_generated/zing_studio/studio.d.ts +6 -28
- package/dist/_generated/zing_studio/studio.js +23 -96
- package/dist/client/index.d.ts +18 -55
- package/dist/client/index.js +1 -28
- package/dist/getters.d.ts +17 -62
- package/dist/getters.js +62 -56
- package/dist/hooks/index.d.ts +0 -1
- package/dist/hooks/index.js +1 -1
- package/dist/hooks/useGetStudio.d.ts +4 -10
- package/dist/hooks/useReclaim.d.ts +0 -10
- package/dist/hooks/useReclaim.js +169 -92
- package/dist/hooks/useSignAndExecuteTransaction.js +4 -1
- package/dist/hooks/useZingInfiniteQueries.d.ts +3 -9
- package/dist/hooks/useZingInfiniteQueries.js +1 -0
- package/dist/hooks/useZingQueries.d.ts +8 -27
- package/dist/hooks/useZingQueries.js +1 -2
- package/dist/hooks/useZingQuery.d.ts +11 -36
- package/dist/hooks/useZingQuery.js +1 -2
- package/dist/lib/utils/index.d.ts +0 -1
- package/dist/lib/utils/index.js +0 -1
- package/dist/lib/utils/reclaim.d.ts +1 -29
- package/dist/lib/utils/reclaim.js +148 -87
- package/dist/mutations/signer.js +1 -1
- package/dist/mutations/walrus.js +1 -1
- package/package.json +1 -1
- package/dist/_generated/zing_framework/deps/sui/object.d.ts +0 -8
- package/dist/_generated/zing_framework/deps/sui/object.js +0 -13
- package/dist/_generated/zing_governance/deps/sui/object.d.ts +0 -8
- package/dist/_generated/zing_governance/deps/sui/object.js +0 -13
- package/dist/_generated/zing_identity/config.d.ts +0 -87
- package/dist/_generated/zing_identity/config.js +0 -98
- package/dist/_generated/zing_identity/deps/std/type_name.d.ts +0 -17
- package/dist/_generated/zing_identity/deps/std/type_name.js +0 -22
- package/dist/_generated/zing_identity/deps/sui/object.d.ts +0 -8
- package/dist/_generated/zing_identity/deps/sui/object.js +0 -13
- package/dist/_generated/zing_identity/deps/sui/object_table.d.ts +0 -12
- package/dist/_generated/zing_identity/deps/sui/object_table.js +0 -23
- package/dist/_generated/zing_identity/deps/sui/table.d.ts +0 -12
- package/dist/_generated/zing_identity/deps/sui/table.js +0 -35
- package/dist/_generated/zing_identity/deps/sui/vec_set.d.ts +0 -17
- package/dist/_generated/zing_identity/deps/sui/vec_set.js +0 -22
- package/dist/_generated/zing_identity/ecdsa.d.ts +0 -81
- package/dist/_generated/zing_identity/ecdsa.js +0 -87
- package/dist/_generated/zing_identity/identity.d.ts +0 -262
- package/dist/_generated/zing_identity/identity.js +0 -294
- package/dist/_generated/zing_identity/reclaim.d.ts +0 -356
- package/dist/_generated/zing_identity/reclaim.js +0 -414
- package/dist/_generated/zing_studio/nitro_attestation.d.ts +0 -148
- package/dist/_generated/zing_studio/nitro_attestation.js +0 -183
|
@@ -5,8 +5,8 @@ export declare const PurchaseStorageTierEvent: MoveStruct<{
|
|
|
5
5
|
owner: import("@mysten/sui/bcs").BcsType<string, string | Uint8Array<ArrayBufferLike>, "bytes[32]">;
|
|
6
6
|
current_epoch: import("@mysten/sui/bcs").BcsType<number, number, "u32">;
|
|
7
7
|
timestamp_ms: import("@mysten/sui/bcs").BcsType<string, string | number | bigint, "u64">;
|
|
8
|
-
prev_period: import("../utils/index.js").MoveTuple<import("@mysten/sui/bcs").BcsType<string, string | number | bigint, "u64">
|
|
9
|
-
current_period: import("../utils/index.js").MoveTuple<import("@mysten/sui/bcs").BcsType<string, string | number | bigint, "u64">
|
|
8
|
+
prev_period: import("../utils/index.js").MoveTuple<readonly [import("@mysten/sui/bcs").BcsType<string, string | number | bigint, "u64">, import("@mysten/sui/bcs").BcsType<string, string | number | bigint, "u64">], "@local-pkg/zing_studio::studio::Period">;
|
|
9
|
+
current_period: import("../utils/index.js").MoveTuple<readonly [import("@mysten/sui/bcs").BcsType<string, string | number | bigint, "u64">, import("@mysten/sui/bcs").BcsType<string, string | number | bigint, "u64">], "@local-pkg/zing_studio::studio::Period">;
|
|
10
10
|
prev_tier: import("@mysten/sui/bcs").BcsType<number | null, number | null | undefined, "Option<u8>">;
|
|
11
11
|
current_tier: import("@mysten/sui/bcs").BcsType<number, number, "u8">;
|
|
12
12
|
prev_storage_limit: import("@mysten/sui/bcs").BcsType<string, string | number | bigint, "u64">;
|
|
@@ -168,6 +168,72 @@ export interface AllocateStorageAndRegisterBlobOptions {
|
|
|
168
168
|
];
|
|
169
169
|
}
|
|
170
170
|
export declare function allocateStorageAndRegisterBlob(options: AllocateStorageAndRegisterBlobOptions): (tx: Transaction) => import("@mysten/sui/transactions").TransactionResult;
|
|
171
|
+
export interface AllocateStorageAndRegisterBlobWithPaymentArguments {
|
|
172
|
+
config: RawTransactionArgument<string>;
|
|
173
|
+
studio: RawTransactionArgument<string>;
|
|
174
|
+
walrusSystem: RawTransactionArgument<string>;
|
|
175
|
+
storageTreasury: RawTransactionArgument<string>;
|
|
176
|
+
storageSpace: RawTransactionArgument<string>;
|
|
177
|
+
blobId: RawTransactionArgument<number | bigint>;
|
|
178
|
+
rootHash: RawTransactionArgument<number | bigint>;
|
|
179
|
+
unencodedBlobSize: RawTransactionArgument<number | bigint>;
|
|
180
|
+
encodingType: RawTransactionArgument<number>;
|
|
181
|
+
payment: RawTransactionArgument<string>;
|
|
182
|
+
}
|
|
183
|
+
export interface AllocateStorageAndRegisterBlobWithPaymentOptions {
|
|
184
|
+
package?: string;
|
|
185
|
+
arguments: AllocateStorageAndRegisterBlobWithPaymentArguments | [
|
|
186
|
+
config: RawTransactionArgument<string>,
|
|
187
|
+
studio: RawTransactionArgument<string>,
|
|
188
|
+
walrusSystem: RawTransactionArgument<string>,
|
|
189
|
+
storageTreasury: RawTransactionArgument<string>,
|
|
190
|
+
storageSpace: RawTransactionArgument<string>,
|
|
191
|
+
blobId: RawTransactionArgument<number | bigint>,
|
|
192
|
+
rootHash: RawTransactionArgument<number | bigint>,
|
|
193
|
+
unencodedBlobSize: RawTransactionArgument<number | bigint>,
|
|
194
|
+
encodingType: RawTransactionArgument<number>,
|
|
195
|
+
payment: RawTransactionArgument<string>
|
|
196
|
+
];
|
|
197
|
+
}
|
|
198
|
+
export declare function allocateStorageAndRegisterBlobWithPayment(options: AllocateStorageAndRegisterBlobWithPaymentOptions): (tx: Transaction) => import("@mysten/sui/transactions").TransactionResult;
|
|
199
|
+
export interface StartPublishArticleWithWalPaymentArguments {
|
|
200
|
+
config: RawTransactionArgument<string>;
|
|
201
|
+
studio: RawTransactionArgument<string>;
|
|
202
|
+
walrusSystem: RawTransactionArgument<string>;
|
|
203
|
+
storageTreasury: RawTransactionArgument<string>;
|
|
204
|
+
storageSpace: RawTransactionArgument<string>;
|
|
205
|
+
subscriptionLevel: RawTransactionArgument<number | null>;
|
|
206
|
+
blobIds: RawTransactionArgument<number | bigint[]>;
|
|
207
|
+
rootHashes: RawTransactionArgument<number | bigint[]>;
|
|
208
|
+
unencodedBlobSizes: RawTransactionArgument<number | bigint[]>;
|
|
209
|
+
encodingType: RawTransactionArgument<number>;
|
|
210
|
+
identifiers: RawTransactionArgument<string[]>;
|
|
211
|
+
blobIndexes: RawTransactionArgument<number | bigint[]>;
|
|
212
|
+
mimeTypes: RawTransactionArgument<string[]>;
|
|
213
|
+
metadataSizes: RawTransactionArgument<number | bigint[]>;
|
|
214
|
+
payment: RawTransactionArgument<string>;
|
|
215
|
+
}
|
|
216
|
+
export interface StartPublishArticleWithWalPaymentOptions {
|
|
217
|
+
package?: string;
|
|
218
|
+
arguments: StartPublishArticleWithWalPaymentArguments | [
|
|
219
|
+
config: RawTransactionArgument<string>,
|
|
220
|
+
studio: RawTransactionArgument<string>,
|
|
221
|
+
walrusSystem: RawTransactionArgument<string>,
|
|
222
|
+
storageTreasury: RawTransactionArgument<string>,
|
|
223
|
+
storageSpace: RawTransactionArgument<string>,
|
|
224
|
+
subscriptionLevel: RawTransactionArgument<number | null>,
|
|
225
|
+
blobIds: RawTransactionArgument<number | bigint[]>,
|
|
226
|
+
rootHashes: RawTransactionArgument<number | bigint[]>,
|
|
227
|
+
unencodedBlobSizes: RawTransactionArgument<number | bigint[]>,
|
|
228
|
+
encodingType: RawTransactionArgument<number>,
|
|
229
|
+
identifiers: RawTransactionArgument<string[]>,
|
|
230
|
+
blobIndexes: RawTransactionArgument<number | bigint[]>,
|
|
231
|
+
mimeTypes: RawTransactionArgument<string[]>,
|
|
232
|
+
metadataSizes: RawTransactionArgument<number | bigint[]>,
|
|
233
|
+
payment: RawTransactionArgument<string>
|
|
234
|
+
];
|
|
235
|
+
}
|
|
236
|
+
export declare function startPublishArticleWithWalPayment(options: StartPublishArticleWithWalPaymentOptions): (tx: Transaction) => import("@mysten/sui/transactions").TransactionResult;
|
|
171
237
|
export interface StartPublishArticleArguments {
|
|
172
238
|
config: RawTransactionArgument<string>;
|
|
173
239
|
studio: RawTransactionArgument<string>;
|
|
@@ -365,6 +431,7 @@ export interface BurnOrKeepPositiveCoinOptions {
|
|
|
365
431
|
}
|
|
366
432
|
export declare function burnOrKeepPositiveCoin(options: BurnOrKeepPositiveCoinOptions): (tx: Transaction) => import("@mysten/sui/transactions").TransactionResult;
|
|
367
433
|
export interface PayoutArguments {
|
|
434
|
+
config: RawTransactionArgument<string>;
|
|
368
435
|
treasury: RawTransactionArgument<string>;
|
|
369
436
|
coin: RawTransactionArgument<string>;
|
|
370
437
|
recipient: RawTransactionArgument<string>;
|
|
@@ -372,6 +439,7 @@ export interface PayoutArguments {
|
|
|
372
439
|
export interface PayoutOptions {
|
|
373
440
|
package?: string;
|
|
374
441
|
arguments: PayoutArguments | [
|
|
442
|
+
config: RawTransactionArgument<string>,
|
|
375
443
|
treasury: RawTransactionArgument<string>,
|
|
376
444
|
coin: RawTransactionArgument<string>,
|
|
377
445
|
recipient: RawTransactionArgument<string>
|
|
@@ -87,11 +87,7 @@ export const PublishReceipt = new MoveStruct({
|
|
|
87
87
|
});
|
|
88
88
|
export function setupFileKey(options) {
|
|
89
89
|
const packageAddress = options.package ?? "@local-pkg/zing_studio";
|
|
90
|
-
const argumentsTypes = [
|
|
91
|
-
`${packageAddress}::config::Config`,
|
|
92
|
-
`${packageAddress}::studio::Studio`,
|
|
93
|
-
"vector<u8>",
|
|
94
|
-
];
|
|
90
|
+
const argumentsTypes = [null, null, "vector<u8>"];
|
|
95
91
|
const parameterNames = ["config", "studio", "encryptedFileKey"];
|
|
96
92
|
return (tx) => tx.moveCall({
|
|
97
93
|
package: packageAddress,
|
|
@@ -102,11 +98,7 @@ export function setupFileKey(options) {
|
|
|
102
98
|
}
|
|
103
99
|
export function updateFileKey(options) {
|
|
104
100
|
const packageAddress = options.package ?? "@local-pkg/zing_studio";
|
|
105
|
-
const argumentsTypes = [
|
|
106
|
-
`${packageAddress}::config::Config`,
|
|
107
|
-
`${packageAddress}::studio::Studio`,
|
|
108
|
-
"vector<u8>",
|
|
109
|
-
];
|
|
101
|
+
const argumentsTypes = [null, null, "vector<u8>"];
|
|
110
102
|
const parameterNames = ["config", "studio", "encryptedFileKey"];
|
|
111
103
|
return (tx) => tx.moveCall({
|
|
112
104
|
package: packageAddress,
|
|
@@ -117,12 +109,7 @@ export function updateFileKey(options) {
|
|
|
117
109
|
}
|
|
118
110
|
export function setMonthlySubscriptionFee(options) {
|
|
119
111
|
const packageAddress = options.package ?? "@local-pkg/zing_studio";
|
|
120
|
-
const argumentsTypes = [
|
|
121
|
-
`${packageAddress}::config::Config`,
|
|
122
|
-
`${packageAddress}::studio::Studio`,
|
|
123
|
-
"u8",
|
|
124
|
-
"u64",
|
|
125
|
-
];
|
|
112
|
+
const argumentsTypes = [null, null, "u8", "u64"];
|
|
126
113
|
const parameterNames = [
|
|
127
114
|
"config",
|
|
128
115
|
"studio",
|
|
@@ -139,12 +126,12 @@ export function setMonthlySubscriptionFee(options) {
|
|
|
139
126
|
export function subscribeToStudio(options) {
|
|
140
127
|
const packageAddress = options.package ?? "@local-pkg/zing_studio";
|
|
141
128
|
const argumentsTypes = [
|
|
142
|
-
|
|
143
|
-
|
|
129
|
+
null,
|
|
130
|
+
null,
|
|
144
131
|
"u8",
|
|
145
|
-
|
|
146
|
-
|
|
147
|
-
"
|
|
132
|
+
null,
|
|
133
|
+
null,
|
|
134
|
+
"0x2::clock::Clock",
|
|
148
135
|
];
|
|
149
136
|
const parameterNames = [
|
|
150
137
|
"studio",
|
|
@@ -164,15 +151,15 @@ export function subscribeToStudio(options) {
|
|
|
164
151
|
export function purchaseStorageTier(options) {
|
|
165
152
|
const packageAddress = options.package ?? "@local-pkg/zing_studio";
|
|
166
153
|
const argumentsTypes = [
|
|
167
|
-
|
|
168
|
-
|
|
169
|
-
|
|
170
|
-
|
|
171
|
-
|
|
172
|
-
|
|
154
|
+
null,
|
|
155
|
+
null,
|
|
156
|
+
null,
|
|
157
|
+
null,
|
|
158
|
+
null,
|
|
159
|
+
null,
|
|
173
160
|
"u8",
|
|
174
|
-
|
|
175
|
-
"
|
|
161
|
+
null,
|
|
162
|
+
"0x2::clock::Clock",
|
|
176
163
|
];
|
|
177
164
|
const parameterNames = [
|
|
178
165
|
"config",
|
|
@@ -195,16 +182,16 @@ export function purchaseStorageTier(options) {
|
|
|
195
182
|
export function allocateStorageAndRegisterBlob(options) {
|
|
196
183
|
const packageAddress = options.package ?? "@local-pkg/zing_studio";
|
|
197
184
|
const argumentsTypes = [
|
|
198
|
-
|
|
199
|
-
|
|
200
|
-
|
|
201
|
-
|
|
202
|
-
|
|
185
|
+
null,
|
|
186
|
+
null,
|
|
187
|
+
null,
|
|
188
|
+
null,
|
|
189
|
+
null,
|
|
203
190
|
"u256",
|
|
204
191
|
"u256",
|
|
205
192
|
"u64",
|
|
206
193
|
"u8",
|
|
207
|
-
"
|
|
194
|
+
"0x2::clock::Clock",
|
|
208
195
|
];
|
|
209
196
|
const parameterNames = [
|
|
210
197
|
"config",
|
|
@@ -224,24 +211,102 @@ export function allocateStorageAndRegisterBlob(options) {
|
|
|
224
211
|
arguments: normalizeMoveArguments(options.arguments, argumentsTypes, parameterNames),
|
|
225
212
|
});
|
|
226
213
|
}
|
|
214
|
+
export function allocateStorageAndRegisterBlobWithPayment(options) {
|
|
215
|
+
const packageAddress = options.package ?? "@local-pkg/zing_studio";
|
|
216
|
+
const argumentsTypes = [
|
|
217
|
+
null,
|
|
218
|
+
null,
|
|
219
|
+
null,
|
|
220
|
+
null,
|
|
221
|
+
null,
|
|
222
|
+
"u256",
|
|
223
|
+
"u256",
|
|
224
|
+
"u64",
|
|
225
|
+
"u8",
|
|
226
|
+
null,
|
|
227
|
+
"0x2::clock::Clock",
|
|
228
|
+
];
|
|
229
|
+
const parameterNames = [
|
|
230
|
+
"config",
|
|
231
|
+
"studio",
|
|
232
|
+
"walrusSystem",
|
|
233
|
+
"storageTreasury",
|
|
234
|
+
"storageSpace",
|
|
235
|
+
"blobId",
|
|
236
|
+
"rootHash",
|
|
237
|
+
"unencodedBlobSize",
|
|
238
|
+
"encodingType",
|
|
239
|
+
"payment",
|
|
240
|
+
];
|
|
241
|
+
return (tx) => tx.moveCall({
|
|
242
|
+
package: packageAddress,
|
|
243
|
+
module: "app",
|
|
244
|
+
function: "allocate_storage_and_register_blob_with_payment",
|
|
245
|
+
arguments: normalizeMoveArguments(options.arguments, argumentsTypes, parameterNames),
|
|
246
|
+
});
|
|
247
|
+
}
|
|
248
|
+
export function startPublishArticleWithWalPayment(options) {
|
|
249
|
+
const packageAddress = options.package ?? "@local-pkg/zing_studio";
|
|
250
|
+
const argumentsTypes = [
|
|
251
|
+
null,
|
|
252
|
+
null,
|
|
253
|
+
null,
|
|
254
|
+
null,
|
|
255
|
+
null,
|
|
256
|
+
"0x1::option::Option<u8>",
|
|
257
|
+
"vector<u256>",
|
|
258
|
+
"vector<u256>",
|
|
259
|
+
"vector<u64>",
|
|
260
|
+
"u8",
|
|
261
|
+
"vector<0x1::string::String>",
|
|
262
|
+
"vector<u64>",
|
|
263
|
+
"vector<0x1::string::String>",
|
|
264
|
+
"vector<u64>",
|
|
265
|
+
null,
|
|
266
|
+
"0x2::clock::Clock",
|
|
267
|
+
];
|
|
268
|
+
const parameterNames = [
|
|
269
|
+
"config",
|
|
270
|
+
"studio",
|
|
271
|
+
"walrusSystem",
|
|
272
|
+
"storageTreasury",
|
|
273
|
+
"storageSpace",
|
|
274
|
+
"subscriptionLevel",
|
|
275
|
+
"blobIds",
|
|
276
|
+
"rootHashes",
|
|
277
|
+
"unencodedBlobSizes",
|
|
278
|
+
"encodingType",
|
|
279
|
+
"identifiers",
|
|
280
|
+
"blobIndexes",
|
|
281
|
+
"mimeTypes",
|
|
282
|
+
"metadataSizes",
|
|
283
|
+
"payment",
|
|
284
|
+
];
|
|
285
|
+
return (tx) => tx.moveCall({
|
|
286
|
+
package: packageAddress,
|
|
287
|
+
module: "app",
|
|
288
|
+
function: "start_publish_article_with_wal_payment",
|
|
289
|
+
arguments: normalizeMoveArguments(options.arguments, argumentsTypes, parameterNames),
|
|
290
|
+
});
|
|
291
|
+
}
|
|
227
292
|
export function startPublishArticle(options) {
|
|
228
293
|
const packageAddress = options.package ?? "@local-pkg/zing_studio";
|
|
229
294
|
const argumentsTypes = [
|
|
230
|
-
|
|
231
|
-
|
|
232
|
-
|
|
233
|
-
|
|
234
|
-
|
|
235
|
-
"
|
|
295
|
+
null,
|
|
296
|
+
null,
|
|
297
|
+
null,
|
|
298
|
+
null,
|
|
299
|
+
null,
|
|
300
|
+
"0x1::option::Option<u8>",
|
|
236
301
|
"vector<u256>",
|
|
237
302
|
"vector<u256>",
|
|
238
303
|
"vector<u64>",
|
|
239
304
|
"u8",
|
|
240
|
-
"vector<
|
|
305
|
+
"vector<0x1::string::String>",
|
|
241
306
|
"vector<u64>",
|
|
242
|
-
"vector<
|
|
307
|
+
"vector<0x1::string::String>",
|
|
243
308
|
"vector<u64>",
|
|
244
|
-
"
|
|
309
|
+
"0x2::clock::Clock",
|
|
245
310
|
];
|
|
246
311
|
const parameterNames = [
|
|
247
312
|
"config",
|
|
@@ -268,12 +333,7 @@ export function startPublishArticle(options) {
|
|
|
268
333
|
}
|
|
269
334
|
export function finalizePublishArticle(options) {
|
|
270
335
|
const packageAddress = options.package ?? "@local-pkg/zing_studio";
|
|
271
|
-
const argumentsTypes = [
|
|
272
|
-
`${packageAddress}::config::Config`,
|
|
273
|
-
`${packageAddress}::studio::Studio`,
|
|
274
|
-
`${packageAddress}::app::PublishReceipt`,
|
|
275
|
-
`${packageAddress}::article::Article`,
|
|
276
|
-
];
|
|
336
|
+
const argumentsTypes = [null, null, null, null];
|
|
277
337
|
const parameterNames = ["config", "studio", "receipt", "article"];
|
|
278
338
|
return (tx) => tx.moveCall({
|
|
279
339
|
package: packageAddress,
|
|
@@ -285,10 +345,10 @@ export function finalizePublishArticle(options) {
|
|
|
285
345
|
export function certifyArticleBlob(options) {
|
|
286
346
|
const packageAddress = options.package ?? "@local-pkg/zing_studio";
|
|
287
347
|
const argumentsTypes = [
|
|
288
|
-
|
|
289
|
-
|
|
290
|
-
|
|
291
|
-
"
|
|
348
|
+
null,
|
|
349
|
+
null,
|
|
350
|
+
null,
|
|
351
|
+
"0x2::object::ID",
|
|
292
352
|
"u64",
|
|
293
353
|
"vector<u8>",
|
|
294
354
|
"vector<u8>",
|
|
@@ -314,12 +374,12 @@ export function certifyArticleBlob(options) {
|
|
|
314
374
|
export function deleteArticle(options) {
|
|
315
375
|
const packageAddress = options.package ?? "@local-pkg/zing_studio";
|
|
316
376
|
const argumentsTypes = [
|
|
317
|
-
|
|
318
|
-
|
|
319
|
-
|
|
320
|
-
|
|
321
|
-
"
|
|
322
|
-
"
|
|
377
|
+
null,
|
|
378
|
+
null,
|
|
379
|
+
null,
|
|
380
|
+
null,
|
|
381
|
+
"0x2::object::ID",
|
|
382
|
+
"0x2::clock::Clock",
|
|
323
383
|
];
|
|
324
384
|
const parameterNames = [
|
|
325
385
|
"config",
|
|
@@ -338,12 +398,12 @@ export function deleteArticle(options) {
|
|
|
338
398
|
export function burnArticle(options) {
|
|
339
399
|
const packageAddress = options.package ?? "@local-pkg/zing_studio";
|
|
340
400
|
const argumentsTypes = [
|
|
341
|
-
|
|
342
|
-
|
|
343
|
-
|
|
344
|
-
|
|
345
|
-
"
|
|
346
|
-
"
|
|
401
|
+
null,
|
|
402
|
+
null,
|
|
403
|
+
null,
|
|
404
|
+
null,
|
|
405
|
+
"0x2::object::ID",
|
|
406
|
+
"0x2::clock::Clock",
|
|
347
407
|
];
|
|
348
408
|
const parameterNames = [
|
|
349
409
|
"config",
|
|
@@ -362,13 +422,13 @@ export function burnArticle(options) {
|
|
|
362
422
|
export function renewArticleWithStorageTreasury(options) {
|
|
363
423
|
const packageAddress = options.package ?? "@local-pkg/zing_studio";
|
|
364
424
|
const argumentsTypes = [
|
|
365
|
-
|
|
366
|
-
|
|
367
|
-
|
|
368
|
-
|
|
369
|
-
|
|
370
|
-
"
|
|
371
|
-
"
|
|
425
|
+
null,
|
|
426
|
+
null,
|
|
427
|
+
null,
|
|
428
|
+
null,
|
|
429
|
+
null,
|
|
430
|
+
"0x2::object::ID",
|
|
431
|
+
"0x2::clock::Clock",
|
|
372
432
|
];
|
|
373
433
|
const parameterNames = [
|
|
374
434
|
"config",
|
|
@@ -388,12 +448,12 @@ export function renewArticleWithStorageTreasury(options) {
|
|
|
388
448
|
export function renewArticleWithWalPayment(options) {
|
|
389
449
|
const packageAddress = options.package ?? "@local-pkg/zing_studio";
|
|
390
450
|
const argumentsTypes = [
|
|
391
|
-
|
|
392
|
-
|
|
393
|
-
|
|
394
|
-
"
|
|
395
|
-
|
|
396
|
-
"
|
|
451
|
+
null,
|
|
452
|
+
null,
|
|
453
|
+
null,
|
|
454
|
+
"0x2::object::ID",
|
|
455
|
+
null,
|
|
456
|
+
"0x2::clock::Clock",
|
|
397
457
|
];
|
|
398
458
|
const parameterNames = [
|
|
399
459
|
"config",
|
|
@@ -412,12 +472,12 @@ export function renewArticleWithWalPayment(options) {
|
|
|
412
472
|
export function updateArticleSubscriptionLevel(options) {
|
|
413
473
|
const packageAddress = options.package ?? "@local-pkg/zing_studio";
|
|
414
474
|
const argumentsTypes = [
|
|
415
|
-
|
|
416
|
-
|
|
417
|
-
|
|
418
|
-
"
|
|
419
|
-
"
|
|
420
|
-
"
|
|
475
|
+
null,
|
|
476
|
+
null,
|
|
477
|
+
null,
|
|
478
|
+
"0x2::object::ID",
|
|
479
|
+
"0x1::option::Option<u8>",
|
|
480
|
+
"0x2::clock::Clock",
|
|
421
481
|
];
|
|
422
482
|
const parameterNames = [
|
|
423
483
|
"config",
|
|
@@ -436,12 +496,12 @@ export function updateArticleSubscriptionLevel(options) {
|
|
|
436
496
|
export function donate(options) {
|
|
437
497
|
const packageAddress = options.package ?? "@local-pkg/zing_studio";
|
|
438
498
|
const argumentsTypes = [
|
|
439
|
-
|
|
440
|
-
|
|
441
|
-
|
|
442
|
-
"
|
|
443
|
-
|
|
444
|
-
"
|
|
499
|
+
null,
|
|
500
|
+
null,
|
|
501
|
+
null,
|
|
502
|
+
"0x1::string::String",
|
|
503
|
+
null,
|
|
504
|
+
"0x2::clock::Clock",
|
|
445
505
|
];
|
|
446
506
|
const parameterNames = [
|
|
447
507
|
"config",
|
|
@@ -460,9 +520,7 @@ export function donate(options) {
|
|
|
460
520
|
}
|
|
461
521
|
export function burnOrKeepPositiveCoin(options) {
|
|
462
522
|
const packageAddress = options.package ?? "@local-pkg/zing_studio";
|
|
463
|
-
const argumentsTypes = [
|
|
464
|
-
`0x0000000000000000000000000000000000000000000000000000000000000002::coin::Coin<${options.typeArguments[0]}>`,
|
|
465
|
-
];
|
|
523
|
+
const argumentsTypes = [null];
|
|
466
524
|
const parameterNames = ["coin"];
|
|
467
525
|
return (tx) => tx.moveCall({
|
|
468
526
|
package: packageAddress,
|
|
@@ -474,12 +532,8 @@ export function burnOrKeepPositiveCoin(options) {
|
|
|
474
532
|
}
|
|
475
533
|
export function payout(options) {
|
|
476
534
|
const packageAddress = options.package ?? "@local-pkg/zing_studio";
|
|
477
|
-
const argumentsTypes = [
|
|
478
|
-
|
|
479
|
-
`0x0000000000000000000000000000000000000000000000000000000000000002::coin::Coin<${options.typeArguments[0]}>`,
|
|
480
|
-
"address",
|
|
481
|
-
];
|
|
482
|
-
const parameterNames = ["treasury", "coin", "recipient"];
|
|
535
|
+
const argumentsTypes = [null, null, null, "address"];
|
|
536
|
+
const parameterNames = ["config", "treasury", "coin", "recipient"];
|
|
483
537
|
return (tx) => tx.moveCall({
|
|
484
538
|
package: packageAddress,
|
|
485
539
|
module: "app",
|
|
@@ -13,42 +13,6 @@ export declare const File: MoveStruct<{
|
|
|
13
13
|
size: import("@mysten/sui/bcs").BcsType<string, string | number | bigint, "u64">;
|
|
14
14
|
}, "@local-pkg/zing_studio::article::File">;
|
|
15
15
|
export declare const PublishArticleEvent: MoveStruct<{
|
|
16
|
-
article_id: import("@mysten/sui/bcs").BcsType<string, string | Uint8Array<ArrayBufferLike>, "bytes[32]">;
|
|
17
|
-
owner: import("@mysten/sui/bcs").BcsType<string, string | Uint8Array<ArrayBufferLike>, "bytes[32]">;
|
|
18
|
-
blob_ids: import("@mysten/sui/bcs").BcsType<string[], Iterable<string | number | bigint> & {
|
|
19
|
-
length: number;
|
|
20
|
-
}, string>;
|
|
21
|
-
blob_sizes: import("@mysten/sui/bcs").BcsType<string[], Iterable<string | number | bigint> & {
|
|
22
|
-
length: number;
|
|
23
|
-
}, string>;
|
|
24
|
-
blob_storage_sizes: import("@mysten/sui/bcs").BcsType<string[], Iterable<string | number | bigint> & {
|
|
25
|
-
length: number;
|
|
26
|
-
}, string>;
|
|
27
|
-
blob_end_epochs: import("@mysten/sui/bcs").BcsType<number[], Iterable<number> & {
|
|
28
|
-
length: number;
|
|
29
|
-
}, string>;
|
|
30
|
-
files: MoveStruct<{
|
|
31
|
-
contents: import("@mysten/sui/bcs").BcsType<{
|
|
32
|
-
key: string;
|
|
33
|
-
value: {
|
|
34
|
-
blob_index: string;
|
|
35
|
-
mime_type: string;
|
|
36
|
-
size: string;
|
|
37
|
-
};
|
|
38
|
-
}[], Iterable<{
|
|
39
|
-
key: string;
|
|
40
|
-
value: {
|
|
41
|
-
blob_index: string | number | bigint;
|
|
42
|
-
mime_type: string;
|
|
43
|
-
size: string | number | bigint;
|
|
44
|
-
};
|
|
45
|
-
}> & {
|
|
46
|
-
length: number;
|
|
47
|
-
}, string>;
|
|
48
|
-
}, "0x2::vec_map::VecMap<string, @local-pkg/zing_studio::article::File>">;
|
|
49
|
-
timestamp_ms: import("@mysten/sui/bcs").BcsType<string, string | number | bigint, "u64">;
|
|
50
|
-
}, "@local-pkg/zing_studio::article::PublishArticleEvent">;
|
|
51
|
-
export declare const PublishArticleEventV1: MoveStruct<{
|
|
52
16
|
article_id: import("@mysten/sui/bcs").BcsType<string, string | Uint8Array<ArrayBufferLike>, "bytes[32]">;
|
|
53
17
|
owner: import("@mysten/sui/bcs").BcsType<string, string | Uint8Array<ArrayBufferLike>, "bytes[32]">;
|
|
54
18
|
subscription_level: import("@mysten/sui/bcs").BcsType<number | null, number | null | undefined, "Option<u8>">;
|
|
@@ -84,7 +48,7 @@ export declare const PublishArticleEventV1: MoveStruct<{
|
|
|
84
48
|
}, string>;
|
|
85
49
|
}, "0x2::vec_map::VecMap<string, @local-pkg/zing_studio::article::File>">;
|
|
86
50
|
timestamp_ms: import("@mysten/sui/bcs").BcsType<string, string | number | bigint, "u64">;
|
|
87
|
-
}, "@local-pkg/zing_studio::article::
|
|
51
|
+
}, "@local-pkg/zing_studio::article::PublishArticleEvent">;
|
|
88
52
|
export declare const BurnArticleEvent: MoveStruct<{
|
|
89
53
|
article_id: import("@mysten/sui/bcs").BcsType<string, string | Uint8Array<ArrayBufferLike>, "bytes[32]">;
|
|
90
54
|
owner: import("@mysten/sui/bcs").BcsType<string, string | Uint8Array<ArrayBufferLike>, "bytes[32]">;
|
|
@@ -109,9 +73,7 @@ export declare const ARTICLE: MoveStruct<{
|
|
|
109
73
|
dummy_field: import("@mysten/sui/bcs").BcsType<boolean, boolean, "bool">;
|
|
110
74
|
}, "@local-pkg/zing_studio::article::ARTICLE">;
|
|
111
75
|
export declare const Article: MoveStruct<{
|
|
112
|
-
id:
|
|
113
|
-
id: import("@mysten/sui/bcs").BcsType<string, string | Uint8Array<ArrayBufferLike>, "bytes[32]">;
|
|
114
|
-
}, "0x2::object::UID">;
|
|
76
|
+
id: import("@mysten/sui/bcs").BcsType<string, string | Uint8Array<ArrayBufferLike>, "bytes[32]">;
|
|
115
77
|
owner: import("@mysten/sui/bcs").BcsType<string, string | Uint8Array<ArrayBufferLike>, "bytes[32]">;
|
|
116
78
|
deleted: import("@mysten/sui/bcs").BcsType<boolean, boolean, "bool">;
|
|
117
79
|
created_at: import("@mysten/sui/bcs").BcsType<string, string | number | bigint, "u64">;
|
|
@@ -121,36 +83,28 @@ export declare const Article: MoveStruct<{
|
|
|
121
83
|
* properties)
|
|
122
84
|
*/
|
|
123
85
|
blobs: import("@mysten/sui/bcs").BcsType<{
|
|
124
|
-
id:
|
|
125
|
-
id: string;
|
|
126
|
-
};
|
|
86
|
+
id: string;
|
|
127
87
|
registered_epoch: number;
|
|
128
88
|
blob_id: string;
|
|
129
89
|
size: string;
|
|
130
90
|
encoding_type: number;
|
|
131
91
|
certified_epoch: number | null;
|
|
132
92
|
storage: {
|
|
133
|
-
id:
|
|
134
|
-
id: string;
|
|
135
|
-
};
|
|
93
|
+
id: string;
|
|
136
94
|
start_epoch: number;
|
|
137
95
|
end_epoch: number;
|
|
138
96
|
storage_size: string;
|
|
139
97
|
};
|
|
140
98
|
deletable: boolean;
|
|
141
99
|
}[], Iterable<{
|
|
142
|
-
id:
|
|
143
|
-
id: string | Uint8Array<ArrayBufferLike>;
|
|
144
|
-
};
|
|
100
|
+
id: string | Uint8Array<ArrayBufferLike>;
|
|
145
101
|
registered_epoch: number;
|
|
146
102
|
blob_id: string | number | bigint;
|
|
147
103
|
size: string | number | bigint;
|
|
148
104
|
encoding_type: number;
|
|
149
105
|
certified_epoch: number | null | undefined;
|
|
150
106
|
storage: {
|
|
151
|
-
id:
|
|
152
|
-
id: string | Uint8Array<ArrayBufferLike>;
|
|
153
|
-
};
|
|
107
|
+
id: string | Uint8Array<ArrayBufferLike>;
|
|
154
108
|
start_epoch: number;
|
|
155
109
|
end_epoch: number;
|
|
156
110
|
storage_size: string | number | bigint;
|