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
64
65
66
//! Unified data provider interface for quantitative finance.
//!
//! This crate provides a unified interface for fetching financial data from
//! multiple providers. It re-exports core types and provider implementations,
//! and provides a [`DataProviderRegistry`] for managing multiple providers
//! with automatic fallback behavior.
//!
//! # Features
//!
//! - `yahoo` - Yahoo Finance provider for price and reference data
//! - `edgar` - SEC EDGAR provider for fundamental data
//! - `fmp` - Financial Modeling Prep provider
//! - `nasdaq` - NASDAQ tick data provider
//! - `ibkr` - Interactive Brokers provider
//! - `cache-sqlite` - SQLite-based caching
//!
//! # Example
//!
//! ```rust,ignore
//! use data::{DataProviderRegistry, Symbol, DataFrequency};
//! use chrono::NaiveDate;
//!
//! #[tokio::main]
//! async fn main() -> data::Result<()> {
//! let registry = DataProviderRegistry::new()
//! .with_yahoo();
//!
//! let symbol = Symbol::new("AAPL");
//! let start = NaiveDate::from_ymd_opt(2024, 1, 1).unwrap();
//! let end = NaiveDate::from_ymd_opt(2024, 12, 31).unwrap();
//!
//! let ohlcv = registry.fetch_ohlcv(&symbol, start, end, DataFrequency::Daily).await?;
//! println!("{:?}", ohlcv);
//!
//! Ok(())
//! }
//! ```
// Core types and traits
pub use *;
// Cache implementations
pub use SqliteCache;
pub use ;
// Providers
pub use EdgarProvider;
pub use FmpProvider;
pub use IbkrProvider;
pub use NasdaqProvider;
pub use YahooProvider;
pub use DataProviderRegistry;