Polymesh SDK API Reference
beta
beta
  • Globals
  • Classes
    • Account
    • AccountManagement
    • Asset
    • AssetHolders
    • AssetPermissions
    • Assets
    • AuthorizationRequest
    • Authorizations
    • Checkpoint
    • CheckpointSchedule
    • Checkpoints
    • Claims
    • Compliance
    • CorporateAction
    • CorporateActionBase
    • CorporateActions
    • Count
    • CustomPermissionGroup
    • DefaultPortfolio
    • DefaultTrustedClaimIssuer
    • Distributions
    • DividendDistribution
    • Documents
    • Entity
    • Identities
    • Identity
    • IdentityAuthorizations
    • Instruction
    • Issuance
    • KnownPermissionGroup
    • Network
    • NumberedPortfolio
    • Offering
    • Offerings
    • Percentage
    • PermissionGroup
    • Permissions
    • Polymesh
    • PolymeshError
    • PolymeshTransaction
    • PolymeshTransactionBase
    • PolymeshTransactionBatch
    • Portfolio
    • Portfolios
    • Requirements
    • Schedules
    • Settlements
    • Subsidy
    • TickerReservation
    • TransactionQueue
    • TransferRestrictionBase
    • TransferRestrictions
    • TrustedClaimIssuers
    • Venue
  • Enums
  • Interfaces
Powered by GitBook
On this page
  • Hierarchy
  • Index
  • Properties
  • Methods
  • Properties
  • Protected context
  • id
  • uuid
  • Methods
  • affirm
  • details
  • exists
  • getAffirmations
  • getLegs
  • getStatus
  • getStatusV2
  • isEqual
  • isExecuted
  • isPending
  • reject
  • reschedule
  • toHuman
  • withdraw
  • Static generateUuid
  • Static unserialize

Was this helpful?

  1. Classes

Instruction

PreviousIdentityAuthorizationsNextIssuance

Last updated 2 years ago

Was this helpful?

Represents a settlement Instruction to be executed on a certain Venue

Hierarchy

  • ‹UniqueIdentifiers, string›

    ↳ Instruction

Index

Properties

Methods

Properties

Protected context

• context: Context


id

• id: BigNumber

Identifier number of the venue


uuid

• uuid: string

Methods

affirm

Affirm this instruction (authorize)

Parameters:

Name
Type

opts?


details

Retrieve information specific to this Instruction


exists

▸ exists(): Promise‹boolean›

Determine whether this Instruction exists on chain (or existed and was pruned)

Returns: Promise‹boolean›


getAffirmations

Retrieve every authorization generated by this Instruction (status and authorizing Identity)

note supports pagination

Parameters:

Name
Type

paginationOpts?


getLegs

Retrieve all legs of this Instruction

note supports pagination

Parameters:

Name
Type

paginationOpts?


getStatus

Retrieve current status of this Instruction

note uses the middleware


getStatusV2

Retrieve current status of this Instruction

note uses the middlewareV2


isEqual

Determine whether this Entity is the same as another one

Parameters:

Name
Type

entity

Returns: boolean


isExecuted

▸ isExecuted(): Promise‹boolean›

Retrieve whether the Instruction has already been executed and pruned from the chain.

Returns: Promise‹boolean›


isPending

▸ isPending(): Promise‹boolean›

Retrieve whether the Instruction is still pending on chain

Returns: Promise‹boolean›


reject

Reject this instruction

note reject on SettleOnAffirmation will execute the settlement and it will fail immediately.

note reject on SettleOnBlock behaves just like unauthorize

Parameters:

Name
Type

opts?


reschedule

Reschedules a failed Instruction to be tried again

throws if the Instruction status is not InstructionStatus.Failed

Parameters:

Name
Type

opts?


toHuman

â–¸ toHuman(): string

Return the Instruction's ID

Returns: string


withdraw

Withdraw affirmation from this instruction (unauthorize)

Parameters:

Name
Type

opts?


Static generateUuid

