@lukso/lsp-smart-contracts 0.12.0 → 0.13.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.
Files changed (160) hide show
  1. package/README.md +2 -2
  2. package/artifacts/LSP0ERC725Account.json +19 -19
  3. package/artifacts/LSP0ERC725AccountInit.json +19 -19
  4. package/artifacts/LSP11BasicSocialRecovery.json +2 -2
  5. package/artifacts/LSP11BasicSocialRecoveryInit.json +2 -2
  6. package/artifacts/LSP1UniversalReceiverDelegateUP.json +15 -15
  7. package/artifacts/LSP1UniversalReceiverDelegateVault.json +15 -15
  8. package/artifacts/LSP4DigitalAssetMetadata.json +5 -0
  9. package/artifacts/LSP4DigitalAssetMetadataInitAbstract.json +5 -0
  10. package/artifacts/LSP6KeyManager.json +15 -15
  11. package/artifacts/LSP6KeyManagerInit.json +15 -15
  12. package/artifacts/LSP7CappedSupply.json +71 -49
  13. package/artifacts/LSP7CappedSupplyInitAbstract.json +71 -49
  14. package/artifacts/LSP7CompatibleERC20.json +71 -49
  15. package/artifacts/LSP7CompatibleERC20InitAbstract.json +71 -49
  16. package/artifacts/LSP7CompatibleERC20Mintable.json +78 -51
  17. package/artifacts/LSP7CompatibleERC20MintableInit.json +78 -51
  18. package/artifacts/LSP7DigitalAsset.json +71 -49
  19. package/artifacts/LSP7DigitalAssetInitAbstract.json +71 -49
  20. package/artifacts/LSP7Mintable.json +78 -51
  21. package/artifacts/LSP7MintableInit.json +78 -51
  22. package/artifacts/LSP8CappedSupply.json +187 -36
  23. package/artifacts/LSP8CappedSupplyInitAbstract.json +200 -49
  24. package/artifacts/LSP8CompatibleERC721.json +187 -36
  25. package/artifacts/LSP8CompatibleERC721InitAbstract.json +200 -49
  26. package/artifacts/LSP8CompatibleERC721Mintable.json +195 -39
  27. package/artifacts/LSP8CompatibleERC721MintableInit.json +208 -52
  28. package/artifacts/LSP8IdentifiableDigitalAsset.json +187 -36
  29. package/artifacts/LSP8IdentifiableDigitalAssetInitAbstract.json +200 -49
  30. package/artifacts/LSP8Mintable.json +195 -39
  31. package/artifacts/LSP8MintableInit.json +208 -52
  32. package/artifacts/LSP9Vault.json +19 -19
  33. package/artifacts/LSP9VaultInit.json +19 -19
  34. package/artifacts/UniversalProfile.json +19 -19
  35. package/artifacts/UniversalProfileInit.json +19 -19
  36. package/contracts/LSP0ERC725Account/LSP0Constants.sol +1 -1
  37. package/contracts/LSP0ERC725Account/LSP0ERC725Account.sol +7 -3
  38. package/contracts/LSP0ERC725Account/LSP0ERC725AccountCore.sol +62 -62
  39. package/contracts/LSP0ERC725Account/LSP0ERC725AccountInit.sol +2 -1
  40. package/contracts/LSP0ERC725Account/LSP0ERC725AccountInitAbstract.sol +3 -1
  41. package/contracts/LSP14Ownable2Step/LSP14Ownable2Step.sol +11 -10
  42. package/contracts/LSP17Extensions/Extension4337.sol +26 -1
  43. package/contracts/LSP17Extensions/OnERC721ReceivedExtension.sol +2 -1
  44. package/contracts/LSP1UniversalReceiver/LSP1UniversalReceiverDelegateUP/LSP1UniversalReceiverDelegateUP.sol +31 -33
  45. package/contracts/LSP1UniversalReceiver/LSP1UniversalReceiverDelegateVault/LSP1UniversalReceiverDelegateVault.sol +24 -17
  46. package/contracts/LSP1UniversalReceiver/LSP1Utils.sol +1 -1
  47. package/contracts/LSP25ExecuteRelayCall/LSP25MultiChannelNonce.sol +1 -5
  48. package/contracts/LSP4DigitalAssetMetadata/LSP4Constants.sol +9 -0
  49. package/contracts/LSP4DigitalAssetMetadata/LSP4DigitalAssetMetadata.sol +20 -34
  50. package/contracts/LSP4DigitalAssetMetadata/LSP4DigitalAssetMetadataCore.sol +47 -0
  51. package/contracts/LSP4DigitalAssetMetadata/LSP4DigitalAssetMetadataInitAbstract.sol +19 -31
  52. package/contracts/LSP4DigitalAssetMetadata/LSP4Errors.sol +13 -6
  53. package/contracts/LSP6KeyManager/LSP6KeyManager.sol +2 -1
  54. package/contracts/LSP6KeyManager/LSP6KeyManagerCore.sol +16 -10
  55. package/contracts/LSP6KeyManager/LSP6KeyManagerInit.sol +2 -1
  56. package/contracts/LSP6KeyManager/LSP6Modules/LSP6ExecuteModule.sol +14 -16
  57. package/contracts/LSP6KeyManager/LSP6Modules/LSP6SetDataModule.sol +6 -2
  58. package/contracts/LSP7DigitalAsset/ILSP7DigitalAsset.sol +20 -9
  59. package/contracts/LSP7DigitalAsset/LSP7Constants.sol +1 -1
  60. package/contracts/LSP7DigitalAsset/LSP7DigitalAsset.sol +7 -5
  61. package/contracts/LSP7DigitalAsset/LSP7DigitalAssetCore.sol +129 -36
  62. package/contracts/LSP7DigitalAsset/LSP7DigitalAssetInitAbstract.sol +5 -2
  63. package/contracts/LSP7DigitalAsset/LSP7Errors.sol +6 -0
  64. package/contracts/LSP7DigitalAsset/extensions/LSP7CompatibleERC20.sol +4 -2
  65. package/contracts/LSP7DigitalAsset/extensions/LSP7CompatibleERC20InitAbstract.sol +7 -4
  66. package/contracts/LSP7DigitalAsset/presets/LSP7CompatibleERC20Mintable.sol +4 -2
  67. package/contracts/LSP7DigitalAsset/presets/LSP7CompatibleERC20MintableInit.sol +5 -2
  68. package/contracts/LSP7DigitalAsset/presets/LSP7CompatibleERC20MintableInitAbstract.sol +8 -2
  69. package/contracts/LSP7DigitalAsset/presets/LSP7Mintable.sol +12 -1
  70. package/contracts/LSP7DigitalAsset/presets/LSP7MintableInit.sol +4 -0
  71. package/contracts/LSP7DigitalAsset/presets/LSP7MintableInitAbstract.sol +4 -0
  72. package/contracts/LSP8IdentifiableDigitalAsset/ILSP8IdentifiableDigitalAsset.sol +77 -4
  73. package/contracts/LSP8IdentifiableDigitalAsset/LSP8Constants.sol +15 -12
  74. package/contracts/LSP8IdentifiableDigitalAsset/LSP8Errors.sol +19 -3
  75. package/contracts/LSP8IdentifiableDigitalAsset/LSP8IdentifiableDigitalAsset.sol +25 -16
  76. package/contracts/LSP8IdentifiableDigitalAsset/LSP8IdentifiableDigitalAssetCore.sol +222 -28
  77. package/contracts/LSP8IdentifiableDigitalAsset/LSP8IdentifiableDigitalAssetInitAbstract.sol +28 -15
  78. package/contracts/LSP8IdentifiableDigitalAsset/extensions/LSP8CompatibleERC721.sol +16 -8
  79. package/contracts/LSP8IdentifiableDigitalAsset/extensions/LSP8CompatibleERC721InitAbstract.sol +9 -8
  80. package/contracts/LSP8IdentifiableDigitalAsset/presets/LSP8CompatibleERC721Mintable.sol +13 -2
  81. package/contracts/LSP8IdentifiableDigitalAsset/presets/LSP8CompatibleERC721MintableInit.sol +6 -2
  82. package/contracts/LSP8IdentifiableDigitalAsset/presets/LSP8CompatibleERC721MintableInitAbstract.sol +4 -2
  83. package/contracts/LSP8IdentifiableDigitalAsset/presets/LSP8Mintable.sol +13 -2
  84. package/contracts/LSP8IdentifiableDigitalAsset/presets/LSP8MintableInit.sol +6 -2
  85. package/contracts/LSP8IdentifiableDigitalAsset/presets/LSP8MintableInitAbstract.sol +6 -2
  86. package/contracts/LSP9Vault/LSP9Constants.sol +1 -1
  87. package/contracts/LSP9Vault/LSP9Vault.sol +3 -2
  88. package/contracts/LSP9Vault/LSP9VaultCore.sol +22 -37
  89. package/contracts/LSP9Vault/LSP9VaultInit.sol +2 -1
  90. package/contracts/LSP9Vault/LSP9VaultInitAbstract.sol +1 -1
  91. package/contracts/UniversalProfile.sol +4 -2
  92. package/contracts/UniversalProfileInit.sol +8 -5
  93. package/contracts/UniversalProfileInitAbstract.sol +4 -2
  94. package/contracts/Version.sol +6 -5
  95. package/devdocs/LSP0ERC725Account.json +3 -8
  96. package/devdocs/LSP0ERC725AccountInit.json +2 -7
  97. package/devdocs/LSP1UniversalReceiverDelegateUP.json +0 -6
  98. package/devdocs/LSP1UniversalReceiverDelegateVault.json +0 -6
  99. package/devdocs/LSP4DigitalAssetMetadata.json +11 -5
  100. package/devdocs/LSP4DigitalAssetMetadataInitAbstract.json +7 -2
  101. package/devdocs/LSP6KeyManager.json +2 -7
  102. package/devdocs/LSP6KeyManagerInit.json +2 -7
  103. package/devdocs/LSP7CappedSupply.json +22 -8
  104. package/devdocs/LSP7CappedSupplyInitAbstract.json +22 -8
  105. package/devdocs/LSP7CompatibleERC20.json +23 -8
  106. package/devdocs/LSP7CompatibleERC20InitAbstract.json +22 -8
  107. package/devdocs/LSP7CompatibleERC20Mintable.json +23 -8
  108. package/devdocs/LSP7CompatibleERC20MintableInit.json +24 -9
  109. package/devdocs/LSP7DigitalAsset.json +27 -12
  110. package/devdocs/LSP7DigitalAssetInitAbstract.json +22 -8
  111. package/devdocs/LSP7Mintable.json +24 -8
  112. package/devdocs/LSP7MintableInit.json +25 -9
  113. package/devdocs/LSP8CappedSupply.json +66 -10
  114. package/devdocs/LSP8CappedSupplyInitAbstract.json +66 -10
  115. package/devdocs/LSP8CompatibleERC721.json +69 -11
  116. package/devdocs/LSP8CompatibleERC721InitAbstract.json +67 -11
  117. package/devdocs/LSP8CompatibleERC721Mintable.json +69 -11
  118. package/devdocs/LSP8CompatibleERC721MintableInit.json +70 -12
  119. package/devdocs/LSP8IdentifiableDigitalAsset.json +71 -14
  120. package/devdocs/LSP8IdentifiableDigitalAssetInitAbstract.json +66 -10
  121. package/devdocs/LSP8Mintable.json +68 -10
  122. package/devdocs/LSP8MintableInit.json +69 -11
  123. package/devdocs/LSP9Vault.json +0 -6
  124. package/devdocs/LSP9VaultInit.json +0 -6
  125. package/devdocs/UniversalProfile.json +3 -8
  126. package/devdocs/UniversalProfileInit.json +4 -9
  127. package/dist/constants.cjs.js +4552 -1859
  128. package/dist/constants.d.ts +4143 -1371
  129. package/dist/constants.es.js +4551 -1859
  130. package/package.json +2 -2
  131. package/userdocs/LSP0ERC725Account.json +3 -3
  132. package/userdocs/LSP0ERC725AccountInit.json +3 -3
  133. package/userdocs/LSP1UniversalReceiverDelegateUP.json +3 -3
  134. package/userdocs/LSP1UniversalReceiverDelegateVault.json +3 -3
  135. package/userdocs/LSP6KeyManager.json +3 -3
  136. package/userdocs/LSP6KeyManagerInit.json +3 -3
  137. package/userdocs/LSP7CappedSupply.json +8 -3
  138. package/userdocs/LSP7CappedSupplyInitAbstract.json +8 -3
  139. package/userdocs/LSP7CompatibleERC20.json +8 -3
  140. package/userdocs/LSP7CompatibleERC20InitAbstract.json +8 -3
  141. package/userdocs/LSP7CompatibleERC20Mintable.json +8 -3
  142. package/userdocs/LSP7CompatibleERC20MintableInit.json +9 -4
  143. package/userdocs/LSP7DigitalAsset.json +8 -3
  144. package/userdocs/LSP7DigitalAssetInitAbstract.json +8 -3
  145. package/userdocs/LSP7Mintable.json +8 -3
  146. package/userdocs/LSP7MintableInit.json +9 -4
  147. package/userdocs/LSP8CappedSupply.json +20 -3
  148. package/userdocs/LSP8CappedSupplyInitAbstract.json +20 -3
  149. package/userdocs/LSP8CompatibleERC721.json +20 -3
  150. package/userdocs/LSP8CompatibleERC721InitAbstract.json +20 -3
  151. package/userdocs/LSP8CompatibleERC721Mintable.json +20 -3
  152. package/userdocs/LSP8CompatibleERC721MintableInit.json +21 -4
  153. package/userdocs/LSP8IdentifiableDigitalAsset.json +20 -3
  154. package/userdocs/LSP8IdentifiableDigitalAssetInitAbstract.json +19 -2
  155. package/userdocs/LSP8Mintable.json +19 -2
  156. package/userdocs/LSP8MintableInit.json +20 -3
  157. package/userdocs/LSP9Vault.json +3 -3
  158. package/userdocs/LSP9VaultInit.json +3 -3
  159. package/userdocs/UniversalProfile.json +3 -3
  160. package/userdocs/UniversalProfileInit.json +3 -3
