Documentation Index
Fetch the complete documentation index at: https://docs.walletkit.com/llms.txt
Use this file to discover all available pages before exploring further.
Signing messages can be used for various method of authentication and off-chain operations, which can be put on-chain if necessary.
Obtain user pincode
In your app, ask the user for their wallet’s 6-digit pincode.You must never store the user pin on your servers.
Sign Message
Fill in the message and sign. Message can be either string or byte array represented in hex string, a common case is to sign a hash. Signing a string message
Signing a bytes array
const transaction = await wk.transactions.signMessage({
network: Network.Base,
signerWalletAddress: "<walelt address>",
message: "hello world",
userPin: "<user pin>",
});
const transaction = await wk.transactions.signMessage({
network: Network.Base,
signerWalletAddress: "<walelt address>",
message: "0xa525d9687bb5b71dbe8ce59d98c77a32a5d4ce00dc271b4e3ad0ac72d44e6013",
message_type: "bytes",
userPin: "<user pin>",
});