Newswrap
Hacker News API bindings for Rust.
use HackerNewsClient;
async
What is newswrap?
Newswrap provides a convenient Rust interface for the Hacker News API. Hacker News is a community-driven website targeted at software developers and technology professionals. While Hacker News offers up its API for the general public, there are no official language-based libraries for connecting to it. This project aims to provide an easy-to-use Rust-based client for retrieving data from Hacker News in an idiomatic fashion with first-class async support.
Using newswrap
To get started with newswrap within your Rust application, simply add the package,
and spin up the client at the start of your application process:
use ;
async
Under the hood, newswrap relies on https://docs.rs/reqwest/latest/reqwest/ for collecting information from the Hacker News API via HTTP. It's advised for consumers of the newswrap client to instantiate a single instance at the start of your application process. Examples are available for using clients in binary applications and web applications (with axum).