| Crates.io | stack-overflow-client |
| lib.rs | stack-overflow-client |
| version | 0.1.1 |
| created_at | 2023-05-27 21:37:23.272647+00 |
| updated_at | 2023-05-27 23:19:46.821063+00 |
| description | An unofficial client for the Stack Exchange API |
| homepage | |
| repository | https://github.com/camerondurham/stack-overflow-client |
| max_upload_size | |
| id | 876131 |
| size | 65,944 |
A feature incomplete Stack website (as in Stack Overflow) api wrapper for fun and no profit.
Create a default client (for the StackOverflow site) and query for featured questions.
let client = StackClient::new();
let results = client
.get_featured_questions("docker")
.await
.expect("Unable to fetch featured docker questions");
dbg!(&results);
Create a client specifically for the Meta Stack Exchange Site and query for featured API questions.
let client = StackClientBuilder::new()
.stack_site(StackSite::Meta)
.version(ApiVersion::V2_3)
.build();
let results = client
.get_featured_questions("api")
.await
.expect("Unable to fetch featured api questions");
dbg!(&results);