@lukso/lsp-smart-contracts 0.8.2 → 0.10.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/README.md +29 -8
- package/artifacts/LSP0ERC725Account.json +90 -50
- package/artifacts/LSP0ERC725AccountInit.json +90 -50
- package/artifacts/LSP11BasicSocialRecovery.json +2 -2
- package/artifacts/LSP11BasicSocialRecoveryInit.json +2 -2
- package/artifacts/LSP16UniversalFactory.json +31 -2
- package/artifacts/LSP1UniversalReceiverDelegateUP.json +19 -35
- package/artifacts/LSP1UniversalReceiverDelegateVault.json +13 -13
- package/artifacts/LSP4Compatibility.json +39 -40
- package/artifacts/LSP4DigitalAssetMetadata.json +39 -40
- package/artifacts/LSP4DigitalAssetMetadataInitAbstract.json +39 -40
- package/artifacts/LSP6KeyManager.json +107 -8
- package/artifacts/LSP6KeyManagerInit.json +119 -20
- package/artifacts/LSP7CappedSupply.json +78 -38
- package/artifacts/LSP7CappedSupplyInitAbstract.json +78 -38
- package/artifacts/LSP7CompatibleERC20.json +78 -38
- package/artifacts/LSP7CompatibleERC20InitAbstract.json +78 -38
- package/artifacts/LSP7CompatibleERC20Mintable.json +80 -40
- package/artifacts/LSP7CompatibleERC20MintableInit.json +80 -40
- package/artifacts/LSP7DigitalAsset.json +78 -38
- package/artifacts/LSP7DigitalAssetInitAbstract.json +78 -38
- package/artifacts/LSP7Mintable.json +80 -40
- package/artifacts/LSP7MintableInit.json +80 -40
- package/artifacts/LSP8CappedSupply.json +39 -40
- package/artifacts/LSP8CappedSupplyInitAbstract.json +39 -40
- package/artifacts/LSP8CompatibleERC721.json +42 -43
- package/artifacts/LSP8CompatibleERC721InitAbstract.json +42 -43
- package/artifacts/LSP8CompatibleERC721Mintable.json +44 -45
- package/artifacts/LSP8CompatibleERC721MintableInit.json +44 -45
- package/artifacts/LSP8IdentifiableDigitalAsset.json +39 -40
- package/artifacts/LSP8IdentifiableDigitalAssetInitAbstract.json +39 -40
- package/artifacts/LSP8Mintable.json +41 -42
- package/artifacts/LSP8MintableInit.json +41 -42
- package/artifacts/LSP9Vault.json +73 -55
- package/artifacts/LSP9VaultInit.json +73 -55
- package/artifacts/UniversalProfile.json +90 -50
- package/artifacts/UniversalProfileInit.json +90 -50
- package/contracts/LSP0ERC725Account/ILSP0ERC725Account.sol +62 -0
- package/contracts/LSP0ERC725Account/LSP0Constants.sol +1 -1
- package/contracts/LSP0ERC725Account/LSP0ERC725Account.sol +36 -6
- package/contracts/LSP0ERC725Account/LSP0ERC725AccountCore.sol +605 -219
- package/contracts/LSP0ERC725Account/LSP0ERC725AccountInit.sol +31 -5
- package/contracts/LSP0ERC725Account/LSP0ERC725AccountInitAbstract.sol +37 -3
- package/contracts/LSP0ERC725Account/LSP0Utils.sol +0 -1
- package/contracts/LSP10ReceivedVaults/LSP10Utils.sol +71 -60
- package/contracts/LSP11BasicSocialRecovery/LSP11BasicSocialRecoveryCore.sol +5 -7
- package/contracts/LSP11BasicSocialRecovery/LSP11BasicSocialRecoveryInit.sol +0 -1
- package/contracts/LSP14Ownable2Step/ILSP14Ownable2Step.sol +27 -4
- package/contracts/LSP14Ownable2Step/LSP14Ownable2Step.sol +41 -84
- package/contracts/LSP16UniversalFactory/LSP16UniversalFactory.sol +8 -8
- package/contracts/LSP17ContractExtension/LSP17Extendable.sol +10 -5
- package/contracts/LSP1UniversalReceiver/ILSP1UniversalReceiver.sol +0 -4
- package/contracts/LSP1UniversalReceiver/LSP1UniversalReceiverDelegateUP/LSP1UniversalReceiverDelegateUP.sol +129 -77
- package/contracts/LSP1UniversalReceiver/LSP1UniversalReceiverDelegateVault/LSP1UniversalReceiverDelegateVault.sol +45 -16
- package/contracts/LSP1UniversalReceiver/LSP1Utils.sol +12 -0
- package/contracts/LSP20CallVerification/ILSP20CallVerification.sol +30 -0
- package/contracts/LSP20CallVerification/LSP20CallVerification.sol +83 -0
- package/contracts/LSP20CallVerification/LSP20Constants.sol +17 -0
- package/contracts/LSP20CallVerification/LSP20Errors.sol +15 -0
- package/contracts/LSP2ERC725YJSONSchema/LSP2Utils.sol +26 -12
- package/contracts/LSP4DigitalAssetMetadata/LSP4DigitalAssetMetadataInitAbstract.sol +0 -1
- package/contracts/LSP5ReceivedAssets/LSP5Utils.sol +76 -66
- package/contracts/LSP6KeyManager/ILSP6KeyManager.sol +12 -3
- package/contracts/LSP6KeyManager/LSP6Constants.sol +9 -3
- package/contracts/LSP6KeyManager/LSP6Errors.sol +22 -1
- package/contracts/LSP6KeyManager/LSP6KeyManagerCore.sol +172 -29
- package/contracts/LSP6KeyManager/LSP6KeyManagerInitAbstract.sol +0 -1
- package/contracts/LSP6KeyManager/LSP6Modules/LSP6ExecuteModule.sol +270 -100
- package/contracts/LSP6KeyManager/LSP6Modules/LSP6SetDataModule.sol +187 -67
- package/contracts/LSP6KeyManager/LSP6Utils.sol +31 -20
- package/contracts/LSP7DigitalAsset/LSP7DigitalAssetCore.sol +79 -30
- package/contracts/LSP7DigitalAsset/LSP7Errors.sol +5 -0
- package/contracts/LSP7DigitalAsset/extensions/LSP7Burnable.sol +2 -2
- package/contracts/LSP7DigitalAsset/extensions/LSP7BurnableInitAbstract.sol +24 -0
- package/contracts/LSP7DigitalAsset/extensions/LSP7CappedSupply.sol +1 -2
- package/contracts/LSP7DigitalAsset/extensions/LSP7CappedSupplyInitAbstract.sol +1 -2
- package/contracts/LSP7DigitalAsset/extensions/LSP7CompatibleERC20.sol +3 -5
- package/contracts/LSP7DigitalAsset/extensions/LSP7CompatibleERC20InitAbstract.sol +3 -5
- package/contracts/LSP8IdentifiableDigitalAsset/LSP8IdentifiableDigitalAssetCore.sol +27 -29
- package/contracts/LSP8IdentifiableDigitalAsset/extensions/ILSP8CompatibleERC721.sol +1 -1
- package/contracts/LSP8IdentifiableDigitalAsset/extensions/LSP8CappedSupply.sol +1 -2
- package/contracts/LSP8IdentifiableDigitalAsset/extensions/LSP8CappedSupplyInitAbstract.sol +1 -2
- package/contracts/LSP8IdentifiableDigitalAsset/extensions/LSP8CompatibleERC721.sol +5 -5
- package/contracts/LSP8IdentifiableDigitalAsset/extensions/LSP8CompatibleERC721InitAbstract.sol +6 -6
- package/contracts/LSP8IdentifiableDigitalAsset/extensions/LSP8Enumerable.sol +2 -2
- package/contracts/LSP8IdentifiableDigitalAsset/extensions/LSP8EnumerableInitAbstract.sol +2 -2
- package/contracts/LSP9Vault/ILSP9Vault.sol +27 -0
- package/contracts/LSP9Vault/LSP9Constants.sol +1 -1
- package/contracts/LSP9Vault/LSP9Vault.sol +11 -8
- package/contracts/LSP9Vault/LSP9VaultCore.sol +96 -71
- package/contracts/LSP9Vault/LSP9VaultInit.sol +2 -1
- package/contracts/LSP9Vault/LSP9VaultInitAbstract.sol +19 -7
- package/contracts/UniversalProfileInitAbstract.sol +5 -0
- package/devdocs/Create2Factory.json +16 -0
- package/devdocs/LSP0ERC725Account.json +200 -0
- package/devdocs/LSP0ERC725AccountInit.json +203 -0
- package/devdocs/LSP11BasicSocialRecovery.json +146 -0
- package/devdocs/LSP11BasicSocialRecoveryInit.json +146 -0
- package/devdocs/LSP16UniversalFactory.json +51 -0
- package/devdocs/LSP1UniversalReceiverDelegateUP.json +80 -0
- package/devdocs/LSP1UniversalReceiverDelegateVault.json +62 -0
- package/devdocs/LSP4Compatibility.json +79 -0
- package/devdocs/LSP4DigitalAssetMetadata.json +84 -0
- package/devdocs/LSP4DigitalAssetMetadataInitAbstract.json +77 -0
- package/devdocs/LSP6KeyManager.json +257 -0
- package/devdocs/LSP6KeyManagerInit.json +260 -0
- package/devdocs/LSP7CappedSupply.json +211 -0
- package/devdocs/LSP7CappedSupplyInitAbstract.json +206 -0
- package/devdocs/LSP7CompatibleERC20.json +225 -0
- package/devdocs/LSP7CompatibleERC20InitAbstract.json +218 -0
- package/devdocs/LSP7CompatibleERC20Mintable.json +217 -0
- package/devdocs/LSP7CompatibleERC20MintableInit.json +227 -0
- package/devdocs/LSP7DigitalAsset.json +210 -0
- package/devdocs/LSP7DigitalAssetInitAbstract.json +202 -0
- package/devdocs/LSP7Mintable.json +219 -0
- package/devdocs/LSP7MintableInit.json +220 -0
- package/devdocs/LSP8CappedSupply.json +232 -0
- package/devdocs/LSP8CappedSupplyInitAbstract.json +227 -0
- package/devdocs/LSP8CompatibleERC721.json +298 -0
- package/devdocs/LSP8CompatibleERC721InitAbstract.json +291 -0
- package/devdocs/LSP8CompatibleERC721Mintable.json +290 -0
- package/devdocs/LSP8CompatibleERC721MintableInit.json +300 -0
- package/devdocs/LSP8IdentifiableDigitalAsset.json +230 -0
- package/devdocs/LSP8IdentifiableDigitalAssetInitAbstract.json +223 -0
- package/devdocs/LSP8Mintable.json +242 -0
- package/devdocs/LSP8MintableInit.json +245 -0
- package/devdocs/LSP9Vault.json +171 -0
- package/devdocs/LSP9VaultInit.json +175 -0
- package/devdocs/UniversalProfile.json +199 -0
- package/devdocs/UniversalProfileInit.json +202 -0
- package/devdocs/UniversalReceiverAddressStore.json +9 -0
- package/dist/constants.cjs.js +31569 -0
- package/dist/constants.d.ts +31681 -0
- package/dist/constants.es.js +31550 -0
- package/package.json +70 -52
- package/userdocs/Create2Factory.json +5 -0
- package/userdocs/LSP0ERC725Account.json +47 -0
- package/userdocs/LSP0ERC725AccountInit.json +47 -0
- package/userdocs/LSP11BasicSocialRecovery.json +29 -0
- package/userdocs/LSP11BasicSocialRecoveryInit.json +29 -0
- package/userdocs/LSP16UniversalFactory.json +5 -0
- package/userdocs/LSP1UniversalReceiverDelegateUP.json +10 -0
- package/userdocs/LSP1UniversalReceiverDelegateVault.json +10 -0
- package/userdocs/LSP4Compatibility.json +20 -0
- package/userdocs/LSP4DigitalAssetMetadata.json +23 -0
- package/userdocs/LSP4DigitalAssetMetadataInitAbstract.json +20 -0
- package/userdocs/LSP6KeyManager.json +18 -0
- package/userdocs/LSP6KeyManagerInit.json +18 -0
- package/userdocs/LSP7CappedSupply.json +29 -0
- package/userdocs/LSP7CappedSupplyInitAbstract.json +26 -0
- package/userdocs/LSP7CompatibleERC20.json +35 -0
- package/userdocs/LSP7CompatibleERC20InitAbstract.json +32 -0
- package/userdocs/LSP7CompatibleERC20Mintable.json +32 -0
- package/userdocs/LSP7CompatibleERC20MintableInit.json +35 -0
- package/userdocs/LSP7DigitalAsset.json +29 -0
- package/userdocs/LSP7DigitalAssetInitAbstract.json +26 -0
- package/userdocs/LSP7Mintable.json +29 -0
- package/userdocs/LSP7MintableInit.json +29 -0
- package/userdocs/LSP8CappedSupply.json +23 -0
- package/userdocs/LSP8CappedSupplyInitAbstract.json +20 -0
- package/userdocs/LSP8CompatibleERC721.json +29 -0
- package/userdocs/LSP8CompatibleERC721InitAbstract.json +26 -0
- package/userdocs/LSP8CompatibleERC721Mintable.json +26 -0
- package/userdocs/LSP8CompatibleERC721MintableInit.json +29 -0
- package/userdocs/LSP8IdentifiableDigitalAsset.json +23 -0
- package/userdocs/LSP8IdentifiableDigitalAssetInitAbstract.json +20 -0
- package/userdocs/LSP8Mintable.json +23 -0
- package/userdocs/LSP8MintableInit.json +23 -0
- package/userdocs/LSP9Vault.json +38 -0
- package/userdocs/LSP9VaultInit.json +38 -0
- package/userdocs/UniversalProfile.json +50 -0
- package/userdocs/UniversalProfileInit.json +50 -0
- package/userdocs/UniversalReceiverAddressStore.json +5 -0
- package/CONTRIBUTING.md +0 -57
- package/common/constants.d.ts +0 -738
- package/common/constants.js +0 -785
- package/contracts/Utils/GasLib.sol +0 -17
- package/module/constants.d.ts +0 -738
- package/module/constants.js +0 -782
|
@@ -0,0 +1,175 @@
|
|
|
1
|
+
{
|
|
2
|
+
"author": "Fabian Vogelsteller, Yamen Merhi, Jean Cavallera",
|
|
3
|
+
"details": "Could be owned by a UniversalProfile and able to register received asset with UniversalReceiverDelegateVault",
|
|
4
|
+
"errors": {
|
|
5
|
+
"CannotTransferOwnershipToSelf()": [
|
|
6
|
+
{
|
|
7
|
+
"details": "reverts when trying to transfer ownership to the address(this)"
|
|
8
|
+
}
|
|
9
|
+
],
|
|
10
|
+
"ERC725X_ContractDeploymentFailed()": [
|
|
11
|
+
{
|
|
12
|
+
"details": "reverts when contract deployment via `ERC725X.execute(...)`/`ERC725X.executeBatch(...)` failed. whether using operation type 1 (CREATE) or 2 (CREATE2)."
|
|
13
|
+
}
|
|
14
|
+
],
|
|
15
|
+
"ERC725X_CreateOperationsRequireEmptyRecipientAddress()": [
|
|
16
|
+
{
|
|
17
|
+
"details": "reverts when passing a `to` address while deploying a contract va `ERC725X.execute(...)`/`ERC725X.executeBatch(...)` whether using operation type 1 (CREATE) or 2 (CREATE2)."
|
|
18
|
+
}
|
|
19
|
+
],
|
|
20
|
+
"ERC725X_ExecuteParametersEmptyArray()": [
|
|
21
|
+
{
|
|
22
|
+
"details": "reverts when one of the array parameter provided to `executeBatch(uint256[],address[],uint256[],bytes[]) is an empty array"
|
|
23
|
+
}
|
|
24
|
+
],
|
|
25
|
+
"ERC725X_ExecuteParametersLengthMismatch()": [
|
|
26
|
+
{
|
|
27
|
+
"details": "reverts when there is not the same number of operation, to addresses, value, and data."
|
|
28
|
+
}
|
|
29
|
+
],
|
|
30
|
+
"ERC725X_InsufficientBalance(uint256,uint256)": [
|
|
31
|
+
{
|
|
32
|
+
"details": "reverts when trying to send more native tokens `value` than available in current `balance`.",
|
|
33
|
+
"params": {
|
|
34
|
+
"balance": "the balance of the ERC725X contract.",
|
|
35
|
+
"value": "the amount of native tokens sent via `ERC725X.execute(...)`/`ERC725X.executeBatch(...)`."
|
|
36
|
+
}
|
|
37
|
+
}
|
|
38
|
+
],
|
|
39
|
+
"ERC725X_MsgValueDisallowedInStaticCall()": [
|
|
40
|
+
{
|
|
41
|
+
"details": "the `value` parameter (= sending native tokens) is not allowed when making a staticcall via `ERC725X.execute(...)`/`ERC725X.executeBatch(...)` because sending native tokens is a state changing operation."
|
|
42
|
+
}
|
|
43
|
+
],
|
|
44
|
+
"ERC725X_NoContractBytecodeProvided()": [
|
|
45
|
+
{
|
|
46
|
+
"details": "reverts when no contract bytecode was provided as parameter when trying to deploy a contract via `ERC725X.execute(...)`/`ERC725X.executeBatch(...)`, whether using operation type 1 (CREATE) or 2 (CREATE2)."
|
|
47
|
+
}
|
|
48
|
+
],
|
|
49
|
+
"ERC725X_UnknownOperationType(uint256)": [
|
|
50
|
+
{
|
|
51
|
+
"details": "reverts when the `operationTypeProvided` is none of the default operation types available. (CALL = 0; CREATE = 1; CREATE2 = 2; STATICCALL = 3; DELEGATECALL = 4)"
|
|
52
|
+
}
|
|
53
|
+
],
|
|
54
|
+
"ERC725Y_DataKeysValuesLengthMismatch()": [
|
|
55
|
+
{
|
|
56
|
+
"details": "reverts when there is not the same number of elements in the lists of data keys and data values when calling setDataBatch."
|
|
57
|
+
}
|
|
58
|
+
],
|
|
59
|
+
"ERC725Y_MsgValueDisallowed()": [
|
|
60
|
+
{
|
|
61
|
+
"details": "reverts when sending value to the `setData(..)` functions"
|
|
62
|
+
}
|
|
63
|
+
],
|
|
64
|
+
"LSP1DelegateNotAllowedToSetDataKey(bytes32)": [
|
|
65
|
+
{
|
|
66
|
+
"details": "reverts when the UniversalReceiverDelegates of the Vault sets LSP1/6/17 Data Keys",
|
|
67
|
+
"params": {
|
|
68
|
+
"dataKey": "The data key that the UniversalReceiverDelegate is not allowed to set"
|
|
69
|
+
}
|
|
70
|
+
}
|
|
71
|
+
],
|
|
72
|
+
"NoExtensionFoundForFunctionSelector(bytes4)": [
|
|
73
|
+
{
|
|
74
|
+
"details": "reverts when there is no extension for the function selector being called with"
|
|
75
|
+
}
|
|
76
|
+
],
|
|
77
|
+
"NotInRenounceOwnershipInterval(uint256,uint256)": [
|
|
78
|
+
{
|
|
79
|
+
"details": "reverts when trying to renounce ownership before the initial confirmation delay"
|
|
80
|
+
}
|
|
81
|
+
]
|
|
82
|
+
},
|
|
83
|
+
"kind": "dev",
|
|
84
|
+
"methods": {
|
|
85
|
+
"acceptOwnership()": {
|
|
86
|
+
"details": "same as ILSP14.acceptOwnership with the additional requirement: Requirements: - when notifying the previous owner via LSP1, the typeId used MUST be keccak256('LSP9OwnershipTransferred_SenderNotification') - when notifying the new owner via LSP1, the typeId used MUST be keccak256('LSP9OwnershipTransferred_RecipientNotification')"
|
|
87
|
+
},
|
|
88
|
+
"batchCalls(bytes[])": {
|
|
89
|
+
"details": "Receives and executes a batch of function calls on this contract."
|
|
90
|
+
},
|
|
91
|
+
"constructor": {
|
|
92
|
+
"details": "initialize (= lock) base implementation contract on deployment"
|
|
93
|
+
},
|
|
94
|
+
"execute(uint256,address,uint256,bytes)": {
|
|
95
|
+
"details": "Executes any other smart contract. SHOULD only be callable by the owner of the contract set via ERC173 Emits a {Executed} event, when a call is executed under `operationType` 0 and 3 Emits a {ContractCreated} event, when a contract is created under `operationType` 1 and 2 Emits a {ValueReceived} event, when receives native token",
|
|
96
|
+
"params": {
|
|
97
|
+
"operationType": "The operation to execute: CALL = 0 CREATE = 1 CREATE2 = 2 STATICCALL = 3"
|
|
98
|
+
}
|
|
99
|
+
},
|
|
100
|
+
"executeBatch(uint256[],address[],uint256[],bytes[])": {
|
|
101
|
+
"details": "Emits a {ValueReceived} event when receiving native tokens.",
|
|
102
|
+
"params": {
|
|
103
|
+
"datas": "The list of call data, or the creation bytecode of the contract to deploy",
|
|
104
|
+
"operationsType": "The list of operations type used: CALL = 0; CREATE = 1; CREATE2 = 2; STATICCALL = 3; DELEGATECALL = 4",
|
|
105
|
+
"targets": "The list of addresses to call. `targets` will be unused if a contract is created (operation types 1 and 2).",
|
|
106
|
+
"values": "The list of native token amounts to transfer (in Wei)"
|
|
107
|
+
}
|
|
108
|
+
},
|
|
109
|
+
"getData(bytes32)": {
|
|
110
|
+
"params": {
|
|
111
|
+
"dataKey": "The key which value to retrieve"
|
|
112
|
+
},
|
|
113
|
+
"returns": {
|
|
114
|
+
"dataValue": "The data stored at the key"
|
|
115
|
+
}
|
|
116
|
+
},
|
|
117
|
+
"getDataBatch(bytes32[])": {
|
|
118
|
+
"params": {
|
|
119
|
+
"dataKeys": "The array of keys which values to retrieve"
|
|
120
|
+
},
|
|
121
|
+
"returns": {
|
|
122
|
+
"dataValues": "The array of data stored at multiple keys"
|
|
123
|
+
}
|
|
124
|
+
},
|
|
125
|
+
"initialize(address)": {
|
|
126
|
+
"details": "Sets the owner of the contract and sets the SupportedStandards:LSP9Vault key",
|
|
127
|
+
"params": {
|
|
128
|
+
"newOwner": "the owner of the contract"
|
|
129
|
+
}
|
|
130
|
+
},
|
|
131
|
+
"owner()": {
|
|
132
|
+
"details": "Returns the address of the current owner."
|
|
133
|
+
},
|
|
134
|
+
"pendingOwner()": {
|
|
135
|
+
"details": "The address that ownership of the contract is transferred to. This address may use `acceptOwnership()` to gain ownership of the contract."
|
|
136
|
+
},
|
|
137
|
+
"renounceOwnership()": {
|
|
138
|
+
"details": "Renounce ownership of the contract in a 2-step process. 1. the first call will initiate the process of renouncing ownership. 2. the second is used as a confirmation and will leave the contract without an owner. WARNING: once ownership of the contract has been renounced, any functions that are restricted to be called by the owner will be permanently inaccessible, making these functions not callable anymore and unusable."
|
|
139
|
+
},
|
|
140
|
+
"setData(bytes32,bytes)": {
|
|
141
|
+
"details": "Sets data as bytes in the vault storage for a single key. SHOULD only be callable by the owner of the contract set via ERC173 and the UniversalReceiverDelegate Emits a {DataChanged} event.",
|
|
142
|
+
"params": {
|
|
143
|
+
"dataKey": "The key to retrieve stored value",
|
|
144
|
+
"dataValue": "The value to set SHOULD only be callable by the owner of the contract set via ERC173 The function is marked as payable to enable flexibility on child contracts If the function is not intended to receive value, an additional check should be implemented to check that value equal 0. Emits a {DataChanged} event."
|
|
145
|
+
}
|
|
146
|
+
},
|
|
147
|
+
"setDataBatch(bytes32[],bytes[])": {
|
|
148
|
+
"details": "Sets array of data at multiple given `key` SHOULD only be callable by the owner of the contract set via ERC173 and the UniversalReceiverDelegate Emits a {DataChanged} event.",
|
|
149
|
+
"params": {
|
|
150
|
+
"dataKeys": "The array of data keys for values to set",
|
|
151
|
+
"dataValues": "The array of values to set"
|
|
152
|
+
}
|
|
153
|
+
},
|
|
154
|
+
"supportsInterface(bytes4)": {
|
|
155
|
+
"details": "Returns true if this contract implements the interface defined by `interfaceId`. If the contract doesn't support the `interfaceId`, it forwards the call to the `supportsInterface` extension according to LSP17, and checks if the extension implements the interface defined by `interfaceId`."
|
|
156
|
+
},
|
|
157
|
+
"transferOwnership(address)": {
|
|
158
|
+
"details": "same as ILSP14.transferOwnership with the additional requirement: Requirements: - when notifying the new owner via LSP1, the typeId used MUST be keccak256('LSP9OwnershipTransferStarted')",
|
|
159
|
+
"params": {
|
|
160
|
+
"newOwner": "the address of the new owner. Requirements: - `newOwner` MUST NOT accept ownership of the contract in the same transaction."
|
|
161
|
+
}
|
|
162
|
+
},
|
|
163
|
+
"universalReceiver(bytes32,bytes)": {
|
|
164
|
+
"params": {
|
|
165
|
+
"receivedData": "The data received.",
|
|
166
|
+
"typeId": "The type of call received."
|
|
167
|
+
},
|
|
168
|
+
"returns": {
|
|
169
|
+
"returnedValues": "The ABI encoded return value of the LSP1UniversalReceiverDelegate call and the LSP1TypeIdDelegate call."
|
|
170
|
+
}
|
|
171
|
+
}
|
|
172
|
+
},
|
|
173
|
+
"title": "Deployable Proxy Implementation of LSP9Vault built on top of ERC725, LSP1UniversalReceiver",
|
|
174
|
+
"version": 1
|
|
175
|
+
}
|
|
@@ -0,0 +1,199 @@
|
|
|
1
|
+
{
|
|
2
|
+
"author": "Fabian Vogelsteller <fabian@lukso.network>",
|
|
3
|
+
"details": "Implementation of the ERC725Account + LSP1 universalReceiver",
|
|
4
|
+
"errors": {
|
|
5
|
+
"CannotTransferOwnershipToSelf()": [
|
|
6
|
+
{
|
|
7
|
+
"details": "reverts when trying to transfer ownership to the address(this)"
|
|
8
|
+
}
|
|
9
|
+
],
|
|
10
|
+
"ERC725X_ContractDeploymentFailed()": [
|
|
11
|
+
{
|
|
12
|
+
"details": "reverts when contract deployment via `ERC725X.execute(...)`/`ERC725X.executeBatch(...)` failed. whether using operation type 1 (CREATE) or 2 (CREATE2)."
|
|
13
|
+
}
|
|
14
|
+
],
|
|
15
|
+
"ERC725X_CreateOperationsRequireEmptyRecipientAddress()": [
|
|
16
|
+
{
|
|
17
|
+
"details": "reverts when passing a `to` address while deploying a contract va `ERC725X.execute(...)`/`ERC725X.executeBatch(...)` whether using operation type 1 (CREATE) or 2 (CREATE2)."
|
|
18
|
+
}
|
|
19
|
+
],
|
|
20
|
+
"ERC725X_ExecuteParametersEmptyArray()": [
|
|
21
|
+
{
|
|
22
|
+
"details": "reverts when one of the array parameter provided to `executeBatch(uint256[],address[],uint256[],bytes[]) is an empty array"
|
|
23
|
+
}
|
|
24
|
+
],
|
|
25
|
+
"ERC725X_ExecuteParametersLengthMismatch()": [
|
|
26
|
+
{
|
|
27
|
+
"details": "reverts when there is not the same number of operation, to addresses, value, and data."
|
|
28
|
+
}
|
|
29
|
+
],
|
|
30
|
+
"ERC725X_InsufficientBalance(uint256,uint256)": [
|
|
31
|
+
{
|
|
32
|
+
"details": "reverts when trying to send more native tokens `value` than available in current `balance`.",
|
|
33
|
+
"params": {
|
|
34
|
+
"balance": "the balance of the ERC725X contract.",
|
|
35
|
+
"value": "the amount of native tokens sent via `ERC725X.execute(...)`/`ERC725X.executeBatch(...)`."
|
|
36
|
+
}
|
|
37
|
+
}
|
|
38
|
+
],
|
|
39
|
+
"ERC725X_MsgValueDisallowedInDelegateCall()": [
|
|
40
|
+
{
|
|
41
|
+
"details": "the `value` parameter (= sending native tokens) is not allowed when making a delegatecall via `ERC725X.execute(...)`/`ERC725X.executeBatch(...)` because msg.value is persisting."
|
|
42
|
+
}
|
|
43
|
+
],
|
|
44
|
+
"ERC725X_MsgValueDisallowedInStaticCall()": [
|
|
45
|
+
{
|
|
46
|
+
"details": "the `value` parameter (= sending native tokens) is not allowed when making a staticcall via `ERC725X.execute(...)`/`ERC725X.executeBatch(...)` because sending native tokens is a state changing operation."
|
|
47
|
+
}
|
|
48
|
+
],
|
|
49
|
+
"ERC725X_NoContractBytecodeProvided()": [
|
|
50
|
+
{
|
|
51
|
+
"details": "reverts when no contract bytecode was provided as parameter when trying to deploy a contract via `ERC725X.execute(...)`/`ERC725X.executeBatch(...)`, whether using operation type 1 (CREATE) or 2 (CREATE2)."
|
|
52
|
+
}
|
|
53
|
+
],
|
|
54
|
+
"ERC725X_UnknownOperationType(uint256)": [
|
|
55
|
+
{
|
|
56
|
+
"details": "reverts when the `operationTypeProvided` is none of the default operation types available. (CALL = 0; CREATE = 1; CREATE2 = 2; STATICCALL = 3; DELEGATECALL = 4)"
|
|
57
|
+
}
|
|
58
|
+
],
|
|
59
|
+
"ERC725Y_DataKeysValuesLengthMismatch()": [
|
|
60
|
+
{
|
|
61
|
+
"details": "reverts when there is not the same number of elements in the lists of data keys and data values when calling setDataBatch."
|
|
62
|
+
}
|
|
63
|
+
],
|
|
64
|
+
"LSP20CallingVerifierFailed(bool)": [
|
|
65
|
+
{
|
|
66
|
+
"details": "reverts when the call to the owner fail with no revert reason",
|
|
67
|
+
"params": {
|
|
68
|
+
"postCall": "True if the execution call was done, False otherwise"
|
|
69
|
+
}
|
|
70
|
+
}
|
|
71
|
+
],
|
|
72
|
+
"LSP20InvalidMagicValue(bool,bytes)": [
|
|
73
|
+
{
|
|
74
|
+
"details": "reverts when the call to the owner does not return the magic value",
|
|
75
|
+
"params": {
|
|
76
|
+
"postCall": "The data returned by the call to the logic verifier"
|
|
77
|
+
}
|
|
78
|
+
}
|
|
79
|
+
],
|
|
80
|
+
"NoExtensionFoundForFunctionSelector(bytes4)": [
|
|
81
|
+
{
|
|
82
|
+
"details": "reverts when there is no extension for the function selector being called with"
|
|
83
|
+
}
|
|
84
|
+
],
|
|
85
|
+
"NotInRenounceOwnershipInterval(uint256,uint256)": [
|
|
86
|
+
{
|
|
87
|
+
"details": "reverts when trying to renounce ownership before the initial confirmation delay"
|
|
88
|
+
}
|
|
89
|
+
]
|
|
90
|
+
},
|
|
91
|
+
"kind": "dev",
|
|
92
|
+
"methods": {
|
|
93
|
+
"acceptOwnership()": {
|
|
94
|
+
"details": "Transfer ownership of the contract from the current `owner()` to the `pendingOwner()`. Once this function is called: - the current `owner()` will loose access to the functions restricted to the `owner()` only. - the `pendingOwner()` will gain access to the functions restricted to the `owner()` only. Requirements: - MUST be called by the pendingOwner. - When notifying the previous owner via LSP1, the typeId used MUST be keccak256('LSP0OwnershipTransferred_SenderNotification'). - When notifying the new owner via LSP1, the typeId used MUST be keccak256('LSP0OwnershipTransferred_RecipientNotification')."
|
|
95
|
+
},
|
|
96
|
+
"batchCalls(bytes[])": {
|
|
97
|
+
"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 It is not possible to send value along the functions call due to the use of delegatecall.",
|
|
98
|
+
"params": {
|
|
99
|
+
"data": "An array of ABI encoded function calls to be called on the contract."
|
|
100
|
+
},
|
|
101
|
+
"returns": {
|
|
102
|
+
"results": "An array of values returned by the executed functions."
|
|
103
|
+
}
|
|
104
|
+
},
|
|
105
|
+
"constructor": {
|
|
106
|
+
"params": {
|
|
107
|
+
"newOwner": "the owner of the contract"
|
|
108
|
+
}
|
|
109
|
+
},
|
|
110
|
+
"execute(uint256,address,uint256,bytes)": {
|
|
111
|
+
"details": "Executes any call on other addresses.",
|
|
112
|
+
"params": {
|
|
113
|
+
"data": "The call data to execute on `target`, or the bytecode of the contract to deploy Requirements: - if a `value` is provided, the contract MUST have at least this amount in its balance to execute successfully. - if the operation type is {STATICCALL} or {DELEGATECALL}, `value` SHOULD be 0. - `target` SHOULD be address(0) when deploying a contract. - MUST pass when called by the owner or by an authorised address that pass the verification check performed on the owner accordinng to LSP20 - CallVerification specification Emits a {Executed} event, when a call is executed under `operationType` 0, 3 and 4 Emits a {ContractCreated} event, when a contract is created under `operationType` 1 and 2 Emits a {ValueReceived} event when receiving native tokens.",
|
|
114
|
+
"operationType": "The operation to execute: CALL = 0 CREATE = 1 CREATE2 = 2 STATICCALL = 3 DELEGATECALL = 4",
|
|
115
|
+
"target": "The address (smart contract/EOA) to interact with, `target` will be unused if a contract is created (operation 1 and 2)",
|
|
116
|
+
"value": "The amount of native tokens to transfer (in Wei)."
|
|
117
|
+
}
|
|
118
|
+
},
|
|
119
|
+
"executeBatch(uint256[],address[],uint256[],bytes[])": {
|
|
120
|
+
"details": "Generic batch executor function that executes any call on other addresses",
|
|
121
|
+
"params": {
|
|
122
|
+
"datas": "The list of call data to execute on `targets`, or the creation bytecode of the contracts to deploy Requirements: - The length of the parameters provided MUST be equal - if a `value` is provided, the contract MUST have at least this amount in its balance to execute successfully. - if the operation type is {STATICCALL} or {DELEGATECALL}, `value` SHOULD be 0. - `target` SHOULD be address(0) when deploying a contract. - MUST pass when called by the owner or by an authorised address that pass the verification check performed on the owner accordinng to LSP20 - CallVerification specification Emits a {Executed} event, when a call is executed under `operationType` 0, 3 and 4 (each iteration) Emits a {ContractCreated} event, when a contract is created under `operationType` 1 and 2 (each iteration) Emits a {ValueReceived} event when receiving native tokens.",
|
|
123
|
+
"operationsType": "The list of operations type used: CALL = 0; CREATE = 1; CREATE2 = 2; STATICCALL = 3; DELEGATECALL = 4",
|
|
124
|
+
"targets": "The list of addresses to call. `targets` will be unused if a contract is created (operation types 1 and 2).",
|
|
125
|
+
"values": "The list of native token amounts to transfer (in Wei)"
|
|
126
|
+
}
|
|
127
|
+
},
|
|
128
|
+
"getData(bytes32)": {
|
|
129
|
+
"params": {
|
|
130
|
+
"dataKey": "The key which value to retrieve"
|
|
131
|
+
},
|
|
132
|
+
"returns": {
|
|
133
|
+
"dataValue": "The data stored at the key"
|
|
134
|
+
}
|
|
135
|
+
},
|
|
136
|
+
"getDataBatch(bytes32[])": {
|
|
137
|
+
"params": {
|
|
138
|
+
"dataKeys": "The array of keys which values to retrieve"
|
|
139
|
+
},
|
|
140
|
+
"returns": {
|
|
141
|
+
"dataValues": "The array of data stored at multiple keys"
|
|
142
|
+
}
|
|
143
|
+
},
|
|
144
|
+
"isValidSignature(bytes32,bytes)": {
|
|
145
|
+
"details": "Handles two cases: - If the owner is an EOA, recovers an address from the hash and the signature provided: - Returns the magicValue if the address recovered is the same as the owner, indicating that it was a valid signature. - If the address is different, it returns the fail value indicating that the signature is not valid. - If the owner is a smart contract, it forwards the call of {isValidSignature} to the owner contract: - If the contract fails or returns the fail value, the {isValidSignature} on the account returns the fail value, indicating that the signature is not valid. - If the {isValidSignature} on the owner returned the magicValue, the {isValidSignature} on the account returns the magicValue, indicating that it's a valid signature.",
|
|
146
|
+
"params": {
|
|
147
|
+
"dataHash": "The hash of the data to be validated.",
|
|
148
|
+
"signature": "A signature that can validate the previous parameter (Hash)."
|
|
149
|
+
},
|
|
150
|
+
"returns": {
|
|
151
|
+
"magicValue": "A bytes4 value that indicates if the signature is valid or not."
|
|
152
|
+
}
|
|
153
|
+
},
|
|
154
|
+
"owner()": {
|
|
155
|
+
"details": "Returns the address of the current owner."
|
|
156
|
+
},
|
|
157
|
+
"pendingOwner()": {
|
|
158
|
+
"details": "The address that ownership of the contract is transferred to. This address may use `acceptOwnership()` to gain ownership of the contract."
|
|
159
|
+
},
|
|
160
|
+
"renounceOwnership()": {
|
|
161
|
+
"details": "Renounce ownership of the contract in a 2-step process. 1. the first call will initiate the process of renouncing ownership. 2. the second is used as a confirmation and will leave the contract without an owner. MUST pass when called by the owner or by an authorised address that pass the verification check performed on the owner accordinng to LSP20 - CallVerification specification WARNING: once ownership of the contract has been renounced, any functions that are restricted to be called by the owner will be permanently inaccessible, making these functions not callable anymore and unusable."
|
|
162
|
+
},
|
|
163
|
+
"setData(bytes32,bytes)": {
|
|
164
|
+
"details": "Sets singular data for a given `dataKey`",
|
|
165
|
+
"params": {
|
|
166
|
+
"dataKey": "The key to retrieve stored value",
|
|
167
|
+
"dataValue": "The value to set Requirements: - MUST pass when called by the owner or by an authorised address that pass the verification check performed on the owner accordinng to LSP20 - CallVerification specification Emits a {ValueReceived} event when receiving native tokens. Emits a {DataChanged} event."
|
|
168
|
+
}
|
|
169
|
+
},
|
|
170
|
+
"setDataBatch(bytes32[],bytes[])": {
|
|
171
|
+
"details": "Sets array of data for multiple given `dataKeys`",
|
|
172
|
+
"params": {
|
|
173
|
+
"dataKeys": "The array of data keys for values to set",
|
|
174
|
+
"dataValues": "The array of values to set Requirements: - MUST pass when called by the owner or by an authorised address that pass the verification check performed on the owner accordinng to LSP20 - CallVerification specification Emits a {ValueReceived} event when receiving native tokens. Emits a {DataChanged} event. (on each iteration of setting data)"
|
|
175
|
+
}
|
|
176
|
+
},
|
|
177
|
+
"supportsInterface(bytes4)": {
|
|
178
|
+
"details": "Returns true if this contract implements the interface defined by `interfaceId`. If the contract doesn't support the `interfaceId`, it forwards the call to the `supportsInterface` extension according to LSP17, and checks if the extension implements the interface defined by `interfaceId`."
|
|
179
|
+
},
|
|
180
|
+
"transferOwnership(address)": {
|
|
181
|
+
"details": "Sets the pending owner address as an address that should call {acceptOwnership} in order to complete the ownership transfer of the account. Notifies the pending owner via LSP1Standard by calling {universalReceiver} on the pending owner if it's an address that supports LSP1.",
|
|
182
|
+
"params": {
|
|
183
|
+
"_pendingOwner": "The address of the new pending owner. Requirements: - MUST pass when called by the owner or by an authorized address that passes the verification check performed on the owner according to LSP20 - CallVerification specification. - When notifying the new owner via LSP1, the typeId used MUST be keccak256('LSP0OwnershipTransferStarted'). - pending owner cannot accept ownership in the same tx via the LSP1 hook."
|
|
184
|
+
}
|
|
185
|
+
},
|
|
186
|
+
"universalReceiver(bytes32,bytes)": {
|
|
187
|
+
"details": "The function performs the following steps: - Emits {ValueReceived} when receiving native tokens. - Query the ERC725Y storage with the data key {_LSP1_UNIVERSAL_RECEIVER_DELEGATE_KEY}. - If there is an address stored under the data key, check if this address supports the LSP1 interfaceId. - If yes, call this address with the typeId and data (params), along with additional calldata consisting of 20 bytes of {msg.sender} and 32 bytes of {msg.value}. If not, continue the execution of the function. - Query the ERC725Y storage with the data key {_LSP1_UNIVERSAL_RECEIVER_DELEGATE_KEY + <bytes32 typeId>}. (Check {LSP2-ERC725YJSONSchema} for encoding the data key) - If there is an address stored under the data key, check if this address supports the LSP1 interfaceId. - If yes, call this address with the typeId and data (params), along with additional calldata consisting of 20 bytes of {msg.sender} and 32 bytes of {msg.value}. If not, continue the execution of the function. - Emits a {UniversalReceiver} event.",
|
|
188
|
+
"params": {
|
|
189
|
+
"receivedData": "The data received.",
|
|
190
|
+
"typeId": "The type of call received."
|
|
191
|
+
},
|
|
192
|
+
"returns": {
|
|
193
|
+
"returnedValues": "The ABI encoded return value of the LSP1UniversalReceiverDelegate call and the LSP1TypeIdDelegate call."
|
|
194
|
+
}
|
|
195
|
+
}
|
|
196
|
+
},
|
|
197
|
+
"title": "implementation of a LUKSO's Universal Profile based on LSP3",
|
|
198
|
+
"version": 1
|
|
199
|
+
}
|
|
@@ -0,0 +1,202 @@
|
|
|
1
|
+
{
|
|
2
|
+
"author": "Fabian Vogelsteller <fabian@lukso.network>",
|
|
3
|
+
"details": "Implementation of the ERC725Account + LSP1 universalReceiver",
|
|
4
|
+
"errors": {
|
|
5
|
+
"CannotTransferOwnershipToSelf()": [
|
|
6
|
+
{
|
|
7
|
+
"details": "reverts when trying to transfer ownership to the address(this)"
|
|
8
|
+
}
|
|
9
|
+
],
|
|
10
|
+
"ERC725X_ContractDeploymentFailed()": [
|
|
11
|
+
{
|
|
12
|
+
"details": "reverts when contract deployment via `ERC725X.execute(...)`/`ERC725X.executeBatch(...)` failed. whether using operation type 1 (CREATE) or 2 (CREATE2)."
|
|
13
|
+
}
|
|
14
|
+
],
|
|
15
|
+
"ERC725X_CreateOperationsRequireEmptyRecipientAddress()": [
|
|
16
|
+
{
|
|
17
|
+
"details": "reverts when passing a `to` address while deploying a contract va `ERC725X.execute(...)`/`ERC725X.executeBatch(...)` whether using operation type 1 (CREATE) or 2 (CREATE2)."
|
|
18
|
+
}
|
|
19
|
+
],
|
|
20
|
+
"ERC725X_ExecuteParametersEmptyArray()": [
|
|
21
|
+
{
|
|
22
|
+
"details": "reverts when one of the array parameter provided to `executeBatch(uint256[],address[],uint256[],bytes[]) is an empty array"
|
|
23
|
+
}
|
|
24
|
+
],
|
|
25
|
+
"ERC725X_ExecuteParametersLengthMismatch()": [
|
|
26
|
+
{
|
|
27
|
+
"details": "reverts when there is not the same number of operation, to addresses, value, and data."
|
|
28
|
+
}
|
|
29
|
+
],
|
|
30
|
+
"ERC725X_InsufficientBalance(uint256,uint256)": [
|
|
31
|
+
{
|
|
32
|
+
"details": "reverts when trying to send more native tokens `value` than available in current `balance`.",
|
|
33
|
+
"params": {
|
|
34
|
+
"balance": "the balance of the ERC725X contract.",
|
|
35
|
+
"value": "the amount of native tokens sent via `ERC725X.execute(...)`/`ERC725X.executeBatch(...)`."
|
|
36
|
+
}
|
|
37
|
+
}
|
|
38
|
+
],
|
|
39
|
+
"ERC725X_MsgValueDisallowedInDelegateCall()": [
|
|
40
|
+
{
|
|
41
|
+
"details": "the `value` parameter (= sending native tokens) is not allowed when making a delegatecall via `ERC725X.execute(...)`/`ERC725X.executeBatch(...)` because msg.value is persisting."
|
|
42
|
+
}
|
|
43
|
+
],
|
|
44
|
+
"ERC725X_MsgValueDisallowedInStaticCall()": [
|
|
45
|
+
{
|
|
46
|
+
"details": "the `value` parameter (= sending native tokens) is not allowed when making a staticcall via `ERC725X.execute(...)`/`ERC725X.executeBatch(...)` because sending native tokens is a state changing operation."
|
|
47
|
+
}
|
|
48
|
+
],
|
|
49
|
+
"ERC725X_NoContractBytecodeProvided()": [
|
|
50
|
+
{
|
|
51
|
+
"details": "reverts when no contract bytecode was provided as parameter when trying to deploy a contract via `ERC725X.execute(...)`/`ERC725X.executeBatch(...)`, whether using operation type 1 (CREATE) or 2 (CREATE2)."
|
|
52
|
+
}
|
|
53
|
+
],
|
|
54
|
+
"ERC725X_UnknownOperationType(uint256)": [
|
|
55
|
+
{
|
|
56
|
+
"details": "reverts when the `operationTypeProvided` is none of the default operation types available. (CALL = 0; CREATE = 1; CREATE2 = 2; STATICCALL = 3; DELEGATECALL = 4)"
|
|
57
|
+
}
|
|
58
|
+
],
|
|
59
|
+
"ERC725Y_DataKeysValuesLengthMismatch()": [
|
|
60
|
+
{
|
|
61
|
+
"details": "reverts when there is not the same number of elements in the lists of data keys and data values when calling setDataBatch."
|
|
62
|
+
}
|
|
63
|
+
],
|
|
64
|
+
"LSP20CallingVerifierFailed(bool)": [
|
|
65
|
+
{
|
|
66
|
+
"details": "reverts when the call to the owner fail with no revert reason",
|
|
67
|
+
"params": {
|
|
68
|
+
"postCall": "True if the execution call was done, False otherwise"
|
|
69
|
+
}
|
|
70
|
+
}
|
|
71
|
+
],
|
|
72
|
+
"LSP20InvalidMagicValue(bool,bytes)": [
|
|
73
|
+
{
|
|
74
|
+
"details": "reverts when the call to the owner does not return the magic value",
|
|
75
|
+
"params": {
|
|
76
|
+
"postCall": "The data returned by the call to the logic verifier"
|
|
77
|
+
}
|
|
78
|
+
}
|
|
79
|
+
],
|
|
80
|
+
"NoExtensionFoundForFunctionSelector(bytes4)": [
|
|
81
|
+
{
|
|
82
|
+
"details": "reverts when there is no extension for the function selector being called with"
|
|
83
|
+
}
|
|
84
|
+
],
|
|
85
|
+
"NotInRenounceOwnershipInterval(uint256,uint256)": [
|
|
86
|
+
{
|
|
87
|
+
"details": "reverts when trying to renounce ownership before the initial confirmation delay"
|
|
88
|
+
}
|
|
89
|
+
]
|
|
90
|
+
},
|
|
91
|
+
"kind": "dev",
|
|
92
|
+
"methods": {
|
|
93
|
+
"acceptOwnership()": {
|
|
94
|
+
"details": "Transfer ownership of the contract from the current `owner()` to the `pendingOwner()`. Once this function is called: - the current `owner()` will loose access to the functions restricted to the `owner()` only. - the `pendingOwner()` will gain access to the functions restricted to the `owner()` only. Requirements: - MUST be called by the pendingOwner. - When notifying the previous owner via LSP1, the typeId used MUST be keccak256('LSP0OwnershipTransferred_SenderNotification'). - When notifying the new owner via LSP1, the typeId used MUST be keccak256('LSP0OwnershipTransferred_RecipientNotification')."
|
|
95
|
+
},
|
|
96
|
+
"batchCalls(bytes[])": {
|
|
97
|
+
"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 It is not possible to send value along the functions call due to the use of delegatecall.",
|
|
98
|
+
"params": {
|
|
99
|
+
"data": "An array of ABI encoded function calls to be called on the contract."
|
|
100
|
+
},
|
|
101
|
+
"returns": {
|
|
102
|
+
"results": "An array of values returned by the executed functions."
|
|
103
|
+
}
|
|
104
|
+
},
|
|
105
|
+
"constructor": {
|
|
106
|
+
"details": "initialize (= lock) base implementation contract on deployment"
|
|
107
|
+
},
|
|
108
|
+
"execute(uint256,address,uint256,bytes)": {
|
|
109
|
+
"details": "Executes any call on other addresses.",
|
|
110
|
+
"params": {
|
|
111
|
+
"data": "The call data to execute on `target`, or the bytecode of the contract to deploy Requirements: - if a `value` is provided, the contract MUST have at least this amount in its balance to execute successfully. - if the operation type is {STATICCALL} or {DELEGATECALL}, `value` SHOULD be 0. - `target` SHOULD be address(0) when deploying a contract. - MUST pass when called by the owner or by an authorised address that pass the verification check performed on the owner accordinng to LSP20 - CallVerification specification Emits a {Executed} event, when a call is executed under `operationType` 0, 3 and 4 Emits a {ContractCreated} event, when a contract is created under `operationType` 1 and 2 Emits a {ValueReceived} event when receiving native tokens.",
|
|
112
|
+
"operationType": "The operation to execute: CALL = 0 CREATE = 1 CREATE2 = 2 STATICCALL = 3 DELEGATECALL = 4",
|
|
113
|
+
"target": "The address (smart contract/EOA) to interact with, `target` will be unused if a contract is created (operation 1 and 2)",
|
|
114
|
+
"value": "The amount of native tokens to transfer (in Wei)."
|
|
115
|
+
}
|
|
116
|
+
},
|
|
117
|
+
"executeBatch(uint256[],address[],uint256[],bytes[])": {
|
|
118
|
+
"details": "Generic batch executor function that executes any call on other addresses",
|
|
119
|
+
"params": {
|
|
120
|
+
"datas": "The list of call data to execute on `targets`, or the creation bytecode of the contracts to deploy Requirements: - The length of the parameters provided MUST be equal - if a `value` is provided, the contract MUST have at least this amount in its balance to execute successfully. - if the operation type is {STATICCALL} or {DELEGATECALL}, `value` SHOULD be 0. - `target` SHOULD be address(0) when deploying a contract. - MUST pass when called by the owner or by an authorised address that pass the verification check performed on the owner accordinng to LSP20 - CallVerification specification Emits a {Executed} event, when a call is executed under `operationType` 0, 3 and 4 (each iteration) Emits a {ContractCreated} event, when a contract is created under `operationType` 1 and 2 (each iteration) Emits a {ValueReceived} event when receiving native tokens.",
|
|
121
|
+
"operationsType": "The list of operations type used: CALL = 0; CREATE = 1; CREATE2 = 2; STATICCALL = 3; DELEGATECALL = 4",
|
|
122
|
+
"targets": "The list of addresses to call. `targets` will be unused if a contract is created (operation types 1 and 2).",
|
|
123
|
+
"values": "The list of native token amounts to transfer (in Wei)"
|
|
124
|
+
}
|
|
125
|
+
},
|
|
126
|
+
"getData(bytes32)": {
|
|
127
|
+
"params": {
|
|
128
|
+
"dataKey": "The key which value to retrieve"
|
|
129
|
+
},
|
|
130
|
+
"returns": {
|
|
131
|
+
"dataValue": "The data stored at the key"
|
|
132
|
+
}
|
|
133
|
+
},
|
|
134
|
+
"getDataBatch(bytes32[])": {
|
|
135
|
+
"params": {
|
|
136
|
+
"dataKeys": "The array of keys which values to retrieve"
|
|
137
|
+
},
|
|
138
|
+
"returns": {
|
|
139
|
+
"dataValues": "The array of data stored at multiple keys"
|
|
140
|
+
}
|
|
141
|
+
},
|
|
142
|
+
"initialize(address)": {
|
|
143
|
+
"params": {
|
|
144
|
+
"newOwner": "the owner of the contract"
|
|
145
|
+
}
|
|
146
|
+
},
|
|
147
|
+
"isValidSignature(bytes32,bytes)": {
|
|
148
|
+
"details": "Handles two cases: - If the owner is an EOA, recovers an address from the hash and the signature provided: - Returns the magicValue if the address recovered is the same as the owner, indicating that it was a valid signature. - If the address is different, it returns the fail value indicating that the signature is not valid. - If the owner is a smart contract, it forwards the call of {isValidSignature} to the owner contract: - If the contract fails or returns the fail value, the {isValidSignature} on the account returns the fail value, indicating that the signature is not valid. - If the {isValidSignature} on the owner returned the magicValue, the {isValidSignature} on the account returns the magicValue, indicating that it's a valid signature.",
|
|
149
|
+
"params": {
|
|
150
|
+
"dataHash": "The hash of the data to be validated.",
|
|
151
|
+
"signature": "A signature that can validate the previous parameter (Hash)."
|
|
152
|
+
},
|
|
153
|
+
"returns": {
|
|
154
|
+
"magicValue": "A bytes4 value that indicates if the signature is valid or not."
|
|
155
|
+
}
|
|
156
|
+
},
|
|
157
|
+
"owner()": {
|
|
158
|
+
"details": "Returns the address of the current owner."
|
|
159
|
+
},
|
|
160
|
+
"pendingOwner()": {
|
|
161
|
+
"details": "The address that ownership of the contract is transferred to. This address may use `acceptOwnership()` to gain ownership of the contract."
|
|
162
|
+
},
|
|
163
|
+
"renounceOwnership()": {
|
|
164
|
+
"details": "Renounce ownership of the contract in a 2-step process. 1. the first call will initiate the process of renouncing ownership. 2. the second is used as a confirmation and will leave the contract without an owner. MUST pass when called by the owner or by an authorised address that pass the verification check performed on the owner accordinng to LSP20 - CallVerification specification WARNING: once ownership of the contract has been renounced, any functions that are restricted to be called by the owner will be permanently inaccessible, making these functions not callable anymore and unusable."
|
|
165
|
+
},
|
|
166
|
+
"setData(bytes32,bytes)": {
|
|
167
|
+
"details": "Sets singular data for a given `dataKey`",
|
|
168
|
+
"params": {
|
|
169
|
+
"dataKey": "The key to retrieve stored value",
|
|
170
|
+
"dataValue": "The value to set Requirements: - MUST pass when called by the owner or by an authorised address that pass the verification check performed on the owner accordinng to LSP20 - CallVerification specification Emits a {ValueReceived} event when receiving native tokens. Emits a {DataChanged} event."
|
|
171
|
+
}
|
|
172
|
+
},
|
|
173
|
+
"setDataBatch(bytes32[],bytes[])": {
|
|
174
|
+
"details": "Sets array of data for multiple given `dataKeys`",
|
|
175
|
+
"params": {
|
|
176
|
+
"dataKeys": "The array of data keys for values to set",
|
|
177
|
+
"dataValues": "The array of values to set Requirements: - MUST pass when called by the owner or by an authorised address that pass the verification check performed on the owner accordinng to LSP20 - CallVerification specification Emits a {ValueReceived} event when receiving native tokens. Emits a {DataChanged} event. (on each iteration of setting data)"
|
|
178
|
+
}
|
|
179
|
+
},
|
|
180
|
+
"supportsInterface(bytes4)": {
|
|
181
|
+
"details": "Returns true if this contract implements the interface defined by `interfaceId`. If the contract doesn't support the `interfaceId`, it forwards the call to the `supportsInterface` extension according to LSP17, and checks if the extension implements the interface defined by `interfaceId`."
|
|
182
|
+
},
|
|
183
|
+
"transferOwnership(address)": {
|
|
184
|
+
"details": "Sets the pending owner address as an address that should call {acceptOwnership} in order to complete the ownership transfer of the account. Notifies the pending owner via LSP1Standard by calling {universalReceiver} on the pending owner if it's an address that supports LSP1.",
|
|
185
|
+
"params": {
|
|
186
|
+
"_pendingOwner": "The address of the new pending owner. Requirements: - MUST pass when called by the owner or by an authorized address that passes the verification check performed on the owner according to LSP20 - CallVerification specification. - When notifying the new owner via LSP1, the typeId used MUST be keccak256('LSP0OwnershipTransferStarted'). - pending owner cannot accept ownership in the same tx via the LSP1 hook."
|
|
187
|
+
}
|
|
188
|
+
},
|
|
189
|
+
"universalReceiver(bytes32,bytes)": {
|
|
190
|
+
"details": "The function performs the following steps: - Emits {ValueReceived} when receiving native tokens. - Query the ERC725Y storage with the data key {_LSP1_UNIVERSAL_RECEIVER_DELEGATE_KEY}. - If there is an address stored under the data key, check if this address supports the LSP1 interfaceId. - If yes, call this address with the typeId and data (params), along with additional calldata consisting of 20 bytes of {msg.sender} and 32 bytes of {msg.value}. If not, continue the execution of the function. - Query the ERC725Y storage with the data key {_LSP1_UNIVERSAL_RECEIVER_DELEGATE_KEY + <bytes32 typeId>}. (Check {LSP2-ERC725YJSONSchema} for encoding the data key) - If there is an address stored under the data key, check if this address supports the LSP1 interfaceId. - If yes, call this address with the typeId and data (params), along with additional calldata consisting of 20 bytes of {msg.sender} and 32 bytes of {msg.value}. If not, continue the execution of the function. - Emits a {UniversalReceiver} event.",
|
|
191
|
+
"params": {
|
|
192
|
+
"receivedData": "The data received.",
|
|
193
|
+
"typeId": "The type of call received."
|
|
194
|
+
},
|
|
195
|
+
"returns": {
|
|
196
|
+
"returnedValues": "The ABI encoded return value of the LSP1UniversalReceiverDelegate call and the LSP1TypeIdDelegate call."
|
|
197
|
+
}
|
|
198
|
+
}
|
|
199
|
+
},
|
|
200
|
+
"title": "Deployable Proxy implementation of a LUKSO's Universal Profile based on LSP3",
|
|
201
|
+
"version": 1
|
|
202
|
+
}
|