Skip to content

bullpen polymarket sweep-stranded

Last updated: July 13, 2026

Move a stranded ERC-20 token out of your Safe/Proxy or Deposit Wallet via a gasless relayer transaction.

Usage

bullpen polymarket sweep-stranded [OPTIONS] --token <TOKEN> --amount <AMOUNT>

Live Help

Move a stranded ERC-20 token out of your Safe/Proxy or Deposit Wallet via a gasless relayer transaction.

Use this only for supported Polygon ERC-20 balances held by your Bullpen Safe/Proxy or Deposit Wallet. It does not bridge or recover wrong-chain, imported-wallet, exchange, KYC, bank, or backend-ledger issues. The token is transferred to the destination address via a gasless relayer transaction — no POL/MATIC required. This sweeps ERC-20s only; `MATIC`/`POL` means wrapped POL/MATIC (WMATIC), not native POL.

By default only your own addresses are accepted as recipients (source signer EOA, source wallet, active wallet EOA, or active Polymarket wallet). Use `--unsafe-recipient` to send to an arbitrary address.

This is a one-way, non-reversible operation. Review the pre-flight summary carefully before confirming.

Usage: bullpen polymarket sweep-stranded [OPTIONS] --token <TOKEN> --amount <AMOUNT>

Options:
      --output <OUTPUT>
          Output format for command results

          [possible values: table, json]

      --token <TOKEN>
          ERC-20 token to sweep: ticker (USDC, USDC.e, pUSD, WMATIC/MATIC/POL, USDe) or 0x address. MATIC/POL means wrapped ERC-20, not native POL

      --env <ENV>
          Target environment to connect to (overrides config.toml)

          [env: BULLPEN_ENV=]
          [possible values: staging, production]

      --from <FROM>
          Source wallet address (0x-prefixed Safe/Proxy or Deposit Wallet). Must be owned by one of your Turnkey EOAs. Defaults to your active wallet when omitted

      --config <CONFIG>
          Path to a custom config.toml file (overrides $BULLPEN_CONFIG and the default location).

          Explicit --config and BULLPEN_CONFIG paths fail closed: if the file is missing, the CLI exits validation instead of silently loading defaults. Credentials still resolve via BULLPEN_HOME, so set BULLPEN_HOME too when isolating a session.

      --to <TO>
          Destination address (0x-prefixed). Defaults to your server-selected Polymarket wallet (the wallet trading commands route to). Pass an explicit address to sweep to a different own-wallet. Use --unsafe-recipient to sweep to a third-party address

      --amount <AMOUNT>
          Amount to sweep in token units (e.g. "10.50" for 10.50 USDC)

      --unsafe-recipient
          Allow sending to an arbitrary address (not just your own wallet addresses)

      --wallet-kind <KIND>
          Override the source wallet kind for the sweep. When set, forces the source to the Safe (`safe`) or Deposit Wallet (`dw`, alias `deposit` / `deposit-wallet`) owned by the resolved owner EOA, instead of auto-detecting from the --from address or the active wallet. Fails fast if the specified wallet kind has no balance

          [possible values: safe, dw]

      --read-only
          Enable read-only mode: blocks all mutating commands

  -y, --yes
          Skip confirmation prompt

      --non-interactive
          Suppress interactive prompts; does NOT imply --yes for money-moving commands

          [env: BULLPEN_NON_INTERACTIVE=]

  -h, --help
          Print help (see a summary with '-h')

EXAMPLES:
  # Open the confirmation flow; destination defaults to your server-selected Polymarket wallet
  bullpen polymarket sweep-stranded --token USDC.e --amount 10

  # Sweep from a Safe/Proxy or Deposit Wallet you own; destination still uses the server-selected default
  bullpen polymarket sweep-stranded --token pUSD --from 0x1111111111111111111111111111111111111111 --amount 10

  # Execute a wrapped POL/MATIC ERC-20 sweep after verification; this is not native POL
  bullpen polymarket sweep-stranded --token WMATIC --amount 0.25 --yes

NOTES:
  There is no separate --preview flag. The command authenticates, resolves the
  owned source and server-selected destination, checks recipient policy,
  balance, and off-chain order-credit warnings, prints the sweep summary, and then prompts
  before relayer submission.

Example Commands

bullpen polymarket sweep-stranded --help

JSON Output

Contract: JSON Output Contract.

This command supports --output json, but this generated reference page intentionally does not include a synthetic success schema or example.

Use the live command in your target environment to inspect command-specific success fields. Error output follows the shared JSON output contract linked above.

Error Envelope

When a Polymarket CLOB or gasless-relayer rejection coincides with a degraded Polymarket status page, the error envelope may include a polymarket_status object:

{
  "polymarket_status": {
    "page_status": "HASISSUES",
    "status_url": "https://status.polymarket.com",
    "affected_components": [
      {"name": "CLOB API", "status": "PARTIALOUTAGE"}
    ],
    "advisory": "Polymarket is experiencing issues; this rejection is most likely a Polymarket-side outage."
  }
}

The field is omitted on local validation/auth/balance errors and when the status-page fetch times out or reports healthy relevant components.

Schema version: 1 when a command emits schema_version; otherwise treat the current command shape as contract version 1.

Stability

Patch releases may add nullable or optional fields. Minor releases may add required fields or increment schema_version. Major releases may remove or rename fields.