@@ -28,12 +28,22 @@
28
28
  ],
29
29
  "LSP4TokenNameNotEditable()": [
30
30
  {
31
- "details": "Reverts when trying to edit the data key `LSP4TokenName` after the digital asset contract has been deployed. The `LSP4TokenName` data key is located inside the ERC725Y Data key-value store of the digital asset contract. It can be set only once inside the constructor/initializer when the digital asset contract is being deployed."
31
+ "details": "Reverts when trying to edit the data key `LSP4TokenName` after the digital asset contract has been deployed / initialized. The `LSP4TokenName` data key is located inside the ERC725Y data key-value store of the digital asset contract. It can be set only once inside the constructor/initializer when the digital asset contract is being deployed / initialized."
32
32
  }
33
33
  ],
34
34
  "LSP4TokenSymbolNotEditable()": [
35
35
  {
36
- "details": "Reverts when trying to edit the data key `LSP4TokenSymbol` after the digital asset contract has been deployed. The `LSP4TokenSymbol` data key is located inside the ERC725Y Data key-value store of the digital asset contract. It can be set only once inside the constructor/initializer when the digital asset contract is being deployed."
36
+ "details": "Reverts when trying to edit the data key `LSP4TokenSymbol` after the digital asset contract has been deployed / initialized. The `LSP4TokenSymbol` data key is located inside the ERC725Y data key-value store of the digital asset contract. It can be set only once inside the constructor/initializer when the digital asset contract is being deployed / initialized."
37
+ }
38
+ ],
39
+ "LSP4TokenTypeNotEditable()": [
40
+ {
41
+ "details": "Reverts when trying to edit the data key `LSP4TokenType` after the digital asset contract has been deployed / initialized. The `LSP4TokenType` data key is located inside the ERC725Y data key-value store of the digital asset contract. It can be set only once inside the constructor / initializer when the digital asset contract is being deployed / initialized."
42
+ }
43
+ ],
44
+ "LSP8BatchCallFailed(uint256)": [
45
+ {
46
+ "details": "Reverts when a batch call failed."
37
47
  }
38
48
  ],
