Skip to content

This repository contains shell scripts for downloading Binance public market data in various formats (NDJSON, CSV and TSV).

License

Notifications You must be signed in to change notification settings

system4-tech/binance-data-downloader-sh

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

5 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

This repository contains shell scripts for downloading Binance public market data in various formats (NDJSON, CSV and TSV).

Usage

$ binance-data-downloader -h
Usage: binance-data-downloader -p <product> -i <interval> -s <start_time> [-e <end_time>] [-f <format>] [-o <output_dir> [-P <max_parallel>]

Options:
  -p    Product: spot, um, cm [required]
  -i    Interval (e.g., 1d, 1h, 15m) [required]
  -s    Start time [required]
  -e    End time (default: current time)
  -f    Output format: csv, tsv, ndjson (default: csv)
  -o    Output directory (default: current directory)
  -P    Maximum parallel jobs (default: 4)
  -h    Show this help message

# Download CSV data for all spot symbols since 2019-01-01
$ binance-data-downloader.sh -p spot -i 1d -s 2019-01-01 -f csv -o data/spot/
data/spot/BTCUSDT_2019-01-01_2024-11-29.csv
data/spot/ETHUSDT_2019-01-01_2024-11-29.csv
data/spot/BNBUSDT_2019-01-01_2024-11-29.csv
...

See tests for more examples.

About

This repository contains shell scripts for downloading Binance public market data in various formats (NDJSON, CSV and TSV).

Resources

License

Stars

Watchers

Forks

Releases

No releases published