Skip to content

rcanderson23/mlbstats-rs

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

3 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

mlbstats-rs

Client for using the MLB Stats API.

Description

Async client for accessing the MLB Stats API. This library is alpha quality and there is no public documentation for the MLB API, expect bugs. Contributions welcome.

Usage

Example

use mlbstats::client::Client;
use chrono::NaiveDate;

#[tokio::main]
async fn main() -> Result<(), anyhow::Error> {
    let client = Client::new();

    let schedule = client.schedule(None, None, None::<NaiveDate>, None).await?;

    for date in schedule.dates {
        for game in date.games {
            println!("{:?}", game);
        }
    }

    Ok(())
}

About

Library and CLI tool for interacting with MLB stats API

Topics

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages