Files
polymarket-5min-15min-1hour…/up-down-spread-bot/.env.example
T
2026-07-27 19:22:46 +08:00

92 lines
3.4 KiB
Bash
Raw Blame History

This file contains ambiguous Unicode characters
This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.
# =============================================================================
# Meridian — Polymarket 多币种交易机器人(环境变量)
# =============================================================================
# 使用方法:
# 1. 将此文件复制为 .env
# cp .env.example .env
# 2. 填入你的真实值
# 3. 启动机器人
#
# ⚠️ 切勿将包含真实密钥的 .env 提交到 git!
# =============================================================================
# =============================================================================
# ① 钱包私钥(必须)
# =============================================================================
# 你的 Polygon 钱包私钥,64 位十六进制字符 + 0x 前缀 = 66 字符
#
# 获取方式:
# - MetaMask:设置 → 安全与隐私 → 导出私钥
# - Polymarketpolymarket.com/settings → 导出私钥
#
# ⚠️ 切勿泄露此密钥,切勿提交到 git!
PRIVATE_KEY=0x0000000000000000000000000000000000000000000000000000000000000000
# =============================================================================
# ② Polygon 网络(必须)
# =============================================================================
# 免费 RPC 节点:
# - https://polygon-rpc.com(公共,有频率限制)
# - https://rpc.ankr.com/polygon(公共,有频率限制)
#
# 推荐使用私有 RPC(更稳定):
# - Alchemyhttps://polygon-mainnet.g.alchemy.com/v2/YOUR_API_KEY
# - Infurahttps://polygon-mainnet.infura.io/v3/YOUR_PROJECT_ID
# - QuickNodehttps://your-endpoint.quiknode.pro/YOUR_KEY/
#
# 免费 API 密钥获取:
# - Alchemyhttps://www.alchemy.com/
# - Ankrhttps://www.ankr.com/rpc/
RPC_URL=https://polygon-rpc.com
# Polygon 链 ID(不要修改)
CHAIN_ID=137
# =============================================================================
# ③ Polymarket API(必须)
# =============================================================================
# Polymarket CLOB API 地址(不要修改)
CLOB_HOST=https://clob.polymarket.com
# API 凭证
# 获取方式:
# 1. 访问 polymarket.com/settings
# 2. 连接钱包
# 3. 生成 API 凭证(Generate API Credentials
# 4. 将生成的 Key / Secret / Passphrase 填入下方
#
# 或者用 py-clob-client 库编程生成
POLYMARKET_API_KEY=your_api_key_here
POLYMARKET_API_SECRET=your_api_secret_here
POLYMARKET_API_PASSPHRASE=your_api_passphrase_here
# =============================================================================
# ④ Telegram 通知(可选)
# =============================================================================
# Telegram Bot Token
# 获取方式:
# 1. 打开 Telegram,搜索 @BotFather
# 2. 发送 /newbot 并按提示操作
# 3. 复制 Bot Token 到此处
TELEGRAM_BOT_TOKEN=
# Telegram Chat ID(你的用户 ID
# 获取方式:
# 1. 打开 Telegram,搜索 @userinfobot
# 2. 发送 /start
# 3. 复制返回的数字 ID 到此处
TELEGRAM_CHAT_ID=
# =============================================================================
# ⑤ 代理(国内用户必需)
# =============================================================================
# 梯子的 HTTP 代理地址,看你梯子客户端里的「本地 HTTP 端口」
# Clash / Clash Verge 默认 7890
# V2RayN 默认 10809
# 不用的话留空即可
HTTP_PROXY=http://127.0.0.1:7890
HTTPS_PROXY=http://127.0.0.1:7890