init: Redis-backed Pokémon 雷達 API
- radar_fetcher.py:呼叫 Function Server 抓 twpkinfo.com 資料後寫入 Redis (TTL 300s) - pokemon_radar_api.py:FastAPI /scan,從 Redis 讀取並依 request 即時二次篩選;Redis 不可用時回 200 空結果,不再 500 - pokemon_location_fetcher.py:舊版 CLI,仍由 fetch_and_upload.sh 使用 - 文件:README (參考手冊)、QUICKSTART (操作指南)、SUMMARY (故事線)、CLAUDE.md Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
This commit is contained in:
14
run_pokemon_radar_api.sh
Executable file
14
run_pokemon_radar_api.sh
Executable file
@@ -0,0 +1,14 @@
|
||||
#!/usr/bin/env bash
|
||||
cd /opt/pokemon-radar-api
|
||||
|
||||
export POKER_URL="http://192.168.42.124:13000/function"
|
||||
export POKER_TOKEN="6R0W53R135510"
|
||||
export POKER_SCRIPT="twpk_radar.mjs"
|
||||
|
||||
# uv run uvicorn pokemon_radar_api:app --host 0.0.0.0 --port 8008
|
||||
|
||||
uv run uvicorn pokemon_radar_api:app \
|
||||
--host 0.0.0.0 \
|
||||
--port 8008 \
|
||||
--log-config logging.ini
|
||||
|
||||
Reference in New Issue
Block a user