neozipkit 0.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 (135) hide show
  1. package/README.md +400 -0
  2. package/contracts/Lock.sol +34 -0
  3. package/contracts/bytecode.txt +1 -0
  4. package/contracts/compile-contract.js +168 -0
  5. package/contracts/deploy/deploy-both-contracts.js +286 -0
  6. package/contracts/deploy/deploy-enhanced-contract.js +197 -0
  7. package/contracts/deploy/deploy-private-contract.js +190 -0
  8. package/contracts/deploy/deploy-public-clean.js +1063 -0
  9. package/contracts/deploy/deploy-public-contract.js +1107 -0
  10. package/contracts/deployment.config.example.js +25 -0
  11. package/contracts/remix-compile.js +222 -0
  12. package/contracts/setup-deployment.js +51 -0
  13. package/contracts/src/NZIP-NFT-Private.sol +350 -0
  14. package/contracts/src/NZIP-NFT.sol +265 -0
  15. package/contracts/src/ZipFileNFT-DEPRECATED-6field.sol +260 -0
  16. package/contracts/src/ZipFileNFT-DEPRECATED-Enhanced.sol +289 -0
  17. package/dist/browser/CertificateGeneratorBrowser.d.ts +75 -0
  18. package/dist/browser/CertificateGeneratorBrowser.js +433 -0
  19. package/dist/browser/TokenVerifierBrowser.d.ts +76 -0
  20. package/dist/browser/TokenVerifierBrowser.js +299 -0
  21. package/dist/browser/ZipKitBrowser.d.ts +18 -0
  22. package/dist/browser/ZipKitBrowser.js +250 -0
  23. package/dist/browser/ZipKitStampBrowser.d.ts +2 -0
  24. package/dist/browser/ZipKitStampBrowser.js +12 -0
  25. package/dist/browser-index.d.ts +21 -0
  26. package/dist/browser-index.js +58 -0
  27. package/dist/browser.d.ts +21 -0
  28. package/dist/browser.js +58 -0
  29. package/dist/index.d.ts +29 -0
  30. package/dist/index.js +76 -0
  31. package/dist/server/blockchain/CertificateToken.d.ts +48 -0
  32. package/dist/server/blockchain/CertificateToken.js +386 -0
  33. package/dist/server/blockchain/NFTMinter.d.ts +41 -0
  34. package/dist/server/blockchain/NFTMinter.js +323 -0
  35. package/dist/server/blockchain/TokenQuerier.d.ts +31 -0
  36. package/dist/server/blockchain/TokenQuerier.js +259 -0
  37. package/dist/server/blockchain/TokenVerifier.d.ts +20 -0
  38. package/dist/server/blockchain/TokenVerifier.js +395 -0
  39. package/dist/server/blockchain/WalletAnalyzer.d.ts +81 -0
  40. package/dist/server/blockchain/WalletAnalyzer.js +356 -0
  41. package/dist/server/blockchain/WalletFormatter.d.ts +39 -0
  42. package/dist/server/blockchain/WalletFormatter.js +196 -0
  43. package/dist/server/blockchain/WalletManager.d.ts +46 -0
  44. package/dist/server/blockchain/WalletManager.js +294 -0
  45. package/dist/server/blockchain/ZipMetadata.d.ts +27 -0
  46. package/dist/server/blockchain/ZipMetadata.js +131 -0
  47. package/dist/server/blockchain/ZipTokenProcessor.d.ts +44 -0
  48. package/dist/server/blockchain/ZipTokenProcessor.js +204 -0
  49. package/dist/server/blockchain/constants.d.ts +102 -0
  50. package/dist/server/blockchain/constants.js +968 -0
  51. package/dist/server/blockchain/index.d.ts +9 -0
  52. package/dist/server/blockchain/index.js +44 -0
  53. package/dist/server/blockchain/test-certificate.d.ts +8 -0
  54. package/dist/server/blockchain/test-certificate.js +100 -0
  55. package/dist/server/blockchain/types.d.ts +69 -0
  56. package/dist/server/blockchain/types.js +51 -0
  57. package/dist/server/platform/server/ZipKitServer.d.ts +105 -0
  58. package/dist/server/platform/server/ZipKitServer.js +437 -0
  59. package/dist/server/platform/servercomponents/ZipKitOTS.d.ts +91 -0
  60. package/dist/server/platform/servercomponents/ZipKitOTS.js +271 -0
  61. package/dist/shared/ZipEntry.d.ts +131 -0
  62. package/dist/shared/ZipEntry.js +686 -0
  63. package/dist/shared/ZipKit.d.ts +249 -0
  64. package/dist/shared/ZipKit.js +789 -0
  65. package/dist/shared/components/CertificateOTS.d.ts +15 -0
  66. package/dist/shared/components/CertificateOTS.js +116 -0
  67. package/dist/shared/components/FileSys.d.ts +2 -0
  68. package/dist/shared/components/FileSys.js +113 -0
  69. package/dist/shared/components/HashAccumulator.d.ts +55 -0
  70. package/dist/shared/components/HashAccumulator.js +100 -0
  71. package/dist/shared/components/Support.d.ts +63 -0
  72. package/dist/shared/components/Support.js +70 -0
  73. package/dist/shared/components/Util.d.ts +21 -0
  74. package/dist/shared/components/Util.js +115 -0
  75. package/dist/shared/components/ZipCrypto.d.ts +3 -0
  76. package/dist/shared/components/ZipCrypto.js +78 -0
  77. package/dist/shared/components/merkleTree.d.ts +66 -0
  78. package/dist/shared/components/merkleTree.js +136 -0
  79. package/dist/shared/constants/Errors.d.ts +53 -0
  80. package/dist/shared/constants/Errors.js +69 -0
  81. package/dist/shared/constants/Headers.d.ts +167 -0
  82. package/dist/shared/constants/Headers.js +191 -0
  83. package/dist/shared/types/index.d.ts +21 -0
  84. package/dist/shared/types/index.js +3 -0
  85. package/dist/shared/types.d.ts +33 -0
  86. package/dist/shared/types.js +8 -0
  87. package/dist/shared/version.d.ts +4 -0
  88. package/dist/shared/version.js +7 -0
  89. package/dist/types/index.d.ts +21 -0
  90. package/dist/types/index.js +3 -0
  91. package/examples/unzip-token.ts +488 -0
  92. package/examples/zip-token.ts +604 -0
  93. package/package.json +117 -0
  94. package/src/browser/CertificateGeneratorBrowser.ts +498 -0
  95. package/src/browser/TokenVerifierBrowser.ts +344 -0
  96. package/src/browser/ZipKitBrowser.ts +242 -0
  97. package/src/browser/ZipKitStampBrowser.ts +9 -0
  98. package/src/browser-index.ts +36 -0
  99. package/src/index.ts +48 -0
  100. package/src/server/blockchain/CertificateToken.ts +444 -0
  101. package/src/server/blockchain/NFTMinter.ts +357 -0
  102. package/src/server/blockchain/TokenQuerier.ts +287 -0
  103. package/src/server/blockchain/TokenVerifier.ts +453 -0
  104. package/src/server/blockchain/WalletAnalyzer.ts +397 -0
  105. package/src/server/blockchain/WalletFormatter.ts +206 -0
  106. package/src/server/blockchain/WalletManager.ts +294 -0
  107. package/src/server/blockchain/ZipMetadata.ts +117 -0
  108. package/src/server/blockchain/ZipTokenProcessor.ts +234 -0
  109. package/src/server/blockchain/constants.ts +969 -0
  110. package/src/server/blockchain/index.ts +42 -0
  111. package/src/server/blockchain/test-certificate.ts +137 -0
  112. package/src/server/blockchain/types.ts +134 -0
  113. package/src/server/platform/server/ZipKitServer.ts +459 -0
  114. package/src/server/platform/servercomponents/ZipKitOTS.ts +313 -0
  115. package/src/server/platform/servercomponents/opentimestamps.d.ts +23 -0
  116. package/src/shared/ZipEntry.ts +767 -0
  117. package/src/shared/ZipKit.ts +899 -0
  118. package/src/shared/components/CertificateOTS.ts +132 -0
  119. package/src/shared/components/FileSys.ts +87 -0
  120. package/src/shared/components/HashAccumulator.ts +113 -0
  121. package/src/shared/components/Support.ts +77 -0
  122. package/src/shared/components/Util.ts +113 -0
  123. package/src/shared/components/ZipCrypto.ts +91 -0
  124. package/src/shared/components/merkleTree.ts +162 -0
  125. package/src/shared/constants/Errors.ts +82 -0
  126. package/src/shared/constants/Headers.ts +203 -0
  127. package/src/shared/types/index.ts +25 -0
  128. package/src/shared/types/modules.d.ts +22 -0
  129. package/src/shared/types/opentimestamps.d.ts +23 -0
  130. package/src/shared/types.d.ts +8 -0
  131. package/src/shared/types.ts +43 -0
  132. package/src/shared/version.ts +4 -0
  133. package/src/types/index.ts +25 -0
  134. package/src/types/modules.d.ts +22 -0
  135. package/src/types/opentimestamps.d.ts +23 -0
