> For a complete index of Agora Finance documentation, fetch https://docs.agora.finance/llms.txt

# Getting Testnet Tokens

> Obtain testnet tokens and get whitelisted for Instant Settlement testing on supported testnets

> **Note**
>
> If you want to run this example, be sure that you have followed the steps [here](/instant-settlement/guides/quick-start#setting-up-a-viem-wallet-client) to configure your Wallet Client.

To try swaps end-to-end you'll need a balance of the demo tokens that live on Sepolia.

Agora provides faucet contracts that mint small amounts of each asset to any address on request.

> **Prerequisite**
>
> Make sure your wallet already holds a little Sepolia ETH for gas (see [Wallet Setup](/instant-settlement/guides/quick-start#wallet-setup)). A single transaction costs only a few gwei, but the transaction will fail if your balance is zero.

---

## Faucet addresses

| Token                                                                                             | Symbol   | Faucet contract                              |
| ------------------------------------------------------------------------------------------------- | -------- | -------------------------------------------- |
| [Agora USD](https://sepolia.etherscan.io/address/0xd236c18D274E54FAccC3dd9DDA4b27965a73ee6C)      | **AUSD** | `0xd236c18D274E54FAccC3dd9DDA4b27965a73ee6C` |
| [Constant Token](https://sepolia.etherscan.io/address/0xf8A143b3406faF59FD9A34891076104B10200B1D) | **CTK**  | `0xf8A143b3406faF59FD9A34891076104B10200B1D` |

## Helper function to request tokens

With the previously mentioned [viem wallet client](/instant-settlement/guides/quick-start#setting-up-a-viem-wallet-client) running, you should just need to use this helper function to call our contract and request testnet tokens.

```tsx
  const { request } = await client.simulateContract({
    address: AUSD_FAUCET,
    abi: ausdFaucetAbi,
    functionName: "requestFunds",
    args: [callerAddress],
  });
```

### Full Example

```tsx
(async () => {
  // Ensure the wallet is configured properly.
  const [callerAddress] = await client.getAddresses();
  console.log(`Caller Address ${callerAddress}`);

  const { request } = await client.simulateContract({
    address: AUSD_FAUCET,
    abi: ausdFaucetAbi,
    functionName: "requestFunds",
    args: [callerAddress],
  });

  let txHash = await client.writeContract(request);
  console.log("AUSD - Request Funds transaction hash:", txHash);
})();
```

### Output

```text
AUSD - Request Funds transaction hash: 0x4625c6c6a97f443b9532593c7604ae98c6c80ff7af279b8f96f2f98fd85c297f
```

You can check the status of the returned transaction hash in the Sepolia explorer. [Here](https://sepolia.etherscan.io/tx/0x4625c6c6a97f443b9532593c7604ae98c6c80ff7af279b8f96f2f98fd85c297f) is the transaction from the example above.

The Sepolia explorer shows that the transaction was successful so there should now be `10,000 AUSD` in the configured wallet's balance.