Skip to main content

Overview

The ghost.closed event fires when a Ghost Trader position is fully closed on any supported asset. It includes the final P&L (net of any TP1 partial sell), the exit price, and a canonical close_reason label. Assets covered: BTC, ETH, SOL, TAO, GOLD Latency: Up to 30 seconds (poll-based dispatcher).

Subscribe

Register via POST /v1/webhooks with "ghost.closed" in the events array.

Payload

Data Fields

string
UUID of the closed trade.
string
Asset symbol. One of: BTC, ETH, SOL, TAO, GOLD.
decimal
Entry price in USD.
decimal
Final exit price in USD.
decimal
Net P&L in USD, including TP1 partial sell profit if TP1 fired before close.
string
Canonical close reason. One of:
string
ISO 8601 timestamp when the trade closed.

Delivery

Delivered as a signed POST to your registered URL with:
  • X-AIOKA-Event: ghost.closed
  • X-AIOKA-Signature: sha256=<hex>
  • X-AIOKA-Timestamp: <unix>
See Register Webhook for signature verification.