-
Notifications
You must be signed in to change notification settings - Fork 11
api.entities.Subsidy.Subsidy
api/entities/Subsidy.Subsidy
Represents a Subsidy relationship on chain
-
Entity
<UniqueIdentifiers
,HumanReadable
>↳
Subsidy
- decreaseAllowance
- exists
- getAllowance
- increaseAllowance
- isEqual
- quit
- setAllowance
- toHuman
- generateUuid
- unserialize
• beneficiary: Account
Account whose transactions are being paid for
api/entities/Subsidy/index.ts:54
• subsidizer: Account
Account that is paying for the transactions
api/entities/Subsidy/index.ts:58
• uuid: string
▸ decreaseAllowance(args
, opts?
): Promise
<GenericPolymeshTransaction
<void
, void
>>
Decrease allowance for this Subsidy relationship
Name | Type |
---|---|
args |
Pick <DecreaseAllowanceParams , "allowance" > |
opts? |
ProcedureOpts |
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
api/entities/Subsidy/index.ts:179
▸ exists(): Promise
<boolean
>
Determine whether this Subsidy relationship exists on chain
Promise
<boolean
>
api/entities/Subsidy/index.ts:186
▸ getAllowance(): Promise
<BigNumber
>
Get amount of POLYX subsidized for this Subsidy relationship
Promise
<BigNumber
>
Throws
if the Subsidy does not exist
api/entities/Subsidy/index.ts:205
▸ increaseAllowance(args
, opts?
): Promise
<GenericPolymeshTransaction
<void
, void
>>
Increase allowance for this Subsidy relationship
Name | Type |
---|---|
args |
Pick <IncreaseAllowanceParams , "allowance" > |
opts? |
ProcedureOpts |
Promise
<GenericPolymeshTransaction
<void
, void
>>
Note
Only the subsidizer is allowed to increase the allowance
Note
this method is of type ProcedureMethod, which means you can call increaseAllowance.checkAuthorization on it to see whether the signing Account and Identity have the required roles and permissions to run it
api/entities/Subsidy/index.ts:165
▸ isEqual(entity
): boolean
Determine whether this Entity is the same as another one
Name | Type |
---|---|
entity |
Entity <unknown , unknown > |
boolean
▸ quit(opts?
): Promise
<GenericPolymeshTransaction
<void
, void
>>
Terminate this Subsidy relationship. The beneficiary Account will be forced to pay for their own transactions
Name | Type |
---|---|
opts? |
ProcedureOpts |
Promise
<GenericPolymeshTransaction
<void
, void
>>
Note
both the beneficiary and the subsidizer are allowed to unilaterally quit the Subsidy
Note
this method is of type NoArgsProcedureMethod, which means you can call quit.checkAuthorization on it to see whether the signing Account and Identity have the required roles and permissions to run it
api/entities/Subsidy/index.ts:139
▸ setAllowance(args
, opts?
): Promise
<GenericPolymeshTransaction
<void
, void
>>
Set allowance for this Subsidy relationship
Name | Type |
---|---|
args |
Pick <SetAllowanceParams , "allowance" > |
opts? |
ProcedureOpts |
Promise
<GenericPolymeshTransaction
<void
, void
>>
Note
Only the subsidizer is allowed to set the allowance
Throws
if the allowance to set is equal to the current allowance
Note
this method is of type ProcedureMethod, which means you can call setAllowance.checkAuthorization on it to see whether the signing Account and Identity have the required roles and permissions to run it
api/entities/Subsidy/index.ts:153
▸ toHuman(): UniqueIdentifiers
Return the Subsidy's static data
api/entities/Subsidy/index.ts:227
▸ Static
generateUuid<Identifiers
>(identifiers
): string
Generate the Entity's UUID from its identifying properties
Name |
---|
Identifiers |
Name | Type |
---|---|
identifiers |
Identifiers |
string
▸ Static
unserialize<Identifiers
>(serialized
): Identifiers
Unserialize a UUID into its Unique Identifiers
Name |
---|
Identifiers |
Name | Type | Description |
---|---|---|
serialized |
string |
UUID to unserialize |
Identifiers
Entities
- Account
- Asset
- Authorization Request
- Checkpoint
- Checkpoint Schedule
- Corporate Action
- Corporate Action Base
- Custom Permission Group
- Default Portfolio
- Default Trusted Claim Issuer
- Dividend Distribution
- Entity
- Identity
- Instruction
- Known Permission Group
- Metadata Entry
- Multi Sig Proposal
- Numbered Portfolio
- Offering
- Permission Group
- Portfolio
- Subsidies
- Subsidy
- Ticker Reservation
- Venue
- Authorizations
- Types