Swaps

Lists the completed or pending swaps for an account or user — currently only the most recent one.

get/swaps

Request

  • Base URL
    https://api.whop.com/api/v1
  • Auth
    • HTTP bearer
    • or HTTP bearer

Query parameters

account_id, string

Business account whose swaps to list, prefixed biz_. Provide this or user_id.

user_id, string

The caller's own user ID, prefixed user_, to list swaps in their personal account. Provide this or account_id.

Headers

Api-Version-Date, string
Example:2026-11-30

Pins the request to a dated API version.

Response

swaps listed

object required
data, object[] required

Swaps returned for this account.

Example response

{
  "data": [
    {
      "account_id": "biz_xxxxxxxxxxxxxx",
      "amount": "0.052341",
      "error": "Swap reverted: quoted price moved beyond the slippage tolerance",
      "id": "vault-swap-cwal_xxxxxxxxxxxxxx",
      "object": "swap",
      "status": "working",
      "tx_hashes": [
        "0xabc"
      ]
    }
  ]
}

Changes

    • info

      the security scope crypto_wallet:swap was added to the endpoint's security scheme bearerAuth

    • info

      the security scope crypto_wallet:manage was removed from the endpoint's security scheme bearerAuth

    • info

      the security scope crypto_wallet:swap was added to the endpoint's security scheme bearerAuth

    1 more change in this revision