Skip to content

Command Index

๐Ÿ“– Command Index (Full Reference)

All available commands in CSharpMT5 CLI, grouped by category. Use with:

dotnet run -- <command> [options]

โš™๏ธ Profiles & Setup

  • profiles

  • profiles โ€” Working with profiles

  • list โ€” Show profile names from profiles.json
  • show โ€” Show profile parameters (respects MT5_PASSWORD)

๐Ÿงพ Account & Diagnostics

  • info โ€” Show account summary
  • health โ€” Quick connectivity & account diagnostics
  • quote โ€” Get a snapshot quote (Bid/Ask/Time)
  • stream โ€” Subscribe to trading events/ticks (auto-reconnect)

๐Ÿ’น Market Orders

  • buy โ€” Market buy
  • sell โ€” Market sell

๐Ÿ”’ SL/TP, Breakeven & Trailing

  • modify

  • modify โ€” Modify StopLoss / TakeProfit by ticket

  • position

  • position.modify โ€” Modify SL/TP for a position by ticket

  • position.modify.points โ€” Set SL/TP by distance in points from entry/market
  • breakeven โ€” Move SL to entry ยฑ offset (breakeven)
  • trail

  • trail.start โ€” Start local trailing stop

  • trail.stop โ€” Stop local trailing stop

๐Ÿ”„ Closing / Reversing

  • close

  • close โ€” Close by ticket (volume normalized)

  • close.percent โ€” Close % of a position by ticket
  • close.half โ€” Close half (alias of close.percent --pct 50)
  • close.partial โ€” Partially close exact volume
  • close-all โ€” Close ALL open positions (optionally by symbol)
  • close-symbol โ€” Close ALL positions for a symbol
  • closeby โ€” Close a position by the opposite position (emulated)
  • reverse

  • reverse โ€” Reverse net position by symbol (--mode net|flat)

  • reverse.ticket โ€” Reverse a specific position by ticket

๐Ÿ“‘ Pending Orders

  • place โ€” Place a pending order (limit/stop/stop-limit)
  • pending

  • pending โ€” Pending utilities

  • pending.modify โ€” Modify pending (price/SL/TP/expiry)
  • pending.move โ€” Move pending by ยฑN points
  • pending list โ€” List pending tickets
  • cancel

  • cancel โ€” Cancel pending by ticket

  • cancel.all โ€” Cancel all pendings (optional filters)

๐ŸŽŸ๏ธ Tickets / Orders / Positions

  • ticket

  • ticket โ€” Work with a specific ticket

  • ticket show โ€” Show info (open or recent history)
  • orders โ€” List open orders & positions tickets
  • positions โ€” List active positions

๐Ÿ“Š Symbols

  • symbol

  • symbol โ€” Symbol utilities

  • symbol ensure โ€” Ensure symbol is visible in terminal
  • symbol limits โ€” Show min/step/max volume
  • symbol show โ€” Short card: Quote + Limits

๐Ÿ•’ History & Tools

  • history

  • history โ€” Orders/deals history (last N days)

  • history.export โ€” Export history to CSV/JSON
  • lot

  • lot.calc โ€” Calculate position volume by risk % and SL distance (points)

  • panic โ€” Close ALL positions and cancel ALL pendings (optionally filtered)