Subsidy
Last updated
Was this helpful?
Last updated
Was this helpful?
Represents a Subsidy relationship on chain
‹UniqueIdentifiers, HumanReadable›
↳ Subsidy
Account whose transactions are being paid for
Protected
context• context: Context
Account that is paying for the transactions
• uuid: string
Decrease allowance for this Subsidy relationship
note
Only the subsidizer is allowed to decrease the allowance
throws
if the amount to decrease by is more than the existing allowance
Parameters:
args
opts?
▸ exists(): Promise‹boolean›
Determine whether this Subsidy relationship exists on chain
Returns: Promise‹boolean›
▸ getAllowance(): Promise‹BigNumber›
Get amount of POLYX subsidized for this Subsidy relationship
throws
if the Subsidy does not exist
Returns: Promise‹BigNumber›
Increase allowance for this Subsidy relationship
note
Only the subsidizer is allowed to increase the allowance
Parameters:
args
opts?
Determine whether this Entity is the same as another one
Parameters:
entity
Returns: boolean
Terminate this Subsidy relationship. The beneficiary Account will be forced to pay for their own transactions
note
both the beneficiary and the subsidizer are allowed to unilaterally quit the Subsidy
Parameters:
opts?
Set allowance for this Subsidy relationship
note
Only the subsidizer is allowed to set the allowance
throws
if the allowance to set is equal to the current allowance
Parameters:
args
opts?
â–¸ toHuman(): HumanReadable
Return the Subsidy's static data
Returns: HumanReadable
Static
generateUuid▸ generateUuid‹Identifiers›(identifiers
: Identifiers): string
Generate the Entity's UUID from its identifying properties
Type parameters:
â–ª Identifiers
Parameters:
identifiers
Identifiers
Returns: string
Static
unserialize▸ unserialize‹Identifiers›(serialized
: string): Identifiers
Unserialize a UUID into its Unique Identifiers
Type parameters:
â–ª Identifiers
Parameters:
serialized
string
UUID to unserialize
Returns: Identifiers
• beneficiary:
Defined in
Inherited from .
Defined in
• subsidizer:
Defined in
Inherited from .
Defined in
â–¸ decreaseAllowance(args
: Pick‹, "allowance"›, opts?
: ): Promise‹‹void››
Defined in
note
this method is of type , which means you can call on it to see whether the signing Account and Identity have the required roles and permissions to run it
Pick‹, "allowance"›
Returns: Promise‹‹void››
Overrides .
Defined in
Defined in
â–¸ increaseAllowance(args
: Pick‹, "allowance"›, opts?
: ): Promise‹‹void››
Defined in
note
this method is of type , which means you can call on it to see whether the signing Account and Identity have the required roles and permissions to run it
Pick‹, "allowance"›
Returns: Promise‹‹void››
â–¸ isEqual(entity
: ‹unknown, unknown›): boolean
Inherited from .
Defined in
‹unknown, unknown›
â–¸ quit(opts?
: ): Promise‹‹void››
Defined in
note
this method is of type , which means you can call on it to see whether the signing Account and Identity have the required roles and permissions to run it
Returns: Promise‹‹void››
â–¸ setAllowance(args
: Pick‹, "allowance"›, opts?
: ): Promise‹‹void››
Defined in
note
this method is of type , which means you can call on it to see whether the signing Account and Identity have the required roles and permissions to run it
Pick‹, "allowance"›
Returns: Promise‹‹void››
Overrides .
Defined in
Inherited from .
Defined in
Inherited from .
Defined in