Files
store-scraper-bot/.env.example
T
tiennm99 cad84e21a4 feat: accept KV_REST_API_* env vars as Upstash fallback
Vercel Marketplace Upstash integration injects KV_REST_API_URL and
KV_REST_API_TOKEN — different names from vanilla Upstash signup
(UPSTASH_REDIS_REST_URL / UPSTASH_REDIS_REST_TOKEN). Adapter and
migration script now accept either form, so the operator doesn't have
to duplicate values when sharing an Upstash DB provisioned via the
Vercel integration. UPSTASH_* takes precedence when both are set.
2026-05-09 20:17:06 +07:00

25 lines
990 B
Bash

# Telegram
TELEGRAM_BOT_TOKEN=your_bot_token_here
TELEGRAM_BOT_USERNAME=your_bot_username
TELEGRAM_WEBHOOK_SECRET=generate_a_random_string_at_least_32_chars
# Upstash Redis (REST API; same DB can be shared with other Vercel projects
# because KEY_PREFIX namespaces this bot's keys).
# If the Vercel Marketplace Upstash integration is enabled, the project will
# already have KV_REST_API_URL and KV_REST_API_TOKEN — the adapter accepts
# those as fallbacks, so duplication is optional.
UPSTASH_REDIS_REST_URL=https://xxx.upstash.io
UPSTASH_REDIS_REST_TOKEN=your_upstash_rest_token
KEY_PREFIX=store-scraper-bot:
# Vercel Cron auth — protects /api/cron from random POSTs.
CRON_SECRET=generate_another_random_string_at_least_32_chars
# Bot config
ADMIN_IDS=123456789,987654321
APP_CACHE_SECONDS=600
NUM_DAYS_WARNING_NOT_UPDATED=30
# One-shot migration only (Phase 5: legacy Atlas → Upstash). Remove after migration done.
MONGODB_URI=mongodb+srv://user:pass@cluster.mongodb.net/dbname