---
title: "Confirm TEE wallet delegation AND drain any pending welcome airdrop"
method: POST
path: "/v1/wallet/enable-trading"
tags: ["User"]
---

# Confirm TEE wallet delegation AND drain any pending welcome airdrop

`POST /v1/wallet/enable-trading`

Two responsibilities, kept in one round-trip so the frontend can
render a single combined success toast:

1. **Delegation status.** Confirms whether the embedded wallet
   is currently delegated to our key quorum. The actual
   delegation is a USER-SIDE action (frontend `addSigners()`);
   this endpoint only reads the current state — it does NOT
   perform the delegation itself.
2. **Pending welcome-airdrop drain.** Under the deferred-airdrop
   flow (TT-airdrop-bug 2026-05-13), the welcome airdrop amount
   is staged on `users.welcome_airdrop_pending_amount` at
   approval time. This endpoint atomically claims that amount,
   mints the USDC from treasury to the canonical wallet, and
   clears the column. Idempotent: a second call after a
   successful drain returns `airdrop: null` (nothing left to
   drain) without re-minting. On mint failure, the pending
   amount is restored so the user can retry on their next call.

## Response `200`

OK

- object
  - `data` object
    - `ready` boolean — True if a wallet is linked and delegation can proceed
    - `delegated` boolean — True if TEE wallet delegation is active (server can sign)
    - `address` string — Solana wallet address (base58). Empty string if no wallet linked.
    - `wallet_id` string — Privy embedded wallet ID (used for delegation API calls)
    - `airdrop` AirdropDrainOutcome — Outcome of the pending-airdrop drain performed by `POST /v1/wallet/enable-trading`. Narrower than `AirdropOutcome` — there is no `pending` field because the drain is the terminal step (either the mint landed or it didn't; the amount is never left in a staged state by this endpoint). `{ success: true, amount }` — the staged amount minted successfully on-chain. `{ success: false, amount }` — the mint attempt failed and the pending amount has been restored; the user can retry on their next call.
      - `success` boolean, required
      - `amount` number, required — USDC amount (whole dollars)

## Other responses

- `401` — Missing or invalid authentication

---

[API](https://skmtc.net/totalistrading/apis/totalis-rfq-api.md) · [All operations](https://skmtc.net/totalistrading/apis/totalis-rfq-api/llms.txt) · [OpenAPI document](https://skmtc-service-staging.skmtc.workers.dev/v1/apis/totalistrading/totalis-rfq-api/revisions/b0adb9a590b4/schema)
