Class: Subsidy
api/entities/Subsidy.Subsidy
Represents a Subsidy relationship on chain
Hierarchy
-
Entity
<UniqueIdentifiers
,HumanReadable
>↳
Subsidy
Properties
beneficiary
• beneficiary: Account
Account whose transactions are being paid for
Defined in
api/entities/Subsidy/index.ts:54
subsidizer
• subsidizer: Account
Account that is paying for the transactions
Defined in
api/entities/Subsidy/index.ts:58
uuid
• uuid: string
Inherited from
Defined in
Methods
decreaseAllowance
▸ decreaseAllowance(args
, opts?
): Promise
<GenericPolymeshTransaction
<void
, void
>>
Decrease allowance for this Subsidy relationship
Parameters
Name | Type |
---|---|
args | Pick <DecreaseAllowanceParams , "allowance" > |
opts? | ProcedureOpts |
Returns
Promise
<GenericPolymeshTransaction
<void
, void
>>
Note
Only the subsidizer is allowed to decrease the allowance
Throws
if the amount to decrease by is more than the existing allowance
Note
this method is of type ProcedureMethod, which means you can call decreaseAllowance.checkAuthorization on it to see whether the signing Account and Identity have the required roles and permissions to run it
Defined in
api/entities/Subsidy/index.ts:179
exists
▸ exists(): Promise
<boolean
>
Determine whether this Subsidy relationship exists on chain
Returns
Promise
<boolean
>
Overrides
Defined in
api/entities/Subsidy/index.ts:186
getAllowance
▸ getAllowance(): Promise
<BigNumber
>
Get amount of POLYX subsidized for this Subsidy relationship