{"id":15032132,"url":"https://github.com/lordofpolls/helldive_rs","last_synced_at":"2025-04-09T21:23:01.039Z","repository":{"id":227664519,"uuid":"772067043","full_name":"LordOfPolls/helldive_rs","owner":"LordOfPolls","description":"A rust wrapper for the unofficial helldivers API","archived":false,"fork":false,"pushed_at":"2024-03-17T09:13:22.000Z","size":89,"stargazers_count":5,"open_issues_count":1,"forks_count":0,"subscribers_count":1,"default_branch":"master","last_synced_at":"2025-03-23T23:15:33.665Z","etag":null,"topics":["api-wrapper","helldivers-2","rust"],"latest_commit_sha":null,"homepage":"","language":"Rust","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/LordOfPolls.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":null,"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-03-14T13:26:30.000Z","updated_at":"2024-04-11T02:13:16.000Z","dependencies_parsed_at":"2025-02-15T21:32:40.777Z","dependency_job_id":"99e9c67d-8181-4272-8541-a57e823f4cac","html_url":"https://github.com/LordOfPolls/helldive_rs","commit_stats":null,"previous_names":["lordofpolls/helldivers.rs","lordofpolls/helldive_rs"],"tags_count":6,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/LordOfPolls%2Fhelldive_rs","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/LordOfPolls%2Fhelldive_rs/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/LordOfPolls%2Fhelldive_rs/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/LordOfPolls%2Fhelldive_rs/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/LordOfPolls","download_url":"https://codeload.github.com/LordOfPolls/helldive_rs/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":248112996,"owners_count":21049767,"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":["api-wrapper","helldivers-2","rust"],"created_at":"2024-09-24T20:17:24.732Z","updated_at":"2025-04-09T21:23:01.017Z","avatar_url":"https://github.com/LordOfPolls.png","language":"Rust","funding_links":[],"categories":[],"sub_categories":[],"readme":"# Helldive_rs 2 Rust API Wrapper\n![GitHub Release](https://img.shields.io/github/v/release/LordOfPolls/helldive_rs?label=GitHub%20Release)\n![Crates.io Version](https://img.shields.io/crates/v/helldive_rs?label=crates.io%20Version)\n![Crates.io Total Downloads](https://img.shields.io/crates/d/helldive_rs)\n![Crates.io License](https://img.shields.io/crates/l/helldive_rs)\n\n\nA Rust wrapper for the unofficial Helldivers API. This library provides an easy way to interact with the Helldivers API \nand retrieve information about wars, planets, factions, and sectors.\n\nPlease do note, the Helldivers API is unofficial and may be subject to change at any time. \nMore functions will be added as the API is reverse-engineered.\n\nThis library is not affiliated with Arrowhead Game Studios or Sony Interactive Entertainment. \nYou are strongly encouraged to use the Helldivers API responsibly \nand to take care not to overload the servers... _more than they already are._\n\n# Installation\n\nRun the following Cargo command in your project directory:\n```shell\ncargo add helldive_rs \n```\n\nOr add the following line to your Cargo.toml:\n```toml\n[dependencies]\nhelldive_rs  = \"0.5\"\n```\n\n# API Reference\n\nThe library provides the following functions:\n\n    get_status(war_id: i64, language: \u0026str) -\u003e Result\u003cStatus, HelldiversError\u003e: Get the current status of a war.\n    get_war_info(war_id: i64) -\u003e Result\u003cWarInfo, HelldiversError\u003e: Get information about a specific war.\n    get_war_time(war_id: i64) -\u003e Result\u003cWarTime, HelldiversError\u003e: Get the current time of a war.\n    get_planet_name(id: i64) -\u003e Option\u003cString\u003e: Get the name of a planet by its ID.\n    get_faction_name(id: i64) -\u003e Option\u003cString\u003e: Get the name of a faction by its ID.\n    get_sector_name(id: i64) -\u003e Option\u003cString\u003e: Get the name of a sector by its ID.\n    // utils\n    get_total_player_count(status: \u0026Status) -\u003e i64: Get the total number of players in a war.\n    get_top_planets_by_player_count(status: \u0026Status, count: usize) -\u003e Vec\u003c(\u0026PlanetStatus, i64)\u003e: Get the top planets by player count.\n    get_faction_distribution(status: \u0026Status) -\u003e Hashmap\u003ci64, i64\u003e: Get the distribution of factions.\n\n\nFor more details about the structs and their fields, please refer to the source code documentation.\n\n# Example \n\n```rust\nuse helldive_rs;\nuse helldive_rs::Language;\nuse tokio;\n\n#[tokio::main]\nasync fn main() {\n    // Get the current status of a war\n    let war_id = 801; // The war ID for the current war\n    let status = helldive_rs ::get_status(war_id, Language::English).await.unwrap();\n    println!(\"Current Message: {}\", status.global_events[0].message);\n\n    // Get information about a specific war\n    let war_info = helldive_rs ::get_war_info(war_id).await.unwrap();\n    println!(\"War Start Date: {}\", war_info.start_date);\n\n    // Get the name of a planet by ID\n    let planet_id = 0;\n    let planet_name = helldive_rs ::get_planet_name(planet_id);\n    println!(\"Planet Name: {}\", planet_name);\n\n    // Get the name of a faction by ID\n    let faction_id = 1;\n    let faction_name = helldive_rs ::get_faction_name(faction_id);\n    println!(\"Faction Name: {}\", faction_name);\n\n    // Get the name of a sector by ID\n    let sector_id = 0;\n    let sector_name = helldive_rs ::get_sector_name(sector_id);\n    println!(\"Sector Name: {}\", sector_name);\n}\n```\n\n# Contributing\n\nContributions are welcome! If you find any issues or have suggestions for improvements, please open an issue or submit a pull request on the GitHub repository.\n\n# License\n\nThis project is licensed under the MIT License.","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Flordofpolls%2Fhelldive_rs","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Flordofpolls%2Fhelldive_rs","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Flordofpolls%2Fhelldive_rs/lists"}