BCD

Tezos Contract Explorer
Search Networks Deploy
  • Home
  • /
  • Mainnet
  • /
  • FXHASH Generative Tokens v2
operations (4.23M)Storage Code Interact Tokens Fork Views Statistics Details
Latest
​x
484
 
1
{ parameter (or
2
              (or
3
                (or
4
                  (or
5
                    (or (nat %burn) (pair %burn_supply (nat %amount) (nat %issuer_id)))
6
                    (or (unit %close_seed_mode)
7
                        (pair %mint (nat %issuer_id)
8
                                    (pair (option %referrer address)
9
                                          (option %reserve_input bytes)))))
10
                  (or
11
                    (or
12
                      (pair %mint_issuer
13
                        (pair (pair (nat %amount) (bool %enabled))
14
                              (pair (bytes %metadata)
15
                                    (pair %pricing (bytes %details) (nat %pricing_id))))
16
                        (pair
17
                          (pair
18
                            (list %primary_split (pair (address %address) (nat %pct)))
19
                            (list %reserves (pair (nat %amount)
20
                                                 (pair (bytes %data) (nat %method_id)))))
21
                          (pair (nat %royalties)
22
                                (pair
23
                                  (list %royalties_split (pair (address %address)
24
                                                              (nat %pct)))
25
                                  (list %tags nat)))))
26
                      (list %seed_tokens (pair
27
                                          (pair
28
                                            (pair (address %author)
29
                                                  (pair (nat %balance) (bool %enabled)))
30
                                            (pair (nat %id)
31
                                                  (pair (bytes %metadata)
32
                                                        (nat %original_supply))))
33
                                          (pair
34
                                            (pair (nat %pricing_id)
35
                                                  (pair
36
                                                    (list %primary_split (pair
37
                                                                          (address %address)
38
                                                                          (nat %pct)))
39
                                                    (nat %royalties)))
40
                                            (pair
41
                                              (list %royalties_split (pair
42
                                                                      (address %address)
43
                                                                      (nat %pct)))
44
                                              (pair (nat %supply)
45
                                                    (timestamp %timestamp_minted)))))))
46
                    (or (nat %set_fees)
47
                        (or (bytes %set_gentk_void_metadata) (nat %set_lock_time)))))
48
                (or
49
                  (or
50
                    (or
51
                      (pair %set_pricing_contract (address %address)
52
                                                  (pair (bool %enabled) (nat %id)))
53
                      (nat %set_referrer_fees_share))
54
                    (or
55
                      (pair %set_reserve_method (nat %id)
56
                                                (pair %reserve_method
57
                                                  (lambda %apply_reserve
58
                                                    (pair
59
                                                      (pair (nat %current_amount)
60
                                                            (bytes %current_data))
61
                                                      (pair (address %sender)
62
                                                            (option %user_input bytes)))
63
                                                    (pair (bool %applied)
64
                                                          (bytes %new_data)))
65
                                                  (pair (bool %enabled)
66
                                                        (lambda %is_valid
67
                                                          (pair (nat %amount)
68
                                                                (pair (bytes %data)
69
                                                                      (address %sender)))
70
                                                          bool))))
71
                      (pair %set_reserve_method_enabled (bool %enabled) (nat %id))))
72
                  (or
73
                    (or (option %transfer_xtz_treasury mutez)
74
                        (pair %update_issuer (pair (bool %enabled) (nat %issuer_id))
75
                                             (pair
76
                                               (list %primary_split (pair
77
                                                                     (address %address)
78
                                                                     (nat %pct)))
79
                                               (pair (nat %royalties)
80
                                                     (list %royalties_split (pair
81
                                                                             (address %address)
82
                                                                             (nat %pct)))))))
83
                    (or (pair %update_price (bytes %details) (nat %issuer_id))
84
                        (or
85
                          (pair %update_reserve (nat %issuer_id)
86
                                                (list %reserves (pair (nat %amount)
87
                                                                     (pair (bytes %data)
88
                                                                           (nat %method_id)))))
89
                          (pair %update_token_mod (nat %issuer_id) (list %tags nat)))))))
90
              (or
91
                (or (pair %ep_set_enabled (bool %enabled) (string %name))
92
                    (or (unit %lock_eps)
93
                        (list %set_addresses (pair (address %address)
94
                                                  (string %address_id)))))
95
                (or
96
                  (or (address %set_administrator) (big_map %set_metadata string bytes))
97
                  (or (bool %set_pause)
98
                      (pair %update_ep
99
                        (lambda %code
100
                          (pair
101
                            (or
102
                              (or
103
                                (or
104
                                  (or (nat %burn)
105
                                      (pair %burn_supply (nat %amount) (nat %issuer_id)))
106
                                  (or (unit %close_seed_mode)
107
                                      (pair %mint (nat %issuer_id)
108
                                                  (pair (option %referrer address)
109
                                                        (option %reserve_input bytes)))))
110
                                (or
111
                                  (or
112
                                    (pair %mint_issuer
113
                                      (pair (pair (nat %amount) (bool %enabled))
114
                                            (pair (bytes %metadata)
115
                                                  (pair %pricing (bytes %details)
116
                                                                 (nat %pricing_id))))
117
                                      (pair
118
                                        (pair
119
                                          (list %primary_split (pair (address %address)
120
                                                                    (nat %pct)))
121
                                          (list %reserves (pair (nat %amount)
122
                                                               (pair (bytes %data)
123
                                                                     (nat %method_id)))))
124
                                        (pair (nat %royalties)
125
                                              (pair
126
                                                (list %royalties_split (pair
127
                                                                        (address %address)
128
                                                                        (nat %pct)))
129
                                                (list %tags nat)))))
130
                                    (list %seed_tokens (pair
131
                                                        (pair
132
                                                          (pair (address %author)
133
                                                                (pair (nat %balance)
134
                                                                      (bool %enabled)))
135
                                                          (pair (nat %id)
136
                                                                (pair (bytes %metadata)
137
                                                                      (nat %original_supply))))
138
                                                        (pair
139
                                                          (pair (nat %pricing_id)
140
                                                                (pair
141
                                                                  (list %primary_split (pair
142
                                                                                        (address %address)
143
                                                                                        (nat %pct)))
144
                                                                  (nat %royalties)))
145
                                                          (pair
146
                                                            (list %royalties_split (pair
147
                                                                                    (address %address)
148
                                                                                    (nat %pct)))
149
                                                            (pair (nat %supply)
150
                                                                  (timestamp %timestamp_minted)))))))
151
                                  (or (nat %set_fees)
152
                                      (or (bytes %set_gentk_void_metadata)
153
                                          (nat %set_lock_time)))))
154
                              (or
155
                                (or
156
                                  (or
157
                                    (pair %set_pricing_contract (address %address)
158
                                                                (pair (bool %enabled)
159
                                                                      (nat %id)))
160
                                    (nat %set_referrer_fees_share))
161
                                  (or
162
                                    (pair %set_reserve_method (nat %id)
163
                                                              (pair %reserve_method
164
                                                                (lambda %apply_reserve
165
                                                                  (pair
166
                                                                    (pair
167
                                                                      (nat %current_amount)
168
                                                                      (bytes %current_data))
169
                                                                    (pair
170
                                                                      (address %sender)
171
                                                                      (option %user_input bytes)))
172
                                                                  (pair (bool %applied)
173
                                                                        (bytes %new_data)))
174
                                                                (pair (bool %enabled)
175
                                                                      (lambda %is_valid
176
                                                                        (pair
177
                                                                          (nat %amount)
178
                                                                          (pair
179
                                                                            (bytes %data)
180
                                                                            (address %sender)))
181
                                                                        bool))))
182
                                    (pair %set_reserve_method_enabled (bool %enabled)
183
                                                                      (nat %id))))
184
                                (or
185
                                  (or (option %transfer_xtz_treasury mutez)
186
                                      (pair %update_issuer
187
                                        (pair (bool %enabled) (nat %issuer_id))
188
                                        (pair
189
                                          (list %primary_split (pair (address %address)
190
                                                                    (nat %pct)))
191
                                          (pair (nat %royalties)
192
                                                (list %royalties_split (pair
193
                                                                        (address %address)
194
                                                                        (nat %pct)))))))
195
                                  (or
196
                                    (pair %update_price (bytes %details)
197
                                                        (nat %issuer_id))
198
                                    (or
199
                                      (pair %update_reserve (nat %issuer_id)
200
                                                            (list %reserves (pair
201
                                                                             (nat %amount)
202
                                                                             (pair
203
                                                                               (bytes %data)
204
                                                                               (nat %method_id)))))
205
                                      (pair %update_token_mod (nat %issuer_id)
206
                                                              (list %tags nat)))))))
207
                            (pair
208
                              (pair
209
                                (pair
210
                                  (pair (big_map %addresses string address)
211
                                        (address %admin))
212
                                  (pair (nat %all_gentk_tokens) (nat %all_tokens)))
213
                                (pair
214
                                  (pair (big_map %entrypoints_enabled string bool)
215
                                        (big_map %extended_storage bytes bytes))
216
                                  (pair (nat %fees)
217
                                        (pair (bytes %gentk_void_metadata)
218
                                              (big_map %ledger nat
219
                                                               (pair
220
                                                                 (pair
221
                                                                   (pair
222
                                                                     (address %author)
223
                                                                     (pair
224
                                                                       (nat %balance)
225
                                                                       (bool %enabled)))
226
                                                                   (pair
227
                                                                     (pair
228
                                                                       (nat %locked_seconds)
229
                                                                       (bytes %metadata))
230
                                                                     (pair
231
                                                                       (nat %original_supply)
232
                                                                       (nat %pricing_id))))
233
                                                                 (pair
234
                                                                   (pair
235
                                                                     (list %primary_split (pair
236
                                                                                           (address %address)
237
                                                                                           (nat %pct)))
238
                                                                     (pair
239
                                                                       (list %reserves (pair
240
                                                                                        (nat %amount)
241
                                                                                        (pair
242
                                                                                          (bytes %data)
243
                                                                                          (nat %method_id))))
244
                                                                       (nat %royalties)))
245
                                                                   (pair
246
                                                                     (pair
247
                                                                       (list %royalties_split (pair
248
                                                                                               (address %address)
249
                                                                                               (nat %pct)))
250
                                                                       (nat %supply))
251
                                                                     (pair
252
                                                                       (list %tags nat)
253
                                                                       (timestamp %timestamp_minted))))))))))
254
                              (pair
255
                                (pair (pair (nat %lock_time) (bool %locked_eps))
256
                                      (pair (big_map %metadata string bytes)
257
                                            (bool %paused)))
258
                                (pair
259
                                  (pair
260
                                    (map %pricing_contracts nat
261
                                                            (pair (address %address)
262
                                                                  (bool %enabled)))
263
                                    (nat %referrer_fees_share))
264
                                  (pair
265
                                    (big_map %reserve_methods nat
266
                                                              (pair
267
                                                                (lambda %apply_reserve
268
                                                                  (pair
269
                                                                    (pair
270
                                                                      (nat %current_amount)
271
                                                                      (bytes %current_data))
272
                                                                    (pair
273
                                                                      (address %sender)
274
                                                                      (option %user_input bytes)))
275
                                                                  (pair (bool %applied)
276
                                                                        (bytes %new_data)))
277
                                                                (pair (bool %enabled)
278
                                                                      (lambda %is_valid
279
                                                                        (pair
280
                                                                          (nat %amount)
281
                                                                          (pair
282
                                                                            (bytes %data)
283
                                                                            (address %sender)))
284
                                                                        bool))))
285
                                    (pair (bool %seed_mode)
286
                                          (big_map %user_actions address
287
                                                                 (pair
288
                                                                   (pair
289
                                                                     (nat %last_issuer_minted)
290
                                                                     (timestamp %last_issuer_minted_time))
291
                                                                   (pair
292
                                                                     (list %last_minted nat)
293
                                                                     (timestamp %last_minted_time))))))))))
294
                          (pair (list operation)
295
                                (pair
296
                                  (pair
297
                                    (pair
298
                                      (pair (big_map %addresses string address)
299
                                            (address %admin))
300
                                      (pair (nat %all_gentk_tokens) (nat %all_tokens)))
301
                                    (pair
302
                                      (pair (big_map %entrypoints_enabled string bool)
303
                                            (big_map %extended_storage bytes bytes))
304
                                      (pair (nat %fees)
305
                                            (pair (bytes %gentk_void_metadata)
306
                                                  (big_map %ledger nat
307
                                                                   (pair
308
                                                                     (pair
309
                                                                       (pair
310
                                                                         (address %author)
311
                                                                         (pair
312
                                                                           (nat %balance)
313
                                                                           (bool %enabled)))
314
                                                                       (pair
315
                                                                         (pair
316
                                                                           (nat %locked_seconds)
317
                                                                           (bytes %metadata))
318
                                                                         (pair
319
                                                                           (nat %original_supply)
320
                                                                           (nat %pricing_id))))
321
                                                                     (pair
322
                                                                       (pair
323
                                                                         (list %primary_split (pair
324
                                                                                               (address %address)
325
                                                                                               (nat %pct)))
326
                                                                         (pair
327
                                                                           (list %reserves (pair
328
                                                                                            (nat %amount)
329
                                                                                            (pair
330
                                                                                              (bytes %data)
331
                                                                                              (nat %method_id))))
332
                                                                           (nat %royalties)))
333
                                                                       (pair
334
                                                                         (pair
335
                                                                           (list %royalties_split (pair
336
                                                                                                   (address %address)
337
                                                                                                   (nat %pct)))
338
                                                                           (nat %supply))
339
                                                                         (pair
340
                                                                           (list %tags nat)
341
                                                                           (timestamp %timestamp_minted))))))))))
342
                                  (pair
343
                                    (pair (pair (nat %lock_time) (bool %locked_eps))
344
                                          (pair (big_map %metadata string bytes)
345
                                                (bool %paused)))
346
                                    (pair
347
                                      (pair
348
                                        (map %pricing_contracts nat
349
                                                                (pair (address %address)
350
                                                                      (bool %enabled)))
351
                                        (nat %referrer_fees_share))
352
                                      (pair
353
                                        (big_map %reserve_methods nat
354
                                                                  (pair
355
                                                                    (lambda %apply_reserve
356
                                                                      (pair
357
                                                                        (pair
358
                                                                          (nat %current_amount)
359
                                                                          (bytes %current_data))
360
                                                                        (pair
361
                                                                          (address %sender)
362
                                                                          (option %user_input bytes)))
363
                                                                      (pair
364
                                                                        (bool %applied)
365
                                                                        (bytes %new_data)))
366
                                                                    (pair
367
                                                                      (bool %enabled)
368
                                                                      (lambda %is_valid
369
                                                                        (pair
370
                                                                          (nat %amount)
371
                                                                          (pair
372
                                                                            (bytes %data)
373
                                                                            (address %sender)))
374
                                                                        bool))))
375
                                        (pair (bool %seed_mode)
376
                                              (big_map %user_actions address
377
                                                                     (pair
378
                                                                       (pair
379
                                                                         (nat %last_issuer_minted)
380
                                                                         (timestamp %last_issuer_minted_time))
381
                                                                       (pair
382
                                                                         (list %last_minted nat)
383
                                                                         (timestamp %last_minted_time)))))))))))
384
                        (or %ep_name
385
                          (or (or (unit %burn) (or (unit %burn_supply) (unit %mint)))
386
                              (or (unit %mint_issuer)
387
                                  (or (unit %set_pricing_contract)
388
                                      (unit %set_reserve_method))))
389
                          (or
390
                            (or (unit %set_reserve_method_enabled)
391
                                (or (unit %transfer_xtz_treasury) (unit %update_issuer)))
392
                            (or (unit %update_price)
393
                                (or (unit %update_reserve) (unit %update_token_mod)))))))))) ;
394
  storage (pair
395
            (pair
396
              (pair
397
                (pair (pair (big_map %addresses string address) (address %admin))
398
                      (pair (nat %all_gentk_tokens) (nat %all_tokens)))
399
                (pair
400
                  (pair (big_map %entrypoints_enabled string bool)
401
                        (big_map %extended_storage bytes bytes))
402
                  (pair (nat %fees)
403
                        (pair (bytes %gentk_void_metadata)
404
                              (big_map %ledger nat
405
                                               (pair
406
                                                 (pair
407
                                                   (pair (address %author)
408
                                                         (pair (nat %balance)
409
                                                               (bool %enabled)))
410
                                                   (pair
411
                                                     (pair (nat %locked_seconds)
412
                                                           (bytes %metadata))
413
                                                     (pair (nat %original_supply)
414
                                                           (nat %pricing_id))))
415
                                                 (pair
416
                                                   (pair
417
                                                     (list %primary_split (pair
418
                                                                           (address %address)
419
                                                                           (nat %pct)))
420
                                                     (pair
421
                                                       (list %reserves (pair
422
                                                                        (nat %amount)
423
                                                                        (pair
424
                                                                          (bytes %data)
425
                                                                          (nat %method_id))))
426
                                                       (nat %royalties)))
427
                                                   (pair
428
                                                     (pair
429
                                                       (list %royalties_split (pair
430
                                                                               (address %address)
431
                                                                               (nat %pct)))
432
                                                       (nat %supply))
433
                                                     (pair (list %tags nat)
434
                                                           (timestamp %timestamp_minted))))))))))
435
              (pair
436
                (pair (pair (nat %lock_time) (bool %locked_eps))
437
                      (pair (big_map %metadata string bytes) (bool %paused)))
438
                (pair
439
                  (pair
440
                    (map %pricing_contracts nat
441
                                            (pair (address %address) (bool %enabled)))
442
                    (nat %referrer_fees_share))
443
                  (pair
444
                    (big_map %reserve_methods nat
445
                                              (pair
446
                                                (lambda %apply_reserve
447
                                                  (pair
448
                                                    (pair (nat %current_amount)
449
                                                          (bytes %current_data))
450
                                                    (pair (address %sender)
451
                                                          (option %user_input bytes)))
452
                                                  (pair (bool %applied)
453
                                                        (bytes %new_data)))
454
                                                (pair (bool %enabled)
455
                                                      (lambda %is_valid
456
                                                        (pair (nat %amount)
457
                                                              (pair (bytes %data)
458
                                                                    (address %sender)))
459
                                                        bool))))
460
                    (pair (bool %seed_mode)
461
                          (big_map %user_actions address
462
                                                 (pair
463
                                                   (pair (nat %last_issuer_minted)
464
                                                         (timestamp %last_issuer_minted_time))
465
                                                   (pair (list %last_minted nat)
466
                                                         (timestamp %last_minted_time)))))))))
467
            (big_map nat
468
                     (lambda
469
                       (pair
470
                         (or
471
                           (or
472
                             (or (or nat (pair nat nat))
473
                                 (or unit
474
                                     (pair nat (pair (option address) (option bytes)))))
475
                             (or
476
                               (or
477
                                 (pair
478
                                   (pair (pair nat bool) (pair bytes (pair bytes nat)))
479
                                   (pair
480
                                     (pair (list (pair address nat))
481
                                           (list (pair nat (pair bytes nat))))
482
                                     (pair nat
483
                                           (pair (list (pair address nat)) (list nat)))))
484
                                 (list (pair
485
                                        (pair (pair address (pair nat bool))
486
                                              (pair nat (pair bytes nat)))
487
                                        (pair
488
                                          (pair nat (pair (list (pair address nat)) nat))
489
                                          (pair (list (pair address nat))
490
                                                (pair nat timestamp))))))
491
                               (or nat (or bytes nat))))
492
                           (or
493
                             (or (or (pair address (pair bool nat)) nat)
494
                                 (or
495
                                   (pair nat
496
                                         (pair
497
                                           (lambda
498
                                             (pair (pair nat bytes)
499
                                                   (pair address (option bytes)))
500
                                             (pair bool bytes))
501
                                           (pair bool
502
                                                 (lambda (pair nat (pair bytes address))
503
                                                         bool))))
504
                                   (pair bool nat)))
505
                             (or
506
                               (or (option mutez)
507
                                   (pair (pair bool nat)
508
                                         (pair (list (pair address nat))
509
                                               (pair nat (list (pair address nat))))))
510
                               (or (pair bytes nat)
511
                                   (or (pair nat (list (pair nat (pair bytes nat))))
512
                                       (pair nat (list nat)))))))
513
                         (pair
514
                           (pair
515
                             (pair (pair (big_map string address) address)
516
                                   (pair nat nat))
517
                             (pair (pair (big_map string bool) (big_map bytes bytes))
518
                                   (pair nat
519
                                         (pair bytes
520
                                               (big_map nat
521
                                                        (pair
522
                                                          (pair
523
                                                            (pair address
524
                                                                  (pair nat bool))
525
                                                            (pair (pair nat bytes)
526
                                                                  (pair nat nat)))
527
                                                          (pair
528
                                                            (pair
529
                                                              (list (pair address nat))
530
                                                              (pair
531
                                                                (list (pair nat
532
                                                                           (pair bytes
533
                                                                                 nat)))
534
                                                                nat))
535
                                                            (pair
536
                                                              (pair
537
                                                                (list (pair address nat))
538
                                                                nat)
539
                                                              (pair (list nat) timestamp)))))))))
540
                           (pair
541
                             (pair (pair nat bool) (pair (big_map string bytes) bool))
542
                             (pair (pair (map nat (pair address bool)) nat)
543
                                   (pair
544
                                     (big_map nat
545
                                              (pair
546
                                                (lambda
547
                                                  (pair (pair nat bytes)
548
                                                        (pair address (option bytes)))
549
                                                  (pair bool bytes))
550
                                                (pair bool
551
                                                      (lambda
552
                                                        (pair nat (pair bytes address))
553
                                                        bool))))
554
                                     (pair bool
555
                                           (big_map address
556
                                                    (pair (pair nat timestamp)
557
                                                          (pair (list nat) timestamp)))))))))
558
                       (pair (list operation)
559
                             (pair
560
                               (pair
561
                                 (pair (pair (big_map string address) address)
562
                                       (pair nat nat))
563
                                 (pair
564
                                   (pair (big_map string bool) (big_map bytes bytes))
565
                                   (pair nat
566
                                         (pair bytes
567
                                               (big_map nat
568
                                                        (pair
569
                                                          (pair
570
                                                            (pair address
571
                                                                  (pair nat bool))
572
                                                            (pair (pair nat bytes)
573
                                                                  (pair nat nat)))
574
                                                          (pair
575
                                                            (pair
576
                                                              (list (pair address nat))
577
                                                              (pair
578
                                                                (list (pair nat
579
                                                                           (pair bytes
580
                                                                                 nat)))
581
                                                                nat))
582
                                                            (pair
583
                                                              (pair
584
                                                                (list (pair address nat))
585
                                                                nat)
586
                                                              (pair (list nat) timestamp)))))))))
587
                               (pair
588
                                 (pair (pair nat bool)
589
                                       (pair (big_map string bytes) bool))
590
                                 (pair (pair (map nat (pair address bool)) nat)
591
                                       (pair
592
                                         (big_map nat
593
                                                  (pair
594
                                                    (lambda
595
                                                      (pair (pair nat bytes)
596
                                                            (pair address (option bytes)))
597
                                                      (pair bool bytes))
598
                                                    (pair bool
599
                                                          (lambda
600
                                                            (pair nat
601
                                                                  (pair bytes address))
602
                                                            bool))))
603
                                         (pair bool
604
                                               (big_map address
605
                                                        (pair (pair nat timestamp)
606
                                                              (pair (list nat) timestamp)))))))))))) ;
607
  code { UNPAIR 3 ;
608
         IF_LEFT
609
           { DUP ;
610
             IF_LEFT
611
               { IF_LEFT
612
                   { IF_LEFT
613
                       { IF_LEFT { DROP ; PUSH nat 0 } { DROP ; PUSH nat 1 } }
614
                       { IF_LEFT { DROP ; PUSH nat 2 } { DROP ; PUSH nat 3 } } }
615
                   { IF_LEFT
616
                       { IF_LEFT { DROP ; PUSH nat 4 } { DROP ; PUSH nat 5 } }
617
                       { IF_LEFT
618
                           { DROP ; PUSH nat 6 }
619
                           { IF_LEFT { DROP ; PUSH nat 7 } { DROP ; PUSH nat 8 } } } } }
620
               { IF_LEFT
621
                   { IF_LEFT
622
                       { IF_LEFT { DROP ; PUSH nat 9 } { DROP ; PUSH nat 10 } }
623
                       { IF_LEFT { DROP ; PUSH nat 11 } { DROP ; PUSH nat 12 } } }
624
                   { IF_LEFT
625
                       { IF_LEFT { DROP ; PUSH nat 13 } { DROP ; PUSH nat 14 } }
626
                       { IF_LEFT
627
                           { DROP ; PUSH nat 15 }
628
                           { IF_LEFT { DROP ; PUSH nat 16 } { DROP ; PUSH nat 17 } } } } } ;
629
             DUP 4 ;
630
             SWAP ;
631
             GET ;
632
             IF_NONE { PUSH int -1 ; FAILWITH } {} ;
633
             DUG 2 ;
634
             PAIR ;
635
             EXEC ;
636
             UNPAIR }
637
           { IF_LEFT
638
               { IF_LEFT
639
                   { SWAP ;
640
                     DUP ;
641
                     DUG 2 ;
642
                     CAR ;
643
                     CAR ;
644
                     CAR ;
645
                     CDR ;
646
                     SENDER ;
647
                     COMPARE ;
648
                     EQ ;
649
                     IF {} { PUSH string "NOT_ADMIN" ; FAILWITH } ;
650
                     SWAP ;
651
                     DUP ;
652
                     DUG 2 ;
653
                     CAR ;
654
                     GET 3 ;
655
                     CAR ;
656
                     SWAP ;
657
                     DUP ;
658
                     DUG 2 ;
659
                     CDR ;
660
                     MEM ;
661
                     IF {} { PUSH string "EP_DOESNT_EXIST" ; FAILWITH } ;
662
                     SWAP ;
663
                     UNPAIR ;
664
                     UNPAIR ;
665
                     SWAP ;
666
                     UNPAIR ;
667
                     UNPAIR ;
668
                     DUP 6 ;
669
                     CAR ;
670
                     SOME ;
671
                     DIG 6 ;
672
                     CDR ;
673
                     UPDATE ;
674
                     PAIR ;
675
                     PAIR ;
676
                     SWAP ;
677
                     PAIR ;
678
                     PAIR }
679
                   { IF_LEFT
680
                       { DROP ;
681
                         DUP ;
682
                         CAR ;
683
                         CAR ;
684
                         CAR ;
685
                         CDR ;
686
                         SENDER ;
687
                         COMPARE ;
688
                         EQ ;
689
                         IF {} { PUSH string "NOT_ADMIN" ; FAILWITH } ;
690
                         UNPAIR ;
691
                         SWAP ;
692
                         UNPAIR ;
693
                         UNPAIR ;
694
                         CAR ;
695
                         PUSH bool True ;
696
                         SWAP ;
697
                         PAIR ;
698
                         PAIR ;
699
                         PAIR ;
700
                         SWAP ;
701
                         PAIR }
702
                       { SWAP ;
703
                         DUP ;
704
                         DUG 2 ;
705
                         CAR ;
706
                         CAR ;
707
                         CAR ;
708
                         CDR ;
709
                         SENDER ;
710
                         COMPARE ;
711
                         EQ ;
712
                         IF {} { PUSH string "NOT_ADMIN" ; FAILWITH } ;
713
                         DUP ;
714
                         ITER { DIG 2 ;
715
                                UNPAIR ;
716
                                UNPAIR ;
717
                                UNPAIR ;
718
                                UNPAIR ;
719
                                DUP 6 ;
720
                                CAR ;
721
                                SOME ;
722
                                DIG 6 ;
723
                                CDR ;
724
                                UPDATE ;
725
                                PAIR ;
726
                                PAIR ;
727
                                PAIR ;
728
                                PAIR ;
729
                                SWAP } ;
730
                         DROP } } }
731
               { IF_LEFT
732
                   { IF_LEFT
733
                       { SWAP ;
734
                         DUP ;
735
                         DUG 2 ;
736
                         CAR ;
737
                         CAR ;
738
                         CAR ;
739
                         CDR ;
740
                         SENDER ;
741
                         COMPARE ;
742
                         EQ ;
743
                         IF {} { PUSH string "NOT_ADMIN" ; FAILWITH } ;
744
                         SWAP ;
745
                         UNPAIR ;
746
                         UNPAIR ;
747
                         UNPAIR ;
748
                         CAR ;
749
                         DIG 4 ;
750
                         SWAP ;
751
                         PAIR ;
752
                         PAIR ;
753
                         PAIR ;
754
                         PAIR }
755
                       { SWAP ;
756
                         DUP ;
757
                         DUG 2 ;
758
                         CAR ;
759
                         CAR ;
760
                         CAR ;
761
                         CDR ;
762
                         SENDER ;
763
                         COMPARE ;
764
                         EQ ;
765
                         IF {} { PUSH string "NOT_ADMIN" ; FAILWITH } ;
766
                         SWAP ;
767
                         UNPAIR ;
768
                         SWAP ;
769
                         UNPAIR ;
770
                         UNPAIR ;
771
                         SWAP ;
772
                         CDR ;
773
                         DIG 4 ;
774
                         PAIR ;
775
                         SWAP ;
776
                         PAIR ;
777
                         PAIR ;
778
                         SWAP ;
779
                         PAIR } }
780
                   { IF_LEFT
781
                       { SWAP ;
782
                         DUP ;
783
                         DUG 2 ;
784
                         CAR ;
785
                         CAR ;
786
                         CAR ;
787
                         CDR ;
788
                         SENDER ;
789
                         COMPARE ;
790
                         EQ ;
791
                         IF {} { PUSH string "NOT_ADMIN" ; FAILWITH } ;
792
                         SWAP ;
793
                         UNPAIR ;
794
                         SWAP ;
795
                         UNPAIR ;
796
                         UNPAIR ;
797
                         SWAP ;
798
                         CAR ;
799
                         DIG 4 ;
800
                         SWAP ;
801
                         PAIR ;
802
                         SWAP ;
803
                         PAIR ;
804
                         PAIR ;
805
                         SWAP ;
806
                         PAIR }
807
                       { SWAP ;
808
                         DUP ;
809
                         DUG 2 ;
810
                         CAR ;
811
                         CAR ;
812
                         CAR ;
813
                         CDR ;
814
                         SENDER ;
815
                         COMPARE ;
816
                         EQ ;
817
                         IF {} { PUSH string "NOT_ADMIN" ; FAILWITH } ;
818
                         SWAP ;
819
                         DUP ;
820
                         DUG 2 ;
821
                         GET 3 ;
822
                         CAR ;
823
                         CDR ;
824
                         IF { PUSH string "EPS_LOCKED" ; FAILWITH } {} ;
825
                         DUP ;
826
                         CDR ;
827
                         IF_LEFT
828
                           { IF_LEFT
829
                               { IF_LEFT
830
                                   { DROP ; DIG 2 ; SWAP ; CAR ; SOME ; PUSH nat 0 ; UPDATE ; SWAP }
831
                                   { IF_LEFT
832
                                       { DROP ; DIG 2 ; SWAP ; CAR ; SOME ; PUSH nat 1 ; UPDATE ; SWAP }
833
                                       { DROP ; DIG 2 ; SWAP ; CAR ; SOME ; PUSH nat 3 ; UPDATE ; SWAP } } }
834
                               { IF_LEFT
835
                                   { DROP ; DIG 2 ; SWAP ; CAR ; SOME ; PUSH nat 4 ; UPDATE ; SWAP }
836
                                   { IF_LEFT
837
                                       { DROP ; DIG 2 ; SWAP ; CAR ; SOME ; PUSH nat 9 ; UPDATE ; SWAP }
838
                                       { DROP ; DIG 2 ; SWAP ; CAR ; SOME ; PUSH nat 11 ; UPDATE ; SWAP } } } }
839
                           { IF_LEFT
840
                               { IF_LEFT
841
                                   { DROP ; DIG 2 ; SWAP ; CAR ; SOME ; PUSH nat 12 ; UPDATE ; SWAP }
842
                                   { IF_LEFT
843
                                       { DROP ; DIG 2 ; SWAP ; CAR ; SOME ; PUSH nat 13 ; UPDATE ; SWAP }
844
                                       { DROP ; DIG 2 ; SWAP ; CAR ; SOME ; PUSH nat 14 ; UPDATE ; SWAP } } }
845
                               { IF_LEFT
846
                                   { DROP ; DIG 2 ; SWAP ; CAR ; SOME ; PUSH nat 15 ; UPDATE ; SWAP }
847
                                   { IF_LEFT
848
                                       { DROP ; DIG 2 ; SWAP ; CAR ; SOME ; PUSH nat 16 ; UPDATE ; SWAP }
849
                                       { DROP ; DIG 2 ; SWAP ; CAR ; SOME ; PUSH nat 17 ; UPDATE ; SWAP } } } } } } } ;
850
             NIL operation } ;
851
         NIL operation ;
852
         SWAP ;
853
         ITER { CONS } ;
854
         DUG 2 ;
855
         PAIR ;
856
         SWAP ;
857
         PAIR } ;
858
  view "get_extended_storage" bytes bytes
859
        { UNPAIR 3 ;
860
          DIG 2 ;
861
          DROP ;
862
          SWAP ;
863
          CAR ;
864
          GET 3 ;
865
          CDR ;
866
          SWAP ;
867
          GET ;
868
          IF_NONE { PUSH int 29 ; FAILWITH } {} } ;
869
  view "get_token_data" nat
870
        (pair
871
          (pair (pair (address %author) (pair (nat %balance) (bool %enabled)))
872
                (pair (pair (nat %locked_seconds) (bytes %metadata))
873
                      (pair (nat %original_supply) (nat %pricing_id))))
874
          (pair
875
            (pair (list %primary_split (pair (address %address) (nat %pct)))
876
                  (pair
877
                    (list %reserves (pair (nat %amount)
878
                                         (pair (bytes %data) (nat %method_id))))
879
                    (nat %royalties)))
880
            (pair
881
              (pair (list %royalties_split (pair (address %address) (nat %pct)))
882
                    (nat %supply))
883
              (pair (list %tags nat) (timestamp %timestamp_minted)))))
884
        { UNPAIR 3 ;
885
          DIG 2 ;
886
          DROP ;
887
          SWAP ;
888
          DUP ;
889
          DUG 2 ;
890
          CAR ;
891
          GET 8 ;
892
          SWAP ;
893
          DUP ;
894
          DUG 2 ;
895
          MEM ;
896
          IF {} { PUSH string "NO_TOKEN" ; FAILWITH } ;
897
          SWAP ;
898
          CAR ;
899
          GET 8 ;
900
          SWAP ;
901
          GET ;
902
          IF_NONE { PUSH int 195 ; FAILWITH } {} } ;
903
  view "get_user_actions" address
904
        (pair (pair (nat %last_issuer_minted) (timestamp %last_issuer_minted_time))
905
              (pair (list %last_minted nat) (timestamp %last_minted_time)))
906
        { UNPAIR 3 ;
907
          DIG 2 ;
908
          DROP ;
909
          SWAP ;
910
          GET 10 ;
911
          SWAP ;
912
          GET ;
913
          IF_NONE
914
            { PUSH (pair (pair nat timestamp) (pair (list nat) timestamp)) (Pair (Pair 0 "1970-01-01T00:00:00Z")
915
                          (Pair {} "1970-01-01T00:00:00Z")) }
916
            {} } }