{"id":13412092,"url":"https://github.com/makarski/gtasks-rs","last_synced_at":"2025-03-14T17:31:38.651Z","repository":{"id":144661093,"uuid":"217100905","full_name":"makarski/gtasks-rs","owner":"makarski","description":"Rust Client for Google Tasks API","archived":false,"fork":false,"pushed_at":"2023-11-10T10:43:48.000Z","size":39,"stargazers_count":11,"open_issues_count":0,"forks_count":2,"subscribers_count":1,"default_branch":"main","last_synced_at":"2025-03-07T14:04:12.496Z","etag":null,"topics":["cli","client","google-api","google-tasks","google-tasks-api","rust","rust-google"],"latest_commit_sha":null,"homepage":null,"language":"Rust","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"apache-2.0","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/makarski.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE-APACHE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2019-10-23T16:14:50.000Z","updated_at":"2024-02-17T16:40:13.000Z","dependencies_parsed_at":null,"dependency_job_id":"b4f2dcc4-3586-4317-8e26-481466c8fe1a","html_url":"https://github.com/makarski/gtasks-rs","commit_stats":null,"previous_names":["makarski/gtasks-rs","makarski/rust_google_tasks"],"tags_count":5,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/makarski%2Fgtasks-rs","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/makarski%2Fgtasks-rs/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/makarski%2Fgtasks-rs/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/makarski%2Fgtasks-rs/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/makarski","download_url":"https://codeload.github.com/makarski/gtasks-rs/tar.gz/refs/heads/main","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":243618770,"owners_count":20320288,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["cli","client","google-api","google-tasks","google-tasks-api","rust","rust-google"],"created_at":"2024-07-30T20:01:20.906Z","updated_at":"2025-03-14T17:31:33.631Z","avatar_url":"https://github.com/makarski.png","language":"Rust","funding_links":[],"categories":["Rust"],"sub_categories":[],"readme":"gtasks\n======\n\n[![CodeScene Code Health](https://codescene.io/projects/45887/status-badges/code-health)](https://codescene.io/projects/45887)\n\nRust Client for [Google Tasks API v1](https://developers.google.com/tasks/v1/reference)\n\n## Example\n\n```toml\n[dependencies]\ngtasks = \"0.5\"\n```\nRead tasks\n\n```rust,no_run\nuse gtasks::Service;\n\nasync fn main() {\n    // Option 1: use static token\n    let task_srvc = Service::with_token(\"access_token\").unwrap();\n    read_tasks(\u0026task_srvc).await;\n\n    // Option 2: use closure to obtain auth token\n    let token_provider = || {\n        Ok(\"access_token\".to_owned())\n    };\n\n    let task_srvc = Service::with_auth(token_provider).unwrap();\n    read_tasks(\u0026task_srvc).await;\n}\n\nasync fn read_tasks(task_srvc: \u0026Service) {\n    let tasklists = task_srvc.list_tasklists(None).await.unwrap();\n    for tasklist in tasklists.items.iter() {\n        println!(\"tasklist: {}\", tasklist.title.as_ref().unwrap());\n    }\n\n    let list_id = tasklists.items[0].id.as_ref().unwrap();\n\n    // print tasks from the list\n    let opts = gtasks::TaskOptions {\n        max_results: Some(5),\n        show_completed: Some(true),\n        show_hidden: Some(true),\n        ..Default::default()\n    };\n\n    let tasks = task_srvc\n        .list_tasks(list_id, Some(opts), None)\n        .await\n        .unwrap();\n\n    if let Some(tasks) = tasks {\n        let items = tasks.items.unwrap();\n\n        for item in items {\n            println!(\"{:?}\", item.title);\n        }\n    }\n}\n```\n\n## License\n\nLicense under either or:\n\n* [MIT](LICENSE-MIT)\n* [Apache License, Version 2.0](LICENSE-APACHE)\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fmakarski%2Fgtasks-rs","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fmakarski%2Fgtasks-rs","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fmakarski%2Fgtasks-rs/lists"}