39
49
  "LSP8CannotSendToAddressZero()": [
@@ -96,9 +106,19 @@
96
106
  "details": "Error occurs when sending native tokens to the LSP8 contract without sending any data. E.g. Sending value without passing a bytes4 function selector to call a LSP17 Extension."
97
107
  }
98
108
  ],
99
- "LSP8TokenIdTypeNotEditable()": [
109
+ "LSP8TokenIdSchemaNotEditable()": [
110
+ {
111
+ "details": "Reverts when trying to edit the data key `LSP8TokenIdSchema` after the identifiable digital asset contract has been deployed. The `LSP8TokenIdSchema` data key is located inside the ERC725Y Data key-value store of the identifiable digital asset contract. It can be set only once inside the constructor/initializer when the identifiable digital asset contract is being deployed."
112
+ }
113
+ ],
114
+ "LSP8TokenIdsDataEmptyArray()": [
100
115
  {
101
- "details": "Reverts when trying to edit the data key `LSP8TokenIdType` after the identifiable digital asset contract has been deployed. The `LSP8TokenIdType` data key is located inside the ERC725Y Data key-value store of the identifiable digital asset contract. It can be set only once inside the constructor/initializer when the identifiable digital asset contract is being deployed."
116
+ "details": "Reverts when empty arrays is passed to the function"
117
+ }
118
+ ],
119
+ "LSP8TokenIdsDataLengthMismatch()": [
120
+ {
121
+ "details": "Reverts when the length of the token IDs data arrays is not equal"
102
122
  }
103
123
  ],
104
124
  "LSP8TokenOwnerCannotBeOperator()": [
@@ -135,7 +155,7 @@
135
155
  }
136
156
  },
