On this page

latest contributor to this doc

Last Edit:

@smk762

active_swaps

The active_swaps method returns all the swaps that are currently running on the Komodo DeFi Framework API node.

This method has been deprecated in favor of active_swaps v2. The legacy version does not include v2 (Trading Protocol Upgrade) swap statuses in responses (it only returns uuids for these).

Parameter* = requiredTypeDescription
include_status
bool
Optional, defaults to false. Whether to include swap statuses in response

Parameter* = requiredTypeDescription
uuids*
array of strings
A list of currently active swap UUIDs
statuses
object (map)
Optional. Only visible if include_status=true. Map of SwapStatus objects by UUID (see /komodo-defi-framework/api/common_structures/swaps/#swap-status)

POST
active_swaps
{
  "method": "active_swaps",
  "userpass": "RPC_UserP@SSW0RD"
}

Response (Success)

SUCCESS
{
  "statuses": null,
  "uuids": []
}

POST
active_swaps
{
  "include_status": true,
  "method": "active_swaps",
  "userpass": "RPC_UserP@SSW0RD"
}

Response (Success)

SUCCESS
{
  "statuses": {},
  "uuids": []
}