MCPcopy Index your code
hub / github.com/Aurora0001/rawr

github.com/Aurora0001/rawr @v0.1.1

Chat with this repo
repository ↗ · DeepWiki ↗ · release v0.1.1 ↗ · + Follow
225 symbols 367 edges 22 files 105 documented · 47% updated 8y agov0.1.1 · 2016-08-03★ 329 open issues
What it actually does AI analysis from the code graph — generated when you open this
loading…
README

rawr

Build Status Gitter Documentation Crates.io

Welcome to rawr, the Rust API Wrapper for Reddit. This library provides simple, pain-free access to the Reddit API in Rust. If you want to create a Reddit bot, scrape data from the API or create a web application powered by Reddit's API, rawr can help to do this simply and effectively.

Features

  • Support for password-based authentication (with OAuth support, so your app is future-proof!) and anonymous authentication.
  • Iterable post and comment listings that automatically fetch data from the API as necessary.
  • 'Streams' to fetch the latest threads/comments/messages that update automatically by polling the API - ideal for bots that react to new posts.

Examples

extern crate rawr;
use rawr::prelude::*;

fn main() {
    // Creates a new client to access the reddit API. You need to set a user agent so Reddit knows
    // who is using this client.
    let client = RedditClient::new("your user agent here", AnonymousAuthenticator::new());
    // Access the subreddit /r/rust.
    let subreddit = client.subreddit("rust");
    // Gets the hot listing of /r/rust. If the API request fails, we will panic with `expect`.
    let mut hot_listing = subreddit.hot(ListingOptions::default()).expect("Could not fetch post listing!");
    // Iterates through the top 50 posts of /r/rust. If you do not `take(n)`, this iterator will
    // continue forever!
    for post in hot_listing.take(50) {
        println!("{}", post.title());
    }
}

Extension points exported contracts — how you extend this code

Core symbols most depended-on inside this repo

Shape

Method 185
Class 22
Interface 13
Enum 3
Function 2

Languages

Rust100%

Modules by API surface

src/structures/submission.rs54 symbols
src/structures/comment.rs34 symbols
src/structures/messages.rs30 symbols
src/structures/subreddit.rs20 symbols
src/client/mod.rs17 symbols
src/traits/mod.rs16 symbols
src/structures/user.rs12 symbols
src/auth/mod.rs10 symbols
src/structures/comment_list.rs9 symbols
src/options/mod.rs9 symbols
src/structures/listing.rs8 symbols
src/errors/mod.rs4 symbols

For agents

$ claude mcp add rawr \
  -- python -m otcore.mcp_server <graph>

⬇ download graph artifact

Ask about this repo answers extend the page