trust-developer
Reference for building on the Trust Wallet developer platform: deep links, browser extension detection, and WalletConnect integration.
Portal: developer.trustwallet.com
Support: developer.trustwallet.com/developer/get-support
Deep Links
Trust Wallet supports deep links for launching the app directly into specific flows. Useful for mobile dApps and marketing campaigns.
Open a dApp inside Trust Wallet browser
https://link.trustwallet.com/open_url?coin_id=60&url=https%3A%2F%2Fyourdapp.com
coin_id— SLIP44 coin ID (60 = Ethereum, 714 = BNB, 501 = Solana)url— URL-encoded dApp URL
Send transaction
trust://send?asset=c60&address=0xRecipient&amount=0.1&memo=optional
asset— asset ID (c<coinId>for native,c<coinId>_t<contractAddress>for tokens)address— recipient addressamount— amount in display units
Buy crypto (on-ramp)
https://link.trustwallet.com/buy?asset=c60
WalletConnect deep link (pairing)
https://link.trustwallet.com/wc?uri=<url-encoded-wc-uri>
Browser Extension Detection
Detect Trust Wallet browser extension in dApps:
// Check for Trust Wallet specifically
function isTrustWallet(): boolean {
const { ethereum } = window as any;
if (!ethereum) return false;
if (ethereum.isTrust || ethereum.isTrustWallet) return true;
// Multi-provider array (EIP-5749)
if (ethereum.providers?.some((p: any) => p.isTrust || p.isTrustWallet)) return true;
return false;
}
// Get Trust Wallet provider from multi-provider array
function getTrustProvider() {
const { ethereum } = window as any;
if (!ethereum) return null;
if (ethereum.isTrust) return ethereum;
return ethereum.providers?.find((p: any) => p.isTrust) ?? null;
}
Trust Wallet extension sets:
window.ethereum.isTrust = truewindow.ethereum.isTrustWallet = true
For Solana:
const isTrustSolana = window.solana?.isTrust === true;
const isTrustSolana2 = window.trustwallet?.solana != null;
WalletConnect Integration
Trust Wallet fully supports WalletConnect v2. Recommended for dApps targeting mobile.
import { EthereumProvider } from '@walletconnect/ethereum-provider';
const provider = await EthereumProvider.init({
projectId: 'YOUR_WC_PROJECT_ID', // https://cloud.walletconnect.com
chains: [1], // Ethereum mainnet
optionalChains: [56, 137], // BNB, Polygon
showQrModal: true,
});
await provider.connect();
const accounts = provider.accounts;
// Trust Wallet will appear in the WalletConnect modal automatically
For mobile: use the deep link https://link.trustwallet.com/wc?uri=<wc-uri> to open directly in Trust Wallet.
Manifest / dApp Listing
To appear in the Trust Wallet dApp browser, submit your dApp to the official DApp list:
github.com/trustwallet/dapp-list
Required manifest.json fields:
{
"name": "Your dApp",
"iconUrl": "https://yourdapp.com/icon.png",
"url": "https://yourdapp.com",
"categories": ["defi", "nft"],
"chains": ["ethereum", "binance"]
}
Common Integration Patterns
Auto-connect to Trust Wallet on mobile
// On mobile, if Trust Wallet is installed, deep-link directly
const isMobile = /iPhone|Android/i.test(navigator.userAgent);
const dappUrl = encodeURIComponent('https://yourdapp.com');
if (isMobile && !window.ethereum) {
window.location.href =
`https://link.trustwallet.com/open_url?coin_id=60&url=${dappUrl}`;
}
Request accounts (EIP-1193)
const provider = getTrustProvider();
if (!provider) throw new Error('Trust Wallet not found');
const accounts = await provider.request({ method: 'eth_requestAccounts' });
Switch / add chain
await provider.request({
method: 'wallet_switchEthereumChain',
params: [{ chainId: '0x38' }], // BNB Chain
});
// If chain not known by wallet:
await provider.request({
method: 'wallet_addEthereumChain',
params: [{
chainId: '0x38',
chainName: 'BNB Smart Chain',
rpcUrls: ['https://bsc-dataseed.binance.org'],
nativeCurrency: { name: 'BNB', symbol: 'BNB', decimals: 18 },
blockExplorerUrls: ['https://bscscan.com'],
}],
});
More from trustwallet/tw-agent-skills
trust-wallet-api
Trust Wallet API for crypto data — token search, prices, trending tokens, swap quotes, market data, security checks, address validation, asset info, and coin status across 100+ blockchains. Use whenever the user asks about crypto prices, token info, swap rates, market cap, trending coins, token risk, honeypot detection, address validation, or wants to call the Trust Wallet / tws.trustwallet.com API directly. Covers HMAC-SHA256 authentication, supported chains, and all REST endpoints.
82trust-wallet-cli
Trust Wallet CLI (`twak`) — install, create wallets, check balances, send tokens, swap, view history, set price alerts, DCA automations, limit orders, manage ERC-20 approvals, check token risk, browse trending/DApps, and run x402 micropayments. Use whenever the user wants to use the twak CLI, manage a crypto wallet from the terminal, send or swap tokens via command line, check portfolio, create price alerts, set up DCA, create limit orders, approve ERC-20 spenders, or interact with Trust Wallet from a shell. Also covers MCP server setup for AI agents.
81trust-wallet-sdk
Trust Wallet open-source libraries — Wallet Core (HD wallets, address derivation, tx signing in Swift/Kotlin/TypeScript/Go for 140+ chains), Web3 Provider (dApp connection for Ethereum/Solana/Cosmos/Bitcoin/Aptos/TON/Tron), deep linking, browser extension integration, WalletConnect, token assets repository, and Barz ERC-4337 smart wallet. Use when working with trustwallet/wallet-core, @trustwallet/wallet-core, trust-web3-provider, Trust Wallet deep links, token logos/metadata from trustwallet/assets, or Barz account abstraction.
68your-skill-name
One sentence — what this skill does and when Claude should use it.
59assets
Work with the Trust Wallet assets repository — look up token logos and metadata, list assets by blockchain, and contribute new assets (add logo, info.json, update tokenlist). Use when the user asks about token logos, asset listings, adding a token to Trust Wallet, or querying trustwallet/assets.
11wallet-core
Build with Trust Wallet Core — HD wallet creation, address derivation, and transaction signing across 140+ blockchains. Use when working with trustwallet/wallet-core, @trustwallet/wallet-core, or implementing key generation and signing in Swift, Kotlin, TypeScript, or Go.
11