137
157
  "authorizeOperator(address,bytes32,bytes)": {
138
- "custom:events": "- LSP7 {AuthorizedOperator} event. - ERC721 {Approval} event.",
158
+ "custom:events": "- LSP7 {OperatorAuthorizationChanged} event. - ERC721 {Approval} event.",
139
159
  "details": "Allow an `operator` address to transfer or burn a specific `tokenId` on behalf of its token owner. See {isOperatorFor}. Notify the operator based on the LSP1-UniversalReceiver standard",
140
160
  "params": {
141
161
  "operator": "The address to authorize as an operator.",
@@ -152,6 +172,16 @@
152
172
  "_0": "The total number of token IDs that `tokenOwner` owns."
153
173
  }
154
174
  },
175
+ "batchCalls(bytes[])": {
176
+ "custom:info": "It's not possible to send value along the functions call due to the use of `delegatecall`.",
177
+ "details": "Allows a caller to batch different function calls in one call. Perform a `delegatecall` on self, to call different functions with preserving the context.",
178
+ "params": {
179
+ "data": "An array of ABI encoded function calls to be called on the contract."
180
+ },
181
+ "returns": {
182
+ "results": "An array of abi-encoded data returned by the functions executed."
183
+ }
184
+ },
155
185
  "getApproved(uint256)": {
156
186
  "details": "Compatible with ERC721 getApproved.",
157
187
  "params": {
@@ -188,6 +218,24 @@
188
218
  "_0": "An array of operators allowed to transfer or burn a specific `tokenId`. Requirements - `tokenId` must exist."
189
219
  }
190
220
  },
221
+ "getTokenIdData(bytes32,bytes32)": {
222
+ "params": {
223
+ "dataKey": "The key for the data to retrieve.",
224
+ "tokenId": "The unique identifier for a token."
225
+ },
226
+ "returns": {
227
+ "dataValues": "The data value associated with the given `tokenId` and `dataKey`."
228
+ }
229
+ },
230
+ "getTokenIdDataBatch(bytes32[],bytes32[])": {
231
+ "params": {
232
+ "dataKey": "An array of data keys corresponding to the token IDs.",
233
+ "tokenId": "An array of token IDs."
234
+ },
235
+ "returns": {
236
+ "dataValues": "An array of data values for each pair of `tokenId` and `dataKey`."
237
+ }
238
+ },
191
239
  "isApprovedForAll(address,address)": {
192
240
  "details": "Compatible with ERC721 isApprovedForAll.",
193
241
  "params": {
@@ -285,6 +333,20 @@
285
333
  "dataValues": "An array of bytes values to set for each `dataKeys`."
286
334
  }
287
335
  },
336
+ "setTokenIdData(bytes32,bytes32,bytes)": {
337
+ "params": {
338
+ "dataKey": "The key for the data to set.",
339
+ "dataValue": "The value to set for the given data key.",
340
+ "tokenId": "The unique identifier for a token."
341
+ }
342
+ },
343
+ "setTokenIdDataBatch(bytes32[],bytes32[],bytes[])": {
344
+ "params": {
345
+ "dataKey": "An array of data keys corresponding to the token IDs.",
346
+ "dataValue": "An array of values to set for the given data keys.",
347
+ "tokenId": "An array of token IDs."
348
+ }
349
+ },
288
350
  "supportsInterface(bytes4)": {
289
351
  "details": "See {IERC165-supportsInterface}."
290
352
  },
@@ -355,12 +417,6 @@
355
417
  },
356
418
  "transferOwnership(address)": {
357
419
  "details": "Transfers ownership of the contract to a new account (`newOwner`). Can only be called by the current owner."
358
- },
359
- "version()": {
360
- "details": "Get the version of the contract.",
361
- "returns": {
362
- "_0": "The version of the the contract."
363
- }
364
420
  }
365
421
  },
366
422
  "stateVariables": {
@@ -27,12 +27,22 @@
27
27
  ],
28
28
  "LSP4TokenNameNotEditable()": [
29
29
  {
30
- "details": "Reverts when trying to edit the data key `LSP4TokenName` after the digital asset contract has been deployed. The `LSP4TokenName` data key is located inside the ERC725Y Data key-value store of the digital asset contract. It can be set only once inside the constructor/initializer when the digital asset contract is being deployed."
30
+ "details": "Reverts when trying to edit the data key `LSP4TokenName` after the digital asset contract has been deployed / initialized. The `LSP4TokenName` data key is located inside the ERC725Y data key-value store of the digital asset contract. It can be set only once inside the constructor/initializer when the digital asset contract is being deployed / initialized."
31
31
  }
32
32
  ],
33
33
  "LSP4TokenSymbolNotEditable()": [
34
34
  {
35
- "details": "Reverts when trying to edit the data key `LSP4TokenSymbol` after the digital asset contract has been deployed. The `LSP4TokenSymbol` data key is located inside the ERC725Y Data key-value store of the digital asset contract. It can be set only once inside the constructor/initializer when the digital asset contract is being deployed."
35
+ "details": "Reverts when trying to edit the data key `LSP4TokenSymbol` after the digital asset contract has been deployed / initialized. The `LSP4TokenSymbol` data key is located inside the ERC725Y data key-value store of the digital asset contract. It can be set only once inside the constructor/initializer when the digital asset contract is being deployed / initialized."
36
+ }
37
+ ],
38
+ "LSP4TokenTypeNotEditable()": [
39
+ {
40
+ "details": "Reverts when trying to edit the data key `LSP4TokenType` after the digital asset contract has been deployed / initialized. The `LSP4TokenType` data key is located inside the ERC725Y data key-value store of the digital asset contract. It can be set only once inside the constructor / initializer when the digital asset contract is being deployed / initialized."
41
+ }
42
+ ],
43
+ "LSP8BatchCallFailed(uint256)": [
44
+ {
45
+ "details": "Reverts when a batch call failed."
36
46
  }
37
47
  ],
