{"id":16496187,"url":"https://github.com/molotovcherry/anime-schedule-rs","last_synced_at":"2025-08-08T02:08:49.047Z","repository":{"id":234621254,"uuid":"789259178","full_name":"MolotovCherry/anime-schedule-rs","owner":"MolotovCherry","description":"Anime Schedule Api in Rust","archived":false,"fork":false,"pushed_at":"2024-04-28T00:48:19.000Z","size":95,"stargazers_count":3,"open_issues_count":0,"forks_count":0,"subscribers_count":1,"default_branch":"main","last_synced_at":"2025-03-18T20:46:49.602Z","etag":null,"topics":["anime","animeschedule","api","client","rust","schedule"],"latest_commit_sha":null,"homepage":"https://crates.io/crates/animeschedule","language":"Rust","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/MolotovCherry.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","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":"2024-04-20T04:00:48.000Z","updated_at":"2024-04-28T00:48:22.000Z","dependencies_parsed_at":"2024-10-28T16:11:41.504Z","dependency_job_id":"3ca0e92d-2966-48be-98d6-df0bb846cdcb","html_url":"https://github.com/MolotovCherry/anime-schedule-rs","commit_stats":null,"previous_names":["molotovcherry/anime-schedule-rs"],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/MolotovCherry%2Fanime-schedule-rs","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/MolotovCherry%2Fanime-schedule-rs/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/MolotovCherry%2Fanime-schedule-rs/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/MolotovCherry%2Fanime-schedule-rs/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/MolotovCherry","download_url":"https://codeload.github.com/MolotovCherry/anime-schedule-rs/tar.gz/refs/heads/main","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":245108187,"owners_count":20562001,"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":["anime","animeschedule","api","client","rust","schedule"],"created_at":"2024-10-11T14:34:10.753Z","updated_at":"2025-03-23T13:31:37.720Z","avatar_url":"https://github.com/MolotovCherry.png","language":"Rust","funding_links":[],"categories":[],"sub_categories":[],"readme":"# AnimeSchedule Api\n\nA complete AnimeSchedule Api v3 client implemented in Rust\n\nTo get your api keys, go to https://animeschedule.net/users/\u003cyour_username\u003e/settings/api\n\nYou can make an app without the animelist scope, but the animelists api will fail if you do so since the tokens will not have permission.\n\nFor an in depth review of their api and which endpoints require oauth2, see https://animeschedule.net/api/v3/documentation\n\nWhen using an oauth2 endpoint, you must have created an oauth2 token for the user. You can do so using the included token api\n```rust\nlet client = AnimeScheduleClientBuilder::new().client_id(\"your-id\").client_secret(\"secret\").access_token(\"your-token\").redirect_url(\"your-url\").build().unwrap();\n\n// if you want to create your token with the full scope, add scope before generating a token\nclient.auth.add_scope(Scope::new(\"animelist\"));\n\n// this requires a webserver to receive the oauth code+state for regenerate\n// set your own custom callback for production usage\nclient.auth.set_callback(|url, state| async {\n    // the url passed in is the one the client needs to navigate to\n\n    // receive the state on your webserver, compare it to the received state above\n    // to ensure it's valid and the right client. if you return wrong state, the\n    // regenerate api will fail due to security check\n\n    // get the code / state and return it\n    (AuthorizationCode::new(\"\".to_owned()), CsrfToken::new(\"\".to_owned()))\n});\n\n// When dealing with access/refresh tokens, please be aware\n// that the site api sets both to 3600\n// if you pass this threshold, you are required to regenerate the tokens\n\n// regenerate tokens from scratch\nclient.auth.regenerate().await;\n\n// if you have a refresh key, you can exchange it for an access token\nclient.auth.refresh_token().await;\n\n// you can automatically try to refresh it if access token expired\n// if no refresh token exists, it will regenerate the whole thing\nclient.auth.try_refresh().await;\n\n// you can also set the access/refresh token manually if you need to\nclient.auth.set_refresh_token_unchecked(RefreshToke::new(\"token\"));\nclient.auth.set_access_token_unchecked(AccessToken::new(\"token\"));\n// set the time from Instant::now() after which access token expires\nclient.auth.set_expires_in_unchecked(Duration::from_secs(3600));\n\n// use the api\nclient.anime().get().q(\"query\").genres(\u0026[\"action\"]).send().await;\n// if using an oauth protected endpoint, make sure you have set your token\n// with correct oauth tokens and scope first!\nclient.animelists().get().await;\nclient.animelists().put().route(\"foo\").etag(\"etag\").episodes_seen(5).note(\"I love anime\").send().await;\n\n// for more information on the api, see their api docs:\n// https://animeschedule.net/api/v3/documentation\n//\n// this api follows a builder pattern, and follows their api\n// it should be relatively intuitive to use\n```\n\nWarning: This crate may change api between versions before 1.0 as the api is fleshed out.\n\nIf you see any bugs, please report them. Mostly these may be instances \"null\" appears in the api but was assumed to always exist in the deserialized types. While this was quickly tested with a bit of data to hopefully get a complete picture, this is not guaranteed to be always correct. Other than that, it should be feature complete and working.\n\nUsage of this crate is subject to the [api tos](https://animeschedule.net/api-terms-of-use)\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fmolotovcherry%2Fanime-schedule-rs","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fmolotovcherry%2Fanime-schedule-rs","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fmolotovcherry%2Fanime-schedule-rs/lists"}