WITNESSMARKETS
Language / 语言

Partner documentation

Partner Shadow LP Integration

Version 0.1 · XAUUSD · Shadow analytics only

Safety boundary
No live execution, no order routing, no custody, no financial settlement. Partner data is used to calculate shadow pricing and economics.

Authentication

Witness issues one bearer API key per approved partner. The key is displayed once and stored hashed server-side.

Authorization: Bearer wxp_...

Download sample shadow-flow CSV

Submit copied flow

POST https://api.witnessmarkets.com/v1/partner/shadow/flow
Content-Type: application/json
Authorization: Bearer <partner-key>

{
  "external_order_id": "BRK-2026-001928",
  "event_time": "2026-11-17T01:15:02Z",
  "side": "buy",
  "quantity_lots": "1.25",
  "actual_execution_price": "3857.90",
  "metadata": {
    "venue": "existing-lp-a",
    "account_group": "retail-xau"
  }
}

Required fields

FieldMeaning
external_order_idUnique within your partner program.
event_timeRFC3339 UTC timestamp. Optional; receive time used if omitted.
sidebuy or sell.
quantity_lotsXAU lots. Witness assumes 100 oz per lot.
actual_execution_priceOptional. Enables execution-price comparison.
metadataOptional JSON object for your own segmentation.

Accepted response

{
  "status": "SHADOW_ACCEPTED",
  "reference": "3857.64",
  "witness_bid": "3857.49",
  "witness_ask": "3857.79",
  "witness_simulated_fill": "3857.79",
  "external_execution": false,
  "financial_settlement": false
}

Retrieve economics

GET https://api.witnessmarkets.com/v1/partner/shadow/report
Authorization: Bearer <partner-key>

The report returns 24H, 7D and 30D windows with gross flow, internalized lots, residual hedge lots, internalization %, external hedge ratio, hedge notional avoided, estimated upstream cost avoided, actual-vs-Witness price comparison and total estimated value.

Methodology

Internalized lots = 2 × min(total buys, total sells) inside the reporting window.

Residual hedge = absolute net buy/sell imbalance.

Upstream cost avoided = internalized ounces × the partner-specific assumed all-in upstream cost per ounce.

Price improvement compares the supplied actual execution price with the contemporaneous Witness shadow quote. Positive means Witness's simulated price was better for the partner.

Operational limits

This is an evaluation interface, not a live trading endpoint.