38
48
  "LSP8CannotSendToAddressZero()": [
@@ -100,9 +110,19 @@
100
110
  "details": "Reverts when `tokenId` has already been minted."
101
111
  }
102
112
  ],
103
- "LSP8TokenIdTypeNotEditable()": [
113
+ "LSP8TokenIdSchemaNotEditable()": [
114
+ {
115
+ "details": "Reverts when trying to edit the data key `LSP8TokenIdSchema` after the identifiable digital asset contract has been deployed. The `LSP8TokenIdSchema` data key is located inside the ERC725Y Data key-value store of the identifiable digital asset contract. It can be set only once inside the constructor/initializer when the identifiable digital asset contract is being deployed."
116
+ }
117
+ ],
118
+ "LSP8TokenIdsDataEmptyArray()": [
104
119
  {
105
- "details": "Reverts when trying to edit the data key `LSP8TokenIdType` after the identifiable digital asset contract has been deployed. The `LSP8TokenIdType` data key is located inside the ERC725Y Data key-value store of the identifiable digital asset contract. It can be set only once inside the constructor/initializer when the identifiable digital asset contract is being deployed."
120
+ "details": "Reverts when empty arrays is passed to the function"
121
+ }
122
+ ],
123
+ "LSP8TokenIdsDataLengthMismatch()": [
124
+ {
125
+ "details": "Reverts when the length of the token IDs data arrays is not equal"
106
126
  }
107
127
  ],
108
128
  "LSP8TokenOwnerCannotBeOperator()": [
@@ -139,7 +159,7 @@
139
159
  }
140
160
  },
141
161
  "authorizeOperator(address,bytes32,bytes)": {
142
- "custom:events": "- LSP7 {AuthorizedOperator} event. - ERC721 {Approval} event.",
162
+ "custom:events": "- LSP7 {OperatorAuthorizationChanged} event. - ERC721 {Approval} event.",
143
163
  "details": "Allow an `operator` address to transfer or burn a specific `tokenId` on behalf of its token owner. See {isOperatorFor}. Notify the operator based on the LSP1-UniversalReceiver standard",
144
164
  "params": {
145
165
  "operator": "The address to authorize as an operator.",
@@ -156,8 +176,20 @@
156
176
  "_0": "The total number of token IDs that `tokenOwner` owns."
157
177
  }
158
178
  },
179
+ "batchCalls(bytes[])": {
180
+ "custom:info": "It's not possible to send value along the functions call due to the use of `delegatecall`.",
181
+ "details": "Allows a caller to batch different function calls in one call. Perform a `delegatecall` on self, to call different functions with preserving the context.",
182
+ "params": {
183
+ "data": "An array of ABI encoded function calls to be called on the contract."
184
+ },
185
+ "returns": {
186
+ "results": "An array of abi-encoded data returned by the functions executed."
187
+ }
188
+ },
159
189
  "constructor": {
160
190
  "params": {
191
+ "lsp4TokenType_": "The type of token this digital asset contract represents (`1` = Token, `2` = NFT, `3` = Collection).",
192
+ "lsp8TokenIdSchema_": "The schema of tokenIds (= NFTs) that this contract will create.",
161
193
  "name_": "The name of the token.",
162
194
  "newOwner_": "The owner of the token contract.",
163
195
  "symbol_": "The symbol of the token."
@@ -199,6 +231,24 @@
199
231
  "_0": "An array of operators allowed to transfer or burn a specific `tokenId`. Requirements - `tokenId` must exist."
200
232
  }
201
233
  },
234
+ "getTokenIdData(bytes32,bytes32)": {
235
+ "params": {
236
+ "dataKey": "The key for the data to retrieve.",
237
+ "tokenId": "The unique identifier for a token."
238
+ },
239
+ "returns": {
240
+ "dataValues": "The data value associated with the given `tokenId` and `dataKey`."
241
+ }
242
+ },
243
+ "getTokenIdDataBatch(bytes32[],bytes32[])": {
244
+ "params": {
245
+ "dataKey": "An array of data keys corresponding to the token IDs.",
246
+ "tokenId": "An array of token IDs."
247
+ },
248
+ "returns": {
249
+ "dataValues": "An array of data values for each pair of `tokenId` and `dataKey`."
250
+ }
251
+ },
202
252
  "isApprovedForAll(address,address)": {
203
253
  "details": "Compatible with ERC721 isApprovedForAll.",
204
254
  "params": {
@@ -305,6 +355,20 @@
305
355
  "dataValues": "An array of bytes values to set for each `dataKeys`."
306
356
  }
307
357
  },
358
+ "setTokenIdData(bytes32,bytes32,bytes)": {
359
+ "params": {
360
+ "dataKey": "The key for the data to set.",
361
+ "dataValue": "The value to set for the given data key.",
362
+ "tokenId": "The unique identifier for a token."
363
+ }
364
+ },
365
+ "setTokenIdDataBatch(bytes32[],bytes32[],bytes[])": {
366
+ "params": {
367
+ "dataKey": "An array of data keys corresponding to the token IDs.",
368
+ "dataValue": "An array of values to set for the given data keys.",
369
+ "tokenId": "An array of token IDs."
370
+ }
371
+ },
308
372
  "supportsInterface(bytes4)": {
309
373
  "details": "Returns true if this contract implements the interface defined by `interfaceId`. See the corresponding https://eips.ethereum.org/EIPS/eip-165#how-interfaces-are-identified[EIP section] to learn more about how these ids are created. This function call must use less than 30 000 gas."
310
374
  },
