getter.gno
ExistsDelegation
func ExistsDelegation(
delegationID int64
) bool
ExistsDelegation checks if a delegation exists.
Parameters
delegationID
int64
ID of the delegation
Return Values
exists
bool
true if delegation exists
GetClaimableRewardByAddress
GetClaimableRewardByAddress returns claimable rewards for an address.
Parameters
addr
address
user address
Return Values
emissionReward
int64
emission reward amount
protocolFeeRewards
map[string]int64
protocol fee rewards by token path
err
error
error if retrieval fails
GetClaimableRewardByLaunchpad
GetClaimableRewardByLaunchpad returns claimable launchpad rewards for an address.
Parameters
addr
address
user address
Return Values
emissionReward
int64
emission reward amount
protocolFeeRewards
map[string]int64
protocol fee rewards by token path
err
error
error if retrieval fails
GetClaimableRewardByRewardID
GetClaimableRewardByRewardID returns claimable reward details by reward ID.
Parameters
rewardID
string
ID of the reward
Return Values
emissionReward
int64
emission reward amount
protocolFeeRewards
map[string]int64
protocol fee rewards by token path
err
error
error if retrieval fails
GetCollectableWithdrawAmount
GetCollectableWithdrawAmount returns the collectable withdraw amount for a specific delegation.
Parameters
delegationID
int64
ID of the delegation
Return Values
amount
int64
collectable withdraw amount
GetDelegationCount
GetDelegationCount returns the total number of delegations.
Return Values
count
int
total number of delegations
GetDelegationIDs
GetDelegationIDs returns a paginated list of delegation IDs.
Parameters
offset
int
starting index
count
int
number of IDs to return
Return Values
delegationIds
[]int64
list of delegation IDs
GetDelegationWithdrawCount
GetDelegationWithdrawCount returns the total number of delegation withdraws for a specific delegation.
Parameters
delegationID
int64
ID of the delegation
Return Values
count
int
number of withdraws
GetDelegatorDelegateeAddresses
GetDelegatorDelegateeAddresses returns a paginated list of delegatee addresses for a specific delegator.
Parameters
delegator
address
delegator address
offset
int
starting index
count
int
number of addresses to return
Return Values
addresses
[]address
list of delegatee addresses
GetDelegatorDelegateeCount
GetDelegatorDelegateeCount returns the number of delegatees for a specific delegator.
Parameters
delegator
address
delegator address
Return Values
count
int
number of delegatees
GetEmissionAccumulatedTimestamp
GetEmissionAccumulatedTimestamp returns the accumulated timestamp for emission rewards.
Return Values
timestamp
int64
accumulated timestamp
GetEmissionAccumulatedX128PerStake
GetEmissionAccumulatedX128PerStake returns the accumulated emission per stake (Q128).
Return Values
accumulatedEmission
*u256.Uint
accumulated emission per stake
GetEmissionDistributedAmount
GetEmissionDistributedAmount returns the total distributed emission amount.
Return Values
amount
int64
total distributed emission amount
GetEmissionRewardBalance
GetEmissionRewardBalance returns the current emission reward balance.
Return Values
balance
int64
current emission reward balance
GetLaunchpadProjectDeposit
GetLaunchpadProjectDeposit returns the deposit amount for a launchpad project.
Parameters
projectAddr
string
project address
Return Values
amount
int64
deposit amount
exists
bool
true if project exists
GetLockedAmount
GetLockedAmount returns the total locked GNS amount.
Return Values
amount
int64
total locked GNS amount
GetProtocolFeeAccumulatedTimestamp
GetProtocolFeeAccumulatedTimestamp returns the accumulated timestamp for protocol fee rewards.
Return Values
timestamp
int64
accumulated timestamp
GetProtocolFeeAccumulatedX128PerStake
GetProtocolFeeAccumulatedX128PerStake returns the accumulated protocol fee per stake (Q128) for a token path.
Parameters
tokenPath
string
path of the token
Return Values
accumulatedFee
*u256.Uint
accumulated protocol fee per stake
GetProtocolFeeAmount
GetProtocolFeeAmount returns the protocol fee amounts for a token path.
Parameters
tokenPath
string
path of the token
Return Values
amount
int64
protocol fee amount
GetTotalDelegated
GetTotalDelegated returns the total amount of GNS delegated.
Return Values
amount
int64
total delegated GNS amount
GetTotalDelegationAmountAtSnapshot
GetTotalDelegationAmountAtSnapshot returns the total delegation amount at a specific snapshot time.
Parameters
snapshotTime
int64
snapshot timestamp
Return Values
amount
int64
total delegation amount
exists
bool
true if snapshot exists
GetTotalLockedAmount
GetTotalLockedAmount returns the total amount of GNS locked in undelegation.
Return Values
amount
int64
total locked GNS amount
GetTotalxGnsSupply
GetTotalxGnsSupply returns the total supply of xGNS tokens.
Return Values
supply
int64
total xGNS token supply
GetUnDelegationLockupPeriod
GetUnDelegationLockupPeriod returns the undelegation lockup period in seconds.
Return Values
period
int64
lockup period in seconds
GetUserDelegationAmountAtSnapshot
GetUserDelegationAmountAtSnapshot returns the user delegation amount at a specific snapshot time.
Parameters
userAddr
address
user address
snapshotTime
int64
snapshot timestamp
Return Values
amount
int64
user delegation amount
exists
bool
true if snapshot exists
GetUserDelegationCount
GetUserDelegationCount returns the number of delegations for a specific delegator-delegatee pair.
Parameters
delegator
address
delegator address
delegatee
address
delegatee address
Return Values
count
int
number of delegations
GetUserDelegationIDs
GetUserDelegationIDs returns a list of delegation IDs for a specific delegator-delegatee pair.
Parameters
delegator
address
delegator address
delegatee
address
delegatee address
Return Values
delegationIds
[]int64
list of delegation IDs
HasDelegationSnapshotsKey
HasDelegationSnapshotsKey returns true if delegation history exists.
Return Values
exists
bool
true if delegation history exists
Last updated