Skip to main content
Version: 30.0.x

Class: Subsidies

Defined in: src/api/entities/Subsidies.ts:8

Handles all Account Subsidies related functionality

Extends​

Methods​

getBeneficiaries()​

getBeneficiaries(): Promise<SubsidyWithAllowance[]>

Defined in: src/api/entities/Subsidies.ts:12

Get the list of Subsidy relationship along with their subsidized amount for which this Account is the subsidizer

Returns​

Promise<SubsidyWithAllowance[]>


getPendingSubsidies()​

getPendingSubsidies(): Promise<SubsidyWithAllowance[]>

Defined in: src/api/entities/Subsidies.ts:94

Get pending subsidies (for which this Account is the beneficiary) that have been authorised but not yet accepted.

Returns​

Promise<SubsidyWithAllowance[]>

Note​

this method is supported only with v8 chains


getSubsidizer()​

Call Signature​

getSubsidizer(): Promise<SubsidyWithAllowance | null>

Defined in: src/api/entities/Subsidies.ts:60

Get the Subsidy relationship along with the subsidized amount for this Account is the beneficiary.

Returns​

Promise<SubsidyWithAllowance | null>

the Subsidy relationship, or null if this Account isn't being subsidized

Call Signature​

getSubsidizer(callback: SubCallback<SubsidyWithAllowance | null>): Promise<UnsubCallback>

Defined in: src/api/entities/Subsidies.ts:70

Get the Subsidy relationship along with the subsidized amount for this Account is the beneficiary.

Parameters​
ParameterTypeDescription

callback

SubCallback<SubsidyWithAllowance | null>

Callback function that can be used to listen for changes to the subsidy relationship

Returns​

Promise<UnsubCallback>

the Subsidy relationship, or null if this Account isn't being subsidized

Note​

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