Api Place Paper Order

Place a paper-trading market order.

Body: { "ticker": str, "side": "buy" | "sell", "shares": number, "thesis": str (optional, ≤250 chars), "challenge_id": str (optional), "client_order_id": str (optional, ≤64 chars of [A-Za-z0-9_-]) }

client_order_id (v254, P1-22, external review 2026-09-26): the order form's idempotency key. A repeat of an order that already filled returns the ORIGINAL fill (200, same body) and never fills twice.

Returns PaperOrderResponse: success: { ok: True, fill: {...} } reject: { ok: False, error: "...", code: "<machine-readable>" }

Validation/rejection paths return 200 with ok=False so the FE can display the rejection reason without distinguishing HTTP status from business-logic state. True transport/auth errors raise.

post/api/paper/order

Request

  • Base URL: https://www.oxfordledge.com (the document declares no server; this is the origin it was published from)
  • URL: https://www.oxfordledge.com/api/paper/order
  • Auth: none declared

Response

Successful Response

okboolean required

Whether the order was filled.

errorstring nullable

Human-readable error on rejection.

codestring nullable

Machine-readable error code: ticker_invalid, side_invalid, shares_invalid, thesis_too_long, no_portfolio, quote_unavailable, insufficient_cash, insufficient_shares, fill_failed.

needednumber nullable

Cash needed (insufficient_cash only).

availablenumber nullable

Cash available (insufficient_cash only).

heldnumber nullable

Shares held (insufficient_shares only).

requestednumber nullable

Shares requested to sell (insufficient_shares only).

Changes

No recorded changes to this operation across all 1 revision of this API.