▸ generateUuid‹Identifiers›(identifiers: Identifiers): string

Generate the Entity's UUID from its identifying properties

Type parameters:

â–ª Identifiers

Parameters:

Name
Type
Description

identifiers

Identifiers

Returns: string


Static unserialize

▸ unserialize‹Identifiers›(serialized: string): Identifiers

Unserialize a UUID into its Unique Identifiers

Type parameters:

â–ª Identifiers

Parameters:

Name
Type
Description

serialized

string

UUID to unserialize

Returns: Identifiers

Inherited from .

Defined in

Defined in

Inherited from .

Defined in

▸ affirm(opts?: ): Promise‹‹››

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‹‹››

▸ details(): Promise‹›

Defined in

Returns: Promise‹›

Overrides .

Defined in

▸ getAffirmations(paginationOpts?: ): Promise‹‹››

Defined in

Returns: Promise‹‹››

▸ getLegs(paginationOpts?: ): Promise‹‹››

Defined in

Returns: Promise‹‹››

▸ getStatus(): Promise‹›

Defined in

Returns: Promise‹›

▸ getStatusV2(): Promise‹›

Defined in

Returns: Promise‹›

▸ isEqual(entity: ‹unknown, unknown›): boolean

Inherited from .

Defined in

‹unknown, unknown›

Defined in

Defined in

▸ reject(opts?: ): Promise‹‹››

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‹‹››

▸ reschedule(opts?: ): Promise‹‹››

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‹‹››

Overrides .

Defined in

▸ withdraw(opts?: ): Promise‹‹››

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‹‹››

Inherited from .

Defined in

Inherited from .

Defined in

src/api/entities/Entity.ts:48
src/api/entities/Instruction/index.ts:80
src/api/entities/Entity.ts:46
ProcedureOpts
TransactionQueue
Instruction
src/api/entities/Instruction/index.ts:448
NoArgsProcedureMethod
affirm.checkAuthorization
TransactionQueue
Instruction
src/api/entities/Instruction/index.ts:201
src/api/entities/Instruction/index.ts:183
PaginationOptions
ResultSet
InstructionAffirmation
src/api/entities/Instruction/index.ts:260
ResultSet
InstructionAffirmation
PaginationOptions
ResultSet
Leg
src/api/entities/Instruction/index.ts:306
ResultSet
Leg
src/api/entities/Instruction/index.ts:357
src/api/entities/Instruction/index.ts:395
Entity
src/api/entities/Entity.ts:61
src/api/entities/Instruction/index.ts:138
src/api/entities/Instruction/index.ts:162
ProcedureOpts
TransactionQueue
Instruction
src/api/entities/Instruction/index.ts:438
NoArgsProcedureMethod
reject.checkAuthorization
TransactionQueue
Instruction
ProcedureOpts
TransactionQueue
Instruction
src/api/entities/Instruction/index.ts:470
NoArgsProcedureMethod
reschedule.checkAuthorization
TransactionQueue
Instruction
src/api/entities/Instruction/index.ts:527
ProcedureOpts
TransactionQueue
Instruction
src/api/entities/Instruction/index.ts:458
NoArgsProcedureMethod
withdraw.checkAuthorization
TransactionQueue
Instruction
src/api/entities/Entity.ts:14
src/api/entities/Entity.ts:23
Entity
context
id
uuid
affirm
details
exists
getAffirmations
getLegs
getStatus
getStatusV2
isEqual
isExecuted
isPending
reject
reschedule
toHuman
withdraw
generateUuid
unserialize
ProcedureOpts
PaginationOptions
PaginationOptions
Entity
ProcedureOpts
ProcedureOpts
ProcedureOpts
CheckpointSchedule
CheckpointSchedule
Entity
CheckpointSchedule
Entity
CheckpointSchedule
CheckpointSchedule
exists
toHuman
context
uuid
isEqual
generateUuid
unserialize
InstructionDetails
InstructionDetails
InstructionStatusResult
InstructionStatusResult
InstructionStatusResult
InstructionStatusResult