Files
websites/packages/contracts/abis/ServiceNodeContribution.ts

676 lines
12 KiB
TypeScript

// This file is generated by the generate-abis script. Do not modify it manually.
/**
* Generated ABI for the ServiceNodeContribution contract.
*/
export const ServiceNodeContributionAbi = [
{
inputs: [
{
internalType: 'address',
name: '_stakingRewardsContract',
type: 'address',
},
{
internalType: 'uint256',
name: '_maxContributors',
type: 'uint256',
},
{
components: [
{
internalType: 'uint256',
name: 'X',
type: 'uint256',
},
{
internalType: 'uint256',
name: 'Y',
type: 'uint256',
},
],
internalType: 'struct BN256G1.G1Point',
name: '_blsPubkey',
type: 'tuple',
},
{
components: [
{
internalType: 'uint256',
name: 'serviceNodePubkey',
type: 'uint256',
},
{
internalType: 'uint256',
name: 'serviceNodeSignature1',
type: 'uint256',
},
{
internalType: 'uint256',
name: 'serviceNodeSignature2',
type: 'uint256',
},
{
internalType: 'uint16',
name: 'fee',
type: 'uint16',
},
],
internalType: 'struct IServiceNodeRewards.ServiceNodeParams',
name: '_serviceNodeParams',
type: 'tuple',
},
],
stateMutability: 'nonpayable',
type: 'constructor',
},
{
inputs: [
{
internalType: 'address',
name: 'target',
type: 'address',
},
],
name: 'AddressEmptyCode',
type: 'error',
},
{
inputs: [
{
internalType: 'address',
name: 'account',
type: 'address',
},
],
name: 'AddressInsufficientBalance',
type: 'error',
},
{
inputs: [],
name: 'FailedInnerCall',
type: 'error',
},
{
inputs: [
{
internalType: 'address',
name: 'token',
type: 'address',
},
],
name: 'SafeERC20FailedOperation',
type: 'error',
},
{
anonymous: false,
inputs: [
{
indexed: true,
internalType: 'uint256',
name: 'serviceNodePubkey',
type: 'uint256',
},
],
name: 'Cancelled',
type: 'event',
},
{
anonymous: false,
inputs: [
{
indexed: true,
internalType: 'uint256',
name: 'serviceNodePubkey',
type: 'uint256',
},
],
name: 'Finalized',
type: 'event',
},
{
anonymous: false,
inputs: [
{
indexed: true,
internalType: 'address',
name: 'contributor',
type: 'address',
},
{
indexed: false,
internalType: 'uint256',
name: 'amount',
type: 'uint256',
},
],
name: 'NewContribution',
type: 'event',
},
{
anonymous: false,
inputs: [
{
indexed: true,
internalType: 'address',
name: 'contributor',
type: 'address',
},
{
indexed: false,
internalType: 'uint256',
name: 'amount',
type: 'uint256',
},
],
name: 'WithdrawContribution',
type: 'event',
},
{
inputs: [],
name: 'SENT',
outputs: [
{
internalType: 'contract IERC20',
name: '',
type: 'address',
},
],
stateMutability: 'view',
type: 'function',
},
{
inputs: [],
name: 'WITHDRAWAL_DELAY',
outputs: [
{
internalType: 'uint64',
name: '',
type: 'uint64',
},
],
stateMutability: 'view',
type: 'function',
},
{
inputs: [],
name: 'blsPubkey',
outputs: [
{
internalType: 'uint256',
name: 'X',
type: 'uint256',
},
{
internalType: 'uint256',
name: 'Y',
type: 'uint256',
},
],
stateMutability: 'view',
type: 'function',
},
{
inputs: [],
name: 'blsSignature',
outputs: [
{
internalType: 'uint256',
name: 'sigs0',
type: 'uint256',
},
{
internalType: 'uint256',
name: 'sigs1',
type: 'uint256',
},
{
internalType: 'uint256',
name: 'sigs2',
type: 'uint256',
},
{
internalType: 'uint256',
name: 'sigs3',
type: 'uint256',
},
],
stateMutability: 'view',
type: 'function',
},
{
inputs: [
{
internalType: 'uint256',
name: 'contributionRemaining',
type: 'uint256',
},
{
internalType: 'uint256',
name: 'numContributors',
type: 'uint256',
},
{
internalType: 'uint256',
name: 'maxNumContributors',
type: 'uint256',
},
],
name: 'calcMinimumContribution',
outputs: [
{
internalType: 'uint256',
name: 'result',
type: 'uint256',
},
],
stateMutability: 'pure',
type: 'function',
},
{
inputs: [],
name: 'cancelNode',
outputs: [],
stateMutability: 'nonpayable',
type: 'function',
},
{
inputs: [],
name: 'cancelled',
outputs: [
{
internalType: 'bool',
name: '',
type: 'bool',
},
],
stateMutability: 'view',
type: 'function',
},
{
inputs: [
{
internalType: 'uint256',
name: 'amount',
type: 'uint256',
},
],
name: 'contributeFunds',
outputs: [],
stateMutability: 'nonpayable',
type: 'function',
},
{
inputs: [
{
internalType: 'uint256',
name: 'amount',
type: 'uint256',
},
{
components: [
{
internalType: 'uint256',
name: 'sigs0',
type: 'uint256',
},
{
internalType: 'uint256',
name: 'sigs1',
type: 'uint256',
},
{
internalType: 'uint256',
name: 'sigs2',
type: 'uint256',
},
{
internalType: 'uint256',
name: 'sigs3',
type: 'uint256',
},
],
internalType: 'struct IServiceNodeRewards.BLSSignatureParams',
name: '_blsSignature',
type: 'tuple',
},
],
name: 'contributeOperatorFunds',
outputs: [],
stateMutability: 'nonpayable',
type: 'function',
},
{
inputs: [
{
internalType: 'address',
name: '',
type: 'address',
},
],
name: 'contributionTimestamp',
outputs: [
{
internalType: 'uint256',
name: '',
type: 'uint256',
},
],
stateMutability: 'view',
type: 'function',
},
{
inputs: [
{
internalType: 'address',
name: '',
type: 'address',
},
],
name: 'contributions',
outputs: [
{
internalType: 'uint256',
name: '',
type: 'uint256',
},
],
stateMutability: 'view',
type: 'function',
},
{
inputs: [
{
internalType: 'uint256',
name: '',
type: 'uint256',
},
],
name: 'contributorAddresses',
outputs: [
{
internalType: 'address',
name: '',
type: 'address',
},
],
stateMutability: 'view',
type: 'function',
},
{
inputs: [],
name: 'contributorAddressesLength',
outputs: [
{
internalType: 'uint256',
name: 'result',
type: 'uint256',
},
],
stateMutability: 'view',
type: 'function',
},
{
inputs: [],
name: 'finalized',
outputs: [
{
internalType: 'bool',
name: '',
type: 'bool',
},
],
stateMutability: 'view',
type: 'function',
},
{
inputs: [],
name: 'getContributions',
outputs: [
{
internalType: 'address[]',
name: 'addrs',
type: 'address[]',
},
{
internalType: 'uint256[]',
name: 'contribs',
type: 'uint256[]',
},
],
stateMutability: 'view',
type: 'function',
},
{
inputs: [],
name: 'maxContributors',
outputs: [
{
internalType: 'uint256',
name: '',
type: 'uint256',
},
],
stateMutability: 'view',
type: 'function',
},
{
inputs: [],
name: 'minimumContribution',
outputs: [
{
internalType: 'uint256',
name: 'result',
type: 'uint256',
},
],
stateMutability: 'view',
type: 'function',
},
{
inputs: [
{
internalType: 'uint256',
name: '_stakingRequirement',
type: 'uint256',
},
],
name: 'minimumOperatorContribution',
outputs: [
{
internalType: 'uint256',
name: 'result',
type: 'uint256',
},
],
stateMutability: 'pure',
type: 'function',
},
{
inputs: [],
name: 'operator',
outputs: [
{
internalType: 'address',
name: '',
type: 'address',
},
],
stateMutability: 'view',
type: 'function',
},
{
inputs: [],
name: 'operatorContribution',
outputs: [
{
internalType: 'uint256',
name: 'result',
type: 'uint256',
},
],
stateMutability: 'view',
type: 'function',
},
{
inputs: [
{
internalType: 'address',
name: 'tokenAddress',
type: 'address',
},
],
name: 'rescueERC20',
outputs: [],
stateMutability: 'nonpayable',
type: 'function',
},
{
inputs: [
{
internalType: 'uint256',
name: 'amount',
type: 'uint256',
},
],
name: 'resetContract',
outputs: [],
stateMutability: 'nonpayable',
type: 'function',
},
{
inputs: [],
name: 'serviceNodeParams',
outputs: [
{
internalType: 'uint256',
name: 'serviceNodePubkey',
type: 'uint256',
},
{
internalType: 'uint256',
name: 'serviceNodeSignature1',
type: 'uint256',
},
{
internalType: 'uint256',
name: 'serviceNodeSignature2',
type: 'uint256',
},
{
internalType: 'uint16',
name: 'fee',
type: 'uint16',
},
],
stateMutability: 'view',
type: 'function',
},
{
inputs: [],
name: 'stakingRequirement',
outputs: [
{
internalType: 'uint256',
name: '',
type: 'uint256',
},
],
stateMutability: 'view',
type: 'function',
},
{
inputs: [],
name: 'stakingRewardsContract',
outputs: [
{
internalType: 'contract IServiceNodeRewards',
name: '',
type: 'address',
},
],
stateMutability: 'view',
type: 'function',
},
{
inputs: [],
name: 'totalContribution',
outputs: [
{
internalType: 'uint256',
name: 'result',
type: 'uint256',
},
],
stateMutability: 'view',
type: 'function',
},
{
inputs: [
{
components: [
{
internalType: 'uint256',
name: 'X',
type: 'uint256',
},
{
internalType: 'uint256',
name: 'Y',
type: 'uint256',
},
],
internalType: 'struct BN256G1.G1Point',
name: 'newBlsPubkey',
type: 'tuple',
},
],
name: 'updateBLSPubkey',
outputs: [],
stateMutability: 'nonpayable',
type: 'function',
},
{
inputs: [
{
components: [
{
internalType: 'uint256',
name: 'serviceNodePubkey',
type: 'uint256',
},
{
internalType: 'uint256',
name: 'serviceNodeSignature1',
type: 'uint256',
},
{
internalType: 'uint256',
name: 'serviceNodeSignature2',
type: 'uint256',
},
{
internalType: 'uint16',
name: 'fee',
type: 'uint16',
},
],
internalType: 'struct IServiceNodeRewards.ServiceNodeParams',
name: 'newParams',
type: 'tuple',
},
],
name: 'updateServiceNodeParams',
outputs: [],
stateMutability: 'nonpayable',
type: 'function',
},
{
inputs: [],
name: 'withdrawContribution',
outputs: [],
stateMutability: 'nonpayable',
type: 'function',
},
] as const;