{"id":27278894,"url":"https://github.com/sigseg5/outline-api","last_synced_at":"2026-04-06T06:04:20.999Z","repository":{"id":193537560,"uuid":"688868451","full_name":"sigseg5/outline-api","owner":"sigseg5","description":"Implementation of the OutlineVPN Server Management API in Rust","archived":false,"fork":false,"pushed_at":"2023-12-03T12:53:34.000Z","size":36,"stargazers_count":12,"open_issues_count":0,"forks_count":1,"subscribers_count":1,"default_branch":"master","last_synced_at":"2025-07-12T08:41:48.455Z","etag":null,"topics":["api","api-client","outline-vpn","rust"],"latest_commit_sha":null,"homepage":"https://crates.io/crates/outline_api","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/sigseg5.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,"zenodo":null}},"created_at":"2023-09-08T09:19:20.000Z","updated_at":"2025-05-13T05:28:39.000Z","dependencies_parsed_at":"2023-12-03T13:48:04.043Z","dependency_job_id":null,"html_url":"https://github.com/sigseg5/outline-api","commit_stats":null,"previous_names":["sigseg5/outline-api"],"tags_count":3,"template":false,"template_full_name":null,"purl":"pkg:github/sigseg5/outline-api","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/sigseg5%2Foutline-api","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/sigseg5%2Foutline-api/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/sigseg5%2Foutline-api/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/sigseg5%2Foutline-api/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/sigseg5","download_url":"https://codeload.github.com/sigseg5/outline-api/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/sigseg5%2Foutline-api/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":31461534,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-04-05T21:22:52.476Z","status":"online","status_checked_at":"2026-04-06T02:00:07.287Z","response_time":112,"last_error":null,"robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":true,"can_crawl_api":true,"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","api-client","outline-vpn","rust"],"created_at":"2025-04-11T17:19:58.168Z","updated_at":"2026-04-06T06:04:20.985Z","avatar_url":"https://github.com/sigseg5.png","language":"Rust","funding_links":[],"categories":[],"sub_categories":[],"readme":"# outline-api\n\nThis package implements [OutlineVPN](https://getoutline.org) Management API.\n\n[![License](https://img.shields.io/badge/license-MIT-blue.svg)](https://opensource.org/licenses/MIT)\n[![Rust](https://img.shields.io/badge/rust-1.70%2B-blue.svg)](https://github.com/rust-lang/rust)\n\n## Installation\n\nTo use this package, you'll need to have Rust and Cargo installed on your system. Once you have them, you can add this package to your application by running the following command:\n\n```bash\ncargo add outline-api\n```\n\n## Usage\n\nYou can use this lib to build your own OutlineVPN management app like this:\n\n### main.rs\n\n```rust\nextern crate toml;\n\nuse std::{fs, io, time::Duration};\nuse toml::Value;\n\nfn main() {\n    let toml_str = fs::read_to_string(\"config.toml\").expect(\"Failed to read config file\");\n\n    let toml_value: Value = toml::from_str(\u0026toml_str).expect(\"Failed to parse config.toml\");\n\n    let server_section = toml_value\n        .get(\"server\")\n        .expect(\"Missing [server] section\")\n        .as_table()\n        .expect(\"[server] section should be a table\");\n\n    let cert_sha256 = server_section\n        .get(\"cert_sha256\")\n        .and_then(Value::as_str)\n        .expect(\"Missing or invalid cert_sha256\");\n\n    let api_url = server_section\n        .get(\"api_url\")\n        .and_then(Value::as_str)\n        .expect(\"Missing or invalid api_url\");\n\n    let request_timeout = server_section\n        .get(\"request_timeout_in_sec\")\n        .and_then(|timeout| timeout.as_integer())\n        .map(|timeout_secs| Duration::from_secs(timeout_secs as u64))\n        .expect(\"Missing or invalid request_timeout\");\n\n    let vpn = outline_api::new(cert_sha256, api_url, Some(request_timeout));\n\n    match vpn.get_server_info() {\n        Ok(info) =\u003e println!(\"Server info: {}\", info),\n        Err(err) =\u003e eprintln!(\"Error getting server info: {}\", err),\n    }\n\n    let raw_id = get_user_input(\"Provide user ID:\");\n    match raw_id.parse::\u003cu16\u003e() {\n        Ok(id) =\u003e match vpn.delete_access_key_by_id(\u0026id) {\n            Ok(info) =\u003e println!(\"response: {:?}\\n\", info),\n            Err(err) =\u003e {\n                eprintln!(\"Error delete_access_key_by_id: {}\", err)\n            }\n        },\n        Err(_) =\u003e {\n            eprintln!(\"Failed to parse the ID input as number (u16)\");\n        }\n    }\n\n    fn get_user_input(prompt: \u0026str) -\u003e String {\n        println!(\"{}\", prompt);\n        let mut input = String::new();\n        io::stdin()\n            .read_line(\u0026mut input)\n            .expect(\"Failed to read line\");\n        input.trim().to_string()\n    }\n}\n```\n\n## config.toml\n\n```toml\n[server]\ncert_sha256 = \"CERT_SHA256\" # like E2DE8...2A75D\napi_url = \"https://\u003cIP_ADDR\u003e:\u003cPORT\u003e/\u003cSECRET\u003e\"\nrequest_timeout_in_sec = 5\n```\n\n## Outline API\n\nThis is some important note about OutlineVPN API:\n\n- The official version of the API (see [api.yml](/api.yml)) is not quite right.\n- In fact, the `/access-keys/\u003cID\u003e` endpoint is not available on the server.\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fsigseg5%2Foutline-api","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fsigseg5%2Foutline-api","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fsigseg5%2Foutline-api/lists"}