unlink1... account from that wallet.
By the end, the browser has registered a private Unlink account, the backend
has issued only short-lived authorization tokens, and no server has handled
the user’s Unlink spending key.
Prerequisites
- An Openfort project with an Openfort publishable key, Openfort secret key, and Shield publishable key.
- An Unlink project for
monad-testnet, with the backend-onlyUNLINK_API_KEYstored on your server. - Packages:
@unlink-xyz/sdk@canary,@openfort/react,@openfort/openfort-node,wagmi,@wagmi/core,@wagmi/connectors,viem, and@tanstack/react-query. - A Monad testnet RPC URL. If you continue into deposits, faucet funding, or private payments, also copy the token address configured for your Unlink project.
Configure Openfort
Wrap your React app with Openfort and wagmi. For this flow, configure an embedded EOA on Monad testnet.Build the Unlink client
After Openfort connects the embedded EOA, pass its EIP-1193 provider toaccount.fromWallet. Keep appId and chainId stable for returning users.
Mount the backend routes
Keep the Unlink admin API key on your server. Validate the Openfort bearer token, then mount the Unlink auth routes.What you built
The browser now has a non-custodial Unlink account backed by an Openfort embedded EOA:execute(). For a complete invoice-payment demo that builds on
this account setup, see Openfort’s
private payments recipe.
For the security model behind these routes, see Custody models
and Accounts and keys.