Skip to main content
POST
/
customers
/
{customerID}
/
liquidation_addresses
/
{liquidationAddressID}
/
drains
/
{drainID}
/
execute
Execute a pending USDT trade on a drain
curl --request POST \
  --url https://api.bridge.xyz/v0/customers/{customerID}/liquidation_addresses/{liquidationAddressID}/drains/{drainID}/execute \
  --header 'Api-Key: <api-key>' \
  --header 'Idempotency-Key: <idempotency-key>'
{
  "id": "<string>",
  "amount": "<string>",
  "customer_id": "<string>",
  "liquidation_address_id": "<string>",
  "created_at": "2023-11-07T05:31:56Z",
  "updated_at": "2023-11-07T05:31:56Z",
  "deposit_tx_hash": "<string>",
  "from_address": "<string>",
  "source_payment_rail": "<string>",
  "destination": {
    "to_address": "<string>",
    "blockchain_memo": "<string>",
    "external_account_id": "<string>",
    "wire_message": "<string>",
    "sepa_reference": "<string>",
    "swift_reference": "<string>",
    "spei_reference": "<string>",
    "reference": "<string>",
    "ach_reference": "<string>",
    "imad": "<string>",
    "trace_number": "<string>",
    "tracking_number": "<string>",
    "transaction_id": "<string>",
    "sending_institution_name": "<string>",
    "uetr": "<string>"
  },
  "destination_tx_hash": "<string>",
  "refund_tx_hash": "<string>",
  "return_details": {
    "reason": "<string>",
    "risk_rejection_reason": "<string>"
  },
  "receipt": {
    "initial_amount": "<string>",
    "developer_fee": "<string>",
    "subtotal_amount": "<string>",
    "converted_amount": "<string>",
    "exchange_rate": "<unknown>",
    "outgoing_amount": "<string>",
    "gas_fee": "<string>",
    "url": "<string>"
  },
  "exchange_details": {
    "fixed_rate": "<string>",
    "estimated_market_rate": "<string>",
    "traded_market_rate": "<string>",
    "trade_at_market": true,
    "updated_at": "2023-11-07T05:31:56Z"
  }
}

Authorizations

Api-Key
string
header
required

Headers

Idempotency-Key
string
required

Path Parameters

customerID
string
required

A UUID that uniquely identifies a resource

Required string length: 1 - 42
Pattern: [a-z0-9]*
liquidationAddressID
string
required

A UUID that uniquely identifies a resource

Required string length: 1 - 42
Pattern: [a-z0-9]*
drainID
string
required

A UUID that uniquely identifies a resource

Required string length: 1 - 42
Pattern: [a-z0-9]*

Response

Drain with trade execute at market rate enabled successfully

id
string
required
read-only

A UUID that uniquely identifies a resource

Required string length: 1 - 42
Pattern: [a-z0-9]*
amount
string
required

Amount of the drain, represented as a dollar denominated string. Examples include "100.25", "0.1", "1.234567", "1.01" etc.

customer_id
string
required
read-only

A UUID that uniquely identifies a resource

Required string length: 1 - 42
Pattern: [a-z0-9]*
liquidation_address_id
string
required
read-only

A UUID that uniquely identifies a resource

Required string length: 1 - 42
Pattern: [a-z0-9]*
currency
enum<string>
required
Available options:
brl,
cop,
eur,
eurc,
gbp,
mxn,
pyusd,
usd,
usdb,
usdc,
usdt
state
enum<string>
required
read-only

Status of the drain

Available options:
awaiting_funds,
in_review,
funds_received,
payment_submitted,
payment_processed,
canceled,
error,
undeliverable,
returned,
refund_in_flight,
refund_failed,
refunded
created_at
string<date-time>
read-only

Time of creation of the drain

updated_at
string<date-time>
read-only

Time of last update of the drain

deposit_tx_hash
string
read-only

Hash of the Liquidation Address deposit that triggered this drain

from_address
string
read-only

The blockchain address that sent funds to the Liquidation Address

source_payment_rail
string
read-only

The source payment rail where the funds originated from

destination
object
read-only

Destination information of a drain.

destination_tx_hash
string
read-only

Hash of withdrawal of funds to the destination

refund_tx_hash
string
read-only

Hash of refund, if the drain has been returned

return_details
object
read-only

Return information, if the drain has been returned.

receipt
object
read-only

Receipt information of a drain.

exchange_details
object
read-only

Exchange details for the associated trade, if applicable.