finance-query v3.0.0

Nasdaq (Market Calendars)#

info · Feature flag required

toml
finance-query = { version = "...", features = ["nasdaq"] }

Capability::CALENDAR previously needed a keyed provider (FMP, Polygon, or Alpha Vantage) for earnings/IPO/dividend/split calendars. This adapter serves those four keylessly from api.nasdaq.com's public calendar endpoints — the same undocumented API several third-party calendar wrappers already rely on.

Setup#

rust · no_run feature=nasdaq
use finance_query::{Capability, CalendarDetail, Provider, Providers};

#[tokio::main]
async fn main() -> Result<(), Box<dyn std::error::Error>> {
    let providers = Providers::builder()
        .route(Capability::CALENDAR, [Provider::Nasdaq])
        .build()
        .await?;

    let calendar = providers.calendar();
    for entry in calendar.earnings("2026-08-24", "2026-08-24").await? {
        if let CalendarDetail::Earnings { eps_estimated, time, .. } = entry.detail {
            println!(
                "{}: est. EPS {:?} ({})",
                entry.symbol.as_deref().unwrap_or("?"),
                eps_estimated,
                time.as_deref().unwrap_or("?")
            );
        }
    }
    Ok(())
}

note · Nasdaq serves four calendar kinds only

earnings, ipos, dividends, and splits are covered. economic, holidays, and market_status are NotSupported here — route CALENDAR to FRED for economic releases, or rely on the always-on local holiday provider and Yahoo for the other two (see Calendar Providers).

Date-Range Fan-Out#

Nasdaq's calendar endpoints take no date-range parameter — each of earnings, dividends, and splits is queried one calendar day at a time, and ipos one calendar month at a time. A [from, to] request fans out into one HTTP call per day (or month) in range internally, so:

Field Mapping Notes#

Bot Detection#

api.nasdaq.com drops any request whose User-Agent doesn't look like a browser — even a self-identifying agent gets the connection reset, confirmed against the live API. This adapter sends a plain browser-shaped User-Agent rather than the crate's usual self-identifying one.

Rate Limits#

Nasdaq documents no formal quota for these endpoints. The client self-paces at 2 requests/second, conservative given that a single range request can already fan out into dozens of calls.

Next Steps#

built with cargo soothfast docs build source