Skip to content

Commit

Permalink
Merge pull request #43 from skalenetwork/paymaster
Browse files Browse the repository at this point in the history
Add PaymasterController
  • Loading branch information
DimaStebaev committed Aug 21, 2024
2 parents e067ad7 + 5bf0a7e commit 97f65c5
Show file tree
Hide file tree
Showing 4 changed files with 45 additions and 2 deletions.
9 changes: 9 additions & 0 deletions contracts/IConstantsHolder.sol
Original file line number Diff line number Diff line change
Expand Up @@ -46,6 +46,15 @@ interface IConstantsHolder {
function setComplaintTimeLimit(uint timeLimit) external;
function setMinNodeBalance(uint newMinNodeBalance) external;
function reinitialize() external;
// Corresponds to the public field
// solhint-disable func-name-mixedcase
// slither-disable-start naming-convention
function NODE_DEPOSIT() external view returns (uint256);
function SECONDS_TO_YEAR() external view returns (uint32);
function SMALL_DIVISOR() external view returns (uint8);
function TOTAL_SPACE_ON_NODE() external view returns (uint8);
// solhint-enable func-name-mixedcase
// slither-disable-end naming-convention
function msr() external view returns (uint);
function launchTimestamp() external view returns (uint);
function rotationDelay() external view returns (uint);
Expand Down
34 changes: 34 additions & 0 deletions contracts/IPaymasterController.sol
Original file line number Diff line number Diff line change
@@ -0,0 +1,34 @@
// SPDX-License-Identifier: AGPL-3.0-only

/*
IPaymasterController.sol - SKALE Manager
Copyright (C) 2018-Present SKALE Labs
@author Artem Payvin
SKALE Manager is free software: you can redistribute it and/or modify
it under the terms of the GNU Affero General Public License as published
by the Free Software Foundation, either version 3 of the License, or
(at your option) any later version.
SKALE Manager is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
GNU Affero General Public License for more details.
You should have received a copy of the GNU Affero General Public License
along with SKALE Manager. If not, see <https://www.gnu.org/licenses/>.
*/

pragma solidity >=0.6.10 <0.9.0;

interface IPaymasterController {
function addSchain(string calldata name) external;
function addValidator(uint256 validatorId, address validatorAddress) external;
function removeSchain(bytes32 schainHash) external;
function setImaAddress(address imaAddress) external;
function setMarionetteAddress(address payable marionetteAddress) external;
function setNodesAmount(uint256 validatorId, uint256 nodesAmount) external;
function setPaymasterAddress(address paymasterAddress) external;
function setPaymasterChainHash(bytes32 chainHash) external;
function setValidatorAddress(uint256 validatorId, address validatorAddress) external;
}
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "@skalenetwork/skale-manager-interfaces",
"version": "3.1.0",
"version": "3.2.0",
"description": "Definitions of interfaces needed to integrate with skale-manager smart contracts",
"main": "index.js",
"repository": "git@github.com:skalenetwork/skale-manager-interfaces.git",
Expand Down
2 changes: 1 addition & 1 deletion scripts/requirements.txt
Original file line number Diff line number Diff line change
@@ -1 +1 @@
slither-analyzer==0.8.0
slither-analyzer==0.10.3

0 comments on commit 97f65c5

Please sign in to comment.