Procházet zdrojové kódy

docs: update API endpoints documentation with query parameters and examples

- Add query parameter examples for symbols search endpoint (q=EURUSD)
- Enhance candles endpoints with detailed parameter examples
- Add missing DELETE /api/candles/cleanup endpoint documentation
- Update git branch references from main to master in deployment guide
- Improve API documentation clarity with practical usage examples
uzairrizwan1 před 9 měsíci
rodič
revize
ca8be1935c
1 změnil soubory, kde provedl 6 přidání a 5 odebrání
  1. 6 5
      README.md

+ 6 - 5
README.md

@@ -474,7 +474,7 @@ cp .env .env.backup
 cp ecosystem.config.js ecosystem.config.js.backup
 
 # Pull latest changes
-git pull origin main
+git pull origin master
 
 # Install any new dependencies
 npm install --production
@@ -506,7 +506,7 @@ sudo systemctl stop nginx
 
 # Update code
 git fetch origin
-git reset --hard origin/main
+git reset --hard origin/master
 
 # Install dependencies
 npm install --production
@@ -679,18 +679,19 @@ CORS_ORIGIN=*
 
 ### Symbols
 - `GET /api/symbols` - Get all symbols (with filtering)
-- `GET /api/symbols/search` - Search symbols by name
+- `GET /api/symbols/search?q=EURUSD` - Search symbols by name
 - `GET /api/symbols/:id` - Get symbol by ID
 - `POST /api/symbols` - Create new symbol
 - `PUT /api/symbols/:id` - Update symbol
 - `DELETE /api/symbols/:id` - Delete symbol (soft delete)
 
 ### Candles
-- `GET /api/candles` - Get candles with filtering
-- `GET /api/candles/ohlc` - Get OHLC data
+- `GET /api/candles?symbolId=1&startTime=2025-01-01T00:00:00Z&endTime=2025-01-02T00:00:00Z&limit=100&offset=0` - Get candles with filtering
+- `GET /api/candles/ohlc?symbolId=1&period=1h&limit=100` - Get OHLC data
 - `GET /api/candles/:symbolId/latest` - Get latest candle for symbol
 - `POST /api/candles` - Create new candle
 - `POST /api/candles/bulk` - Bulk create candles
+- `DELETE /api/candles/cleanup/:symbolId?keep=1000` - Clean up old candles, keep latest N (default 1000)
 
 ### Live Prices
 - `GET /api/live-prices` - Get all live prices