@@ -375,12 +439,6 @@
375
439
  },
376
440
  "transferOwnership(address)": {
377
441
  "details": "Transfers ownership of the contract to a new account (`newOwner`). Can only be called by the current owner."
378
- },
379
- "version()": {
380
- "details": "Get the version of the contract.",
381
- "returns": {
382
- "_0": "The version of the the contract."
383
- }
384
442
  }
385
443
  },
386
444
  "title": "LSP8CompatibleERC721Mintable deployable preset contract with a public {mint} function callable only by the contract {owner}.",
@@ -27,12 +27,22 @@
27
27
  ],
28
28
  "LSP4TokenNameNotEditable()": [
29
29
  {
30
- "details": "Reverts when trying to edit the data key `LSP4TokenName` after the digital asset contract has been deployed. The `LSP4TokenName` data key is located inside the ERC725Y Data key-value store of the digital asset contract. It can be set only once inside the constructor/initializer when the digital asset contract is being deployed."
30
+ "details": "Reverts when trying to edit the data key `LSP4TokenName` after the digital asset contract has been deployed / initialized. The `LSP4TokenName` data key is located inside the ERC725Y data key-value store of the digital asset contract. It can be set only once inside the constructor/initializer when the digital asset contract is being deployed / initialized."
31
31
  }
32
32
  ],
33
33
  "LSP4TokenSymbolNotEditable()": [
34
34
  {
35
- "details": "Reverts when trying to edit the data key `LSP4TokenSymbol` after the digital asset contract has been deployed. The `LSP4TokenSymbol` data key is located inside the ERC725Y Data key-value store of the digital asset contract. It can be set only once inside the constructor/initializer when the digital asset contract is being deployed."
35
+ "details": "Reverts when trying to edit the data key `LSP4TokenSymbol` after the digital asset contract has been deployed / initialized. The `LSP4TokenSymbol` data key is located inside the ERC725Y data key-value store of the digital asset contract. It can be set only once inside the constructor/initializer when the digital asset contract is being deployed / initialized."
36
+ }
37
+ ],
38
+ "LSP4TokenTypeNotEditable()": [
39
+ {
40
+ "details": "Reverts when trying to edit the data key `LSP4TokenType` after the digital asset contract has been deployed / initialized. The `LSP4TokenType` data key is located inside the ERC725Y data key-value store of the digital asset contract. It can be set only once inside the constructor / initializer when the digital asset contract is being deployed / initialized."
41
+ }
42
+ ],
43
+ "LSP8BatchCallFailed(uint256)": [
44
+ {
45
+ "details": "Reverts when a batch call failed."
36
46
  }
37
47
  ],
38
48
  "LSP8CannotSendToAddressZero()": [
@@ -100,9 +110,19 @@
100
110
  "details": "Reverts when `tokenId` has already been minted."
101
111
  }
102
112
  ],
103
- "LSP8TokenIdTypeNotEditable()": [
113
+ "LSP8TokenIdSchemaNotEditable()": [
114
+ {
115
+ "details": "Reverts when trying to edit the data key `LSP8TokenIdSchema` after the identifiable digital asset contract has been deployed. The `LSP8TokenIdSchema` data key is located inside the ERC725Y Data key-value store of the identifiable digital asset contract. It can be set only once inside the constructor/initializer when the identifiable digital asset contract is being deployed."
116
+ }
117
+ ],
118
+ "LSP8TokenIdsDataEmptyArray()": [
104
119
  {
105
- "details": "Reverts when trying to edit the data key `LSP8TokenIdType` after the identifiable digital asset contract has been deployed. The `LSP8TokenIdType` data key is located inside the ERC725Y Data key-value store of the identifiable digital asset contract. It can be set only once inside the constructor/initializer when the identifiable digital asset contract is being deployed."
120
+ "details": "Reverts when empty arrays is passed to the function"
121
+ }
122
+ ],
123
+ "LSP8TokenIdsDataLengthMismatch()": [
124
+ {
125
+ "details": "Reverts when the length of the token IDs data arrays is not equal"
106
126
  }
107
127
  ],
108
128
  "LSP8TokenOwnerCannotBeOperator()": [
@@ -139,7 +159,7 @@
139
159
  }
140
160
  },
141
161
  "authorizeOperator(address,bytes32,bytes)": {
142
- "custom:events": "- LSP7 {AuthorizedOperator} event. - ERC721 {Approval} event.",
162
+ "custom:events": "- LSP7 {OperatorAuthorizationChanged} event. - ERC721 {Approval} event.",
143
163
  "details": "Allow an `operator` address to transfer or burn a specific `tokenId` on behalf of its token owner. See {isOperatorFor}. Notify the operator based on the LSP1-UniversalReceiver standard",
144
164
  "params": {
145
165
  "operator": "The address to authorize as an operator.",
@@ -156,6 +176,16 @@
156
176
  "_0": "The total number of token IDs that `tokenOwner` owns."
157
177
  }
158
178
  },
179
+ "batchCalls(bytes[])": {
180
+ "custom:info": "It's not possible to send value along the functions call due to the use of `delegatecall`.",
181
+ "details": "Allows a caller to batch different function calls in one call. Perform a `delegatecall` on self, to call different functions with preserving the context.",
182
+ "params": {
183
+ "data": "An array of ABI encoded function calls to be called on the contract."
184
+ },
185
+ "returns": {
186
+ "results": "An array of abi-encoded data returned by the functions executed."
187
+ }
188
+ },
159
189
  "constructor": {
160
190
  "details": "initialize (= lock) base implementation contract on deployment"
161
191
  },
