-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathenv.example
More file actions
63 lines (51 loc) · 1.87 KB
/
env.example
File metadata and controls
63 lines (51 loc) · 1.87 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
# Application
NODE_ENV=production
PORT=8080
API_KEYS=prod-key-velvet-2024-001,prod-key-velvet-2024-002,prod-key-velvet-2024-003
CORS_ORIGINS=https://yourdomain.com,https://api.yourdomain.com
# Redis
REDIS_URL=redis://localhost:6379/0
CACHE_TTL_SECONDS=5
SINGLEFLIGHT_LOCK_MS=1500
# Price Providers
PROVIDERS_TIMEOUT_MS=900
PROVIDERS_HARD_TIMEOUT_MS=1500
PROVIDERS_QUORUM=5
OUTLIER_REL_THRESHOLD=0.1
OUTLIER_K=3.5
MAX_TOKENS_PER_REQUEST=50
PARALLEL_TOKENS=50
# Rate Limiting (API endpoint throttling - Production)
THROTTLE_TTL=1
THROTTLE_LIMIT=100
# Provider Rate Limits (Performance Optimized - Aggressive)
# CoinGecko Pro: ~1000 calls/min = 16.6 RPS (aggressive: 15 RPS)
COINGECKO_RATE_LIMIT=15.0
# Moralis Pro: ~200 calls/min = 3.3 RPS (aggressive: 3 RPS)
MORALIS_RATE_LIMIT=3.0
# Portals.fi Pro: ~300 calls/min = 5.0 RPS (aggressive: 8 RPS)
PORTALS_RATE_LIMIT=8.0
# 1inch Business: ~1000 calls/min = 16.6 RPS (aggressive: 15 RPS)
ONEINCH_RATE_LIMIT=15.0
# DeFiLlama: No rate limits (ultra-aggressive: 20 RPS)
DEFILLAMA_RATE_LIMIT=20.0
# Logging
LOG_LEVEL=info
LOG_FILE=logs/app.log
# Monitoring
SENTRY_DSN=
# Swagger
SWAGGER_TITLE=Crypto Price Provider API
SWAGGER_DESCRIPTION=API for aggregating cryptocurrency prices from multiple providers
SWAGGER_VERSION=1.0
# Provider API Keys (Production Ready)
# CoinGecko Pro: get Pro key at https://www.coingecko.com/en/api (1000 calls/min)
COINGECKO_API_KEY=CG-your-actual-coingecko-pro-key-here
# Moralis Pro: get Pro key at https://moralis.io (200 calls/min)
MORALIS_API_KEY=your-actual-moralis-pro-key-here
# Portals.fi Pro: get Pro key at https://portals.fi (300 calls/min)
PORTALS_API_KEY=your-actual-portals-pro-key-here
# 1inch Business: get Business key at https://business.1inch.com (1000 calls/min)
ONEINCH_API_KEY=your-actual-1inch-business-key-here
# DeFiLlama: No API key required (completely free, no rate limits)
# DEFILLAMA_API_KEY=not-needed