Four points first
- The reason is the clue; 201 means rejected.
- 100 × USD 50 = USD 5,000; USD 4,000 is USD 1,000 short.
- A 1% preset blocks USD 51 against USD 50.
- Confirm the first order did not fill.
01Read the full reason
A rejection returns a code and one sentence. The reason names the failed check; copy code, reason, symbol, and time.
| Keyword | Check |
|---|---|
| insufficient funds | Buying power, unsettled |
| no permissions | Product, market access |
| margin | Initial, maintenance |
| price band / tick | Band, limit, tick |
| not shortable | Borrow, locate fee |
02Permissions are not global
New accounts trade basic stocks in cash. Options, futures, FX, and some markets need separate permissions; orders are blocked without them. Cash cannot short; retirement accounts cannot margin.
03Buying power: cash means the full amount
A cash account needs the full order value: 100 shares at USD 50 is USD 5,000; USD 4,000 is USD 1,000 short. Unsettled proceeds, unconverted currency, and pending buys reduce usable funds.
| Setting | Requires | Outcome |
|---|---|---|
| Cash, USD 4,000 | USD 5,000 | Rejected, USD 1,000 short |
| Margin, USD 4,000 | USD 2,500 | Accepted, USD 1,000 debit |
| Cash, USD 1,200 pending | USD 2,800 | Rejected, USD 2,200 short |
04Margin: initial, then maintenance
Reg T requires 50% initial equity on US stocks: USD 5,000 needs USD 2,500. Maintenance, commonly 25%, applies after the fill. A margin reason means the product's method differs.
05Price: bands, limits, and the 1% cap
Price checks come from exchange bands, preset percentages, and the tick. At USD 50 last with a 1% preset, USD 51.00 is 2% away and blocked; USD 50.40 passes.
| Limit | Range | Result |
|---|---|---|
| 1% preset | 49.50–50.50 | 51.00 blocked, 50.40 passes |
| 5% preset | 47.50–52.50 | 52.00 passes |
| Daily limit | Per notice | Outside band rejected |
06Shorting: borrow first
A shortable tier of 0 means no borrow; more shares than available is rejected. A locate costs USD 0.30 per share, or USD 300 on 1,000. A falling stock can only be shorted higher.
07Halts, restrictions, untradeable names
A halted stock cannot trade, so the order is cancelled as halted. Restricted lists, some OTC names, and corporate actions block orders.
08Time in force and session
DAY expires today, GTC stays until cancelled, and GTD needs a date. Extended hours need the outside-RTH flag; market orders outside regular hours are often rejected, while limits wait.
| Setting | Validity | Note |
|---|---|---|
| DAY, outside RTH | Today, extended hours | Needs the flag |
| DAY, no flag | Regular session | May wait for the open |
| GTD | Until the date | Missing date rejected |
09Minimum size and contract specs
US stocks trade in single shares. Hong Kong uses board lots, so 100 shares against a 500-share lot is rejected.
10API messages and resend discipline
API rejections arrive as log messages: 201 rejected, 202 cancelled, 399 a warning, 110 an off-tick price, 103 a duplicate ID. Check the prior state.
| Code | Meaning | Handling |
|---|---|---|
| 201 | Rejected | Read reason, resend once |
| 202 | Cancelled | Check if cancelled elsewhere |
| 110 | Off-tick price | Adjust price |
| 103 | Duplicate ID | New ID or check state |
11Five-step checklist
Copy the code and reason. Confirm account type and permissions. Recalculate buying power. Check price against band and tick. Confirm the symbol is tradeable, shortable, and in session.
12Five common questions
Can I resend now?
Confirm the first order did not fill, or one signal becomes two. Fix the variable and resend.
Cash is enough, so why insufficient power?
Unsettled proceeds, unconverted currency, and pending buys reduce usable funds.
Can USD 4,000 buy 100 shares at USD 50?
Not in cash; USD 1,000 short. Margin can, at 50% initial, with USD 1,000 of debit.
Price inside the limit, so why blocked?
Your preset can be stricter; 1% blocks a price 2% away.
Is API 399 a failure?
No, it is a warning; the order may still be live. Check first.