@@ -0,0 +1,969 @@
1
+ /**
2
+ * Contract addresses for different networks
3
+ */
4
+ export const CONTRACT_ADDRESSES = {
5
+ NZIP_NFT: {
6
+ 84532: "0xFD76a5d420704F34d84b0767961835c43D7b30a8", // Current v2.0 contract
7
+ 8453: "", // To be configured when deploying to mainnet
8
+ 1: "", // Ethereum Mainnet
9
+ 11155111: "", // Sepolia Testnet
10
+ 137: "", // Polygon
11
+ 42161: "", // Arbitrum
12
+ } as Record<number, string>
13
+ };
14
+
15
+ /**
16
+ * Deprecated contract addresses (no longer in use)
17
+ */
18
+ export const DEPRECATED_CONTRACTS = {
19
+ NZIP_NFT_V1: {
20
+ 84532: "0xb78CB3bcC788fca38c731b1E9D70CF60b04CA015", // DEPRECATED v1.0
21
+ } as Record<number, string>
22
+ };
23
+
24
+ /**
25
+ * Complete NZIP NFT Contract v2.0 ABI
26
+ * This is the full ABI from Remix compilation used by the current deployment
27
+ */
28
+ export const NZIP_CONTRACT_ABI = [
29
+ {
30
+ "inputs": [],
31
+ "stateMutability": "nonpayable",
32
+ "type": "constructor"
33
+ },
34
+ {
35
+ "inputs": [
36
+ {
37
+ "internalType": "address",
38
+ "name": "sender",
39
+ "type": "address"
40
+ },
41
+ {
42
+ "internalType": "uint256",
43
+ "name": "tokenId",
44
+ "type": "uint256"
45
+ },
46
+ {
47
+ "internalType": "address",
48
+ "name": "owner",
49
+ "type": "address"
50
+ }
51
+ ],
52
+ "name": "ERC721IncorrectOwner",
53
+ "type": "error"
54
+ },
55
+ {
56
+ "inputs": [
57
+ {
58
+ "internalType": "address",
59
+ "name": "operator",
60
+ "type": "address"
61
+ },
62
+ {
63
+ "internalType": "uint256",
64
+ "name": "tokenId",
65
+ "type": "uint256"
66
+ }
67
+ ],
68
+ "name": "ERC721InsufficientApproval",
69
+ "type": "error"
70
+ },
71
+ {
72
+ "inputs": [
73
+ {
74
+ "internalType": "address",
75
+ "name": "approver",
76
+ "type": "address"
77
+ }
78
+ ],
79
+ "name": "ERC721InvalidApprover",
80
+ "type": "error"
81
+ },
82
+ {
83
+ "inputs": [
84
+ {
85
+ "internalType": "address",
86
+ "name": "operator",
87
+ "type": "address"
88
+ }
89
+ ],
90
+ "name": "ERC721InvalidOperator",
91
+ "type": "error"
92
+ },
93
+ {
94
+ "inputs": [
95
+ {
96
+ "internalType": "address",
97
+ "name": "owner",
98
+ "type": "address"
99
+ }
100
+ ],
101
+ "name": "ERC721InvalidOwner",
102
+ "type": "error"
103
+ },
104
+ {
105
+ "inputs": [
106
+ {
107
+ "internalType": "address",
108
+ "name": "receiver",
109
+ "type": "address"
110
+ }
111
+ ],
112
+ "name": "ERC721InvalidReceiver",
113
+ "type": "error"
114
+ },
115
+ {
116
+ "inputs": [
117
+ {
118
+ "internalType": "address",
119
+ "name": "sender",
120
+ "type": "address"
121
+ }
122
+ ],
123
+ "name": "ERC721InvalidSender",
124
+ "type": "error"
125
+ },
126
+ {
127
+ "inputs": [
128
+ {
129
+ "internalType": "uint256",
130
+ "name": "tokenId",
131
+ "type": "uint256"
132
+ }
133
+ ],
134
+ "name": "ERC721NonexistentToken",
135
+ "type": "error"
136
+ },
137
+ {
138
+ "inputs": [
139
+ {
140
+ "internalType": "address",
141
+ "name": "owner",
142
+ "type": "address"
143
+ }
144
+ ],
145
+ "name": "OwnableInvalidOwner",
146
+ "type": "error"
147
+ },
148
+ {
149
+ "inputs": [
150
+ {
151
+ "internalType": "address",
152
+ "name": "account",
153
+ "type": "address"
154
+ }
155
+ ],
156
+ "name": "OwnableUnauthorizedAccount",
157
+ "type": "error"
158
+ },
159
+ {
160
+ "anonymous": false,
161
+ "inputs": [
162
+ {
163
+ "indexed": true,
164
+ "internalType": "address",
165
+ "name": "owner",
166
+ "type": "address"
167
+ },
168
+ {
169
+ "indexed": true,
170
+ "internalType": "address",
171
+ "name": "approved",
172
+ "type": "address"
173
+ },
174
+ {
175
+ "indexed": true,
176
+ "internalType": "uint256",
177
+ "name": "tokenId",
178
+ "type": "uint256"
179
+ }
180
+ ],
181
+ "name": "Approval",
182
+ "type": "event"
183
+ },
184
+ {
185
+ "anonymous": false,
186
+ "inputs": [
187
+ {
188
+ "indexed": true,
189
+ "internalType": "address",
190
+ "name": "owner",
191
+ "type": "address"
192
+ },
193
+ {
194
+ "indexed": true,
195
+ "internalType": "address",
196
+ "name": "operator",
197
+ "type": "address"
198
+ },
199
+ {
200
+ "indexed": false,
201
+ "internalType": "bool",
202
+ "name": "approved",
203
+ "type": "bool"
204
+ }
205
+ ],
206
+ "name": "ApprovalForAll",
207
+ "type": "event"
208
+ },
209
+ {
210
+ "anonymous": false,
211
+ "inputs": [
212
+ {
213
+ "indexed": false,
214
+ "internalType": "uint256",
215
+ "name": "_fromTokenId",
216
+ "type": "uint256"
217
+ },
218
+ {
219
+ "indexed": false,
220
+ "internalType": "uint256",
221
+ "name": "_toTokenId",
222
+ "type": "uint256"
223
+ }
224
+ ],
225
+ "name": "BatchMetadataUpdate",
226
+ "type": "event"
227
+ },
228
+ {
229
+ "anonymous": false,
230
+ "inputs": [
231
+ {
232
+ "indexed": false,
233
+ "internalType": "uint256",
234
+ "name": "_tokenId",
235
+ "type": "uint256"
236
+ }
237
+ ],
238
+ "name": "MetadataUpdate",
239
+ "type": "event"
240
+ },
241
+ {
242
+ "anonymous": false,
243
+ "inputs": [
244
+ {
245
+ "indexed": true,
246
+ "internalType": "address",
247
+ "name": "previousOwner",
248
+ "type": "address"
249
+ },
250
+ {
251
+ "indexed": true,
252
+ "internalType": "address",
253
+ "name": "newOwner",
254
+ "type": "address"
255
+ }
256
+ ],
257
+ "name": "OwnershipTransferred",
258
+ "type": "event"
259
+ },
260
+ {
261
+ "anonymous": false,
262
+ "inputs": [
263
+ {
264
+ "indexed": true,
265
+ "internalType": "address",
266
+ "name": "from",
267
+ "type": "address"
268
+ },
269
+ {
270
+ "indexed": true,
271
+ "internalType": "address",
272
+ "name": "to",
273
+ "type": "address"
274
+ },
275
+ {
276
+ "indexed": true,
277
+ "internalType": "uint256",
278
+ "name": "tokenId",
279
+ "type": "uint256"
280
+ }
281
+ ],
282
+ "name": "Transfer",
283
+ "type": "event"
284
+ },
285
+ {
286
+ "anonymous": false,
287
+ "inputs": [
288
+ {
289
+ "indexed": true,
290
+ "internalType": "uint256",
291
+ "name": "tokenId",
292
+ "type": "uint256"
293
+ },
294
+ {
295
+ "indexed": true,
296
+ "internalType": "address",
297
+ "name": "creator",
298
+ "type": "address"
299
+ },
300
+ {
301
+ "indexed": false,
302
+ "internalType": "string",
303
+ "name": "fileName",
304
+ "type": "string"
305
+ },
306
+ {
307
+ "indexed": false,
308
+ "internalType": "string",
309
+ "name": "merkleRootHash",
310
+ "type": "string"
311
+ },
312
+ {
313
+ "indexed": false,
314
+ "internalType": "uint256",
315
+ "name": "creationTimestamp",
316
+ "type": "uint256"
317
+ },
318
+ {
319
+ "indexed": false,
320
+ "internalType": "string",
321
+ "name": "ipfsHash",
322
+ "type": "string"
323
+ },
324
+ {
325
+ "indexed": false,
326
+ "internalType": "uint256",
327
+ "name": "tokenizationTime",
328
+ "type": "uint256"
329
+ },
330
+ {
331
+ "indexed": false,
332
+ "internalType": "uint256",
333
+ "name": "blockNumber",
334
+ "type": "uint256"
335
+ }
336
+ ],
337
+ "name": "ZipFileTokenized",
338
+ "type": "event"
339
+ },
340
+ {
341
+ "inputs": [
342
+ {
343
+ "internalType": "address",
344
+ "name": "to",
345
+ "type": "address"
346
+ },
347
+ {
348
+ "internalType": "uint256",
349
+ "name": "tokenId",
350
+ "type": "uint256"
351
+ }
352
+ ],
353
+ "name": "approve",
354
+ "outputs": [],
355
+ "stateMutability": "nonpayable",
356
+ "type": "function"
357
+ },
358
+ {
359
+ "inputs": [
360
+ {
361
+ "internalType": "address",
362
+ "name": "owner",
363
+ "type": "address"
364
+ }
365
+ ],
366
+ "name": "balanceOf",
367
+ "outputs": [
368
+ {
369
+ "internalType": "uint256",
370
+ "name": "",
371
+ "type": "uint256"
372
+ }
373
+ ],
374
+ "stateMutability": "view",
375
+ "type": "function"
376
+ },
377
+ {
378
+ "inputs": [
379
+ {
380
+ "internalType": "bytes32",
381
+ "name": "",
382
+ "type": "bytes32"
383
+ }
384
+ ],
385
+ "name": "compositeKeyToTokenId",
386
+ "outputs": [
387
+ {
388
+ "internalType": "uint256",
389
+ "name": "",
390
+ "type": "uint256"
391
+ }
392
+ ],
393
+ "stateMutability": "view",
394
+ "type": "function"
395
+ },
396
+ {
397
+ "inputs": [
398
+ {
399
+ "internalType": "string",
400
+ "name": "merkleRootHash",
401
+ "type": "string"
402
+ },
403
+ {
404
+ "internalType": "uint256",
405
+ "name": "creationTimestamp",
406
+ "type": "uint256"
407
+ }
408
+ ],
409
+ "name": "generateCompositeKey",
410
+ "outputs": [
411
+ {
412
+ "internalType": "bytes32",
413
+ "name": "",
414
+ "type": "bytes32"
415
+ }
416
+ ],
417
+ "stateMutability": "pure",
418
+ "type": "function"
419
+ },
420
+ {
421
+ "inputs": [
422
+ {
423
+ "internalType": "uint256",
424
+ "name": "tokenId",
425
+ "type": "uint256"
426
+ }
427
+ ],
428
+ "name": "getApproved",
429
+ "outputs": [
430
+ {
431
+ "internalType": "address",
432
+ "name": "",
433
+ "type": "address"
434
+ }
435
+ ],
436
+ "stateMutability": "view",
437
+ "type": "function"
438
+ },
439
+ {
440
+ "inputs": [
441
+ {
442
+ "internalType": "uint256",
443
+ "name": "tokenId",
444
+ "type": "uint256"
445
+ }
446
+ ],
447
+ "name": "getBlockchainMetadata",
448
+ "outputs": [
449
+ {
450
+ "internalType": "uint256",
451
+ "name": "blockNumber",
452
+ "type": "uint256"
453
+ },
454
+ {
455
+ "internalType": "uint256",
456
+ "name": "tokenizationTime",
457
+ "type": "uint256"
458
+ }
459
+ ],
460
+ "stateMutability": "view",
461
+ "type": "function"
462
+ },
463
+ {
464
+ "inputs": [
465
+ {
466
+ "internalType": "string",
467
+ "name": "merkleRoot",
468
+ "type": "string"
469
+ }
470
+ ],
471
+ "name": "getTokensByMerkleRoot",
472
+ "outputs": [
473
+ {
474
+ "internalType": "uint256[]",
475
+ "name": "",
476
+ "type": "uint256[]"
477
+ }
478
+ ],
479
+ "stateMutability": "view",
480
+ "type": "function"
481
+ },
482
+ {
483
+ "inputs": [],
484
+ "name": "getVersion",
485
+ "outputs": [
486
+ {
487
+ "internalType": "string",
488
+ "name": "",
489
+ "type": "string"
490
+ }
491
+ ],
492
+ "stateMutability": "pure",
493
+ "type": "function"
494
+ },
495
+ {
496
+ "inputs": [
497
+ {
498
+ "internalType": "uint256",
499
+ "name": "tokenId",
500
+ "type": "uint256"
501
+ }
502
+ ],
503
+ "name": "getZipFileInfo",
504
+ "outputs": [
505
+ {
506
+ "components": [
507
+ {
508
+ "internalType": "string",
509
+ "name": "fileName",
510
+ "type": "string"
511
+ },
512
+ {
513
+ "internalType": "string",
514
+ "name": "merkleRootHash",
515
+ "type": "string"
516
+ },
517
+ {
518
+ "internalType": "string",
519
+ "name": "ipfsHash",
520
+ "type": "string"
521
+ },
522
+ {
523
+ "internalType": "address",
524
+ "name": "creator",
525
+ "type": "address"
526
+ },
527
+ {
528
+ "internalType": "uint256",
529
+ "name": "creationTimestamp",
530
+ "type": "uint256"
531
+ },
532
+ {
533
+ "internalType": "uint256",
534
+ "name": "tokenizationTime",
535
+ "type": "uint256"
536
+ },
537
+ {
538
+ "internalType": "uint256",
539
+ "name": "blockNumber",
540
+ "type": "uint256"
541
+ }
542
+ ],
543
+ "internalType": "struct ZipFileNFT.ZipFileInfo",
544
+ "name": "",
545
+ "type": "tuple"
546
+ }
547
+ ],
548
+ "stateMutability": "view",
549
+ "type": "function"
550
+ },
551
+ {
552
+ "inputs": [
553
+ {
554
+ "internalType": "address",
555
+ "name": "owner",
556
+ "type": "address"
557
+ },
558
+ {
559
+ "internalType": "address",
560
+ "name": "operator",
561
+ "type": "address"
562
+ }
563
+ ],
564
+ "name": "isApprovedForAll",
565
+ "outputs": [
566
+ {
567
+ "internalType": "bool",
568
+ "name": "",
569
+ "type": "bool"
570
+ }
571
+ ],
572
+ "stateMutability": "view",
573
+ "type": "function"
574
+ },
575
+ {
576
+ "inputs": [
577
+ {
578
+ "internalType": "string",
579
+ "name": "merkleRootHash",
580
+ "type": "string"
581
+ },
582
+ {
583
+ "internalType": "uint256",
584
+ "name": "creationTimestamp",
585
+ "type": "uint256"
586
+ }
587
+ ],
588
+ "name": "isZipFileTokenized",
589
+ "outputs": [
590
+ {
591
+ "internalType": "bool",
592
+ "name": "exists",
593
+ "type": "bool"
594
+ },
595
+ {
596
+ "internalType": "uint256",
597
+ "name": "tokenId",
598
+ "type": "uint256"
599
+ }
600
+ ],
601
+ "stateMutability": "view",
602
+ "type": "function"
603
+ },
604
+ {
605
+ "inputs": [],
606
+ "name": "name",
607
+ "outputs": [
608
+ {
609
+ "internalType": "string",
610
+ "name": "",
611
+ "type": "string"
612
+ }
613
+ ],
614
+ "stateMutability": "view",
615
+ "type": "function"
616
+ },
617
+ {
618
+ "inputs": [],
619
+ "name": "owner",
620
+ "outputs": [
621
+ {
622
+ "internalType": "address",
623
+ "name": "",
624
+ "type": "address"
625
+ }
626
+ ],
627
+ "stateMutability": "view",
628
+ "type": "function"
629
+ },
630
+ {
631
+ "inputs": [
632
+ {
633
+ "internalType": "uint256",
634
+ "name": "tokenId",
635
+ "type": "uint256"
636
+ }
637
+ ],
638
+ "name": "ownerOf",
639
+ "outputs": [
640
+ {
641
+ "internalType": "address",
642
+ "name": "",
643
+ "type": "address"
644
+ }
645
+ ],
646
+ "stateMutability": "view",
647
+ "type": "function"
648
+ },
649
+ {
650
+ "inputs": [
651
+ {
652
+ "internalType": "string",
653
+ "name": "fileName",
654
+ "type": "string"
655
+ },
656
+ {
657
+ "internalType": "string",
658
+ "name": "merkleRootHash",
659
+ "type": "string"
660
+ },
661
+ {
662
+ "internalType": "uint256",
663
+ "name": "creationTimestamp",
664
+ "type": "uint256"
665
+ },
666
+ {
667
+ "internalType": "string",
668
+ "name": "ipfsHash",
669
+ "type": "string"
670
+ },
671
+ {
672
+ "internalType": "string",
673
+ "name": "metadataURI",
674
+ "type": "string"
675
+ }
676
+ ],
677
+ "name": "publicMintZipFile",
678
+ "outputs": [
679
+ {
680
+ "internalType": "uint256",
681
+ "name": "",
682
+ "type": "uint256"
683
+ }
684
+ ],
685
+ "stateMutability": "nonpayable",
686
+ "type": "function"
687
+ },
688
+ {
689
+ "inputs": [],
690
+ "name": "renounceOwnership",
691
+ "outputs": [],
692
+ "stateMutability": "nonpayable",
693
+ "type": "function"
694
+ },
695
+ {
696
+ "inputs": [
697
+ {
698
+ "internalType": "address",
699
+ "name": "from",
700
+ "type": "address"
701
+ },
702
+ {
703
+ "internalType": "address",
704
+ "name": "to",
705
+ "type": "address"
706
+ },
707
+ {
708
+ "internalType": "uint256",
709
+ "name": "tokenId",
710
+ "type": "uint256"
711
+ }
712
+ ],
713
+ "name": "safeTransferFrom",
714
+ "outputs": [],
715
+ "stateMutability": "nonpayable",
716
+ "type": "function"
717
+ },
718
+ {
719
+ "inputs": [
720
+ {
721
+ "internalType": "address",
722
+ "name": "from",
723
+ "type": "address"
724
+ },
725
+ {
726
+ "internalType": "address",
727
+ "name": "to",
728
+ "type": "address"
729
+ },
730
+ {
731
+ "internalType": "uint256",
732
+ "name": "tokenId",
733
+ "type": "uint256"
734
+ },
735
+ {
736
+ "internalType": "bytes",
737
+ "name": "data",
738
+ "type": "bytes"
739
+ }
740
+ ],
741
+ "name": "safeTransferFrom",
742
+ "outputs": [],
743
+ "stateMutability": "nonpayable",
744
+ "type": "function"
745
+ },
746
+ {
747
+ "inputs": [
748
+ {
749
+ "internalType": "address",
750
+ "name": "operator",
751
+ "type": "address"
752
+ },
753
+ {
754
+ "internalType": "bool",
755
+ "name": "approved",
756
+ "type": "bool"
757
+ }
758
+ ],
759
+ "name": "setApprovalForAll",
760
+ "outputs": [],
761
+ "stateMutability": "nonpayable",
762
+ "type": "function"
763
+ },
764
+ {
765
+ "inputs": [
766
+ {
767
+ "internalType": "bytes4",
768
+ "name": "interfaceId",
769
+ "type": "bytes4"
770
+ }
771
+ ],
772
+ "name": "supportsInterface",
773
+ "outputs": [
774
+ {
775
+ "internalType": "bool",
776
+ "name": "",
777
+ "type": "bool"
778
+ }
779
+ ],
780
+ "stateMutability": "view",
781
+ "type": "function"
782
+ },
783
+ {
784
+ "inputs": [],
785
+ "name": "symbol",
786
+ "outputs": [
787
+ {
788
+ "internalType": "string",
789
+ "name": "",
790
+ "type": "string"
791
+ }
792
+ ],
793
+ "stateMutability": "view",
794
+ "type": "function"
795
+ },
796
+ {
797
+ "inputs": [
798
+ {
799
+ "internalType": "uint256",
800
+ "name": "tokenId",
801
+ "type": "uint256"
802
+ }
803
+ ],
804
+ "name": "tokenURI",
805
+ "outputs": [
806
+ {
807
+ "internalType": "string",
808
+ "name": "",
809
+ "type": "string"
810
+ }
811
+ ],
812
+ "stateMutability": "view",
813
+ "type": "function"
814
+ },
815
+ {
816
+ "inputs": [],
817
+ "name": "totalSupply",
818
+ "outputs": [
819
+ {
820
+ "internalType": "uint256",
821
+ "name": "",
822
+ "type": "uint256"
823
+ }
824
+ ],
825
+ "stateMutability": "view",
826
+ "type": "function"
827
+ },
828
+ {
829
+ "inputs": [
830
+ {
831
+ "internalType": "address",
832
+ "name": "from",
833
+ "type": "address"
834
+ },
835
+ {
836
+ "internalType": "address",
837
+ "name": "to",
838
+ "type": "address"
839
+ },
840
+ {
841
+ "internalType": "uint256",
842
+ "name": "tokenId",
843
+ "type": "uint256"
844
+ }
845
+ ],
846
+ "name": "transferFrom",
847
+ "outputs": [],
848
+ "stateMutability": "nonpayable",
849
+ "type": "function"
850
+ },
851
+ {
852
+ "inputs": [
853
+ {
854
+ "internalType": "address",
855
+ "name": "newOwner",
856
+ "type": "address"
857
+ }
858
+ ],
859
+ "name": "transferOwnership",
860
+ "outputs": [],
861
+ "stateMutability": "nonpayable",
862
+ "type": "function"
863
+ },
864
+ {
865
+ "inputs": [
866
+ {
867
+ "internalType": "uint256",
868
+ "name": "tokenId",
869
+ "type": "uint256"
870
+ },
871
+ {
872
+ "internalType": "string",
873
+ "name": "providedMerkleRoot",
874
+ "type": "string"
875
+ }
876
+ ],
877
+ "name": "verifyZipFile",
878
+ "outputs": [
879
+ {
880
+ "internalType": "bool",
881
+ "name": "isValid",
882
+ "type": "bool"
883
+ }
884
+ ],
885
+ "stateMutability": "view",
886
+ "type": "function"
887
+ },
888
+ {
889
+ "inputs": [
890
+ {
891
+ "internalType": "uint256",
892
+ "name": "",
893
+ "type": "uint256"
894
+ }
895
+ ],
896
+ "name": "zipFileInfo",
897
+ "outputs": [
898
+ {
899
+ "internalType": "string",
900
+ "name": "fileName",
901
+ "type": "string"
902
+ },
903
+ {
904
+ "internalType": "string",
905
+ "name": "merkleRootHash",
906
+ "type": "string"
907
+ },
908
+ {
909
+ "internalType": "string",
910
+ "name": "ipfsHash",
911
+ "type": "string"
912
+ },
913
+ {
914
+ "internalType": "address",
915
+ "name": "creator",
916
+ "type": "address"
917
+ },
918
+ {
919
+ "internalType": "uint256",
920
+ "name": "creationTimestamp",
921
+ "type": "uint256"
922
+ },
923
+ {
924
+ "internalType": "uint256",
925
+ "name": "tokenizationTime",
926
+ "type": "uint256"
927
+ },
928
+ {
929
+ "internalType": "uint256",
930
+ "name": "blockNumber",
931
+ "type": "uint256"
932
+ }
933
+ ],
934
+ "stateMutability": "view",
935
+ "type": "function"
936
+ }
937
+ ];
938
+
939
+ /**
940
+ * Helper function to get contract address for a chain
941
+ */
942
+ export function getNZipContractAddress(chainId: number): string {
943
+ return CONTRACT_ADDRESSES.NZIP_NFT[chainId] || "";
944
+ }
945
+
946
+ /**
947
+ * Network configurations
948
+ */
949
+ export const NETWORK_CONFIG: Record<number, string> = {
950
+ 1: "Ethereum Mainnet",
951
+ 11155111: "Sepolia Testnet",
952
+ 84532: "Base Sepolia",
953
+ 8453: "Base Mainnet",
954
+ 137: "Polygon",
955
+ 42161: "Arbitrum",
956
+ };
957
+
958
+ /**
959
+ * Current deployment information
960
+ */
961
+ export const CURRENT_DEPLOYMENT = {
962
+ version: "2.0.0",
963
+ network: "Base Sepolia",
964
+ chainId: 84532,
965
+ address: CONTRACT_ADDRESSES.NZIP_NFT[84532],
966
+ deployedAt: "2024-11-29", // Update when deploying to new networks
967
+ txHash: "0x7f12a5974b6e6ee6cbb8bc6068b6d784fcc448a6fc567d1cc8a34b98a48efd9f",
968
+ explorer: "https://sepolia.basescan.org/address/0xFD76a5d420704F34d84b0767961835c43D7b30a8"
969
+ };