{"id":13636816,"url":"https://github.com/iddm/randomorg","last_synced_at":"2025-12-12T12:52:37.622Z","repository":{"id":52422366,"uuid":"95548524","full_name":"iddm/randomorg","owner":"iddm","description":"A random.org client library for Rust","archived":false,"fork":false,"pushed_at":"2023-12-05T17:49:26.000Z","size":48,"stargazers_count":8,"open_issues_count":4,"forks_count":4,"subscribers_count":1,"default_branch":"master","last_synced_at":"2024-11-09T06:38:52.584Z","etag":null,"topics":["library","random","rust"],"latest_commit_sha":null,"homepage":null,"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/iddm.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":".github/FUNDING.yml","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},"funding":{"github":"iddm"}},"created_at":"2017-06-27T10:51:44.000Z","updated_at":"2024-01-07T12:32:38.000Z","dependencies_parsed_at":"2024-08-02T00:14:52.041Z","dependency_job_id":null,"html_url":"https://github.com/iddm/randomorg","commit_stats":null,"previous_names":["iddm/randomorg","vityafx/randomorg"],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/iddm%2Frandomorg","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/iddm%2Frandomorg/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/iddm%2Frandomorg/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/iddm%2Frandomorg/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/iddm","download_url":"https://codeload.github.com/iddm/randomorg/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":225305789,"owners_count":17453450,"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":["library","random","rust"],"created_at":"2024-08-02T00:01:05.829Z","updated_at":"2025-12-12T12:52:32.575Z","avatar_url":"https://github.com/iddm.png","language":"Rust","funding_links":["https://github.com/sponsors/iddm"],"categories":["Libraries"],"sub_categories":["Cryptography"],"readme":"# random.org\n[![Build status](https://travis-ci.org/iddm/randomorg.svg?branch=master)](https://travis-ci.org/iddm/randomorg)\n[![Crates](https://img.shields.io/crates/v/randomorg.svg)](https://crates.io/crates/randomorg)\n[![Docs](https://docs.rs/randomorg/badge.svg)](https://docs.rs/randomorg)\n[![MIT licensed](https://img.shields.io/badge/license-MIT-blue.svg)](./LICENSE)\n\n\nA https://random.org client library. The randomness comes from atmospheric noise, which\nfor many purposes is better than the pseudo-random number algorithms typically used in computer\nprograms.\n\n## Status\nEverything is implemented. Note, that the [`random.org`](https://random.org) service\nAPI is at beta stage of development, however the library will try to be up-to-date.\n\n## The documentation\nThe [documentation](https://docs.rs/randomorg) which may help you using this library.\n\n## Implementation\n- Immutable interface, no need to synchronize,\nthread-safe ([`Sync`](https://doc.rust-lang.org/std/marker/trait.Sync.html) and\n[`Send`](https://doc.rust-lang.org/std/marker/trait.Send.html)).\n- No unsafe blocks.\n- [`reqwest`](https://crates.io/crates/reqwest) crate is used for performing requests.\n- [`chrono`](https://crates.io/crates/chrono) for dates.\n- [`serde`](https://crates.io/crates/serde) for serialization and deserialization.\n\n## Features\n- `rand` feature which provides the\n[`rand_core::RngCore`](https://rust-random.github.io/rand/rand_core/trait.RngCore.html)\ntrait implementation for the [`Random`](https://docs.rs/randomorg/0.5.0/randomorg/struct.Random.html)\nstruct and adds new `FallibleRandom\u003cT: rand_core::RngCore\u003e` structure\nfor better random generation UX.\n\n## Usage\nStart by creating `Random` instance and perform needed operations after.\n\n```rust\nextern crate randomorg;\n\nfn main() {\n    use randomorg::Random;\n    let r = Random::new(\"API KEY HERE\");\n    // A method-call way:\n    println!(\"Result: {:?}\", r.generate_integers(-100, 100, 15, true));\n    // A lazy request builder way:\n    let random_data = r.request_integers().min(0).max(100).limit(5).collect::\u003cVec\u003ci32\u003e\u003e();\n    println!(\"Random integers: {:?}\", random_data);\n}\n```\n\nWith the `rand` feature you can also use it that way:\n\n```rust\nextern crate randomorg;\n\nfn main() {\n    use rand_core::RngCore;\n    use randomorg::Random;\n   \n    let mut random = Random::new(\"API KEY HERE\");\n    let mut key = [0u8; 16];\n    random.fill_bytes(\u0026mut key);\n    let random_u64 = random.next_u64();\n}\n```\n\n## License\n\nThis project is\n[licensed under the MIT license](https://github.com/iddm/randomorg/blob/master/LICENSE).\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fiddm%2Frandomorg","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fiddm%2Frandomorg","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fiddm%2Frandomorg/lists"}