Configuration Reference¶
The dccd daemon is driven by a YAML config file. The full annotated
template is at examples/config.example.yml in the repository.
# Generate a starter config
cp examples/config.example.yml config.yml
dccd validate --config config.yml
Top-level structure¶
settings:
data_path: /data/crypto
log_level: INFO
storage:
local_path: /data/crypto
remotes: [] # optional rclone destinations
histo_jobs:
- exchange: binance
pairs: [BTC/USDT]
span: 3600
stream_jobs:
- exchange: binance
pairs: [BTC/USDT]
channels: [trades, book]
time_step: 60
alerts:
webhook_url: https://hooks.slack.com/...
max_consecutive_errors: 5
settings block¶
Field |
Default |
Description |
|---|---|---|
|
|
Root directory where all data files are stored. |
|
|
|
|
|
Bind address for the web UI ( |
|
|
TCP port for the web UI. |
|
|
Bearer token required to access the web UI. |
storage block¶
Field |
Default |
Description |
|---|---|---|
|
(required) |
Same as |
|
|
List of rclone remote destinations (see below). |
rclone remotes¶
storage:
local_path: /data/crypto
remotes:
- name: s3-backup
path: s3:my-bucket/crypto
sync_interval: 3600 # seconds between rclone syncs
histo_jobs block¶
Each entry schedules periodic OHLCV REST downloads for one exchange and span.
Field |
Default |
Description |
|---|---|---|
|
(required) |
Exchange name: |
|
(required) |
List of pairs, e.g. |
|
(required) |
Candle interval in seconds: 60, 300, 900, 3600, 14400, 86400. |
|
|
Earliest date to backfill from. |
|
|
Number of retry attempts on transient network errors (1–10). |
|
|
Base delay in seconds; actual delay is |
Example with retry configuration:
histo_jobs:
- exchange: okx
pairs: [BTC/USDT, ETH/USDT, SOL/USDT]
span: 3600
start: '2022-01-01'
max_retries: 5
retry_delay: 3.0
stream_jobs block¶
Each entry opens a persistent WebSocket stream for one exchange.
Field |
Default |
Description |
|---|---|---|
|
(required) |
Exchange name: |
|
(required) |
List of pairs. |
|
(required) |
List of channels: |
|
|
Snapshot interval in seconds — how often data is flushed to disk. |
|
|
Total run duration in seconds. |
stream_jobs:
- exchange: kraken
pairs: [BTC/USD, ETH/USD]
channels: [trades, book, ohlcv]
time_step: 60
alerts block¶
Field |
Default |
Description |
|---|---|---|
|
|
Slack (or any webhook) URL; a POST is sent when the error threshold is hit. |
|
|
Number of consecutive job errors before an alert is fired. |
Slack example:
alerts:
webhook_url: https://hooks.slack.com/services/T.../B.../xxx
max_consecutive_errors: 3
The webhook payload is a JSON object {"text": "dccd alert: <message>"}.
Complete example¶
settings:
data_path: /data/crypto
log_level: INFO
storage:
local_path: /data/crypto
remotes:
- name: s3
path: s3:my-bucket/crypto
sync_interval: 3600
histo_jobs:
- exchange: binance
pairs: [BTC/USDT, ETH/USDT]
span: 3600
max_retries: 3
retry_delay: 2.0
- exchange: kraken
pairs: [BTC/USD]
span: 3600
stream_jobs:
- exchange: binance
pairs: [BTC/USDT]
channels: [trades, book]
time_step: 60
alerts:
webhook_url: https://hooks.slack.com/services/T.../B.../xxx
max_consecutive_errors: 5
Config models reference¶
|
Root configuration model for the dccd daemon. |
|
Global local settings shared by the daemon and the backfill command. |
|
Local and optional remote storage configuration. |
|
Remote storage configuration for rclone. |
|
Historical (REST) data collection job. |
|
Real-time (WebSocket) data collection job. |
|
Optional alerting configuration. |