Instruction
Represents a settlement Instruction to be executed on a certain Venue
Hierarchy
Entity‹UniqueIdentifiers, string›
↳ Instruction
Index
Properties
Methods
Properties
Protected
context
Protected
context• context: Context
Inherited from CheckpointSchedule.context
Defined in src/api/entities/Entity.ts:48
id
• id: BigNumber
Defined in src/api/entities/Instruction/index.ts:80
Identifier number of the venue
uuid
• uuid: string
Inherited from CheckpointSchedule.uuid
Defined in src/api/entities/Entity.ts:46
Methods
affirm
▸ affirm(opts?
: ProcedureOpts): Promise‹TransactionQueue‹Instruction››
Defined in src/api/entities/Instruction/index.ts:448
Affirm this instruction (authorize)
note
this method is of type NoArgsProcedureMethod, which means you can call affirm.checkAuthorization on it to see whether the signing Account and Identity have the required roles and permissions to run it
Parameters:
Name | Type |
---|---|
|
Returns: Promise‹TransactionQueue‹Instruction››
details
▸ details(): Promise‹InstructionDetails›
Defined in src/api/entities/Instruction/index.ts:201
Retrieve information specific to this Instruction
Returns: Promise‹InstructionDetails›
exists
▸ exists(): Promise‹boolean›
Defined in src/api/entities/Instruction/index.ts:183
Determine whether this Instruction exists on chain (or existed and was pruned)
Returns: Promise‹boolean›
getAffirmations
▸ getAffirmations(paginationOpts?
: PaginationOptions): Promise‹ResultSet‹InstructionAffirmation››
Defined in src/api/entities/Instruction/index.ts:260
Retrieve every authorization generated by this Instruction (status and authorizing Identity)
note
supports pagination
Parameters:
Name | Type |
---|---|
|
Returns: Promise‹ResultSet‹InstructionAffirmation››
getLegs
▸ getLegs(paginationOpts?
: PaginationOptions): Promise‹ResultSet‹Leg››
Defined in src/api/entities/Instruction/index.ts:306
Retrieve all legs of this Instruction
note
supports pagination
Parameters:
Name | Type |
---|---|
|
Returns: Promise‹ResultSet‹Leg››
getStatus
▸ getStatus(): Promise‹InstructionStatusResult›
Defined in src/api/entities/Instruction/index.ts:357
Retrieve current status of this Instruction
note
uses the middleware
Returns: Promise‹InstructionStatusResult›
getStatusV2
▸ getStatusV2(): Promise‹InstructionStatusResult›
Defined in src/api/entities/Instruction/index.ts:395
Retrieve current status of this Instruction
note
uses the middlewareV2
Returns: Promise‹InstructionStatusResult›
isEqual
▸ isEqual(entity
: Entity‹unknown, unknown›): boolean
Inherited from CheckpointSchedule.isEqual
Defined in src/api/entities/Entity.ts:61
Determine whether this Entity is the same as another one
Parameters:
Name | Type |
---|---|
| Entity‹unknown, unknown› |
Returns: boolean
isExecuted
▸ isExecuted(): Promise‹boolean›
Defined in src/api/entities/Instruction/index.ts:138
Retrieve whether the Instruction has already been executed and pruned from the chain.
Returns: Promise‹boolean›
isPending
▸ isPending(): Promise‹boolean›
Defined in src/api/entities/Instruction/index.ts:162
Retrieve whether the Instruction is still pending on chain
Returns: Promise‹boolean›
reject
▸ reject(opts?
: ProcedureOpts): Promise‹TransactionQueue‹Instruction››
Defined in src/api/entities/Instruction/index.ts:438
Reject this instruction
note
reject on SettleOnAffirmation
will execute the settlement and it will fail immediately.
note
reject on SettleOnBlock
behaves just like unauthorize
note
this method is of type NoArgsProcedureMethod, which means you can call reject.checkAuthorization on it to see whether the signing Account and Identity have the required roles and permissions to run it
Parameters:
Name | Type |
---|---|
|
Returns: Promise‹TransactionQueue‹Instruction››
reschedule
▸ reschedule(opts?
: ProcedureOpts): Promise‹TransactionQueue‹Instruction››
Defined in src/api/entities/Instruction/index.ts:470
Reschedules a failed Instruction to be tried again
throws
if the Instruction status is not InstructionStatus.Failed
note
this method is of type NoArgsProcedureMethod, which means you can call reschedule.checkAuthorization on it to see whether the signing Account and Identity have the required roles and permissions to run it
Parameters:
Name | Type |
---|---|
|
Returns: Promise‹TransactionQueue‹Instruction››
toHuman
▸ toHuman(): string
Defined in src/api/entities/Instruction/index.ts:527
Return the Instruction's ID
Returns: string
withdraw
▸ withdraw(opts?
: ProcedureOpts): Promise‹TransactionQueue‹Instruction››
Defined in src/api/entities/Instruction/index.ts:458
Withdraw affirmation from this instruction (unauthorize)
note
this method is of type NoArgsProcedureMethod, which means you can call withdraw.checkAuthorization on it to see whether the signing Account and Identity have the required roles and permissions to run it
Parameters:
Name | Type |
---|---|
|
Returns: Promise‹TransactionQueue‹Instruction››
Static
generateUuid
Static
generateUuid▸ generateUuid‹Identifiers›(identifiers
: Identifiers): string
Inherited from CheckpointSchedule.generateUuid
Defined in src/api/entities/Entity.ts:14
Generate the Entity's UUID from its identifying properties
Type parameters:
▪ Identifiers
Parameters:
Name | Type | Description |
---|---|---|
| Identifiers |
Returns: string
Static
unserialize
Static
unserialize▸ unserialize‹Identifiers›(serialized
: string): Identifiers
Inherited from CheckpointSchedule.unserialize
Defined in src/api/entities/Entity.ts:23
Unserialize a UUID into its Unique Identifiers
Type parameters:
▪ Identifiers
Parameters:
Name | Type | Description |
---|---|---|
| string | UUID to unserialize |
Returns: Identifiers
Last updated