@@ -195,8 +225,28 @@
195
225
  "_0": "An array of operators allowed to transfer or burn a specific `tokenId`. Requirements - `tokenId` must exist."
196
226
  }
197
227
  },
198
- "initialize(string,string,address,uint256)": {
228
+ "getTokenIdData(bytes32,bytes32)": {
229
+ "params": {
230
+ "dataKey": "The key for the data to retrieve.",
231
+ "tokenId": "The unique identifier for a token."
232
+ },
233
+ "returns": {
234
+ "dataValues": "The data value associated with the given `tokenId` and `dataKey`."
235
+ }
236
+ },
237
+ "getTokenIdDataBatch(bytes32[],bytes32[])": {
238
+ "params": {
239
+ "dataKey": "An array of data keys corresponding to the token IDs.",
240
+ "tokenId": "An array of token IDs."
241
+ },
242
+ "returns": {
243
+ "dataValues": "An array of data values for each pair of `tokenId` and `dataKey`."
244
+ }
245
+ },
246
+ "initialize(string,string,address,uint256,uint256)": {
199
247
  "params": {
248
+ "lsp4TokenType_": "The type of token this digital asset contract represents (`1` = Token, `2` = NFT, `3` = Collection).",
249
+ "lsp8TokenIdSchema_": "The schema of tokenIds (= NFTs) that this contract will create.",
200
250
  "name_": "The name of the token.",
201
251
  "newOwner_": "The owner of the token contract.",
202
252
  "symbol_": "The symbol of the token."
@@ -308,6 +358,20 @@
308
358
  "dataValues": "An array of bytes values to set for each `dataKeys`."
309
359
  }
310
360
  },
361
+ "setTokenIdData(bytes32,bytes32,bytes)": {
362
+ "params": {
363
+ "dataKey": "The key for the data to set.",
364
+ "dataValue": "The value to set for the given data key.",
365
+ "tokenId": "The unique identifier for a token."
366
+ }
367
+ },
368
+ "setTokenIdDataBatch(bytes32[],bytes32[],bytes[])": {
369
+ "params": {
370
+ "dataKey": "An array of data keys corresponding to the token IDs.",
371
+ "dataValue": "An array of values to set for the given data keys.",
372
+ "tokenId": "An array of token IDs."
373
+ }
374
+ },
311
375
  "supportsInterface(bytes4)": {
312
376
  "details": "See {IERC165-supportsInterface}."
313
377
  },
@@ -378,12 +442,6 @@
378
442
  },
379
443
  "transferOwnership(address)": {
380
444
  "details": "Transfers ownership of the contract to a new account (`newOwner`). Can only be called by the current owner."
381
- },
382
- "version()": {
383
- "details": "Get the version of the contract.",
384
- "returns": {
385
- "_0": "The version of the the contract."
386
- }
387
445
  }
388
446
  },
389
447
  "title": "LSP8CompatibleERC721MintableInit deployable preset contract (proxy version) with a public mint function callable only by the contract {owner}",
@@ -29,12 +29,22 @@
29
29
  ],
30
30
  "LSP4TokenNameNotEditable()": [
31
31
  {
32
- "details": "Reverts when trying to edit the data key `LSP4TokenName` after the digital asset contract has been deployed. The `LSP4TokenName` data key is located inside the ERC725Y Data key-value store of the digital asset contract. It can be set only once inside the constructor/initializer when the digital asset contract is being deployed."
32
+ "details": "Reverts when trying to edit the data key `LSP4TokenName` after the digital asset contract has been deployed / initialized. The `LSP4TokenName` data key is located inside the ERC725Y data key-value store of the digital asset contract. It can be set only once inside the constructor/initializer when the digital asset contract is being deployed / initialized."
33
33
  }
34
34
  ],
35
35
  "LSP4TokenSymbolNotEditable()": [
36
36
  {
37
- "details": "Reverts when trying to edit the data key `LSP4TokenSymbol` after the digital asset contract has been deployed. The `LSP4TokenSymbol` data key is located inside the ERC725Y Data key-value store of the digital asset contract. It can be set only once inside the constructor/initializer when the digital asset contract is being deployed."
37
+ "details": "Reverts when trying to edit the data key `LSP4TokenSymbol` after the digital asset contract has been deployed / initialized. The `LSP4TokenSymbol` data key is located inside the ERC725Y data key-value store of the digital asset contract. It can be set only once inside the constructor/initializer when the digital asset contract is being deployed / initialized."
38
+ }
39
+ ],
40
+ "LSP4TokenTypeNotEditable()": [
41
+ {
42
+ "details": "Reverts when trying to edit the data key `LSP4TokenType` after the digital asset contract has been deployed / initialized. The `LSP4TokenType` data key is located inside the ERC725Y data key-value store of the digital asset contract. It can be set only once inside the constructor / initializer when the digital asset contract is being deployed / initialized."
43
+ }
44
+ ],
45
+ "LSP8BatchCallFailed(uint256)": [
46
+ {
47
+ "details": "Reverts when a batch call failed."
38
48
  }
39
49
  ],
40
50
  "LSP8CannotSendToAddressZero()": [
@@ -97,9 +107,19 @@
97
107
  "details": "Error occurs when sending native tokens to the LSP8 contract without sending any data. E.g. Sending value without passing a bytes4 function selector to call a LSP17 Extension."
98
108
  }
99
109
  ],
