Repository navigation
EN Configuration
Andrewkydev edited this page Aug 25, 2026
·
1 revision
Русский: RU-Configuration
AstraEngine does not require its own configuration format. Adapter configuration can be built directly from the environment.
The CLI and examples/multi-platform provide a helper:
cfg := runtimecfg.Load()
if err := cfg.ValidatePlatforms(); err != nil {
return err
}runtime.Load() reads a local .env file, then the environment. configs/config.example.yaml is only an example schema and is not loaded automatically.
| Variable | Default | Purpose |
|---|---|---|
ASTRAENGINE_APP_NAME |
multi-platform-bot |
application name |
ASTRAENGINE_LOG_LEVEL |
info |
debug, info, warn, error
|
ASTRAENGINE_LOG_FORMAT |
text |
text or json
|
ASTRAENGINE_LOG_SOURCE |
false | source location |
TELEGRAM_TOKEN |
— | Telegram token |
TG_SERVER_URL |
— | custom Bot API URL |
TG_PROXY_URL |
— | proxy URL |
TG_INIT_TIMEOUT_SEC |
20 | initialization timeout |
TG_POLL_TIMEOUT_SEC |
30 | polling timeout |
TG_REQUEST_TIMEOUT_SEC |
30 | request timeout |
TG_SKIP_GETME |
false | skip the initial getMe call |
VK_TOKEN |
— | VK community token |
VK_GROUP_ID |
0 | positive community ID |
VK_DEBUG |
false | adapter debug mode |
DISCORD_TOKEN |
— | Discord bot token |
ASTRAENGINE_STORAGE_DRIVER |
memory |
CLI storage driver |
ASTRAENGINE_DATABASE_URL |
— | PostgreSQL DSN |
ASTRAENGINE_PG_AUTO_SCHEMA |
false | CLI schema creation |
ASTRAENGINE_MIGRATIONS_STORE |
file |
file or session
|
ASTRAENGINE_MIGRATIONS_FILE |
.astraengine/migrations.json |
migration state file |
Boolean true values are 1, true, yes, and on, case-insensitively. Do not commit .env.