> ## Documentation Index
> Fetch the complete documentation index at: https://docs.aioka.io/llms.txt
> Use this file to discover all available pages before exploring further.

# ghost.tp1 Event

> Fired when a Ghost Trader position hits TP1 and executes a partial sell.

## Overview

The `ghost.tp1` event fires once per trade, at the moment the Ghost Trader executes
a TP1 (Take Profit 1) partial sell on any supported asset. TP1 closes 50% of the
position and activates the Break-Even Shield, raising the stop-loss to the entry price.

**Assets covered:** BTC, ETH, SOL, TAO, GOLD

**Latency:** Up to 30 seconds (poll-based dispatcher).

## Subscribe

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

```json theme={null}
{
  "url": "https://your-server.com/aioka-hook",
  "events": ["ghost.tp1"]
}
```

## Payload

```json theme={null}
{
  "event": "ghost.tp1",
  "timestamp": "2026-05-08T14:32:10.123456Z",
  "data": {
    "trade_id": "3fa85f64-5717-4562-b3fc-2c963f66afa6",
    "asset": "ETH",
    "entry_price": "2845.50",
    "tp1_price": "2903.21",
    "tp1_pnl": "58.35",
    "be_shield_active": true,
    "timestamp": "2026-05-08 14:32:00+00:00"
  }
}
```

## Data Fields

<ResponseField name="trade_id" type="string">
  UUID of the trade that fired TP1.
</ResponseField>

<ResponseField name="asset" type="string">
  Asset symbol. One of: `BTC`, `ETH`, `SOL`, `TAO`, `GOLD`.
</ResponseField>

<ResponseField name="entry_price" type="decimal">
  Original entry price in USD.
</ResponseField>

<ResponseField name="tp1_price" type="decimal">
  Price at which the TP1 partial sell executed (may be null if not separately tracked).
</ResponseField>

<ResponseField name="tp1_pnl" type="decimal">
  Locked P\&L from the partial sell in USD. Null if not yet persisted.
</ResponseField>

<ResponseField name="be_shield_active" type="boolean">
  Always `true` for TP1 events -- TP1 execution always activates the Break-Even Shield.
</ResponseField>

<ResponseField name="timestamp" type="string">
  ISO 8601 timestamp when TP1 was detected by the dispatcher.
</ResponseField>

## Delivery

Delivered as a signed `POST` to your registered URL with:

* `X-AIOKA-Event: ghost.tp1`
* `X-AIOKA-Signature: sha256=<hex>`
* `X-AIOKA-Timestamp: <unix>`

See [Register Webhook](/api-reference/webhooks/register) for signature verification.
