Overview
Configuring autosign requires two main steps: setting up Privy for embedded wallet management and configuring autosign permissions in yourInterwovenKitProvider. This guide walks you through both processes.
Prerequisites
Before configuring autosign, ensure you have:- A Privy account and application ID
- InterwovenKit already integrated into your application
- An understanding of which transaction types you need to auto-sign
Setting Up Privy
Autosign requires Privy to manage embedded wallets. Privy provides secure key management and wallet creation for ghost wallets.1
Create a Privy Account
- Visit Privy’s website and create an account
- Create a new application in the Privy dashboard
- Copy your application ID from the dashboard
2
Install Privy Dependencies
Install the required Privy packages in your application. This guide assumes
InterwovenKit is already installed:
3
Configure Allowed Domains
Before configuring your application, set up allowed domains in the Privy
dashboard to ensure security and proper functionality:
- Access Privy Dashboard: Log in to your Privy account
- Click Into Application: Click into the application you would like Privy to work with
- Navigate to Allowed Domains: Click App settings on the left sidebar and then click on the Domains tab
- Add Domains: Under Allowed Origins, add:
- Your production domain (e.g.,
app.example.com) - Your development domain (e.g.,
localhost:3000) - Any staging domains you use
- Your production domain (e.g.,
4
Configure Privy and Integrate with InterwovenKit
The following configuration wires Privy into InterwovenKit to enable embedded
wallets and autosign:
- Wrap your app with
PrivyProviderto enable authentication and embedded wallet management. - Use Privy hooks (
usePrivy,useLoginWithSiwe,useCreateWallet,useWallets) to access wallet and auth state. - Pass those hooks into
InterwovenKitProviderviaprivyContext. - Enable autosign for supported message types using
enableAutoSign.
appId: Your Privy application IDembeddedWallets.ethereum.createOnLogin: "all-users": Required for autosign. Ensures an embedded (ghost) wallet is created at login. Privy’s default behavior may not create an embedded wallet automatically, which will prevent autosign from working.
providers.tsx
Configuring Autosign Permissions
Choose Your Autosign Mode
Before enabling autosign, decide which mode fits your application:-
Boolean (
enableAutoSign)- Best for simple, single-chain apps
- Automatically allows default contract execution messages for the chain
- Does not allow token transfers, staking, or other non-default messages
-
Per-Chain Configuration
(
enableAutoSign: { "chain-id": ["msg.type.Url", ...] })- Required if your app sends tokens, delegates, or uses multiple chains
- You must explicitly list every allowed message type
Simple Configuration (Limited)
This option only enables autosign for default contract execution messages and is intentionally restrictive.If you later need to support token transfers, staking, or multiple chains, you
must switch from the boolean configuration to the per-chain configuration in
the Advanced Configuration
section.
- Detects your chain’s VM type
- Grants permission for the appropriate message type:
- MiniEVM:
/minievm.evm.v1.MsgCall - MiniWasm:
/cosmwasm.wasm.v1.MsgExecuteContract - MiniMove:
/initia.move.v1.MsgExecute
- MiniEVM:
Advanced Configuration (Explicit Permissions)
For multi-chain applications or when you need custom message types, specify autosign permissions per chain:enableAutoSign prop accepts an object where:
- Keys: Chain IDs (strings)
- Values: Arrays of message type URLs (strings)
- EVM Chains:
/minievm.evm.v1.MsgCall - Wasm Chains:
/cosmwasm.wasm.v1.MsgExecuteContract - Move Chains:
/initia.move.v1.MsgExecute - Bank Module:
/cosmos.bank.v1beta1.MsgSend - Staking:
/cosmos.staking.v1beta1.MsgDelegate