100
- "LSP8TokenIdTypeNotEditable()": [
110
+ "LSP8TokenIdSchemaNotEditable()": [
111
+ {
112
+ "details": "Reverts when trying to edit the data key `LSP8TokenIdSchema` after the identifiable digital asset contract has been deployed. The `LSP8TokenIdSchema` data key is located inside the ERC725Y Data key-value store of the identifiable digital asset contract. It can be set only once inside the constructor/initializer when the identifiable digital asset contract is being deployed."
113
+ }
114
+ ],
115
+ "LSP8TokenIdsDataEmptyArray()": [
101
116
  {
102
- "details": "Reverts when trying to edit the data key `LSP8TokenIdType` after the identifiable digital asset contract has been deployed. The `LSP8TokenIdType` data key is located inside the ERC725Y Data key-value store of the identifiable digital asset contract. It can be set only once inside the constructor/initializer when the identifiable digital asset contract is being deployed."
117
+ "details": "Reverts when empty arrays is passed to the function"
118
+ }
119
+ ],
120
+ "LSP8TokenIdsDataLengthMismatch()": [
121
+ {
122
+ "details": "Reverts when the length of the token IDs data arrays is not equal"
103
123
  }
104
124
  ],
105
125
  "LSP8TokenOwnerCannotBeOperator()": [
@@ -145,14 +165,25 @@
145
165
  "_0": "The total number of token IDs that `tokenOwner` owns."
146
166
  }
147
167
  },
168
+ "batchCalls(bytes[])": {
169
+ "custom:info": "It's not possible to send value along the functions call due to the use of `delegatecall`.",
170
+ "details": "Allows a caller to batch different function calls in one call. Perform a `delegatecall` on self, to call different functions with preserving the context.",
171
+ "params": {
172
+ "data": "An array of ABI encoded function calls to be called on the contract."
173
+ },
174
+ "returns": {
175
+ "results": "An array of abi-encoded data returned by the functions executed."
176
+ }
177
+ },
148
178
  "constructor": {
149
- "custom:warning": "Make sure the tokenId type provided on deployment is correct, as it can only be set once and cannot be changed in the ERC725Y storage after the contract has been deployed.",
150
- "details": "Deploy a `LSP8IdentifiableDigitalAsset` contract and set the tokenId type inside the ERC725Y storage of the contract. This will also set the token `name_` and `symbol_` under the ERC725Y data keys `LSP4TokenName` and `LSP4TokenSymbol`.",
179
+ "custom:warning": "Make sure the tokenId schema provided on deployment is correct, as it can only be set once and cannot be changed in the ERC725Y storage after the contract has been deployed.",
180
+ "details": "Deploy a `LSP8IdentifiableDigitalAsset` contract and set the tokenId schema inside the ERC725Y storage of the contract. This will also set the token `name_` and `symbol_` under the ERC725Y data keys `LSP4TokenName` and `LSP4TokenSymbol`.",
151
181
  "params": {
182
+ "lsp4TokenType_": "The type of token this digital asset contract represents (`1` = Token, `2` = NFT, `3` = Collection).",
183
+ "lsp8TokenIdSchema_": "The schema of tokenIds (= NFTs) that this contract will create.",
152
184
  "name_": "The name of the token",
153
185
  "newOwner_": "The owner of the the token-Metadata",
154
- "symbol_": "The symbol of the token",
155
- "tokenIdType_": "The type of tokenIds (= NFTs) that this contract will create. Available options are: NUMBER = `0`; STRING = `1`; UNIQUE_ID = `2`; HASH = `3`; ADDRESS = `4`."
186
+ "symbol_": "The symbol of the token"
156
187
  }
157
188
  },
158
189
  "getData(bytes32)": {
@@ -182,6 +213,24 @@
182
213
  "_0": "An array of operators allowed to transfer or burn a specific `tokenId`. Requirements - `tokenId` must exist."
183
214
  }
184
215
  },
216
+ "getTokenIdData(bytes32,bytes32)": {
217
+ "params": {
218
+ "dataKey": "The key for the data to retrieve.",
219
+ "tokenId": "The unique identifier for a token."
220
+ },
221
+ "returns": {
222
+ "dataValues": "The data value associated with the given `tokenId` and `dataKey`."
223
+ }
224
+ },
225
+ "getTokenIdDataBatch(bytes32[],bytes32[])": {
226
+ "params": {
227
+ "dataKey": "An array of data keys corresponding to the token IDs.",
228
+ "tokenId": "An array of token IDs."
229
+ },
230
+ "returns": {
231
+ "dataValues": "An array of data values for each pair of `tokenId` and `dataKey`."
232
+ }
233
+ },
185
234
  "isOperatorFor(address,bytes32)": {
186
235
  "details": "Returns whether `operator` address is an operator for a given `tokenId`.",
187
236
  "params": {
@@ -227,6 +276,20 @@
227
276
  "dataValues": "An array of bytes values to set for each `dataKeys`."
228
277
  }
229
278
  },
279
+ "setTokenIdData(bytes32,bytes32,bytes)": {
280
+ "params": {
281
+ "dataKey": "The key for the data to set.",
282
+ "dataValue": "The value to set for the given data key.",
283
+ "tokenId": "The unique identifier for a token."
284
+ }
285
+ },
286
+ "setTokenIdDataBatch(bytes32[],bytes32[],bytes[])": {
287
+ "params": {
288
+ "dataKey": "An array of data keys corresponding to the token IDs.",
289
+ "dataValue": "An array of values to set for the given data keys.",
290
+ "tokenId": "An array of token IDs."
291
+ }
292
+ },
230
293
  "supportsInterface(bytes4)": {
231
294
  "details": "Returns true if this contract implements the interface defined by `interfaceId`. See the corresponding https://eips.ethereum.org/EIPS/eip-165#how-interfaces-are-identified[EIP section] to learn more about how these ids are created. This function call must use less than 30 000 gas."
232
295
  },
@@ -276,12 +339,6 @@
276
339
  },
277
340
  "transferOwnership(address)": {
278
341
  "details": "Transfers ownership of the contract to a new account (`newOwner`). Can only be called by the current owner."
279
- },
280
- "version()": {
281
- "details": "Get the version of the contract.",
282
- "returns": {
283
- "_0": "The version of the the contract."
284
- }
285
342
  }
286
343
  },
287
344
  "title": "Implementation of a LSP8 Identifiable Digital Asset, a contract that represents a non-fungible token.",