Polymesh
Main entry point of the Polymesh SDK
Hierarchy
Polymesh
Index
Properties
Accessors
Methods
Properties
claims
• claims: Claims
Defined in src/Polymesh.ts:83
middleware
• middleware: Middleware
Defined in src/Polymesh.ts:84
Accessors
_polkadotApi
• get _polkadotApi(): ApiPromise
Defined in src/Polymesh.ts:655
Polkadot client
Returns: ApiPromise
Methods
getAccount
▸ getAccount(): CurrentAccount
Defined in src/Polymesh.ts:445
Create an Account instance from an address. If no address is passed, the current Account is returned
Returns: CurrentAccount
▸ getAccount(args
: object): Account
Defined in src/Polymesh.ts:446
Parameters:
▪ args: object
Returns: Account
getAccountBalance
▸ getAccountBalance(args?
: undefined | object): Promise‹AccountBalance›
Defined in src/Polymesh.ts:276
Get the free/locked POLYX balance of an Account
note
can be subscribed to
Parameters:
Returns: Promise‹AccountBalance›
▸ getAccountBalance(callback
: SubCallback‹AccountBalance›): Promise‹UnsubCallback›
Defined in src/Polymesh.ts:277
Parameters:
Returns: Promise‹UnsubCallback›
▸ getAccountBalance(args
: object, callback
: SubCallback‹AccountBalance›): Promise‹UnsubCallback›
Defined in src/Polymesh.ts:278
Parameters:
▪ args: object
▪ callback: SubCallback‹AccountBalance›
Returns: Promise‹UnsubCallback›
getCurrentIdentity
▸ getCurrentIdentity(): Promise‹CurrentIdentity | null›
Defined in src/Polymesh.ts:438
Retrieve the Identity associated to the current Account (null if there is none)
Returns: Promise‹CurrentIdentity | null›
getIdentity
▸ getIdentity(args
: object): Identity
Defined in src/Polymesh.ts:431
Create an Identity instance from a DID
Parameters:
▪ args: object
Returns: Identity
getLatestBlock
▸ getLatestBlock(): Promise‹BigNumber›
Defined in src/Polymesh.ts:646
Retrieve the number of the latest block in the chain
Returns: Promise‹BigNumber›
getNetworkProperties
▸ getNetworkProperties(): Promise‹NetworkProperties›
Defined in src/Polymesh.ts:588
Retrieve information for the current network
Returns: Promise‹NetworkProperties›
getSecurityToken
▸ getSecurityToken(args
: object): Promise‹SecurityToken›
Defined in src/Polymesh.ts:562
Retrieve a Security Token
Parameters:
▪ args: object
Returns: Promise‹SecurityToken›
getSecurityTokens
▸ getSecurityTokens(args?
: undefined | object): Promise‹SecurityToken[]›
Defined in src/Polymesh.ts:525
Retrieve all the Security Tokens owned by an Identity
note
tokens with unreadable characters in their tickers will be left out
Parameters:
Returns: Promise‹SecurityToken[]›
getTickerReservation
▸ getTickerReservation(args
: object): Promise‹TickerReservation›
Defined in src/Polymesh.ts:405
Retrieve a Ticker Reservation
Parameters:
▪ args: object
Returns: Promise‹TickerReservation›
getTickerReservations
▸ getTickerReservations(args?
: undefined | object): Promise‹TickerReservation[]›
Defined in src/Polymesh.ts:366
Retrieve all the ticker reservations currently owned by an Identity. This doesn't include tokens that have already been launched
Parameters:
Returns: Promise‹TickerReservation[]›
getTransactionFees
▸ getTransactionFees(args
: object): Promise‹BigNumber›
Defined in src/Polymesh.ts:473
Retrieve the protocol fees associated with running a specific transaction
Parameters:
▪ args: object
Returns: Promise‹BigNumber›
getTreasuryAccount
▸ getTreasuryAccount(): Account
Defined in src/Polymesh.ts:480
Get the treasury wallet address
Returns: Account
getTreasuryBalance
▸ getTreasuryBalance(): Promise‹BigNumber›
Defined in src/Polymesh.ts:612
Get the Treasury POLYX balance
note
can be subscribed to
Returns: Promise‹BigNumber›
▸ getTreasuryBalance(callback
: SubCallback‹BigNumber›): Promise‹UnsubCallback›
Defined in src/Polymesh.ts:613
Parameters:
Returns: Promise‹UnsubCallback›
isIdentityValid
▸ isIdentityValid(args
: object): Promise‹boolean›
Defined in src/Polymesh.ts:462
Return whether the supplied Identity/DID exists
Parameters:
▪ args: object
Returns: Promise‹boolean›
isTickerAvailable
▸ isTickerAvailable(args
: object): Promise‹boolean›
Defined in src/Polymesh.ts:334
Check if a ticker hasn't been reserved
note
can be subscribed to
Parameters:
▪ args: object
Returns: Promise‹boolean›
▸ isTickerAvailable(args
: object, callback
: SubCallback‹boolean›): Promise‹UnsubCallback›
Defined in src/Polymesh.ts:335
Parameters:
▪ args: object
▪ callback: SubCallback‹boolean›
Returns: Promise‹UnsubCallback›
onConnectionError
▸ onConnectionError(callback
: function): function
Defined in src/Polymesh.ts:489
Handle connection errors
Parameters:
▪ callback: function
▸ (...args
: unknown[]): unknown
Parameters:
Returns: function
an unsubscribe callback
▸ (): void
onDisconnect
▸ onDisconnect(callback
: function): function
Defined in src/Polymesh.ts:506
Handle disconnection
Parameters:
▪ callback: function
▸ (...args
: unknown[]): unknown
Parameters:
Returns: function
an unsubscribe callback
▸ (): void
registerIdentity
▸ registerIdentity(args
: RegisterIdentityParams): Promise‹TransactionQueue‹Identity››
Defined in src/Polymesh.ts:639
Register an Identity
note
must be a CDD provider
note
this may create Authorization Requests which have to be accepted by the corresponding Accounts and/or Identities. An Account or Identity can fetch its pending Authorization Requests by calling authorizations.getReceived
Parameters:
Returns: Promise‹TransactionQueue‹Identity››
reserveTicker
▸ reserveTicker(args
: ReserveTickerParams): Promise‹TransactionQueue‹TickerReservation››
Defined in src/Polymesh.ts:325
Reserve a ticker symbol to later use in the creation of a Security Token. The ticker will expire after a set amount of time, after which other users can reserve it
Parameters:
Returns: Promise‹TransactionQueue‹TickerReservation››
transferPolyX
▸ transferPolyX(args
: TransferPolyXParams): Promise‹TransactionQueue‹void››
Defined in src/Polymesh.ts:265
Transfer an amount of POLYX to a specified Account
Parameters:
Returns: Promise‹TransactionQueue‹void››
Static
connect
Static
connect▸ connect(params
: ConnectParamsBase & object): Promise‹Polymesh›
Defined in src/Polymesh.ts:106
Create the instance and connect to the Polymesh node using an account seed
Parameters:
Returns: Promise‹Polymesh›
▸ connect(params
: ConnectParamsBase & object): Promise‹Polymesh›
Defined in src/Polymesh.ts:116
Create the instance and connect to the Polymesh node using a keyring
Parameters:
Returns: Promise‹Polymesh›
▸ connect(params
: ConnectParamsBase & object): Promise‹Polymesh›
Defined in src/Polymesh.ts:130
Create the instance and connect to the Polymesh node using an account URI
Parameters:
Returns: Promise‹Polymesh›
▸ connect(params
: ConnectParamsBase): Promise‹Polymesh›
Defined in src/Polymesh.ts:139
Create the instance and connect to the Polymesh node without an account
Parameters:
Returns: Promise‹Polymesh›
Last updated