CLI and library for managing predictions on fatebook.io.
cargo install fatebook-rsGet your API key from fatebook.io/api-setup, then:
fatebook config --set-keyfatebook list
fatebook list --full-idsThe list output includes a shortened question ID (QID) that is unique for the current list.
Use that suffix (or the full ID) for follow-up actions.
Use --full-ids to show full question IDs.
List output is sorted by resolve date (earliest first). Use --sort to change or --no-sort to preserve API order.
# Resolve in 2 weeks, 70% confidence
fatebook new "Will I finish the project?" 0.7 --in 2w
# Resolve by specific date
fatebook new "Will it rain tomorrow?" 0.3 --by 2026-01-30fatebook show f8qsg5gk # Use QID suffix from list output
fatebook show cmkodsxi70001pe92upx89p9k # Or use full QIDfatebook resolve f8qsg5gk yes # or: no, ambiguous
fatebook resolve cmkodsxi70001pe92upx89p9k yesresolve looks up suffixes against unresolved questions only. Use the full ID if a suffix is ambiguous.
Suffix lookups are not scoped to list filters like --resolving-soon or --tag-ids.
If a suffix matches multiple questions, the CLI will list the matching full IDs; rerun the command with a longer suffix or the full ID.
fatebook edit f8qsg5gk --title "Updated question?" --note "Added context"
fatebook edit cmkodsxi70001pe92upx89p9k --note "Added context"fatebook delete f8qsg5gk
fatebook delete cmkodsxi70001pe92upx89p9kThe crate also provides an async library for use in Rust applications:
[dependencies]
fatebook-rs = { version = "0.1", default-features = false }
tokio = { version = "1", features = ["rt-multi-thread", "macros"] }use fatebook::{FatebookClient, CreateQuestionParams};
#[tokio::main]
async fn main() -> Result<(), Box<dyn std::error::Error>> {
let client = FatebookClient::new("your-api-key".into(), None);
// List questions
let questions = client.get_questions(None).await?;
for q in questions {
println!("{}: {}", q.id, q.title);
}
// Create a question
let params = CreateQuestionParams::new(
"Will this work?".into(),
"2026-12-31".into(),
0.8,
);
let created = client.create_question(params).await?;
println!("Created: {}", created.url);
Ok(())
}MIT