Skip to main content
Version: 27.4.x

Class: Staking

api/entities/Account/Staking.Staking

Handles Account staking related functionality

Hierarchy

Methods

getCommission

getCommission(): Promise<null | StakingCommission>

Returns

Promise<null | StakingCommission>

null unless the account is seeking nominations as a validator

Defined in

api/entities/Account/Staking/index.ts:216


getController

getController(): Promise<null | Account>

Fetch the controller associated to this account if there is one

Returns

Promise<null | Account>

null unless the account is a stash

Note

can be subscribed to, if connected to node using a web socket

Note

a stash can be its own controller

Defined in

api/entities/Account/Staking/index.ts:169

getController(callback): Promise<UnsubCallback>

Parameters

NameType
callbackSubCallback<null | Account>

Returns

Promise<UnsubCallback>

Defined in

api/entities/Account/Staking/index.ts:170


getLedger

getLedger(): Promise<null | StakingLedger>

Fetch the ledger information for a stash account

Returns

Promise<null | StakingLedger>

null unless the account is a controller

Defined in

api/entities/Account/Staking/index.ts:32


getNomination

getNomination(): Promise<null | StakingNomination>

Fetch this account's current nominations

Returns

Promise<null | StakingNomination>

null unless the account is a controller

Note

can be subscribed to, if connected to node using a web socket

Defined in

api/entities/Account/Staking/index.ts:117

getNomination(callback): Promise<UnsubCallback>

Parameters

NameType
callbackSubCallback<null | StakingNomination>

Returns

Promise<UnsubCallback>

Defined in

api/entities/Account/Staking/index.ts:118


getPayee

getPayee(): Promise<null | StakingPayee>

Fetch the payee that will receive a stash account's rewards

Returns

Promise<null | StakingPayee>

Note

null is returned when the account is not a stash

Note

can be subscribed to, if connected to node using a web socket

Defined in

api/entities/Account/Staking/index.ts:57

getPayee(callback): Promise<UnsubCallback>

Parameters

NameType
callbackSubCallback<null | StakingPayee>

Returns

Promise<UnsubCallback>

Defined in

api/entities/Account/Staking/index.ts:58