@medialane/sdk 0.61.0 → 0.63.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/index.js CHANGED
@@ -35,9 +35,9 @@ var COORDINATES = {
35
35
  creatorCoinFactoryClassHash: "0x51765926b1344c9a20b8cd4b5abe7b7d47375ae97cf6804db3ea5d4b05a9b55",
36
36
  creatorCoinStartBlock: 10474544,
37
37
  ekuboCore: "0x00000005dd3d2f4429af886cd1a3b08289dbcea99a294197e9eb43b0e0325b4b",
38
- ipTicketsFactory: "0x0664c2d6a4da9ee3ff053ceeba7579c01f2fedfd9d2b57b4c07af3734bd4acab",
39
- ipTicketCollectionClassHash: "0x086f59c416e365e2bee4ceff9f1dcb96198f2342d50ba4621f60b831863adb6",
40
- ipTicketsStartBlock: 11404656,
38
+ ipTicketsFactory: "0x03ffef4162fe2c44e17d6be2aad3553cab0ac2274cd0b1bb3fafb12fd66695c1",
39
+ ipTicketCollectionClassHash: "0x036393fb4241ed55bd12d8b328ed877d08100fadf9150a650e2b84cbab95e1d4",
40
+ ipTicketsStartBlock: 11689800,
41
41
  ipClubRegistry: "0x00e189c619b6bb07d78973a149641c59c37eb0716f8584d7520bce12d303eede",
42
42
  ipClubNftClassHash: "0x02bc9b20cca21b04245e9215bf7121f4d7295b195890e449b472b573017fb889",
43
43
  ipClubStartBlock: 11404776,
@@ -5819,26 +5819,8 @@ var CreatorCoinFactoryABI = [{ "type": "impl", "name": "FactoryImpl", "interface
5819
5819
  var IPTicketCollectionABI = [
5820
5820
  {
5821
5821
  "type": "impl",
5822
- "name": "ERC721MetadataImpl",
5823
- "interface_name": "openzeppelin_token::erc721::interface::IERC721Metadata"
5824
- },
5825
- {
5826
- "type": "struct",
5827
- "name": "core::byte_array::ByteArray",
5828
- "members": [
5829
- {
5830
- "name": "data",
5831
- "type": "core::array::Array::<core::bytes_31::bytes31>"
5832
- },
5833
- {
5834
- "name": "pending_word",
5835
- "type": "core::felt252"
5836
- },
5837
- {
5838
- "name": "pending_word_len",
5839
- "type": "core::internal::bounded_int::BoundedInt::<0, 30>"
5840
- }
5841
- ]
5822
+ "name": "ERC1155MetadataURIImpl",
5823
+ "interface_name": "openzeppelin_token::erc1155::interface::IERC1155MetadataURI"
5842
5824
  },
5843
5825
  {
5844
5826
  "type": "struct",
@@ -5855,64 +5837,33 @@ var IPTicketCollectionABI = [
5855
5837
  ]
5856
5838
  },
5857
5839
  {
5858
- "type": "interface",
5859
- "name": "openzeppelin_token::erc721::interface::IERC721Metadata",
5860
- "items": [
5840
+ "type": "struct",
5841
+ "name": "core::byte_array::ByteArray",
5842
+ "members": [
5861
5843
  {
5862
- "type": "function",
5863
- "name": "name",
5864
- "inputs": [],
5865
- "outputs": [
5866
- {
5867
- "type": "core::byte_array::ByteArray"
5868
- }
5869
- ],
5870
- "state_mutability": "view"
5844
+ "name": "data",
5845
+ "type": "core::array::Array::<core::bytes_31::bytes31>"
5871
5846
  },
5872
5847
  {
5873
- "type": "function",
5874
- "name": "symbol",
5875
- "inputs": [],
5876
- "outputs": [
5877
- {
5878
- "type": "core::byte_array::ByteArray"
5879
- }
5880
- ],
5881
- "state_mutability": "view"
5848
+ "name": "pending_word",
5849
+ "type": "core::felt252"
5882
5850
  },
5883
5851
  {
5884
- "type": "function",
5885
- "name": "token_uri",
5886
- "inputs": [
5887
- {
5888
- "name": "token_id",
5889
- "type": "core::integer::u256"
5890
- }
5891
- ],
5892
- "outputs": [
5893
- {
5894
- "type": "core::byte_array::ByteArray"
5895
- }
5896
- ],
5897
- "state_mutability": "view"
5852
+ "name": "pending_word_len",
5853
+ "type": "core::internal::bounded_int::BoundedInt::<0, 30>"
5898
5854
  }
5899
5855
  ]
5900
5856
  },
5901
- {
5902
- "type": "impl",
5903
- "name": "ERC721MetadataCamelOnlyImpl",
5904
- "interface_name": "openzeppelin_token::erc721::interface::IERC721MetadataCamelOnly"
5905
- },
5906
5857
  {
5907
5858
  "type": "interface",
5908
- "name": "openzeppelin_token::erc721::interface::IERC721MetadataCamelOnly",
5859
+ "name": "openzeppelin_token::erc1155::interface::IERC1155MetadataURI",
5909
5860
  "items": [
5910
5861
  {
5911
5862
  "type": "function",
5912
- "name": "tokenURI",
5863
+ "name": "uri",
5913
5864
  "inputs": [
5914
5865
  {
5915
- "name": "tokenId",
5866
+ "name": "token_id",
5916
5867
  "type": "core::integer::u256"
5917
5868
  }
5918
5869
  ],
@@ -5927,16 +5878,16 @@ var IPTicketCollectionABI = [
5927
5878
  },
5928
5879
  {
5929
5880
  "type": "impl",
5930
- "name": "IPTicketImpl",
5881
+ "name": "IPTicketCollectionImpl",
5931
5882
  "interface_name": "ip_ticket::interface::IIPTicketCollection"
5932
5883
  },
5933
5884
  {
5934
5885
  "type": "enum",
5935
- "name": "core::option::Option::<core::starknet::contract_address::ContractAddress>",
5886
+ "name": "core::option::Option::<core::integer::u64>",
5936
5887
  "variants": [
5937
5888
  {
5938
5889
  "name": "Some",
5939
- "type": "core::starknet::contract_address::ContractAddress"
5890
+ "type": "core::integer::u64"
5940
5891
  },
5941
5892
  {
5942
5893
  "name": "None",
@@ -5960,16 +5911,12 @@ var IPTicketCollectionABI = [
5960
5911
  },
5961
5912
  {
5962
5913
  "type": "struct",
5963
- "name": "ip_ticket::types::TicketCollection",
5914
+ "name": "ip_ticket::types::EventRecord",
5964
5915
  "members": [
5965
5916
  {
5966
5917
  "name": "creator",
5967
5918
  "type": "core::starknet::contract_address::ContractAddress"
5968
5919
  },
5969
- {
5970
- "name": "price",
5971
- "type": "core::integer::u256"
5972
- },
5973
5920
  {
5974
5921
  "name": "max_supply",
5975
5922
  "type": "core::integer::u256"
@@ -5979,16 +5926,16 @@ var IPTicketCollectionABI = [
5979
5926
  "type": "core::integer::u256"
5980
5927
  },
5981
5928
  {
5982
- "name": "expiration",
5983
- "type": "core::integer::u64"
5929
+ "name": "start_time",
5930
+ "type": "core::option::Option::<core::integer::u64>"
5984
5931
  },
5985
5932
  {
5986
- "name": "royalty_bps",
5987
- "type": "core::integer::u256"
5933
+ "name": "end_time",
5934
+ "type": "core::option::Option::<core::integer::u64>"
5988
5935
  },
5989
5936
  {
5990
- "name": "payment_token",
5991
- "type": "core::option::Option::<core::starknet::contract_address::ContractAddress>"
5937
+ "name": "royalty_bps",
5938
+ "type": "core::integer::u16"
5992
5939
  },
5993
5940
  {
5994
5941
  "name": "metadata_uri",
@@ -6000,71 +5947,29 @@ var IPTicketCollectionABI = [
6000
5947
  }
6001
5948
  ]
6002
5949
  },
6003
- {
6004
- "type": "struct",
6005
- "name": "ip_ticket::types::TicketData",
6006
- "members": [
6007
- {
6008
- "name": "token_id",
6009
- "type": "core::integer::u256"
6010
- },
6011
- {
6012
- "name": "owner",
6013
- "type": "core::starknet::contract_address::ContractAddress"
6014
- },
6015
- {
6016
- "name": "collection_id",
6017
- "type": "core::integer::u256"
6018
- },
6019
- {
6020
- "name": "creator",
6021
- "type": "core::starknet::contract_address::ContractAddress"
6022
- },
6023
- {
6024
- "name": "metadata_uri",
6025
- "type": "core::byte_array::ByteArray"
6026
- },
6027
- {
6028
- "name": "expiration",
6029
- "type": "core::integer::u64"
6030
- },
6031
- {
6032
- "name": "redeemed",
6033
- "type": "core::bool"
6034
- },
6035
- {
6036
- "name": "valid",
6037
- "type": "core::bool"
6038
- }
6039
- ]
6040
- },
6041
5950
  {
6042
5951
  "type": "interface",
6043
5952
  "name": "ip_ticket::interface::IIPTicketCollection",
6044
5953
  "items": [
6045
5954
  {
6046
5955
  "type": "function",
6047
- "name": "create_ticket_collection",
5956
+ "name": "create_event",
6048
5957
  "inputs": [
6049
- {
6050
- "name": "price",
6051
- "type": "core::integer::u256"
6052
- },
6053
5958
  {
6054
5959
  "name": "max_supply",
6055
5960
  "type": "core::integer::u256"
6056
5961
  },
6057
5962
  {
6058
- "name": "expiration",
6059
- "type": "core::integer::u64"
5963
+ "name": "start_time",
5964
+ "type": "core::option::Option::<core::integer::u64>"
6060
5965
  },
6061
5966
  {
6062
- "name": "royalty_bps",
6063
- "type": "core::integer::u256"
5967
+ "name": "end_time",
5968
+ "type": "core::option::Option::<core::integer::u64>"
6064
5969
  },
6065
5970
  {
6066
- "name": "payment_token",
6067
- "type": "core::option::Option::<core::starknet::contract_address::ContractAddress>"
5971
+ "name": "royalty_bps",
5972
+ "type": "core::integer::u16"
6068
5973
  },
6069
5974
  {
6070
5975
  "name": "metadata_uri",
@@ -6080,43 +5985,35 @@ var IPTicketCollectionABI = [
6080
5985
  },
6081
5986
  {
6082
5987
  "type": "function",
6083
- "name": "set_collection_active",
5988
+ "name": "mint",
6084
5989
  "inputs": [
6085
5990
  {
6086
- "name": "collection_id",
6087
- "type": "core::integer::u256"
5991
+ "name": "to",
5992
+ "type": "core::starknet::contract_address::ContractAddress"
6088
5993
  },
6089
5994
  {
6090
- "name": "active",
6091
- "type": "core::bool"
6092
- }
6093
- ],
6094
- "outputs": [],
6095
- "state_mutability": "external"
6096
- },
6097
- {
6098
- "type": "function",
6099
- "name": "mint_ticket",
6100
- "inputs": [
6101
- {
6102
- "name": "collection_id",
5995
+ "name": "token_id",
6103
5996
  "type": "core::integer::u256"
6104
- }
6105
- ],
6106
- "outputs": [
5997
+ },
6107
5998
  {
5999
+ "name": "amount",
6108
6000
  "type": "core::integer::u256"
6109
6001
  }
6110
6002
  ],
6003
+ "outputs": [],
6111
6004
  "state_mutability": "external"
6112
6005
  },
6113
6006
  {
6114
6007
  "type": "function",
6115
- "name": "redeem_ticket",
6008
+ "name": "pause_event",
6116
6009
  "inputs": [
6117
6010
  {
6118
6011
  "name": "token_id",
6119
6012
  "type": "core::integer::u256"
6013
+ },
6014
+ {
6015
+ "name": "active",
6016
+ "type": "core::bool"
6120
6017
  }
6121
6018
  ],
6122
6019
  "outputs": [],
@@ -6124,15 +6021,15 @@ var IPTicketCollectionABI = [
6124
6021
  },
6125
6022
  {
6126
6023
  "type": "function",
6127
- "name": "has_valid_ticket",
6024
+ "name": "is_valid",
6128
6025
  "inputs": [
6129
6026
  {
6130
- "name": "user",
6131
- "type": "core::starknet::contract_address::ContractAddress"
6027
+ "name": "token_id",
6028
+ "type": "core::integer::u256"
6132
6029
  },
6133
6030
  {
6134
- "name": "collection_id",
6135
- "type": "core::integer::u256"
6031
+ "name": "holder",
6032
+ "type": "core::starknet::contract_address::ContractAddress"
6136
6033
  }
6137
6034
  ],
6138
6035
  "outputs": [
@@ -6144,23 +6041,7 @@ var IPTicketCollectionABI = [
6144
6041
  },
6145
6042
  {
6146
6043
  "type": "function",
6147
- "name": "get_ticket_collection",
6148
- "inputs": [
6149
- {
6150
- "name": "collection_id",
6151
- "type": "core::integer::u256"
6152
- }
6153
- ],
6154
- "outputs": [
6155
- {
6156
- "type": "ip_ticket::types::TicketCollection"
6157
- }
6158
- ],
6159
- "state_mutability": "view"
6160
- },
6161
- {
6162
- "type": "function",
6163
- "name": "get_ticket_data",
6044
+ "name": "get_event",
6164
6045
  "inputs": [
6165
6046
  {
6166
6047
  "name": "token_id",
@@ -6169,72 +6050,34 @@ var IPTicketCollectionABI = [
6169
6050
  ],
6170
6051
  "outputs": [
6171
6052
  {
6172
- "type": "ip_ticket::types::TicketData"
6053
+ "type": "ip_ticket::types::EventRecord"
6173
6054
  }
6174
6055
  ],
6175
6056
  "state_mutability": "view"
6176
6057
  },
6177
6058
  {
6178
6059
  "type": "function",
6179
- "name": "get_ticket_collection_id",
6060
+ "name": "royalty_info",
6180
6061
  "inputs": [
6181
6062
  {
6182
6063
  "name": "token_id",
6183
6064
  "type": "core::integer::u256"
6184
- }
6185
- ],
6186
- "outputs": [
6187
- {
6188
- "type": "core::integer::u256"
6189
- }
6190
- ],
6191
- "state_mutability": "view"
6192
- },
6193
- {
6194
- "type": "function",
6195
- "name": "get_active_ticket_balance",
6196
- "inputs": [
6197
- {
6198
- "name": "user",
6199
- "type": "core::starknet::contract_address::ContractAddress"
6200
6065
  },
6201
6066
  {
6202
- "name": "collection_id",
6203
- "type": "core::integer::u256"
6204
- }
6205
- ],
6206
- "outputs": [
6207
- {
6208
- "type": "core::integer::u256"
6209
- }
6210
- ],
6211
- "state_mutability": "view"
6212
- },
6213
- {
6214
- "type": "function",
6215
- "name": "get_last_collection_id",
6216
- "inputs": [],
6217
- "outputs": [
6218
- {
6067
+ "name": "sale_price",
6219
6068
  "type": "core::integer::u256"
6220
6069
  }
6221
6070
  ],
6222
- "state_mutability": "view"
6223
- },
6224
- {
6225
- "type": "function",
6226
- "name": "total_supply",
6227
- "inputs": [],
6228
6071
  "outputs": [
6229
6072
  {
6230
- "type": "core::integer::u256"
6073
+ "type": "(core::starknet::contract_address::ContractAddress, core::integer::u256)"
6231
6074
  }
6232
6075
  ],
6233
6076
  "state_mutability": "view"
6234
6077
  },
6235
6078
  {
6236
6079
  "type": "function",
6237
- "name": "royalty_info",
6080
+ "name": "royaltyInfo",
6238
6081
  "inputs": [
6239
6082
  {
6240
6083
  "name": "token_id",
@@ -6254,20 +6097,11 @@ var IPTicketCollectionABI = [
6254
6097
  },
6255
6098
  {
6256
6099
  "type": "function",
6257
- "name": "royaltyInfo",
6258
- "inputs": [
6259
- {
6260
- "name": "token_id",
6261
- "type": "core::integer::u256"
6262
- },
6263
- {
6264
- "name": "sale_price",
6265
- "type": "core::integer::u256"
6266
- }
6267
- ],
6100
+ "name": "version",
6101
+ "inputs": [],
6268
6102
  "outputs": [
6269
6103
  {
6270
- "type": "(core::starknet::contract_address::ContractAddress, core::integer::u256)"
6104
+ "type": "core::byte_array::ByteArray"
6271
6105
  }
6272
6106
  ],
6273
6107
  "state_mutability": "view"
@@ -6276,8 +6110,28 @@ var IPTicketCollectionABI = [
6276
6110
  },
6277
6111
  {
6278
6112
  "type": "impl",
6279
- "name": "ERC721Impl",
6280
- "interface_name": "openzeppelin_token::erc721::interface::IERC721"
6113
+ "name": "ERC1155Impl",
6114
+ "interface_name": "openzeppelin_token::erc1155::interface::IERC1155"
6115
+ },
6116
+ {
6117
+ "type": "struct",
6118
+ "name": "core::array::Span::<core::starknet::contract_address::ContractAddress>",
6119
+ "members": [
6120
+ {
6121
+ "name": "snapshot",
6122
+ "type": "@core::array::Array::<core::starknet::contract_address::ContractAddress>"
6123
+ }
6124
+ ]
6125
+ },
6126
+ {
6127
+ "type": "struct",
6128
+ "name": "core::array::Span::<core::integer::u256>",
6129
+ "members": [
6130
+ {
6131
+ "name": "snapshot",
6132
+ "type": "@core::array::Array::<core::integer::u256>"
6133
+ }
6134
+ ]
6281
6135
  },
6282
6136
  {
6283
6137
  "type": "struct",
@@ -6291,7 +6145,7 @@ var IPTicketCollectionABI = [
6291
6145
  },
6292
6146
  {
6293
6147
  "type": "interface",
6294
- "name": "openzeppelin_token::erc721::interface::IERC721",
6148
+ "name": "openzeppelin_token::erc1155::interface::IERC1155",
6295
6149
  "items": [
6296
6150
  {
6297
6151
  "type": "function",
@@ -6300,6 +6154,10 @@ var IPTicketCollectionABI = [
6300
6154
  {
6301
6155
  "name": "account",
6302
6156
  "type": "core::starknet::contract_address::ContractAddress"
6157
+ },
6158
+ {
6159
+ "name": "token_id",
6160
+ "type": "core::integer::u256"
6303
6161
  }
6304
6162
  ],
6305
6163
  "outputs": [
@@ -6311,16 +6169,20 @@ var IPTicketCollectionABI = [
6311
6169
  },
6312
6170
  {
6313
6171
  "type": "function",
6314
- "name": "owner_of",
6172
+ "name": "balance_of_batch",
6315
6173
  "inputs": [
6316
6174
  {
6317
- "name": "token_id",
6318
- "type": "core::integer::u256"
6175
+ "name": "accounts",
6176
+ "type": "core::array::Span::<core::starknet::contract_address::ContractAddress>"
6177
+ },
6178
+ {
6179
+ "name": "token_ids",
6180
+ "type": "core::array::Span::<core::integer::u256>"
6319
6181
  }
6320
6182
  ],
6321
6183
  "outputs": [
6322
6184
  {
6323
- "type": "core::starknet::contract_address::ContractAddress"
6185
+ "type": "core::array::Span::<core::integer::u256>"
6324
6186
  }
6325
6187
  ],
6326
6188
  "state_mutability": "view"
@@ -6341,6 +6203,10 @@ var IPTicketCollectionABI = [
6341
6203
  "name": "token_id",
6342
6204
  "type": "core::integer::u256"
6343
6205
  },
6206
+ {
6207
+ "name": "value",
6208
+ "type": "core::integer::u256"
6209
+ },
6344
6210
  {
6345
6211
  "name": "data",
6346
6212
  "type": "core::array::Span::<core::felt252>"
@@ -6351,7 +6217,7 @@ var IPTicketCollectionABI = [
6351
6217
  },
6352
6218
  {
6353
6219
  "type": "function",
6354
- "name": "transfer_from",
6220
+ "name": "safe_batch_transfer_from",
6355
6221
  "inputs": [
6356
6222
  {
6357
6223
  "name": "from",
@@ -6362,24 +6228,16 @@ var IPTicketCollectionABI = [
6362
6228
  "type": "core::starknet::contract_address::ContractAddress"
6363
6229
  },
6364
6230
  {
6365
- "name": "token_id",
6366
- "type": "core::integer::u256"
6367
- }
6368
- ],
6369
- "outputs": [],
6370
- "state_mutability": "external"
6371
- },
6372
- {
6373
- "type": "function",
6374
- "name": "approve",
6375
- "inputs": [
6231
+ "name": "token_ids",
6232
+ "type": "core::array::Span::<core::integer::u256>"
6233
+ },
6376
6234
  {
6377
- "name": "to",
6378
- "type": "core::starknet::contract_address::ContractAddress"
6235
+ "name": "values",
6236
+ "type": "core::array::Span::<core::integer::u256>"
6379
6237
  },
6380
6238
  {
6381
- "name": "token_id",
6382
- "type": "core::integer::u256"
6239
+ "name": "data",
6240
+ "type": "core::array::Span::<core::felt252>"
6383
6241
  }
6384
6242
  ],
6385
6243
  "outputs": [],
@@ -6387,66 +6245,50 @@ var IPTicketCollectionABI = [
6387
6245
  },
6388
6246
  {
6389
6247
  "type": "function",
6390
- "name": "set_approval_for_all",
6248
+ "name": "is_approved_for_all",
6391
6249
  "inputs": [
6392
6250
  {
6393
- "name": "operator",
6251
+ "name": "owner",
6394
6252
  "type": "core::starknet::contract_address::ContractAddress"
6395
6253
  },
6396
6254
  {
6397
- "name": "approved",
6398
- "type": "core::bool"
6399
- }
6400
- ],
6401
- "outputs": [],
6402
- "state_mutability": "external"
6403
- },
6404
- {
6405
- "type": "function",
6406
- "name": "get_approved",
6407
- "inputs": [
6408
- {
6409
- "name": "token_id",
6410
- "type": "core::integer::u256"
6255
+ "name": "operator",
6256
+ "type": "core::starknet::contract_address::ContractAddress"
6411
6257
  }
6412
6258
  ],
6413
6259
  "outputs": [
6414
6260
  {
6415
- "type": "core::starknet::contract_address::ContractAddress"
6261
+ "type": "core::bool"
6416
6262
  }
6417
6263
  ],
6418
6264
  "state_mutability": "view"
6419
6265
  },
6420
6266
  {
6421
6267
  "type": "function",
6422
- "name": "is_approved_for_all",
6268
+ "name": "set_approval_for_all",
6423
6269
  "inputs": [
6424
- {
6425
- "name": "owner",
6426
- "type": "core::starknet::contract_address::ContractAddress"
6427
- },
6428
6270
  {
6429
6271
  "name": "operator",
6430
6272
  "type": "core::starknet::contract_address::ContractAddress"
6431
- }
6432
- ],
6433
- "outputs": [
6273
+ },
6434
6274
  {
6275
+ "name": "approved",
6435
6276
  "type": "core::bool"
6436
6277
  }
6437
6278
  ],
6438
- "state_mutability": "view"
6279
+ "outputs": [],
6280
+ "state_mutability": "external"
6439
6281
  }
6440
6282
  ]
6441
6283
  },
6442
6284
  {
6443
6285
  "type": "impl",
6444
- "name": "ERC721CamelOnly",
6445
- "interface_name": "openzeppelin_token::erc721::interface::IERC721CamelOnly"
6286
+ "name": "ERC1155CamelImpl",
6287
+ "interface_name": "openzeppelin_token::erc1155::interface::IERC1155Camel"
6446
6288
  },
6447
6289
  {
6448
6290
  "type": "interface",
6449
- "name": "openzeppelin_token::erc721::interface::IERC721CamelOnly",
6291
+ "name": "openzeppelin_token::erc1155::interface::IERC1155Camel",
6450
6292
  "items": [
6451
6293
  {
6452
6294
  "type": "function",
@@ -6455,6 +6297,10 @@ var IPTicketCollectionABI = [
6455
6297
  {
6456
6298
  "name": "account",
6457
6299
  "type": "core::starknet::contract_address::ContractAddress"
6300
+ },
6301
+ {
6302
+ "name": "tokenId",
6303
+ "type": "core::integer::u256"
6458
6304
  }
6459
6305
  ],
6460
6306
  "outputs": [
@@ -6466,16 +6312,20 @@ var IPTicketCollectionABI = [
6466
6312
  },
6467
6313
  {
6468
6314
  "type": "function",
6469
- "name": "ownerOf",
6315
+ "name": "balanceOfBatch",
6470
6316
  "inputs": [
6471
6317
  {
6472
- "name": "tokenId",
6473
- "type": "core::integer::u256"
6318
+ "name": "accounts",
6319
+ "type": "core::array::Span::<core::starknet::contract_address::ContractAddress>"
6320
+ },
6321
+ {
6322
+ "name": "tokenIds",
6323
+ "type": "core::array::Span::<core::integer::u256>"
6474
6324
  }
6475
6325
  ],
6476
6326
  "outputs": [
6477
6327
  {
6478
- "type": "core::starknet::contract_address::ContractAddress"
6328
+ "type": "core::array::Span::<core::integer::u256>"
6479
6329
  }
6480
6330
  ],
6481
6331
  "state_mutability": "view"
@@ -6496,6 +6346,10 @@ var IPTicketCollectionABI = [
6496
6346
  "name": "tokenId",
6497
6347
  "type": "core::integer::u256"
6498
6348
  },
6349
+ {
6350
+ "name": "value",
6351
+ "type": "core::integer::u256"
6352
+ },
6499
6353
  {
6500
6354
  "name": "data",
6501
6355
  "type": "core::array::Span::<core::felt252>"
@@ -6506,7 +6360,7 @@ var IPTicketCollectionABI = [
6506
6360
  },
6507
6361
  {
6508
6362
  "type": "function",
6509
- "name": "transferFrom",
6363
+ "name": "safeBatchTransferFrom",
6510
6364
  "inputs": [
6511
6365
  {
6512
6366
  "name": "from",
@@ -6517,24 +6371,16 @@ var IPTicketCollectionABI = [
6517
6371
  "type": "core::starknet::contract_address::ContractAddress"
6518
6372
  },
6519
6373
  {
6520
- "name": "tokenId",
6521
- "type": "core::integer::u256"
6522
- }
6523
- ],
6524
- "outputs": [],
6525
- "state_mutability": "external"
6526
- },
6527
- {
6528
- "type": "function",
6529
- "name": "setApprovalForAll",
6530
- "inputs": [
6374
+ "name": "tokenIds",
6375
+ "type": "core::array::Span::<core::integer::u256>"
6376
+ },
6531
6377
  {
6532
- "name": "operator",
6533
- "type": "core::starknet::contract_address::ContractAddress"
6378
+ "name": "values",
6379
+ "type": "core::array::Span::<core::integer::u256>"
6534
6380
  },
6535
6381
  {
6536
- "name": "approved",
6537
- "type": "core::bool"
6382
+ "name": "data",
6383
+ "type": "core::array::Span::<core::felt252>"
6538
6384
  }
6539
6385
  ],
6540
6386
  "outputs": [],
@@ -6542,39 +6388,39 @@ var IPTicketCollectionABI = [
6542
6388
  },
6543
6389
  {
6544
6390
  "type": "function",
6545
- "name": "getApproved",
6391
+ "name": "isApprovedForAll",
6546
6392
  "inputs": [
6547
6393
  {
6548
- "name": "tokenId",
6549
- "type": "core::integer::u256"
6394
+ "name": "owner",
6395
+ "type": "core::starknet::contract_address::ContractAddress"
6396
+ },
6397
+ {
6398
+ "name": "operator",
6399
+ "type": "core::starknet::contract_address::ContractAddress"
6550
6400
  }
6551
6401
  ],
6552
6402
  "outputs": [
6553
6403
  {
6554
- "type": "core::starknet::contract_address::ContractAddress"
6404
+ "type": "core::bool"
6555
6405
  }
6556
6406
  ],
6557
6407
  "state_mutability": "view"
6558
6408
  },
6559
6409
  {
6560
6410
  "type": "function",
6561
- "name": "isApprovedForAll",
6411
+ "name": "setApprovalForAll",
6562
6412
  "inputs": [
6563
- {
6564
- "name": "owner",
6565
- "type": "core::starknet::contract_address::ContractAddress"
6566
- },
6567
6413
  {
6568
6414
  "name": "operator",
6569
6415
  "type": "core::starknet::contract_address::ContractAddress"
6570
- }
6571
- ],
6572
- "outputs": [
6416
+ },
6573
6417
  {
6418
+ "name": "approved",
6574
6419
  "type": "core::bool"
6575
6420
  }
6576
6421
  ],
6577
- "state_mutability": "view"
6422
+ "outputs": [],
6423
+ "state_mutability": "external"
6578
6424
  }
6579
6425
  ]
6580
6426
  },
@@ -6685,9 +6531,14 @@ var IPTicketCollectionABI = [
6685
6531
  },
6686
6532
  {
6687
6533
  "type": "event",
6688
- "name": "openzeppelin_token::erc721::erc721::ERC721Component::Transfer",
6534
+ "name": "openzeppelin_token::erc1155::erc1155::ERC1155Component::TransferSingle",
6689
6535
  "kind": "struct",
6690
6536
  "members": [
6537
+ {
6538
+ "name": "operator",
6539
+ "type": "core::starknet::contract_address::ContractAddress",
6540
+ "kind": "key"
6541
+ },
6691
6542
  {
6692
6543
  "name": "from",
6693
6544
  "type": "core::starknet::contract_address::ContractAddress",
@@ -6699,37 +6550,52 @@ var IPTicketCollectionABI = [
6699
6550
  "kind": "key"
6700
6551
  },
6701
6552
  {
6702
- "name": "token_id",
6553
+ "name": "id",
6703
6554
  "type": "core::integer::u256",
6704
- "kind": "key"
6555
+ "kind": "data"
6556
+ },
6557
+ {
6558
+ "name": "value",
6559
+ "type": "core::integer::u256",
6560
+ "kind": "data"
6705
6561
  }
6706
6562
  ]
6707
6563
  },
6708
6564
  {
6709
6565
  "type": "event",
6710
- "name": "openzeppelin_token::erc721::erc721::ERC721Component::Approval",
6566
+ "name": "openzeppelin_token::erc1155::erc1155::ERC1155Component::TransferBatch",
6711
6567
  "kind": "struct",
6712
6568
  "members": [
6713
6569
  {
6714
- "name": "owner",
6570
+ "name": "operator",
6715
6571
  "type": "core::starknet::contract_address::ContractAddress",
6716
6572
  "kind": "key"
6717
6573
  },
6718
6574
  {
6719
- "name": "approved",
6575
+ "name": "from",
6720
6576
  "type": "core::starknet::contract_address::ContractAddress",
6721
6577
  "kind": "key"
6722
6578
  },
6723
6579
  {
6724
- "name": "token_id",
6725
- "type": "core::integer::u256",
6580
+ "name": "to",
6581
+ "type": "core::starknet::contract_address::ContractAddress",
6726
6582
  "kind": "key"
6583
+ },
6584
+ {
6585
+ "name": "ids",
6586
+ "type": "core::array::Span::<core::integer::u256>",
6587
+ "kind": "data"
6588
+ },
6589
+ {
6590
+ "name": "values",
6591
+ "type": "core::array::Span::<core::integer::u256>",
6592
+ "kind": "data"
6727
6593
  }
6728
6594
  ]
6729
6595
  },
6730
6596
  {
6731
6597
  "type": "event",
6732
- "name": "openzeppelin_token::erc721::erc721::ERC721Component::ApprovalForAll",
6598
+ "name": "openzeppelin_token::erc1155::erc1155::ERC1155Component::ApprovalForAll",
6733
6599
  "kind": "struct",
6734
6600
  "members": [
6735
6601
  {
@@ -6751,22 +6617,44 @@ var IPTicketCollectionABI = [
6751
6617
  },
6752
6618
  {
6753
6619
  "type": "event",
6754
- "name": "openzeppelin_token::erc721::erc721::ERC721Component::Event",
6620
+ "name": "openzeppelin_token::erc1155::erc1155::ERC1155Component::URI",
6621
+ "kind": "struct",
6622
+ "members": [
6623
+ {
6624
+ "name": "value",
6625
+ "type": "core::byte_array::ByteArray",
6626
+ "kind": "data"
6627
+ },
6628
+ {
6629
+ "name": "id",
6630
+ "type": "core::integer::u256",
6631
+ "kind": "key"
6632
+ }
6633
+ ]
6634
+ },
6635
+ {
6636
+ "type": "event",
6637
+ "name": "openzeppelin_token::erc1155::erc1155::ERC1155Component::Event",
6755
6638
  "kind": "enum",
6756
6639
  "variants": [
6757
6640
  {
6758
- "name": "Transfer",
6759
- "type": "openzeppelin_token::erc721::erc721::ERC721Component::Transfer",
6641
+ "name": "TransferSingle",
6642
+ "type": "openzeppelin_token::erc1155::erc1155::ERC1155Component::TransferSingle",
6760
6643
  "kind": "nested"
6761
6644
  },
6762
6645
  {
6763
- "name": "Approval",
6764
- "type": "openzeppelin_token::erc721::erc721::ERC721Component::Approval",
6646
+ "name": "TransferBatch",
6647
+ "type": "openzeppelin_token::erc1155::erc1155::ERC1155Component::TransferBatch",
6765
6648
  "kind": "nested"
6766
6649
  },
6767
6650
  {
6768
6651
  "name": "ApprovalForAll",
6769
- "type": "openzeppelin_token::erc721::erc721::ERC721Component::ApprovalForAll",
6652
+ "type": "openzeppelin_token::erc1155::erc1155::ERC1155Component::ApprovalForAll",
6653
+ "kind": "nested"
6654
+ },
6655
+ {
6656
+ "name": "URI",
6657
+ "type": "openzeppelin_token::erc1155::erc1155::ERC1155Component::URI",
6770
6658
  "kind": "nested"
6771
6659
  }
6772
6660
  ]
@@ -6830,42 +6718,27 @@ var IPTicketCollectionABI = [
6830
6718
  },
6831
6719
  {
6832
6720
  "type": "event",
6833
- "name": "ip_ticket::IPTicketCollection::IPTicketCollection::TicketCollectionCreated",
6721
+ "name": "ip_ticket::IPTicketCollection::IPTicketCollection::EventCreated",
6834
6722
  "kind": "struct",
6835
6723
  "members": [
6836
6724
  {
6837
- "name": "collection_id",
6725
+ "name": "token_id",
6838
6726
  "type": "core::integer::u256",
6839
6727
  "kind": "key"
6840
6728
  },
6841
- {
6842
- "name": "creator",
6843
- "type": "core::starknet::contract_address::ContractAddress",
6844
- "kind": "key"
6845
- },
6846
- {
6847
- "name": "price",
6848
- "type": "core::integer::u256",
6849
- "kind": "data"
6850
- },
6851
6729
  {
6852
6730
  "name": "max_supply",
6853
6731
  "type": "core::integer::u256",
6854
6732
  "kind": "data"
6855
6733
  },
6856
6734
  {
6857
- "name": "expiration",
6858
- "type": "core::integer::u64",
6859
- "kind": "data"
6860
- },
6861
- {
6862
- "name": "royalty_bps",
6863
- "type": "core::integer::u256",
6735
+ "name": "start_time",
6736
+ "type": "core::option::Option::<core::integer::u64>",
6864
6737
  "kind": "data"
6865
6738
  },
6866
6739
  {
6867
- "name": "payment_token",
6868
- "type": "core::option::Option::<core::starknet::contract_address::ContractAddress>",
6740
+ "name": "end_time",
6741
+ "type": "core::option::Option::<core::integer::u64>",
6869
6742
  "kind": "data"
6870
6743
  },
6871
6744
  {
@@ -6882,11 +6755,11 @@ var IPTicketCollectionABI = [
6882
6755
  },
6883
6756
  {
6884
6757
  "type": "event",
6885
- "name": "ip_ticket::IPTicketCollection::IPTicketCollection::CollectionStatusUpdated",
6758
+ "name": "ip_ticket::IPTicketCollection::IPTicketCollection::EventPaused",
6886
6759
  "kind": "struct",
6887
6760
  "members": [
6888
6761
  {
6889
- "name": "collection_id",
6762
+ "name": "token_id",
6890
6763
  "type": "core::integer::u256",
6891
6764
  "kind": "key"
6892
6765
  },
@@ -6894,65 +6767,6 @@ var IPTicketCollectionABI = [
6894
6767
  "name": "active",
6895
6768
  "type": "core::bool",
6896
6769
  "kind": "data"
6897
- },
6898
- {
6899
- "name": "updated_at",
6900
- "type": "core::integer::u64",
6901
- "kind": "data"
6902
- }
6903
- ]
6904
- },
6905
- {
6906
- "type": "event",
6907
- "name": "ip_ticket::IPTicketCollection::IPTicketCollection::TicketMinted",
6908
- "kind": "struct",
6909
- "members": [
6910
- {
6911
- "name": "token_id",
6912
- "type": "core::integer::u256",
6913
- "kind": "key"
6914
- },
6915
- {
6916
- "name": "collection_id",
6917
- "type": "core::integer::u256",
6918
- "kind": "key"
6919
- },
6920
- {
6921
- "name": "owner",
6922
- "type": "core::starknet::contract_address::ContractAddress",
6923
- "kind": "key"
6924
- },
6925
- {
6926
- "name": "minted_at",
6927
- "type": "core::integer::u64",
6928
- "kind": "data"
6929
- }
6930
- ]
6931
- },
6932
- {
6933
- "type": "event",
6934
- "name": "ip_ticket::IPTicketCollection::IPTicketCollection::TicketRedeemed",
6935
- "kind": "struct",
6936
- "members": [
6937
- {
6938
- "name": "token_id",
6939
- "type": "core::integer::u256",
6940
- "kind": "key"
6941
- },
6942
- {
6943
- "name": "collection_id",
6944
- "type": "core::integer::u256",
6945
- "kind": "key"
6946
- },
6947
- {
6948
- "name": "owner",
6949
- "type": "core::starknet::contract_address::ContractAddress",
6950
- "kind": "key"
6951
- },
6952
- {
6953
- "name": "redeemed_at",
6954
- "type": "core::integer::u64",
6955
- "kind": "data"
6956
6770
  }
6957
6771
  ]
6958
6772
  },
@@ -6962,8 +6776,8 @@ var IPTicketCollectionABI = [
6962
6776
  "kind": "enum",
6963
6777
  "variants": [
6964
6778
  {
6965
- "name": "ERC721Event",
6966
- "type": "openzeppelin_token::erc721::erc721::ERC721Component::Event",
6779
+ "name": "ERC1155Event",
6780
+ "type": "openzeppelin_token::erc1155::erc1155::ERC1155Component::Event",
6967
6781
  "kind": "flat"
6968
6782
  },
6969
6783
  {
@@ -6977,23 +6791,13 @@ var IPTicketCollectionABI = [
6977
6791
  "kind": "flat"
6978
6792
  },
6979
6793
  {
6980
- "name": "TicketCollectionCreated",
6981
- "type": "ip_ticket::IPTicketCollection::IPTicketCollection::TicketCollectionCreated",
6982
- "kind": "nested"
6983
- },
6984
- {
6985
- "name": "CollectionStatusUpdated",
6986
- "type": "ip_ticket::IPTicketCollection::IPTicketCollection::CollectionStatusUpdated",
6987
- "kind": "nested"
6988
- },
6989
- {
6990
- "name": "TicketMinted",
6991
- "type": "ip_ticket::IPTicketCollection::IPTicketCollection::TicketMinted",
6794
+ "name": "EventCreated",
6795
+ "type": "ip_ticket::IPTicketCollection::IPTicketCollection::EventCreated",
6992
6796
  "kind": "nested"
6993
6797
  },
6994
6798
  {
6995
- "name": "TicketRedeemed",
6996
- "type": "ip_ticket::IPTicketCollection::IPTicketCollection::TicketRedeemed",
6799
+ "name": "EventPaused",
6800
+ "type": "ip_ticket::IPTicketCollection::IPTicketCollection::EventPaused",
6997
6801
  "kind": "nested"
6998
6802
  }
6999
6803
  ]
@@ -7053,7 +6857,7 @@ var IPTicketCollectionFactoryABI = [
7053
6857
  },
7054
6858
  {
7055
6859
  "type": "function",
7056
- "name": "deploy_ticket_collection",
6860
+ "name": "deploy_collection",
7057
6861
  "inputs": [
7058
6862
  {
7059
6863
  "name": "name",
@@ -7073,6 +6877,47 @@ var IPTicketCollectionFactoryABI = [
7073
6877
  }
7074
6878
  ]
7075
6879
  },
6880
+ {
6881
+ "type": "impl",
6882
+ "name": "SRC5Impl",
6883
+ "interface_name": "openzeppelin_introspection::interface::ISRC5"
6884
+ },
6885
+ {
6886
+ "type": "enum",
6887
+ "name": "core::bool",
6888
+ "variants": [
6889
+ {
6890
+ "name": "False",
6891
+ "type": "()"
6892
+ },
6893
+ {
6894
+ "name": "True",
6895
+ "type": "()"
6896
+ }
6897
+ ]
6898
+ },
6899
+ {
6900
+ "type": "interface",
6901
+ "name": "openzeppelin_introspection::interface::ISRC5",
6902
+ "items": [
6903
+ {
6904
+ "type": "function",
6905
+ "name": "supports_interface",
6906
+ "inputs": [
6907
+ {
6908
+ "name": "interface_id",
6909
+ "type": "core::felt252"
6910
+ }
6911
+ ],
6912
+ "outputs": [
6913
+ {
6914
+ "type": "core::bool"
6915
+ }
6916
+ ],
6917
+ "state_mutability": "view"
6918
+ }
6919
+ ]
6920
+ },
7076
6921
  {
7077
6922
  "type": "constructor",
7078
6923
  "name": "constructor",
@@ -7083,6 +6928,12 @@ var IPTicketCollectionFactoryABI = [
7083
6928
  }
7084
6929
  ]
7085
6930
  },
6931
+ {
6932
+ "type": "event",
6933
+ "name": "openzeppelin_introspection::src5::SRC5Component::Event",
6934
+ "kind": "enum",
6935
+ "variants": []
6936
+ },
7086
6937
  {
7087
6938
  "type": "event",
7088
6939
  "name": "ip_ticket::IPTicketCollectionFactory::IPTicketCollectionFactory::CollectionDeployed",
@@ -7115,6 +6966,11 @@ var IPTicketCollectionFactoryABI = [
7115
6966
  "name": "ip_ticket::IPTicketCollectionFactory::IPTicketCollectionFactory::Event",
7116
6967
  "kind": "enum",
7117
6968
  "variants": [
6969
+ {
6970
+ "name": "SRC5Event",
6971
+ "type": "openzeppelin_introspection::src5::SRC5Component::Event",
6972
+ "kind": "flat"
6973
+ },
7118
6974
  {
7119
6975
  "name": "CollectionDeployed",
7120
6976
  "type": "ip_ticket::IPTicketCollectionFactory::IPTicketCollectionFactory::CollectionDeployed",
@@ -12811,66 +12667,84 @@ var CreatorCoinService = class {
12811
12667
  };
12812
12668
  var TicketService = class {
12813
12669
  constructor(config) {
12670
+ this.config = config;
12814
12671
  this.factoryAddress = getStarknetCoordinates(config.chain).ipTicketsFactory;
12815
12672
  }
12673
+ _factory(account, factoryAddress) {
12674
+ const address = factoryAddress ?? this.factoryAddress;
12675
+ if (!address) throw new Error("IP-Tickets factory address not configured for this chain");
12676
+ return new Contract(IPTicketCollectionFactoryABI, normalizeAddress("STARKNET", address), account);
12677
+ }
12816
12678
  _collection(address, account) {
12817
12679
  return new Contract(IPTicketCollectionABI, normalizeAddress("STARKNET", address), account);
12818
12680
  }
12819
- /** Deploys a new IPTicketCollection via the factory. Caller becomes its owner. */
12820
- async deployTicketCollection(account, params) {
12821
- const factoryAddress = params.factoryAddress ?? this.factoryAddress;
12822
- if (!factoryAddress) {
12823
- throw new Error("IP-Tickets factory address not configured for this chain");
12824
- }
12825
- const factory = new Contract(IPTicketCollectionFactoryABI, factoryAddress, account);
12826
- const call = factory.populate("deploy_ticket_collection", [params.name, params.symbol]);
12681
+ _collectionRead(address) {
12682
+ const provider = new RpcProvider({ nodeUrl: this.config.rpcUrl });
12683
+ return new Contract(IPTicketCollectionABI, normalizeAddress("STARKNET", address), provider);
12684
+ }
12685
+ /** Deploys a new IPTicketCollection via the factory. Caller becomes owner. */
12686
+ async deployCollection(account, params) {
12687
+ const call = this._factory(account, params.factoryAddress).populate("deploy_collection", [params.name, params.symbol]);
12827
12688
  const res = await account.execute([call]);
12828
12689
  return { txHash: res.transaction_hash };
12829
12690
  }
12830
- /** Owner-only. Creates a new ticket collection (event/tier) inside the caller's deployed IPTicketCollection. */
12831
- async createTicketCollection(account, params) {
12832
- const paymentToken = params.paymentToken ? new CairoOption(CairoOptionVariant.Some, params.paymentToken) : new CairoOption(CairoOptionVariant.None);
12833
- const call = this._collection(params.collection, account).populate("create_ticket_collection", [
12834
- cairo.uint256(params.price),
12691
+ /** Owner-only. Creates a new event inside the caller's deployed collection. */
12692
+ async createEvent(account, params) {
12693
+ const startTime = params.startTime != null ? new CairoOption(CairoOptionVariant.Some, params.startTime) : new CairoOption(CairoOptionVariant.None);
12694
+ const endTime = params.endTime != null ? new CairoOption(CairoOptionVariant.Some, params.endTime) : new CairoOption(CairoOptionVariant.None);
12695
+ const call = this._collection(params.collection, account).populate("create_event", [
12835
12696
  cairo.uint256(params.maxSupply),
12836
- params.expiration,
12697
+ startTime,
12698
+ endTime,
12837
12699
  params.royaltyBps,
12838
- paymentToken,
12839
12700
  params.metadataUri
12840
12701
  ]);
12841
12702
  const res = await account.execute([call]);
12842
12703
  return { txHash: res.transaction_hash };
12843
12704
  }
12844
- /** Owner-only. Gates minting only existing tickets keep access/transfer/redeem. */
12845
- async setCollectionActive(account, params) {
12846
- const call = this._collection(params.collection, account).populate("set_collection_active", [
12847
- cairo.uint256(params.collectionId),
12848
- params.active
12705
+ /** Owner-only. Mints `amount` of `tokenId` to `to`. */
12706
+ async mint(account, params) {
12707
+ const call = this._collection(params.collection, account).populate("mint", [
12708
+ params.to,
12709
+ cairo.uint256(params.tokenId),
12710
+ cairo.uint256(params.amount)
12849
12711
  ]);
12850
12712
  const res = await account.execute([call]);
12851
12713
  return { txHash: res.transaction_hash };
12852
12714
  }
12853
- /** Mints a ticket. Prepends an ERC-20 approve when the collection is paid. */
12854
- async mintTicket(account, params) {
12855
- const calls = [];
12856
- if (params.paymentToken && params.price && BigInt(params.price) > 0n) {
12857
- const amount = cairo.uint256(params.price);
12858
- calls.push({
12859
- contractAddress: params.paymentToken,
12860
- entrypoint: "approve",
12861
- calldata: [normalizeAddress("STARKNET", params.collection), amount.low.toString(), amount.high.toString()]
12862
- });
12863
- }
12864
- calls.push(this._collection(params.collection, account).populate("mint_ticket", [cairo.uint256(params.collectionId)]));
12865
- const res = await account.execute(calls);
12866
- return { txHash: res.transaction_hash };
12867
- }
12868
- /** Only the current token owner may redeem. */
12869
- async redeemTicket(account, params) {
12870
- const call = this._collection(params.collection, account).populate("redeem_ticket", [cairo.uint256(params.tokenId)]);
12715
+ /** Owner-only. Pauses or resumes minting for one event. */
12716
+ async pauseEvent(account, params) {
12717
+ const call = this._collection(params.collection, account).populate("pause_event", [
12718
+ cairo.uint256(params.tokenId),
12719
+ params.active
12720
+ ]);
12871
12721
  const res = await account.execute([call]);
12872
12722
  return { txHash: res.transaction_hash };
12873
12723
  }
12724
+ /** Read — true if holder has balance > 0 and current time is within the event window. */
12725
+ async isValid(params) {
12726
+ const result = await this._collectionRead(params.collection).call("is_valid", [
12727
+ cairo.uint256(params.tokenId),
12728
+ params.holder
12729
+ ]);
12730
+ return Boolean(result);
12731
+ }
12732
+ /** Read — returns the EventRecord for a token ID. */
12733
+ async getEvent(params) {
12734
+ const ev = await this._collectionRead(params.collection).call("get_event", [
12735
+ cairo.uint256(params.tokenId)
12736
+ ]);
12737
+ return {
12738
+ creator: ev.creator,
12739
+ maxSupply: BigInt(ev.max_supply),
12740
+ minted: BigInt(ev.minted),
12741
+ startTime: ev.start_time?.variant === "Some" ? Number(ev.start_time.values[0] ?? ev.start_time.value) : null,
12742
+ endTime: ev.end_time?.variant === "Some" ? Number(ev.end_time.values[0] ?? ev.end_time.value) : null,
12743
+ royaltyBps: Number(ev.royalty_bps),
12744
+ metadataUri: ev.metadata_uri,
12745
+ active: Boolean(ev.active)
12746
+ };
12747
+ }
12874
12748
  };
12875
12749
  var ClubService = class {
12876
12750
  constructor(config) {