Preparing search index...
The search index is not available
Connect SDK - v0.1.7
Connect SDK
@wormhole-foundation/sdk-definitions
Platform
Interface Platform<P>
Type Parameters
P
extends
PlatformName
Hierarchy
PlatformUtils
<
P
>
Platform
Implemented by
testing
.
mocks
.
MockPlatform
testing
.
mocks
.
MockPlatform
Index
Properties
conf
network
platform
Methods
chain
From
Chain
Id
chain
From
Rpc
get
Balance
get
Balances
get
Chain
get
Current
Block
get
Decimals
get
Rpc
is
Native
Token
Id
is
Supported
Chain
native
Token
Id
parse
Transaction
send
Wait
set
Config
Properties
Readonly
conf
conf
:
ChainsConfig
Readonly
network
network
:
"Mainnet"
|
"Testnet"
|
"Devnet"
Readonly
platform
platform
:
P
Methods
chain
From
Chain
Id
chain
From
Chain
Id
(
chainId
)
:
[
"Mainnet"
|
"Testnet"
|
"Devnet"
,
"Solana"
|
"Btc"
|
"Algorand"
|
"Sui"
|
"Aptos"
|
"Near"
|
"Ethereum"
|
"Terra"
|
"Bsc"
|
"Polygon"
|
"Avalanche"
|
"Oasis"
|
"Aurora"
|
"Fantom"
|
"Karura"
|
"Acala"
|
"Klaytn"
|
"Celo"
|
"Moonbeam"
|
"Neon"
|
"Terra2"
|
"Injective"
|
"Osmosis"
|
"Arbitrum"
|
"Optimism"
|
"Gnosis"
|
"Pythnet"
|
"Xpla"
|
"Base"
|
"Sei"
|
"Rootstock"
|
"Wormchain"
|
"Cosmoshub"
|
"Evmos"
|
"Kujira"
|
"Sepolia"
]
Parameters
chainId
:
string
Returns
[
"Mainnet"
|
"Testnet"
|
"Devnet"
,
"Solana"
|
"Btc"
|
"Algorand"
|
"Sui"
|
"Aptos"
|
"Near"
|
"Ethereum"
|
"Terra"
|
"Bsc"
|
"Polygon"
|
"Avalanche"
|
"Oasis"
|
"Aurora"
|
"Fantom"
|
"Karura"
|
"Acala"
|
"Klaytn"
|
"Celo"
|
"Moonbeam"
|
"Neon"
|
"Terra2"
|
"Injective"
|
"Osmosis"
|
"Arbitrum"
|
"Optimism"
|
"Gnosis"
|
"Pythnet"
|
"Xpla"
|
"Base"
|
"Sei"
|
"Rootstock"
|
"Wormchain"
|
"Cosmoshub"
|
"Evmos"
|
"Kujira"
|
"Sepolia"
]
chain
From
Rpc
chain
From
Rpc
(
rpc
)
:
Promise
<
[
"Mainnet"
|
"Testnet"
|
"Devnet"
,
"Solana"
|
"Btc"
|
"Algorand"
|
"Sui"
|
"Aptos"
|
"Near"
|
"Ethereum"
|
"Terra"
|
"Bsc"
|
"Polygon"
|
"Avalanche"
|
"Oasis"
|
"Aurora"
|
"Fantom"
|
"Karura"
|
"Acala"
|
"Klaytn"
|
"Celo"
|
"Moonbeam"
|
"Neon"
|
"Terra2"
|
"Injective"
|
"Osmosis"
|
"Arbitrum"
|
"Optimism"
|
"Gnosis"
|
"Pythnet"
|
"Xpla"
|
"Base"
|
"Sei"
|
"Rootstock"
|
"Wormchain"
|
"Cosmoshub"
|
"Evmos"
|
"Kujira"
|
"Sepolia"
]
>
Parameters
rpc
:
any
Returns
Promise
<
[
"Mainnet"
|
"Testnet"
|
"Devnet"
,
"Solana"
|
"Btc"
|
"Algorand"
|
"Sui"
|
"Aptos"
|
"Near"
|
"Ethereum"
|
"Terra"
|
"Bsc"
|
"Polygon"
|
"Avalanche"
|
"Oasis"
|
"Aurora"
|
"Fantom"
|
"Karura"
|
"Acala"
|
"Klaytn"
|
"Celo"
|
"Moonbeam"
|
"Neon"
|
"Terra2"
|
"Injective"
|
"Osmosis"
|
"Arbitrum"
|
"Optimism"
|
"Gnosis"
|
"Pythnet"
|
"Xpla"
|
"Base"
|
"Sei"
|
"Rootstock"
|
"Wormchain"
|
"Cosmoshub"
|
"Evmos"
|
"Kujira"
|
"Sepolia"
]
>
get
Balance
get
Balance
(
chain
,
rpc
,
walletAddr
,
token
)
:
Promise
<
null
|
bigint
>
Parameters
chain
:
"Solana"
|
"Btc"
|
"Algorand"
|
"Sui"
|
"Aptos"
|
"Near"
|
"Ethereum"
|
"Terra"
|
"Bsc"
|
"Polygon"
|
"Avalanche"
|
"Oasis"
|
"Aurora"
|
"Fantom"
|
"Karura"
|
"Acala"
|
"Klaytn"
|
"Celo"
|
"Moonbeam"
|
"Neon"
|
"Terra2"
|
"Injective"
|
"Osmosis"
|
"Arbitrum"
|
"Optimism"
|
"Gnosis"
|
"Pythnet"
|
"Xpla"
|
"Base"
|
"Sei"
|
"Rootstock"
|
"Wormchain"
|
"Cosmoshub"
|
"Evmos"
|
"Kujira"
|
"Sepolia"
rpc
:
any
walletAddr
:
string
token
:
AnyAddress
Returns
Promise
<
null
|
bigint
>
get
Balances
get
Balances
(
chain
,
rpc
,
walletAddress
,
tokens
)
:
Promise
<
Balances
>
Parameters
chain
:
"Solana"
|
"Btc"
|
"Algorand"
|
"Sui"
|
"Aptos"
|
"Near"
|
"Ethereum"
|
"Terra"
|
"Bsc"
|
"Polygon"
|
"Avalanche"
|
"Oasis"
|
"Aurora"
|
"Fantom"
|
"Karura"
|
"Acala"
|
"Klaytn"
|
"Celo"
|
"Moonbeam"
|
"Neon"
|
"Terra2"
|
"Injective"
|
"Osmosis"
|
"Arbitrum"
|
"Optimism"
|
"Gnosis"
|
"Pythnet"
|
"Xpla"
|
"Base"
|
"Sei"
|
"Rootstock"
|
"Wormchain"
|
"Cosmoshub"
|
"Evmos"
|
"Kujira"
|
"Sepolia"
rpc
:
any
walletAddress
:
string
tokens
:
AnyAddress
[]
Returns
Promise
<
Balances
>
get
Chain
get
Chain
(
chain
)
:
ChainContext
<
P
>
Parameters
chain
:
"Solana"
|
"Btc"
|
"Algorand"
|
"Sui"
|
"Aptos"
|
"Near"
|
"Ethereum"
|
"Terra"
|
"Bsc"
|
"Polygon"
|
"Avalanche"
|
"Oasis"
|
"Aurora"
|
"Fantom"
|
"Karura"
|
"Acala"
|
"Klaytn"
|
"Celo"
|
"Moonbeam"
|
"Neon"
|
"Terra2"
|
"Injective"
|
"Osmosis"
|
"Arbitrum"
|
"Optimism"
|
"Gnosis"
|
"Pythnet"
|
"Xpla"
|
"Base"
|
"Sei"
|
"Rootstock"
|
"Wormchain"
|
"Cosmoshub"
|
"Evmos"
|
"Kujira"
|
"Sepolia"
Returns
ChainContext
<
P
>
get
Current
Block
get
Current
Block
(
rpc
)
:
Promise
<
number
>
Parameters
rpc
:
any
Returns
Promise
<
number
>
get
Decimals
get
Decimals
(
chain
,
rpc
,
token
)
:
Promise
<
bigint
>
Parameters
chain
:
"Solana"
|
"Btc"
|
"Algorand"
|
"Sui"
|
"Aptos"
|
"Near"
|
"Ethereum"
|
"Terra"
|
"Bsc"
|
"Polygon"
|
"Avalanche"
|
"Oasis"
|
"Aurora"
|
"Fantom"
|
"Karura"
|
"Acala"
|
"Klaytn"
|
"Celo"
|
"Moonbeam"
|
"Neon"
|
"Terra2"
|
"Injective"
|
"Osmosis"
|
"Arbitrum"
|
"Optimism"
|
"Gnosis"
|
"Pythnet"
|
"Xpla"
|
"Base"
|
"Sei"
|
"Rootstock"
|
"Wormchain"
|
"Cosmoshub"
|
"Evmos"
|
"Kujira"
|
"Sepolia"
rpc
:
any
token
:
AnyAddress
Returns
Promise
<
bigint
>
get
Rpc
get
Rpc
(
chain
)
:
any
Parameters
chain
:
"Solana"
|
"Btc"
|
"Algorand"
|
"Sui"
|
"Aptos"
|
"Near"
|
"Ethereum"
|
"Terra"
|
"Bsc"
|
"Polygon"
|
"Avalanche"
|
"Oasis"
|
"Aurora"
|
"Fantom"
|
"Karura"
|
"Acala"
|
"Klaytn"
|
"Celo"
|
"Moonbeam"
|
"Neon"
|
"Terra2"
|
"Injective"
|
"Osmosis"
|
"Arbitrum"
|
"Optimism"
|
"Gnosis"
|
"Pythnet"
|
"Xpla"
|
"Base"
|
"Sei"
|
"Rootstock"
|
"Wormchain"
|
"Cosmoshub"
|
"Evmos"
|
"Kujira"
|
"Sepolia"
Returns
any
is
Native
Token
Id
is
Native
Token
Id
(
chain
,
tokenId
)
:
boolean
Parameters
chain
:
"Solana"
|
"Btc"
|
"Algorand"
|
"Sui"
|
"Aptos"
|
"Near"
|
"Ethereum"
|
"Terra"
|
"Bsc"
|
"Polygon"
|
"Avalanche"
|
"Oasis"
|
"Aurora"
|
"Fantom"
|
"Karura"
|
"Acala"
|
"Klaytn"
|
"Celo"
|
"Moonbeam"
|
"Neon"
|
"Terra2"
|
"Injective"
|
"Osmosis"
|
"Arbitrum"
|
"Optimism"
|
"Gnosis"
|
"Pythnet"
|
"Xpla"
|
"Base"
|
"Sei"
|
"Rootstock"
|
"Wormchain"
|
"Cosmoshub"
|
"Evmos"
|
"Kujira"
|
"Sepolia"
tokenId
:
TokenId
Returns
boolean
is
Supported
Chain
is
Supported
Chain
(
chain
)
:
boolean
Parameters
chain
:
"Solana"
|
"Btc"
|
"Algorand"
|
"Sui"
|
"Aptos"
|
"Near"
|
"Ethereum"
|
"Terra"
|
"Bsc"
|
"Polygon"
|
"Avalanche"
|
"Oasis"
|
"Aurora"
|
"Fantom"
|
"Karura"
|
"Acala"
|
"Klaytn"
|
"Celo"
|
"Moonbeam"
|
"Neon"
|
"Terra2"
|
"Injective"
|
"Osmosis"
|
"Arbitrum"
|
"Optimism"
|
"Gnosis"
|
"Pythnet"
|
"Xpla"
|
"Base"
|
"Sei"
|
"Rootstock"
|
"Wormchain"
|
"Cosmoshub"
|
"Evmos"
|
"Kujira"
|
"Sepolia"
Returns
boolean
native
Token
Id
native
Token
Id
(
chain
)
:
TokenId
Parameters
chain
:
"Solana"
|
"Btc"
|
"Algorand"
|
"Sui"
|
"Aptos"
|
"Near"
|
"Ethereum"
|
"Terra"
|
"Bsc"
|
"Polygon"
|
"Avalanche"
|
"Oasis"
|
"Aurora"
|
"Fantom"
|
"Karura"
|
"Acala"
|
"Klaytn"
|
"Celo"
|
"Moonbeam"
|
"Neon"
|
"Terra2"
|
"Injective"
|
"Osmosis"
|
"Arbitrum"
|
"Optimism"
|
"Gnosis"
|
"Pythnet"
|
"Xpla"
|
"Base"
|
"Sei"
|
"Rootstock"
|
"Wormchain"
|
"Cosmoshub"
|
"Evmos"
|
"Kujira"
|
"Sepolia"
Returns
TokenId
parse
Transaction
parse
Transaction
(
chain
,
rpc
,
txid
)
:
Promise
<
WormholeMessageId
[]
>
Parameters
chain
:
"Solana"
|
"Btc"
|
"Algorand"
|
"Sui"
|
"Aptos"
|
"Near"
|
"Ethereum"
|
"Terra"
|
"Bsc"
|
"Polygon"
|
"Avalanche"
|
"Oasis"
|
"Aurora"
|
"Fantom"
|
"Karura"
|
"Acala"
|
"Klaytn"
|
"Celo"
|
"Moonbeam"
|
"Neon"
|
"Terra2"
|
"Injective"
|
"Osmosis"
|
"Arbitrum"
|
"Optimism"
|
"Gnosis"
|
"Pythnet"
|
"Xpla"
|
"Base"
|
"Sei"
|
"Rootstock"
|
"Wormchain"
|
"Cosmoshub"
|
"Evmos"
|
"Kujira"
|
"Sepolia"
rpc
:
any
txid
:
string
Returns
Promise
<
WormholeMessageId
[]
>
send
Wait
send
Wait
(
chain
,
rpc
,
stxns
)
:
Promise
<
string
[]
>
Parameters
chain
:
"Solana"
|
"Btc"
|
"Algorand"
|
"Sui"
|
"Aptos"
|
"Near"
|
"Ethereum"
|
"Terra"
|
"Bsc"
|
"Polygon"
|
"Avalanche"
|
"Oasis"
|
"Aurora"
|
"Fantom"
|
"Karura"
|
"Acala"
|
"Klaytn"
|
"Celo"
|
"Moonbeam"
|
"Neon"
|
"Terra2"
|
"Injective"
|
"Osmosis"
|
"Arbitrum"
|
"Optimism"
|
"Gnosis"
|
"Pythnet"
|
"Xpla"
|
"Base"
|
"Sei"
|
"Rootstock"
|
"Wormchain"
|
"Cosmoshub"
|
"Evmos"
|
"Kujira"
|
"Sepolia"
rpc
:
any
stxns
:
any
[]
Returns
Promise
<
string
[]
>
set
Config
set
Config
(
network
,
_conf
?
)
:
Platform
<
P
>
Parameters
network
:
"Mainnet"
|
"Testnet"
|
"Devnet"
Optional
_conf
:
ChainsConfig
Returns
Platform
<
P
>
Settings
Member Visibility
Protected
Private
Inherited
Theme
OS
Light
Dark
On This Page
conf
network
platform
chain
From
Chain
Id
chain
From
Rpc
get
Balance
get
Balances
get
Chain
get
Current
Block
get
Decimals
get
Rpc
is
Native
Token
Id
is
Supported
Chain
native
Token
Id
parse
Transaction
send
Wait
set
Config
Connect SDK -
v0.1.7
@wormhole-
foundation/connect-
sdk -
v0.1.7
@wormhole-
foundation/connect-
sdk-
solana -
v0.1.7
@wormhole-
foundation/connect-
sdk-
evm -
v0.1.7
@wormhole-
foundation/connect-
sdk-
cosmwasm -
v0.1.7
@wormhole-
foundation/sdk-
base -
v0.1.7
@wormhole-
foundation/sdk-
definitions -
v0.1.7
Token
Bridge
testing
Chain
Context
Signature
Universal
Address
Address
Automatic
Circle
Bridge
Automatic
Token
Bridge
Circle
Bridge
Gateway
Ibc
Transfer
Msg
Gateway
Msg
Gateway
Transfer
Msg
Gateway
Transfer
With
Payload
Msg
Ibc
Bridge
Ibc
Transfer
Data
Ibc
Transfer
Info
Platform
Platform
Utils
Relayer
Sign
And
Send
Signer
Sign
Only
Signer
Supports
Automatic
Circle
Bridge
Supports
Automatic
Token
Bridge
Supports
Circle
Bridge
Supports
Ibc
Bridge
Supports
Token
Bridge
Supports
Wormhole
Core
Token
Bridge
Unsigned
Transaction
VAA
Wormhole
Core
Any
Address
Balances
Byteish
Chain
Address
Chain
Config
Chains
Config
Circle
Attestation
Circle
Message
Id
Circle
Transfer
Message
Contracts
DistributiveVAA
Extract
Literal
Gateway
Transfer
Details
Ibc
Message
Id
Layout
Literal
Mapped
Platforms
Named
Payloads
Native
Address
Payload
Discriminator
Payload
Literal
ProtocolVAA
Register
Payload
Types
Rpc
Connection
Sequence
Id
Signed
Tx
Signer
Token
Id
Transaction
Id
Tx
Hash
Universal
Or
Native
Wormhole
Message
Id
get
Circle
Attestation
get
Wormhole
Attestation
circle
Message
Layout
Err
Not
Wrapped
blind
Deserialize
Payload
compose
Literal
createVAA
deserialize
deserialize
Circle
Message
deserialize
Payload
gateway
Transfer
Msg
get
Contracts
is
Circle
Message
Id
is
Gateway
Ibc
Transfer
Msg
is
Gateway
Transfer
Details
is
Gateway
Transfer
Msg
is
Gateway
Transfer
With
Payload
Msg
is
Ibc
Message
Id
is
Ibc
Transfer
Info
is
Sign
And
Send
Signer
is
Sign
Only
Signer
is
Signer
is
Token
Id
is
Transaction
Identifier
is
Wormhole
Message
Id
make
Gateway
Transfer
Msg
native
Chain
Address
native
Is
Registered
payload
Discriminator
register
Native
register
Payload
Type
register
Payload
Types
serialize
serialize
Payload
supports
Automatic
Circle
Bridge
supports
Automatic
Token
Bridge
supports
Circle
Bridge
supports
Ibc
Bridge
supports
Token
Bridge
supports
Wormhole
Core
to
Gateway
Msg
to
Native
Generated using
TypeDoc