Nomination Pools
GraphQL Endpoint
https://platform.beta.enjin.io/graphql
Nomination pools live on the Relaychain — pass chain: RELAY on every query in this section. They let many small ENJ holders pool their stake under a single nominator, sharing rewards proportionally. To bond into a pool or unbond, see Nomination Pool Mutations.
GetNominationPool
Returns a single nomination pool by id.
- GraphQL
- Response
query GetNominationPool {
GetNominationPool(network: ENJIN, chain: RELAY, id: 1) {
id
name
state
capacity
balance {
stash
reward
active
}
commission
apy
totalMembers
members {
publicKey
bonded
unrealisedEnj
}
}
}
{
"data": {
"GetNominationPool": {
"id": 1,
"name": "",
"state": "OPEN",
"capacity": "32000000000000000000000000",
"balance": {
"stash": "17679671198897628191743870",
"reward": "100000000000000000",
"active": "37463637246328117435530629"
},
"commission": 0,
"apy": 22.636730650749662,
"totalMembers": 195,
"members": [
{
"publicKey": "0xded3c8a93e4a4b3a5e8f3c9a2d1b6f0e7c8a9b0d1e2f3a4b5c6d7e8f9a0b1c2d",
"bonded": "5000000000000000000000",
"unrealisedEnj": "0"
}
]
}
}
}
Field notes:
stateis one ofOPEN,BLOCKED,DESTROYING,DESTROYED. You can only bond intoOPENpools.capacityis the maximum bondable amount, in the smallest ENJ unit.balance.stash/.active/.rewarddescribe the pool's on-chain state —activeis the currently-staked portion that earns rewards.commissionis a fraction in the range0..1(e.g.0.05means the pool operator takes 5%).apyis a percentage (e.g.22.6means ~22.6% annualised).members[].unrealisedEnjis the member's pending reward not yet claimed.
GetNominationPools
Returns a paginated list of pools. Pagination is offset-based (limit + page).
- GraphQL
- Response
query GetNominationPools {
GetNominationPools(network: ENJIN, chain: RELAY, limit: 15, page: 1) {
id
name
state
commission
apy
totalMembers
balance {
active
}
}
}
{
"data": {
"GetNominationPools": [
{
"id": 1,
"name": "",
"state": "OPEN",
"commission": 0,
"apy": 22.636730650749662,
"totalMembers": 195,
"balance": { "active": "37463637246328117435530629" }
},
{
"id": 2,
"name": "Pool Two",
"state": "OPEN",
"commission": 0.05,
"apy": 21.8,
"totalMembers": 87,
"balance": { "active": "12300000000000000000000000" }
}
]
}
}
GetAccountPools
Returns every pool a given address is a member of, with that account's per-pool bonded amount and unrealised rewards.
- GraphQL
- Response
query GetAccountPools {
GetAccountPools(
network: ENJIN
chain: RELAY
address: "efStakerAddress"
) {
id
name
state
bonded
unrealisedEnj
totalUnbonding
apy
}
}
{
"data": {
"GetAccountPools": [
{
"id": 1,
"name": "",
"state": "OPEN",
"bonded": "5000000000000000000000",
"unrealisedEnj": "12500000000000000",
"totalUnbonding": "0",
"apy": 22.636730650749662
}
]
}
}
totalUnbonding is the amount the account has requested to unbond but hasn't yet withdrawn (Substrate nomination pools have an unbonding period before unbonded ENJ becomes spendable).