Get your API key at
hackathon-apikey.vercel.app.
requestTestTokens()mints ERC-20 test tokens to an EVM wallet outside the unlink contractrequestPrivateTokens()transfers shielded test tokens directly into an Unlink account inside the unlink contract
Current test token
On the current Base Sepolia environment, the faucet token is:token parameter in the examples below unless your project specifies a different faucet token.
Mint to an EVM wallet
evmAddress, the SDK uses the connected EVM provider address.
Omitting
evmAddress requires an EVM provider on the client.Fund a private Unlink account
unlinkAddress, the SDK automatically registers the caller if needed and uses the caller’s own Unlink address.
You can also target another Unlink account explicitly:
When to use which
- Use
requestTestTokens()when the user needs public ERC-20 balance for an approval or public wallet flow - Use
requestPrivateTokens()when the user should start with funds already inside the unlink contract
Responses
requestTestTokens() returns an on-chain transaction hash:
requestPrivateTokens() returns an internal transfer result:
The faucet
tx_id is scoped to the faucet and cannot be polled via pollTransactionStatus(). It is not the same as transaction IDs returned by deposit(), transfer(), or withdraw(). To confirm private tokens have arrived, use getBalances() (see Utilities).