@desmoslabs/desmjs-walletconnect-v2
Namespaces
Enumerations
Classes
Interfaces
- GetAccountsRpcResponse
- LocalStorageI
- QrCodeModalController
- SerializedAccountData
- SignAminoDecodedRpcRequestParams
- SignAminoRpcRequestParams
- SignAminoRpcResponseParams
- SignDirectDecodedRpcRequestParams
- SignDirectRpcRequestParams
- SignDirectRpcResponseParams
- WalletConnectGetAccountsRequest
- WalletConnectSignAminoRequest
- WalletConnectSignDirectRequest
- WalletConnectSignerOptions
Type Aliases
WalletConnectRequest
Ƭ WalletConnectRequest: WalletConnectGetAccountsRequest
| WalletConnectSignAminoRequest
| WalletConnectSignDirectRequest
Type that represents the current supported WalletConnect RPC requests.
Defined in
packages/walletconnect-v2/src/types.ts:131
Functions
decodeAminoSignRequest
▸ decodeAminoSignRequest(request
): DecodeResult
<WalletConnectSignAminoRequest
>
Function to decode a WalletConnect "cosmos_signAmino" request.
Parameters
Name | Type | Description |
---|---|---|
request | BaseEventArgs <{ chainId : string ; request : { method : string ; params : any } }> | The request to convert. |
Returns
DecodeResult
<WalletConnectSignAminoRequest
>
Defined in
packages/walletconnect-v2/src/decode.ts:305
decodeAminoSignRpcRequestParams
▸ decodeAminoSignRpcRequestParams(params
): DecodeResult
<SignAminoDecodedRpcRequestParams
>
Decodes the params received from the cosmos_signAmino RPC method.
Parameters
Name | Type | Description |
---|---|---|
params | any [] | The params to decode. |
Returns
DecodeResult
<SignAminoDecodedRpcRequestParams
>
Defined in
packages/walletconnect-v2/src/decode.ts:193
decodeDirectSignRequest
▸ decodeDirectSignRequest(request
): DecodeResult
<WalletConnectSignDirectRequest
>
Function to decode a WalletConnect "cosmos_signDirect" request.
Parameters
Name | Type | Description |
---|---|---|
request | BaseEventArgs <{ chainId : string ; request : { method : string ; params : any } }> | The request to convert. |
Returns
DecodeResult
<WalletConnectSignDirectRequest
>
Defined in
packages/walletconnect-v2/src/decode.ts:223
decodeDirectSignRpcRequestParams
▸ decodeDirectSignRpcRequestParams(params
): DecodeResult
<SignDirectDecodedRpcRequestParams
>
Decodes the params received from the cosmos_signDirect RPC method.
Parameters
Name | Type | Description |
---|---|---|
params | any [] | The params to decode. |
Returns
DecodeResult
<SignDirectDecodedRpcRequestParams
>
Defined in
packages/walletconnect-v2/src/decode.ts:155
decodeGetAccountsRpcResponse
▸ decodeGetAccountsRpcResponse(response
): DecodeResult
<AccountData
[]>
Decodes the response received from the cosmos_getAccounts RPC method.
Parameters
Name | Type | Description |
---|---|---|
response | any | The response to decode. |
Returns
DecodeResult
<AccountData
[]>
Defined in
packages/walletconnect-v2/src/decode.ts:101
decodeSessionRequest
▸ decodeSessionRequest(request
): DecodeResult
<WalletConnectRequest
>
Function to decode a WalletConnect request received through the "session_request" event listener.
Parameters
Name | Type | Description |
---|---|---|
request | BaseEventArgs <{ chainId : string ; request : { method : string ; params : any } }> | The request to decode. |
Returns
DecodeResult
<WalletConnectRequest
>
Defined in
packages/walletconnect-v2/src/decode.ts:366
encodeAminoSignRpcRequestParams
▸ encodeAminoSignRpcRequestParams(signerAddress
, signDoc
): SignAminoRpcRequestParams
Encodes the params that are sent in the cosmos_signAmino RPC method.
Parameters
Name | Type | Description |
---|---|---|
signerAddress | string | Address of who is singing the transaction. |
signDoc | StdSignDoc | Transaction to be signed. |
Returns
Defined in
packages/walletconnect-v2/src/encode.ts:64
encodeAminoSignRpcResponse
▸ encodeAminoSignRpcResponse(signResponse
): SignAminoRpcResponseParams
Encodes the signature to be returned as response of the cosmos_signAmino RPC method.
Parameters
Name | Type | Description |
---|---|---|
signResponse | AminoSignResponse | Signature to encode. |
Returns
Defined in
packages/walletconnect-v2/src/encode.ts:78
encodeDirectSignRpcRequestParams
▸ encodeDirectSignRpcRequestParams(signerAddress
, signDoc
): SignDirectRpcRequestParams
Encodes the params that are sent in the cosmos_signDirect RPC method.
Parameters
Name | Type | Description |
---|---|---|
signerAddress | string | Address of who will sign the transaction. |
signDoc | SignDoc | Transaction to be signed. |
Returns
Defined in
packages/walletconnect-v2/src/encode.ts:34
encodeDirectSignRpcResponse
▸ encodeDirectSignRpcResponse(signResponse
): SignDirectRpcResponseParams
Encodes the signature to be returned as response of the cosmos_signDirect RPC method.
Parameters
Name | Type | Description |
---|---|---|
signResponse | DirectSignResponse | Signature to encode. |
Returns
Defined in
packages/walletconnect-v2/src/encode.ts:51
encodeGetAccountsRpcResponse
▸ encodeGetAccountsRpcResponse(accounts
): GetAccountsRpcResponse
Encodes the accounts to be returned as response of the cosmos_getAccounts RPC method.
Parameters
Name | Type | Description |
---|---|---|
accounts | readonly AccountData [] | Accounts to encode. |