{"id":18301950,"url":"https://github.com/kazooki123/ripledd-api-rust","last_synced_at":"2025-04-09T09:47:13.743Z","repository":{"id":243219414,"uuid":"811769302","full_name":"Kazooki123/ripledd-api-rust","owner":"Kazooki123","description":"A API wrapper for Ripledd using Rust🦀","archived":false,"fork":false,"pushed_at":"2024-06-09T00:29:56.000Z","size":65,"stargazers_count":0,"open_issues_count":0,"forks_count":0,"subscribers_count":1,"default_branch":"main","last_synced_at":"2025-02-15T04:19:34.989Z","etag":null,"topics":["api","library","ripledd","rust","wrapper","wrapper-api"],"latest_commit_sha":null,"homepage":"","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/Kazooki123.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-06-07T09:07:18.000Z","updated_at":"2024-10-02T18:54:27.000Z","dependencies_parsed_at":"2024-06-07T12:28:40.266Z","dependency_job_id":"c4e98ec3-0132-4aa5-841f-9df7d27ffd1c","html_url":"https://github.com/Kazooki123/ripledd-api-rust","commit_stats":null,"previous_names":["kazooki123/ripledd-api-rust"],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Kazooki123%2Fripledd-api-rust","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Kazooki123%2Fripledd-api-rust/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Kazooki123%2Fripledd-api-rust/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Kazooki123%2Fripledd-api-rust/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/Kazooki123","download_url":"https://codeload.github.com/Kazooki123/ripledd-api-rust/tar.gz/refs/heads/main","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":248017995,"owners_count":21034042,"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","library","ripledd","rust","wrapper","wrapper-api"],"created_at":"2024-11-05T15:17:30.739Z","updated_at":"2025-04-09T09:47:13.717Z","avatar_url":"https://github.com/Kazooki123.png","language":"Rust","funding_links":[],"categories":[],"sub_categories":[],"readme":"# Ripledd Rust API Wrapper\n\n![Banner](docs/images/banner.png)\n\nAn API Wrapper for Ripledd API's services💫\n\nNote: This is the Rust version of the **original** Ripledd API wrapper from [Foxy](https://github.com/foxy4096)\n\n## Installation\n\nTo use the Ripledd Rust library in your project, add it as a dependency in your `Cargo.toml` file:\n\n```Ini, TOML\n[dependencies]\nripledd_api_wrapper = { git = \"https://github.com/Kazooki123/ripledd-api-rust\" }\n```\n\nThen, run `cargo build` to download and compile the library.\n\n## Usage Example\n\nHere's an example of how to use the Ripledd Rust library to create a post:\n\n```Rust\nuse ripledd_api_wrapper::RipleddClient;\n\nfn main() -\u003e Result\u003c(), reqwest::Error\u003e {\n    // Replace with your Ripledd email and password (consider using environment variables for security)\n    let email = \"your_email@example.com\";\n    let password = \"your_password\";\n\n    // Create a Ripledd client\n    let mut ripledd = RipleddClient::new(email.to_string(), password.to_string(), None);\n\n    // Create a post\n    let post_body = \"The post from the API\";\n    let response = ripledd.create_post(post_body).await?;\n\n    // Check for successful response\n    if response.status().is_success() {\n        println!(\"Post created successfully!\");\n    } else {\n        println!(\"Error creating post: {}\", response.status());\n    }\n\n    Ok(())\n}\n```\n\n## Explanation\n\n1. We import the RipleddClient struct from your ripledd_api_wrapper library.\nIn the main function, we define placeholder values for email and password (consider using environment variables for security).\n2. We create a new RipleddClient instance.\n3. We define the post content (post_body).\n4. We call create_post on the client with the post body and await the asynchronous response.\n5. We check the response status code. If successful, we print a success message. Otherwise, we print an error message with the status code.\n\n### Running the Example\n\n1. Save the code snippet above as a Rust file (e.g., demo.rs).\n2. Make sure you have Rust and Cargo installed.\n3. In your terminal, navigate to the directory where you saved `demo.rs`.\n4. Run the following command to compile and run the example:\n\n```bash\ncargo run\n```\n\nThis will build the library and execute the example code, printing the response from the Ripledd API.\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fkazooki123%2Fripledd-api-rust","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fkazooki123%2Fripledd-api-rust","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fkazooki123%2Fripledd-api-rust/lists"}